File parcellite.spec of Package parcellite

# spec file for package parcellite
# Copyright (c) 2012 SUSE LINUX Products 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:           parcellite
Version:        0.9.2
Release:        0
Summary:        A lightweight GTK+ clipboard manager
License:        GPL-3.0+
Group:          Productivity/Other
Source0:        %{name}-%{version}.tar.bz2
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Patch0:         parcellite-0.9.1-german.diff
Patch1:         parcellite-0.9.1-lxde-autostart.patch
Patch2:         parcellite-0.9.1-defaults.diff
Patch3:         parcellite-0.9.1-ld_fix.diff
# PATCH-FIX-UPSTREAM parcellite-0.9.2-fix-glib-includes.patch -- Do not include glib/gtypes.h directly
Patch4:         parcellite-0.9.2-fix-glib-includes.patch
BuildRequires:  automake
BuildRequires:  gnome-icon-theme
BuildRequires:  gtk2-devel >= 2.10.0
BuildRequires:  intltool >= 0.23
BuildRequires:  update-desktop-files

Parcellite is a stripped down, basic-features-only clipboard manager with a 
small memory footprint for those who like simplicity.

In GNOME and Xfce the clipboard manager will be started automatically. For 
other desktops or window managers you should also install a panel with a 
system tray or notification area if you want to use this package.

%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1

autoreconf -fi
make %{?_smp_mflags} %{?jobs:-j%jobs}
sed -i -e '/^Icon/s/=.*/=parcellite/' data/parcellite.desktop

make install DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p'
mkdir -p $RPM_BUILD_ROOT%{_datadir}/pixmaps
%if 0%suse_version > 1110
%define iconname edit-paste
%define iconname gtk-paste
install -m 644 \
	/usr/share/icons/gnome/32x32/actions/%{iconname}.png \
%find_lang %{name}
%suse_update_desktop_file -r -G "Clipboard Manager" %{name} GTK GNOME Utility DesktopUtility
%suse_update_desktop_file -r -G "Clipboard Manager" %{name}-startup GTK GNOME Utility DesktopUtility TrayIcon


%if 0%{?suse_version} >= 1140



%files -f %{name}.lang
%config(noreplace) %{_sysconfdir}/xdg/autostart/%{name}-startup.desktop