File ktrip.spec of Package ktrip
# spec file for ktrip
#
# Copyright (c) 2021 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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.
%bcond_with lang
Name: ktrip
Version: 22.04
Release: 0
License: GPL-3.0-only
Summary: Public Transport Assistance for Mobile Devices
Url: https://invent.kde.org/utilities/ktrip
Source0: ktrip-%{version}.tar.xz
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: cmake
BuildRequires: fdupes
BuildRequires: AppStream
BuildRequires: extra-cmake-modules
BuildRequires: hicolor-icon-theme
BuildRequires: update-desktop-files
BuildRequires: cmake(Qt5Core)
BuildRequires: cmake(Qt5Gui)
BuildRequires: cmake(Qt5Qml)
BuildRequires: cmake(Qt5Quick)
BuildRequires: cmake(Qt5QuickControls2)
BuildRequires: cmake(Qt5Widgets)
BuildRequires: cmake(KF5CoreAddons)
BuildRequires: cmake(KF5I18n)
BuildRequires: cmake(KF5ItemModels)
BuildRequires: cmake(KF5Config)
BuildRequires: cmake(KF5Contacts)
BuildRequires: cmake(KF5ItemModels)
BuildRequires: cmake(KF5QQC2DesktopStyle)
BuildRequires: cmake(KPublicTransport)
Requires: kirigami2
Requires: kirigami-addons-dateandtime
Requires: kitemmodels-imports
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
KTrip is a public transport assistant targeted towards
mobile Linux and Android. It allows to query journeys
for a wide range of countries/public transport providers
by leveraging KPublicTransport.
%lang_package
%prep
%setup -q -n ktrip-%{version}
%build
%cmake_kf5 -d build
%cmake_build
%install
%kf5_makeinstall -C build
%kf5_post_install
%fdupes %{buildroot}%{_prefix}
%if %{with lang}
%find_lang %{name}
%endif
%if %{with lang}
%files lang -f %{name}.lang
%endif
%files
%defattr(-,root,root,-)
%doc README.md
%license LICENSES/*
%{_kf5_bindir}/%{name}
%{_kf5_applicationsdir}/*.desktop
%{_kf5_appstreamdir}/*.appdata.xml
%{_kf5_iconsdir}/*/*/*/*.{svg}
%changelog