File khelpcenter5.spec of Package khelpcenter5
#
# spec file for package khelpcenter5
#
# Copyright (c) 2018 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.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%bcond_without lang
%define kf5_version 5.26.0
# Latest stable Applications (e.g. 17.08 in KA, but 17.11.80 in KUA)
%{!?_kapp_version: %global _kapp_version %(echo %{version}| awk -F. '{print $1"."$2}')}
Name: khelpcenter5
Version: 18.04.3
Release: 0
Summary: KDE Documentation Application
License: GPL-2.0-or-later
Group: Productivity/Other
Url: http://www.kde.org
Source: khelpcenter-%{version}.tar.xz
# PATCH-FIX-OPENSUSE khelpcenter-fallback-to-kde4-docs.patch -- allow khelpcenter to see into kde4 documentation
Patch2: khelpcenter-fallback-to-kde4-docs.patch
BuildRequires: extra-cmake-modules >= 1.3.0
BuildRequires: grantlee5-devel
BuildRequires: kf5-filesystem
BuildRequires: libxapian-devel
BuildRequires: update-desktop-files
BuildRequires: cmake(KF5Config)
BuildRequires: cmake(KF5CoreAddons)
BuildRequires: cmake(KF5DBusAddons)
BuildRequires: cmake(KF5I18n)
BuildRequires: cmake(KF5Init)
BuildRequires: cmake(KF5KCMUtils)
BuildRequires: cmake(KF5KDELibs4Support)
BuildRequires: cmake(KF5KHtml)
BuildRequires: cmake(KF5Service)
BuildRequires: cmake(Qt5DBus) >= 5.4.0
BuildRequires: cmake(Qt5Widgets) >= 5.4.0
BuildRequires: cmake(Qt5Xml) >= 5.4.0
# khelpcenter uses some images and stylesheets from kdoctools (boo#1011094)
Requires: kdoctools
Provides: suse_help_viewer
Conflicts: kdebase4-runtime < 17.04.1
%if %{with lang}
Recommends: %{name}-lang
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Application to show KDE Applications' documentation.
%if %{with lang}
%lang_package
%endif
%prep
%setup -q -n khelpcenter-%{version}
%patch2 -p1
%build
%cmake_kf5 -d build -- -DCMAKE_INSTALL_LOCALEDIR=share/locale/kf5
%make_jobs
%install
%kf5_makeinstall -C build
%if %{with lang}
%kf5_find_lang
%kf5_find_htmldocs
%endif
%suse_update_desktop_file org.kde.Help Documentation Viewer
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%doc COPYING* README*
%config %{_kf5_configdir}/khelpcenter.categories
%doc %lang(en) %{_kf5_htmldir}/en/*/
%{_kf5_applicationsdir}/org.kde.Help.desktop
%{_kf5_appstreamdir}/org.kde.Help.appdata.xml
%{_kf5_bindir}/khelpcenter
%{_kf5_configkcfgdir}/
%{_kf5_libdir}/libexec/
%{_kf5_libdir}/libkdeinit5_khelpcenter.so
%{_kf5_servicesdir}/
%{_kf5_sharedir}/kde4/
%{_kf5_sharedir}/khelpcenter/
%{_kf5_sharedir}/kxmlgui5/
%if %{with lang}
%files lang -f %{name}.lang
%doc COPYING*
%endif
%changelog