File nautilus.spec of Package nautilus

#
# spec file for package nautilus
#
# 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:           nautilus
License:        GPLv2+
Group:          Productivity/File utilities
Version:        3.2.1
Release:        1
# FIXME: replace libexempi-devel BuildRequires with pkgconfig(exempi-2.0) once fixed exempi is in
Summary:        File Manager for the GNOME Desktop
Source:         http://download.gnome.org/sources/nautilus/3.2/%{name}-%{version}.tar.bz2
# fate#308344 bgo#602147
Source1:        mount-archive.desktop
Source99:       baselibs.conf
Url:            http://www.gnome.org
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
# PATCH-NEEDS-REBASE nautilus-drives-and-volumes-on-desktop.diff bnc335411 federico@novell.com
Patch15:        nautilus-drives-and-volumes-on-desktop.diff
# PATCH-NEEDS-REBASE nautilus-sysadmin-desktop-items.diff fate305252 federico@novell.com -- Support sysadmin-defined desktop items (was PATCH-FEATURE-OPENSUSE)
Patch21:        nautilus-sysadmin-desktop-items.diff
# needed for directory ownership
BuildRequires:  dbus-1
BuildRequires:  fdupes
BuildRequires:  gnome-common
BuildRequires:  gnome-icon-theme
BuildRequires:  gnome-patch-translation
BuildRequires:  gobject-introspection-devel
BuildRequires:  gtk-doc
BuildRequires:  intltool
BuildRequires:  libexempi-devel
BuildRequires:  libselinux-devel
# We need the %%mime_database_* macros
BuildRequires:  shared-mime-info
BuildRequires:  translation-update-upstream
BuildRequires:  update-desktop-files
BuildRequires:  pkgconfig(gail-3.0)
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gnome-desktop-3.0)
BuildRequires:  pkgconfig(gtk+-3.0)
BuildRequires:  pkgconfig(libexif)
BuildRequires:  pkgconfig(libnotify)
BuildRequires:  pkgconfig(libxml-2.0)
BuildRequires:  pkgconfig(pango)
BuildRequires:  pkgconfig(tracker-sparql-0.12)
# So that symlinks to icons work:
Requires:       gnome-icon-theme
Recommends:     %{name}-lang
Recommends:     gvfs
Provides:       nautilus2 = %{version}
Obsoletes:      nautilus2 < %{version}
%glib2_gsettings_schema_requires

%description
Nautilus is the file manager for the GNOME desktop.

%package -n libnautilus-extension1
License:        GPLv2+
Group:          System/Libraries
Summary:        File Manager for the GNOME Desktop -- Extension Library
Summary:        File Manager for the GNOME Desktop -- Extension Library

%description  -n libnautilus-extension1
Nautilus is the file manager for the GNOME desktop.

This package contains the library used by nautilus extensions.

%package devel
License:        GPLv2+
Summary:        File Manager for the GNOME Desktop -- Development Files
Group:          Development/Libraries/GNOME
Requires:       %{name} = %{version} glib2-devel gtk2-devel
Provides:       nautilus2-devel = %{version}
Obsoletes:      nautilus2-devel < %{version}

%description devel
Nautilus is the file manager for the GNOME desktop.

This package contains development files for nautilus.

%lang_package
%prep
%setup -q
translation-update-upstream
#gnome-patch-translation-prepare
### %patch15 -p1
#%patch21 -p1
#gnome-patch-translation-update

%build
#NOCONFIGURE=1 gnome-autogen.sh
%configure\
	--disable-update-mimedb \
	--enable-gtk-doc
%__make %{?jobs:-j%jobs} V=1

%install
%makeinstall
%if 0%{?suse_version} <= 1110
%{__rm} %{buildroot}%{_datadir}/locale/ha/LC_MESSAGES/*
%{__rm} %{buildroot}%{_datadir}/locale/ig/LC_MESSAGES/*
%endif
%if 0%{?suse_version} <= 1120
%{__rm} %{buildroot}%{_datadir}/locale/en@shaw/LC_MESSAGES/*
%endif
rm $RPM_BUILD_ROOT/%{_libdir}/{*.*a,nautilus/extensions-3.0/*.la}
### ln -s ../icons/gnome/24x24/devices/gnome-fs-client.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/
# FIXME: this is probably wrong, but it enables the build to succeed for now
# ln -s ../icons/gnome/24x24/devices/gnome-computer.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/
ln -s ../icons/gnome/24x24/actions/system-search.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/
ln -s ../icons/gnome/24x24/places/user-home.png $RPM_BUILD_ROOT/%{_datadir}/pixmaps/
%suse_update_desktop_file nautilus
%suse_update_desktop_file nautilus-autorun-software
%suse_update_desktop_file nautilus-autostart
# Install the archive mime handler
test ! -e %{buildroot}%{_datadir}/applications/mount-archive.desktop
%{__install} -m0644 %{SOURCE1} %{buildroot}%{_datadir}/applications/mount-archive.desktop
%suse_update_desktop_file mount-archive
mkdir -p $RPM_BUILD_ROOT/%{_libdir}/nautilus/extensions-3.0
%find_lang %{name} %{?no_lang_C}
%fdupes $RPM_BUILD_ROOT

%clean
rm -rf $RPM_BUILD_ROOT

%post
%glib2_gsettings_schema_post
%desktop_database_post
%icon_theme_cache_post
%mime_database_post

%postun
%glib2_gsettings_schema_postun
%desktop_database_postun
%icon_theme_cache_postun
%mime_database_postun

%post -n libnautilus-extension1 -p /sbin/ldconfig

%postun -n libnautilus-extension1 -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc AUTHORS COPYING COPYING-DOCS ChangeLog MAINTAINERS NEWS README THANKS TODO
%{_bindir}/*
%{_datadir}/GConf/gsettings/*.convert
%{_datadir}/applications/*.desktop
%{_datadir}/dbus-1/services/org.gnome.Nautilus.service
%{_datadir}/glib-2.0/schemas/*.xml
%{_datadir}/icons/hicolor/*/*/*.*
%{_datadir}/mime/packages/*.xml
%{_datadir}/nautilus
%{_datadir}/pixmaps/nautilus
%{_datadir}/pixmaps/*.png
%dir %{_libdir}/nautilus
%{_libexecdir}/nautilus-convert-metadata
%doc %{_mandir}/man1/nautilus*.1.gz
%{_sysconfdir}/xdg/autostart/*.desktop

%files -n libnautilus-extension1
%defattr(-,root,root)
%{_libdir}/libnautilus-extension.so.1*
%{_libdir}/girepository-1.0/Nautilus-3.0.typelib
%dir %{_libdir}/nautilus
%dir %{_libdir}/nautilus/extensions-3.0
%{_libdir}/nautilus/extensions-3.0/*.so

%files lang -f %{name}.lang

%files devel
%defattr(-,root,root)
%{_libdir}/*.so
%{_includedir}/*
%{_libdir}/pkgconfig/*.pc
%{_datadir}/gir-1.0/*.gir
# Own these repositories to not depend on gtk-doc while building:
%dir %{_datadir}/gtk-doc
%dir %{_datadir}/gtk-doc/html
%{_datadir}/gtk-doc/html/*

%changelog
openSUSE Build Service is sponsored by