File pk-update-icon.spec of Package pk-update-icon

#
# spec file for package pk-update-icon
#
# Copyright (c) 2015 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/
#


Name:           pk-update-icon
Version:        2
Release:        0
Summary:        Software Update Notifier based on PackageKit
License:        GPL-2.0+
Group:          System/Daemons
Url:            https://hg.guido-berhoerster.org/projects/pk-update-icon/
Source:         %{name}-%{version}.tar.gz
# PATCH-FEATURE-OPENSUSE pk-update-icon-also-in-gnome.patch dimstar@opensuse.org -- Also use pk-update-icon in GNOME
Patch0:         pk-update-icon-also-in-gnome.patch
BuildRequires:  docbook5-xsl-stylesheets
BuildRequires:  docbook_5
BuildRequires:  intltool
BuildRequires:  libxslt-tools
BuildRequires:  update-desktop-files
BuildRequires:  pkgconfig(gtk+-2.0)
BuildRequires:  pkgconfig(libnotify)
BuildRequires:  pkgconfig(packagekit-glib2)
BuildRequires:  pkgconfig(unique-1.0)
Recommends:     %{name}-lang
# activating the tray icon executes gpk-update-viewer
Requires:       gnome-packagekit

%description
pk-update-icon displays notifications and an icon in the tray area of the panel
when package updates are available.

%lang_package

%prep
%setup -q
%patch0 -p1

%build
make %{?_smp_mflags} \
    prefix=%{_prefix} \
%if 0%{?suse_version} == 1230
    DOCBOOK5_MANPAGES_STYLESHEET='/usr/share/xml/docbook/stylesheet/nwalsh5/1.77.1/manpages/docbook.xsl' \
%endif
    CFLAGS="%{optflags}" \
    UPDATE_VIEWER_COMMAND="/usr/bin/gpk-update-viewer"

%install
%make_install prefix=%{_prefix}
%suse_update_desktop_file %{name}

%find_lang %{name} %{?no_lang_C}

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root)
%doc README COPYING NEWS
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1*
%{_sysconfdir}/xdg/autostart/%{name}.desktop

%files lang -f %{name}.lang

%changelog