-%define kdeappsver 21.08.0
+#
+# Conditional build:
+%bcond_with tests # build with tests
+%define kdeappsver 22.04.1
%define kframever 5.56.0
%define qtver 5.9.0
%define kaname kalgebra
Summary: Kalgebra
Name: ka5-%{kaname}
-Version: 21.08.0
+Version: 22.04.1
Release: 1
License: GPL v2+/LGPL v2.1+
Group: X11/Libraries
Source0: http://download.kde.org/stable/release-service/%{kdeappsver}/src/%{kaname}-%{version}.tar.xz
-# Source0-md5: ba7fdda5d8df9a77a4613e95f01e82a6
+# Source0-md5: 811f4e91c1fcd2f212b02154f9c897d9
URL: http://www.kde.org/
BuildRequires: Qt5Core-devel
BuildRequires: Qt5Core-devel >= %{qtver}
BuildRequires: Qt5Quick-devel
BuildRequires: Qt5Svg-devel
BuildRequires: Qt5Test-devel
-BuildRequires: Qt5WebEngine-devel
+BuildRequires: Qt5WebEngine-devel >= 5.15.5
BuildRequires: Qt5Widgets-devel >= 5.11.1
BuildRequires: Qt5Xml-devel
BuildRequires: cmake >= 2.8.12
and code completion.
%description -l pl.UTF-8
-KAlgebra jest wszechstronnym kalkulatorem, pozwalającym rysować
-różne typy funkcji dwu- i trójwymiarowych i przeliczać łatwe (i nie tylko)
-operacje matematycze, jak dodawanie, funkcje trygonometryczne i pochodne.
+KAlgebra jest wszechstronnym kalkulatorem, pozwalającym rysować różne
+typy funkcji dwu- i trójwymiarowych i przeliczać łatwe (i nie tylko)
+operacje matematycze, jak dodawanie, funkcje trygonometryczne i
+pochodne.
-Aplikacja została pomyślana tak, aby była stopniowo rozumiana przez studentów.
-Język jest głęboko zintegrowany z interfejsem użykownika, dostarczając słownik
-z reprezentacją wszystkich dostępnych operacji, a także podświetlanie kodu
-i podpowiadanie dopełnień.
+Aplikacja została pomyślana tak, aby była stopniowo rozumiana przez
+studentów. Język jest głęboko zintegrowany z interfejsem użykownika,
+dostarczając słownik z reprezentacją wszystkich dostępnych operacji, a
+także podświetlanie kodu i podpowiadanie dopełnień.
%prep
%setup -q -n %{kaname}-%{version}
cd build
%cmake \
-G Ninja \
+ %{!?with_tests:-DBUILD_TESTING=OFF} \
-DHTML_INSTALL_DIR=%{_kdedocdir} \
-DKDE_INSTALL_USE_QT_SYS_PATHS=ON \
..
%ninja_build
+%if %{with tests}
+ctest
+%endif
+
+
%install
rm -rf $RPM_BUILD_ROOT
%ninja_install -C build
%attr(755,root,root) %{_bindir}/calgebra
%attr(755,root,root) %{_bindir}/kalgebra
%attr(755,root,root) %{_bindir}/kalgebramobile
-%{_desktopdir}/org.kde.kalgebra.desktop
%{_desktopdir}/org.kde.kalgebramobile.desktop
%{_iconsdir}/hicolor/64x64/apps/kalgebra.png
%{_iconsdir}/hicolor/scalable/apps/kalgebra.svgz
+%{_datadir}/metainfo/org.kde.kalgebramobile.appdata.xml
+%{_desktopdir}/org.kde.kalgebra.desktop
%{_datadir}/katepart5/syntax/kalgebra.xml
%{_datadir}/kservices5/graphsplasmoid.desktop
%{_datadir}/metainfo/org.kde.kalgebra.appdata.xml
-%{_datadir}/metainfo/org.kde.kalgebramobile.appdata.xml
-%dir %{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid
-%dir %{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid/contents
-%dir %{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid/contents/ui
-%{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid/contents/ui/config.ui
-%{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid/contents/ui/main.qml
-%{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid/metadata.desktop
+%{_datadir}/plasma/plasmoids/org.kde.graphsplasmoid