File exo.spec of Package exo

#
# spec file for package exo
#
# 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:           exo
Version:        0.6.0
Release:        8.<RELEASE3>
License:        GPLv2+ ; LGPLv2.1+
Summary:        Application Development Library for Xfce
Url:            http://www.xfce.org/projects/exo/
Group:          System/Libraries
Source:         %{name}-%{version}.tar.bz2
Source1:        %{name}-rpmlintrc
Patch0:         %{name}-firefox-params.patch
Patch1:         %{name}-env.patch
BuildRequires:  fdupes
BuildRequires:  gtk-doc
BuildRequires:  intltool
BuildRequires:  perl-URI
BuildRequires:  pkgconfig(dbus-1)
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gtk+-2.0)
BuildRequires:  pkgconfig(libstartup-notification-1.0)
BuildRequires:  pkgconfig(libxfce4util-1.0)
BuildRequires:  python-devel
BuildRequires:  python-gtk-devel
BuildRequires:  update-desktop-files
Recommends:     %{name}-lang = %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Provides:       libexo-1-0 = %{version}
Obsoletes:      libexo-1-0 < %{version}

%description
Exo is an extension library to Xfce which is targeted at application
development.

%package devel
License:        GPLv2+ ; LGPLv2.1+
Summary:        Development Files for exo
Group:          Development/Libraries/C and C++
Requires:       exo = %{version}
Requires:       perl-URI
Requires:       pkgconfig(dbus-1)
Requires:       pkgconfig(glib-2.0)
Requires:       pkgconfig(gtk+-2.0)
Requires:       pkgconfig(libstartup-notification-1.0)
Requires:       pkgconfig(libxfce4util-1.0)

%description devel
This package contains development files needed for developing applications
based on exo.

%package -n python-exo
License:        GPLv2+ ; LGPLv2.1+
Summary:        Python Interface to exo
Group:          Development/Libraries/Python
Requires:       exo = %{version}
%py_requires
Requires:       python-gtk

%description -n python-exo
Exo is an extension library to Xfce which is targeted at application
development.

This package contains the python interface to exo.

%package doc
License:        GPLv2+ ; LGPLv2.1+
Summary:        Documentation for exo
Group:          Documentation/HTML
Requires:       exo = %{version}
Requires(pre):  %install_info_prereq

%description doc
This package contains the HTML documentation for exo.

%package branding-upstream
License:        GPLv2+
Summary:        Upstream Branding of exo
Group:          System/GUI/XFCE
# BRAND: helpers.rc: Controls default applications and MIME handler.
Conflicts:      otherproviders(exo-branding)
Provides:       exo-branding = %{version}
Supplements:    packageand(exo:branding-upstream)

%description branding-upstream
This package provides the upstream look and feel for the exo library.

%lang_package
%prep
%setup -q
%patch0
%patch1

%build
%configure \
  --enable-gtk-doc \
  --enable-python \
  --disable-static
make %{?_smp_mflags} V=1

%install
%make_install
%__rm -f %{buildroot}%{_libdir}/*.la

# recompile in order strip buildroot from libs
%py_compile %{buildroot}%{python_sitearch}/exo-0.6/exo/
%py_compile -O %{buildroot}%{python_sitelib}/

%if %suse_version <= 1130
%__rm -f %buildroot/%_libdir/gio/modules/*.la
%endif

%fdupes %{buildroot}%{_datadir}
%fdupes %{buildroot}%{_libdir}
%fdupes %{buildroot}%{python_sitearch}

# remove unsupported locales
rm -rf %{buildroot}%{_datadir}/locale/{ast,kk,tl_PH,ur_PK}

%find_lang exo-1

%suse_update_desktop_file exo-preferred-applications
%suse_update_desktop_file exo-mail-reader
%suse_update_desktop_file exo-terminal-emulator
%suse_update_desktop_file exo-file-manager
%suse_update_desktop_file exo-web-browser

%clean
rm -rf %{buildroot}

%post
/sbin/ldconfig
%if 0%{?suse_version} >= 1140
%icon_theme_cache_post
%desktop_database_post
%endif

%postun
/sbin/ldconfig
%if 0%{?suse_version} >= 1140
%icon_theme_cache_postun
%desktop_database_postun
%endif

%files lang -f exo-1.lang

%files
%defattr(-,root,root)
%doc README ChangeLog NEWS COPYING AUTHORS THANKS TODO
%{_bindir}/exo*
%{_libdir}/libexo-1.so.*
%dir %{_libdir}/xfce4
%dir %{_libdir}/xfce4/exo-1
%{_libdir}/xfce4/exo-1/exo-compose-mail-1
%{_libdir}/xfce4/exo-1/exo-helper-1
%dir %{_datadir}/xfce4
%{_datadir}/xfce4/helpers
%{_datadir}/applications/*
%{_mandir}/man?/*
%dir %{_datadir}/pixmaps/exo-1
%{_datadir}/pixmaps/exo-1/exo-thumbnail-frame.png
%dir %{_datadir}/icons/*/*
%{_datadir}/icons/*/*/*/
%if %suse_version <= 1130
%{_libdir}/gio/modules/libexo-module-1.so
%endif

%files -n python-exo
%defattr(-,root,root)
%{python_sitearch}/exo-0.6/
%{python_sitelib}/pyexo.py*
%dir %{_datadir}/pygtk/2.0/defs/exo-0.6
%{_datadir}/pygtk/2.0/defs/exo-0.6/exo.defs

%files devel
%defattr(-,root,root)
%{_includedir}/exo-1
%{_libdir}/*exo*.so
%{_libdir}/pkgconfig/*

%files doc
%defattr(-,root,root)
%{_datadir}/gtk-doc/html/exo-1/
%dir %{_datadir}/doc/exo
%{_datadir}/doc/exo/html/

%files branding-upstream
%defattr(-,root,root)
%dir %{_sysconfdir}/xdg/xfce4
%config %{_sysconfdir}/xdg/xfce4/helpers.rc

%changelog
openSUSE Build Service is sponsored by