File x-tile.spec of Package x-tile
#
# spec file for package x-tile
#
# Copyright (c) 2011 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 http://bugs.opensuse.org/
#
Name: x-tile
Version: 1.8.4
Release: 2
License: GPLv2+
Summary: Panel applet for tiling windows
Url: http://www.giuspen.com/x-tile/
Group: Productivity/Other
Source: %{name}-%{version}.tar.bz2
BuildRequires: fdupes
BuildRequires: gnome-python-desktop
BuildRequires: python-gobject2-devel
BuildRequires: python-gtk-devel
BuildRequires: update-desktop-files
Requires: gnome-python-desktop
Requires: python-gobject2
Requires: python-gtk
Recommends: %{name}-lang
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%py_requires
%if %suse_version <= 1110
%define python_sitelib %{py_sitedir}
%endif
%description
X-tile is a GNOME applet for your panel (or optionally a standalone
application, working with kde as well) that allows you to select a
number of windows and tile them in different ways.
This is especially useful for comparing products in separate web pages,
or for programmers refering to documentation as they are programming.
%lang_package
%prep
%setup -q
%build
%install
%{__python} setup.py install --prefix=%{_prefix} --exec-prefix=%{_exec_prefix} -f --root=%{buildroot}
%ifarch x86_64
install -D -m 644 %{buildroot}%{_prefix}/lib/bonobo/servers/x-tile.server \
%{buildroot}%{_libdir}/bonobo/servers/x-tile.server
rm %{buildroot}%{_prefix}/lib/bonobo/servers/x-tile.server
%endif
#Correct permissions of non-executable .svg files.
chmod 644 %{buildroot}%{_datadir}/x-tile/glade/*.svg
# Fail once the chmod is not needed anymore
test -x %{buildroot}%{_datadir}/pixmaps/x-tile.svg
chmod 644 %{buildroot}%{_datadir}/pixmaps/x-tile.svg
%find_lang %{name} %{?no_lang_C}
%fdupes %{buildroot}
%suse_update_desktop_file %{name} DesktopUtility
%clean
rm -rf %{buildroot}
%if 0%{?suse_version} > 1130
%post
%desktop_database_post
%endif
%if 0%{?suse_version} > 1130
%postun
%desktop_database_postun
%endif
%files
%defattr(-,root,root)
%doc license
%{_bindir}/x-tile
%{_libdir}/bonobo/servers/x-tile.server
%{_datadir}/applications/x-tile.desktop
%{_datadir}/pixmaps/x-tile.svg
%{_datadir}/x-tile/
%{python_sitelib}/*.egg-info
%files lang -f %{name}.lang
%changelog