File lxqt-admin.spec of Package lxqt-admin

# spec file for package lxqt-admin
# 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

Name:           lxqt-admin
Version:        @SERVICE@
Release:        0
Summary:        Admin tools
License:        LGPL-2.1-or-later
Group:          System/GUI/LXQt
Source:         %{name}-%{version}.tar.xz
BuildRequires:  cmake >= 3.1.0
BuildRequires:  lxqt-build-tools-devel >= 0.6.0
BuildRequires:  pkgconfig
BuildRequires:  cmake(KF5WindowSystem)
BuildRequires:  pkgconfig(Qt5DBus)
BuildRequires:  pkgconfig(Qt5Widgets)
BuildRequires:  pkgconfig(lxqt)
BuildRequires:  pkgconfig(polkit-qt5-1)
#Requires:       polkit
Requires:       system-tools-backends
Requires(post): desktop-file-utils
Requires(pre):  desktop-file-utils
Recommends:     %{name}-lang
%if 0%{?suse_version} == 1315
BuildRequires:  gcc5-c++
BuildRequires:  gcc-c++ >= 4.9.0

Administration tools for LXQt


%setup -q
sed -i '/^Categories/s/\(LXQt\;\)/X-\1/' lxqt-admin-*/lxqt-admin-*
sed -i '/^OnlyShowIn/s/\(LXQt\)/X-\1/' lxqt-admin-*/lxqt-admin-*
sed -i 's/\(Icon=\).*/\1preferences-system-time/' lxqt-admin-time/
sed -i 's/\(Icon=\).*/\1preferences-desktop-user/' lxqt-admin-user/

%cmake \
%if 0%{?suse_version} == 1315
    -DCMAKE_CXX_COMPILER=%{_bindir}/g++-5 \
make %{?_smp_mflags}


%find_lang lxqt-admin-time lxqt-admin-user --with-qt

%license COPYING
%dir %{_datadir}/polkit-1
%dir %{_datadir}/polkit-1/actions

%files -n lxqt-admin-lang
%dir %{_datadir}/lxqt
%dir %{_datadir}/lxqt/translations