90 lines
2.5 KiB
RPMSpec
90 lines
2.5 KiB
RPMSpec
|
|
%define qt6_version 6.8.0
|
|
|
|
%define rname kunitconversion
|
|
|
|
# Full KF6 version (e.g. 6.22.0)
|
|
%{!?_kf6_version: %global _kf6_version %{version}}
|
|
|
|
Name: kf6-kunitconversion
|
|
Version: 6.22.0
|
|
Release: 0
|
|
Summary: Tool for converting physical units
|
|
License: LGPL-2.1-or-later
|
|
URL: https://www.kde.org
|
|
Source: https://download.kde.org/stable/frameworks/6.22/%{rname}-%{version}.tar.xz
|
|
|
|
BuildRequires: fdupes
|
|
BuildRequires: kf6-extra-cmake-modules >= %{_kf6_version}
|
|
BuildRequires: cmake(KF6I18n) >= %{_kf6_version}
|
|
BuildRequires: cmake(Qt6Core) >= %{qt6_version}
|
|
BuildRequires: cmake(Qt6Network) >= %{qt6_version}
|
|
BuildRequires: cmake(Qt6ToolsTools) >= %{qt6_version}
|
|
BuildRequires: qt6-qttools
|
|
BuildRequires: qt6-doctools
|
|
BuildRequires: qt6-linguist
|
|
BuildRequires: python3 >= 3.9
|
|
BuildRequires: python3-devel >= 3.9
|
|
BuildRequires: python3-build
|
|
BuildRequires: python3-setuptools
|
|
BuildRequires: python3-wheel
|
|
BuildRequires: cmake(Shiboken6)
|
|
BuildRequires: cmake(PySide6)
|
|
# /SECTION
|
|
|
|
%description
|
|
KUnitConversion provides functions to convert values in different physical
|
|
units. It supports converting different prefixes (e.g. kilo, mega, giga) as
|
|
well as converting between different unit systems (e.g. liters, gallons).
|
|
|
|
%package devel
|
|
Summary: Converting physical units: Build Environment
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
Requires: cmake(Qt6Core) >= %{qt6_version}
|
|
|
|
%description devel
|
|
KUnitConversion provides functions to convert values in different physical
|
|
units. It supports converting different prefixes (e.g. kilo, mega, giga) as
|
|
well as converting between different unit systems (e.g. liters, gallons).
|
|
Development files.
|
|
|
|
%prep
|
|
%autosetup -p1 -n %{rname}-%{version}
|
|
|
|
%build
|
|
%cmake_kf6 \
|
|
-DBUILD_PYTHON_BINDINGS=OFF
|
|
|
|
%kf6_build
|
|
|
|
%install
|
|
%kf6_install
|
|
|
|
# todo: fix the name error.
|
|
# Avoid illegal package names
|
|
rm -rf $RPM_BUILD_ROOT%{_datadir}/locale/*@*
|
|
rm -rf $RPM_BUILD_ROOT%{_datadir}/locale/en_GB/
|
|
# Use langpacks macro to auto-split translations
|
|
%find_lang %{name} --with-qt --all-name --generate-subpackages
|
|
|
|
%fdupes %{buildroot}
|
|
|
|
|
|
%files
|
|
%license LICENSES/*
|
|
%doc README.md
|
|
%{_kf6_debugdir}/kunitconversion.categories
|
|
%{_kf6_libdir}/libKF6UnitConversion.so.*
|
|
|
|
%files devel
|
|
%{_kf6_includedir}/KUnitConversion/
|
|
%{_kf6_cmakedir}/KF6UnitConversion/
|
|
%{_kf6_libdir}/libKF6UnitConversion.so
|
|
|
|
%if %{with kde_python_bindings}
|
|
%files -n python3-kf6-kunitconversion
|
|
%{mypython_sitearch}/*.so
|
|
%endif
|
|
|
|
%changelog
|