File util-dfm.spec of Package util-dfm
#
# spec file for package util-dfm
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2023 Hillwood Yang <hillwood@opensuse.org>
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define sover 1
%define dtkver 6
Name: util-dfm
Version: 1.3.39
Release: 0
Summary: Toolkit of dfm
License: GPL-3.0-or-later
Group: System/GUI/Other
URL: https://github.com/linuxdeepin/util-dfm
Source0: https://github.com/linuxdeepin/util-dfm/archive/%{version}/%{name}-%{version}.tar.gz
# PATCH-FIX-UPSTREAM fix-boost-link.patch hillwood@opensuse.org - Make sure boost library can be found
# Patch0: fix-boost-link.patch
BuildRequires: boost-devel
%if 0%{?suse_version} <= 1600
BuildRequires: libboost_system-devel
%endif
BuildRequires: libboost_atomic-devel
BuildRequires: libboost_filesystem-devel
BuildRequires: chrpath
BuildRequires: gtest
BuildRequires: pkgconfig(dtk6core)
BuildRequires: pkgconfig(Qt6Core)
BuildRequires: pkgconfig(Qt6Concurrent)
BuildRequires: pkgconfig(Qt6DBus)
BuildRequires: pkgconfig(Qt6Widgets)
BuildRequires: pkgconfig(Qt6Xml)
BuildRequires: pkgconfig(udisks2)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(gio-2.0)
BuildRequires: pkgconfig(gobject-2.0)
BuildRequires: pkgconfig(gio-unix-2.0)
BuildRequires: pkgconfig(libsecret-1)
BuildRequires: pkgconfig(libisoburn-1)
BuildRequires: pkgconfig(libmediainfo)
BuildRequires: pkgconfig(liblucene++)
%if 0%{?suse_version} < 1600
BuildRequires: gcc13-c++
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
A Toolkits of libdfm-io, libdfm-mount and libdfm-burn,developed by UnionTech
Software Technology Co., Ltd
%package -n libdfm%{dtkver}-burn%{sover}
Summary: The dfm-burn libraries
Group: System/Libraries
%description -n libdfm%{dtkver}-burn%{sover}
A Toolkit of libdfm-burn.
%package -n libdfm%{dtkver}-io%{sover}
Summary: The dfm-io libraries
Group: System/Libraries
%description -n libdfm%{dtkver}-io%{sover}
A Toolkit of libdfm-io.
%package -n libdfm%{dtkver}-mount%{sover}
Summary: The dfm-mount libraries
Group: System/Libraries
%description -n libdfm%{dtkver}-mount%{sover}
A Toolkit of libdfm-mount.
%package -n libdfm%{dtkver}-search%{sover}
Summary: The dfm-search libraries
Group: System/Libraries
%description -n libdfm%{dtkver}-search%{sover}
A Toolkit of libdfm-search.
%package -n dfm%{dtkver}-devel
Summary: Development tools for dfm
Group: Development/Languages/C and C++
Requires: libdfm%{dtkver}-burn%{sover} = %{version}
Requires: libdfm%{dtkver}-io%{sover} = %{version}
Requires: libdfm%{dtkver}-mount%{sover} = %{version}
Requires: libdfm%{dtkver}-search%{sover} = %{version}
%description -n dfm%{dtkver}-devel
The dfm%{dtkver}-devel package contains the header files and developer
docs for util-dfm.
%prep
%autosetup -p1
%build
%if 0%{?suse_version} < 1600
export CXX=g++-13
%endif
%cmake
%cmake_build
%install
%cmake_install
%post -n libdfm%{dtkver}-burn%{sover} -p /sbin/ldconfig
%postun -n libdfm%{dtkver}-burn%{sover} -p /sbin/ldconfig
%post -n libdfm%{dtkver}-io%{sover} -p /sbin/ldconfig
%postun -n libdfm%{dtkver}-io%{sover} -p /sbin/ldconfig
%post -n libdfm%{dtkver}-mount%{sover} -p /sbin/ldconfig
%postun -n libdfm%{dtkver}-mount%{sover} -p /sbin/ldconfig
%post -n libdfm%{dtkver}-search%{sover} -p /sbin/ldconfig
%postun -n libdfm%{dtkver}-search%{sover} -p /sbin/ldconfig
%files
%doc README.md README.zh_CN.md
%license LICENSE
%{_libexecdir}/dfm6-search-client
%files -n libdfm%{dtkver}-burn%{sover}
%{_libdir}/libdfm%{dtkver}-burn.so.*
%files -n libdfm%{dtkver}-io%{sover}
%{_libdir}/libdfm%{dtkver}-io.so.*
%files -n libdfm%{dtkver}-mount%{sover}
%{_libdir}/libdfm%{dtkver}-mount.so.*
%files -n libdfm%{dtkver}-search%{sover}
%{_libdir}/libdfm%{dtkver}-search.so.*
%files -n dfm%{dtkver}-devel
%{_includedir}/dfm%{dtkver}-*
%{_libdir}/libdfm%{dtkver}-*.so
%{_libdir}/pkgconfig/dfm%{dtkver}-*.pc
%{_libdir}/cmake/dfm%{dtkver}-*
%changelog