File lxqt-policykit.spec of Package lxqt-policykit
#
# spec file for package lxqt-policykit
#
# Copyright (c) 2017 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/
#
%define _qtver 5.10.0
Name: lxqt-policykit
Version: @SERVICE@
Release: 0
Summary: PolicyKit authentication agent
License: LGPL-2.1+
Group: System/GUI/LXQt
Url: http://www.lxqt.org
Source: %{name}-%{version}.tar.xz
BuildRequires: cmake >= 3.0.2
BuildRequires: gcc-c++
BuildRequires: lxqt-build-tools
BuildRequires: pkgconfig
BuildRequires: cmake(KF5WindowSystem)
BuildRequires: pkgconfig(Qt5UiTools) >= %{_qtver}
BuildRequires: pkgconfig(Qt5Xdg)
BuildRequires: pkgconfig(lxqt)
BuildRequires: pkgconfig(lxqt-globalkeys)
BuildRequires: pkgconfig(polkit-agent-1)
BuildRequires: pkgconfig(polkit-qt5-core-1)
Recommends: %{name}-lang = %{version}-%{release}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
PolicyKit authentication agent for LXQt
%lang_package
%prep
%setup -q
%build
%cmake
make %{?_smp_mflags}
%install
%cmake_install
install -Dm 0644 man/%{name}-agent.1 %{buildroot}%{_mandir}/man1/%{name}-agent.1
%find_lang %{name} --with-qt --all-name
for lng in ast arn ; do
for i in $(find %{buildroot}// -name "*_$lng.qm" | cut -d \/ -f7-) ; do
echo "%lang($lng) $i" >> %{name}.lang
done
done
%files
%defattr(-,root,root)
%doc AUTHORS LICENSE
%{_bindir}/%{name}-agent
%{_mandir}/man?/%{name}-agent.?%{ext_man}
%{_sysconfdir}/xdg/autostart/%{name}-agent.desktop
%files lang -f %{name}.lang
%defattr(-,root,root)
%dir %{_datadir}/lxqt
%dir %{_datadir}/lxqt/translations
%dir %{_datadir}/lxqt/translations/%{name}-agent
%changelog