File skrooge.spec of Package skrooge

#
# spec file for package skrooge
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2008 - 2012 Sascha Manns <saigkill@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 kf5_version 5.86.0
%define qt5_version 5.15.2

Name:           skrooge
Version:        2.25.0
Release:        0
Summary:        A Personal Finance Management Tool
License:        GPL-3.0-only
Group:          Productivity/Office/Finance
URL:            https://www.skrooge.org/
Source:         https://download.kde.org/stable/skrooge/%{name}-%{version}.tar.xz
%if %{with released}
Source1:        https://download.kde.org/stable/skrooge/%{name}-%{version}.tar.xz.sig
Source2:        skrooge.keyring
%endif
BuildRequires:  breeze5-icons
BuildRequires:  extra-cmake-modules >= %{kf5_version}
BuildRequires:  fdupes
BuildRequires:  hicolor-icon-theme
BuildRequires:  libQt5Sql-private-headers-devel
BuildRequires:  libofx-devel
BuildRequires:  libxslt-tools
BuildRequires:  shared-mime-info
BuildRequires:  sqlcipher-devel
BuildRequires:  sqlite-devel
BuildRequires:  cmake(Grantlee5)
BuildRequires:  cmake(KF5Activities) >= %{kf5_version}
BuildRequires:  cmake(KF5Archive) >= %{kf5_version}
BuildRequires:  cmake(KF5Completion) >= %{kf5_version}
BuildRequires:  cmake(KF5Config) >= %{kf5_version}
BuildRequires:  cmake(KF5ConfigWidgets) >= %{kf5_version}
BuildRequires:  cmake(KF5CoreAddons) >= %{kf5_version}
BuildRequires:  cmake(KF5DBusAddons) >= %{kf5_version}
BuildRequires:  cmake(KF5DesignerPlugin) >= %{kf5_version}
BuildRequires:  cmake(KF5DocTools) >= %{kf5_version}
BuildRequires:  cmake(KF5GuiAddons) >= %{kf5_version}
BuildRequires:  cmake(KF5I18n) >= %{kf5_version}
BuildRequires:  cmake(KF5IconThemes) >= %{kf5_version}
BuildRequires:  cmake(KF5ItemViews) >= %{kf5_version}
BuildRequires:  cmake(KF5JobWidgets) >= %{kf5_version}
BuildRequires:  cmake(KF5KIO) >= %{kf5_version}
BuildRequires:  cmake(KF5NewStuff) >= %{kf5_version}
BuildRequires:  cmake(KF5Notifications) >= %{kf5_version}
BuildRequires:  cmake(KF5NotifyConfig) >= %{kf5_version}
BuildRequires:  cmake(KF5Parts) >= %{kf5_version}
BuildRequires:  cmake(KF5Runner) >= %{kf5_version}
BuildRequires:  cmake(KF5Wallet) >= %{kf5_version}
BuildRequires:  cmake(KF5WidgetsAddons) >= %{kf5_version}
BuildRequires:  cmake(KF5XmlGui) >= %{kf5_version}
BuildRequires:  cmake(Qca-qt5)
BuildRequires:  cmake(Qt5Concurrent) >= %{qt5_version}
BuildRequires:  cmake(Qt5Core) >= %{qt5_version}
BuildRequires:  cmake(Qt5DBus) >= %{qt5_version}
BuildRequires:  cmake(Qt5Designer) >= %{qt5_version}
BuildRequires:  cmake(Qt5PrintSupport) >= %{qt5_version}
BuildRequires:  cmake(Qt5Qml) >= %{qt5_version}
BuildRequires:  cmake(Qt5QuickControls2) >= %{qt5_version}
BuildRequires:  cmake(Qt5QuickWidgets) >= %{qt5_version}
BuildRequires:  cmake(Qt5Script) >= %{qt5_version}
BuildRequires:  cmake(Qt5XmlPatterns) >= %{qt5_version}
BuildRequires:  cmake(Qt5Sql) >= %{qt5_version}
BuildRequires:  cmake(Qt5Svg) >= %{qt5_version}
BuildRequires:  cmake(Qt5Test) >= %{qt5_version}
BuildRequires:  cmake(Qt5WebEngineWidgets) >= %{qt5_version}
BuildRequires:  cmake(Qt5Widgets) >= %{qt5_version}
Requires:       hicolor-icon-theme
%ifnarch %{ix86} x86_64 %{arm} aarch64
ExclusiveArch:  do_not_build
%endif

%description
Skrooge allows managing personal finances, powered by KDE.
It has many features and can be used to enter, follow, and
analyze expenses.

%lang_package

%prep
%autosetup -p1

%build
%cmake_kf5 -- -DSKG_WEBENGINE=ON -DSKG_WEBKIT=OFF

%cmake_build

%install
%kf5_makeinstall

%find_lang %{name} --with-kde
%{kf5_find_htmldocs}

%fdupes -s %{buildroot}

%{kf5_post_install}

# E: env-script-interpreter
sed -i 's#env python3#python3#' %{buildroot}%{_kf5_sharedir}/skrooge/*.py

%ldconfig_scriptlets

%files
%license COPYING
%doc CHANGELOG README.md AUTHORS
%doc %lang(en) %{_kf5_htmldir}/en/skrooge/
%dir %{_kf5_iconsdir}/breeze
%dir %{_kf5_iconsdir}/breeze-dark
%dir %{_kf5_iconsdir}/breeze-dark/actions
%dir %{_kf5_iconsdir}/breeze-dark/actions/22
%dir %{_kf5_iconsdir}/breeze/actions
%dir %{_kf5_iconsdir}/breeze/actions/22
%dir %{_kf5_iconsdir}/hicolor/512x512
%dir %{_kf5_iconsdir}/hicolor/512x512/actions
%dir %{_kf5_iconsdir}/hicolor/512x512/apps
%dir %{_kf5_iconsdir}/hicolor/512x512/mimetypes
%dir %{_kf5_sharedir}/config.kcfg
%{_kf5_appstreamdir}/org.kde.%{name}.appdata.xml
%{_kf5_bindir}/%{name}*
%{_kf5_iconsdir}/breeze*/actions/22/*.svgz
%{_kf5_iconsdir}/hicolor/*/*/%{name}*.svgz
%{_kf5_iconsdir}/hicolor/*/*/skg*.svgz
%{_kf5_iconsdir}/hicolor/*/actions/*.png
%{_kf5_iconsdir}/hicolor/*/apps/*.png
%{_kf5_iconsdir}/hicolor/*/mimetypes/*.png
%{_kf5_iconsdir}/hicolor/*/mimetypes/*.svgz
%{_kf5_knsrcfilesdir}/skrooge_monthly.knsrc
%{_kf5_knsrcfilesdir}/skrooge_unit.knsrc
%{_kf5_kxmlguidir}/*
%{_kf5_libdir}/libskgbankgui.so.*
%{_kf5_libdir}/libskgbankmodeler.so.*
%{_kf5_libdir}/libskgbasegui.so.*
%{_kf5_libdir}/libskgbasemodeler.so.*
%{_kf5_notifydir}/%{name}.notifyrc
%{_kf5_plugindir}/designer/libskgbankguidesigner.so
%{_kf5_plugindir}/designer/libskgbaseguidesigner.so
%{_kf5_plugindir}/grantlee/
%{_kf5_plugindir}/skg_gui/
%{_kf5_plugindir}/skrooge/
%{_kf5_plugindir}/sqldrivers/libskgsqlcipher.so
%{_kf5_servicesdir}/org.kde.*
%{_kf5_servicesdir}/sources/
%{_kf5_servicetypesdir}/org.kde.*
%{_kf5_sharedir}/%{name}
%{_kf5_sharedir}/applications/org.kde.%{name}.desktop
%{_kf5_sharedir}/config.kcfg/skg*.kcfg
%{_kf5_sharedir}/mime/packages/x-skg.xml

%files lang -f %{name}.lang

%changelog
openSUSE Build Service is sponsored by