File dtk6systemsettings.spec of Package dtk6systemsettings
#
# spec file for package dtk6systemsettings
#
# Copyright (c) 2024 SUSE LLC
#
# 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 6
Name: dtk6systemsettings
Version: 6.0.2
Release: 0
Summary: Development Tool Kit System Settings
License: LGPL-3.0-or-later
Group: System/GUI/Other
URL: https://github.com/linuxdeepin/dtk6systemsetting
Source0: https://github.com/linuxdeepin/dtk6systemsettings/archive/%{version}/%{name}-%{version}.tar.gz
BuildRequires: doxygen
BuildRequires: gtest
BuildRequires: gmock
BuildRequires: cmake(Qt6ToolsTools)
BuildRequires: pkgconfig(dtk6core)
BuildRequires: pkgconfig(libcrypt)
BuildRequires: pkgconfig(Qt6Core)
BuildRequires: pkgconfig(Qt6DBus)
BuildRequires: pkgconfig(Qt6Xml)
%if 0%{?suse_version} < 1600
BuildRequires: gcc13-c++
%endif
%description
Qt-based development library for system settings on Deepin.
%package -n lib%{name}%{sover}
Summary: Dtk6systemsettings libraries
Group: System/Libraries
%description -n lib%{name}%{sover}
Qt-based development library for system settings on Deepin.
%package devel
Summary: Development tools for dtk6systemsettings
Group: Development/Languages/C and C++
Requires: lib%{name}%{sover} = %{version}
%description devel
The dtk6systemsettings-devel package contains the header files and developer docs for
dtk6gui.
%prep
%autosetup -p1
%build
%if 0%{?suse_version} < 1600
export CXX=g++-13
%endif
%cmake -DDTK_VERSION=%{version}
%cmake_build
%install
%cmake_install
%check
%post -n lib%{name}%{sover} -p /sbin/ldconfig
%postun -n lib%{name}%{sover} -p /sbin/ldconfig
%files -n lib%{name}%{sover}
%{_libdir}/lib%{name}.so.*
%files devel
%doc README.md README.zh_CN.md
%license LICENSE
%{_libdir}/lib%{name}.so
%{_libdir}/qt6/qt_lib_%{name}.pri
%{_libdir}/cmake/Dtk6SystemSettings
%{_libdir}/pkgconfig/%{name}.pc
%dir %{_includedir}/dtk6
%{_includedir}/dtk6/DSystemSettings
%dir %{_datadir}/qt6/doc
%{_datadir}/qt6/doc/%{name}.qch
%changelog