File caja-extensions.spec of Package caja-extensions

#
# spec file for package caja-extensions
#
# Copyright (c) 2014 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:           caja-extensions
Summary:        Set of extensions for Caja, the MATE file manager 
Version:        1.8.0
Release:        0
License:        GPL-2.0+
Url:            http://mate-desktop.org/
Group:          System/GUI/Other
Source:         http://pub.mate-desktop.org/releases/1.8/%{name}-%{version}.tar.xz
Requires:       ImageMagick
Requires:       caja >= 1.8.0

BuildRequires:  libglade2-devel
BuildRequires:  mate-common
BuildRequires:  pkgconfig(dbus-glib-1)
BuildRequires:  pkgconfig(libcaja-extension) >= 1.8.0
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gtk+-2.0)
BuildRequires:  pkgconfig(gupnp-1.0)
BuildRequires:  pkgconfig(mate-desktop-2.0)

%description
Set of extensions for Caja, the MATE file manager.

%package -n caja-image-converter
Summary:        MATE Desktop file manager image converter
Group:          System/GUI/Other
Requires:       ImageMagick
Requires:       caja >= 1.8.0
Provides:       mate-file-manager-image-converter = %{version}
Obsoletes:      mate-file-manager-image-converter < %{version}
Recommends:     caja-image-converter-lang

%description -n caja-image-converter
ImageResizer adds a "Resize Images..." menu item to the context menu of
all images. This opens a dialog where you set the desired image size and
file name. A click on "Resize" finally resizes the image(s) using
ImageMagick's convert tool.

%package -n caja-open-terminal
Summary:        Mate file manager Terminal plugin
Group:          System/GUI/Other
Requires:       caja >= 1.8.0
Provides:       mate-file-manager-open-terminal = %{version}
Obsoletes:      mate-file-manager-open-terminal < %{version}
Recommends:     caja-open-terminal-lang

%description -n caja-open-terminal
This extension allows to open a Terminal in arbitrary directories though
mate file manager, caja. This is a fork of nautilus-open-terminal.

%package -n caja-sendto
Summary:        A collection of 'sendto' plugins for MATE file manager
Group:          System/GUI/Other
Requires:       caja >= 1.8.0
Provides:       mate-file-manager-sendto = %{version}
Obsoletes:      mate-file-manager-sendto < %{version}
Recommends:     caja-sendto-lang

%description -n caja-sendto
This package provides extra functionality to the MATE Desktop file
manager, caja. The core package includes CD burner, archiving, email
client links and devices.

%package -n  caja-sendto-pidgin
Summary:        Pidgin integration for the MATE Desktop file manager
Group:          System/GUI/Other
Requires:       pidgin
Requires:       caja-sendto = %{version}-%{release}
Provides:       mate-file-manager-sendto-pidgin = %{version}
Obsoletes:      mate-file-manager-sendto-pidgin < %{version}

%description -n  caja-sendto-pidgin
This package provides pidgin integration to the MATE Desktop file
manager, caja.

%package -n  caja-sendto-upnp
Summary:        UPnP integration for the MATE Desktop file manager
Group:          System/GUI/Other
Requires:       caja-sendto = %{version}-%{release}
Provides:       mate-file-manager-sendto-upnp = %{version}
Obsoletes:      mate-file-manager-sendto-upnp < %{version}

%description -n caja-sendto-upnp
This package provides the functionality to the caja file browser to
send files over e-mail or instant messaging protocols via Evolution,
Empathy and Pidgin.

%package -n caja-sendto-devel
Summary:        Development files for caja-sendto
Group:          Development/Libraries/X11
Requires:       caja-sendto = %{version}-%{release}
Requires:       caja-sendto-upnp = %{version}-%{release}
Requires:       caja-sendto-pidgin = %{version}-%{release}
Provides:       mate-file-manager-sendto-devel = %{version}
Obsoletes:      mate-file-manager-sendto-devel < %{version}

%description -n caja-sendto-devel
This package provides the functionality to the caja file browser to
send files over e-mail or instant messaging protocols via Evolution,
Empathy and Pidgin.

%package -n caja-share
Summary:        Share directory from caja via samba
Group:          System/GUI/Other
Requires:       caja >= 1.8.0
Requires:       mate-icon-theme
Requires:       samba >= 3.0.23
Provides:       mate-file-manager-share = %{version}
Obsoletes:      mate-file-manager-share < %{version}
Recommends:     caja-share-lang

%description -n caja-share
Mate-file-manager-share allows you to quickly share a folder from the MATE Caja
file manager without requiring root access. It uses Samba, so your folders
can be accessed by any operating system.

%package common-lang
Summary:        Languages for Caja extensions
Group:          System/Localization
Provides:       caja-image-converter-lang = %{version}
Provides:       caja-open-terminal-lang = %{version}
Provides:       caja-sendto-lang = %{version}
Provides:       caja-share-lang = %{version}
BuildArch:      noarch

%description common-lang
Provides common translations shared by Caja extensions

%prep
%setup -q

%build
%configure                         \
    --disable-static               \
    --enable-shared                \
    --enable-image-convert         \
    --enable-open-terminal         \
    --enable-share                 \
    --enable-sendto                
make %{?_smp_mflags}

%install
%makeinstall
find %{buildroot} -type f -name "*.la" -delete -print
%find_lang %{name}
# Remove unwanted caja-gksu library
rm %{buildroot}%{_libdir}/caja/extensions-2.0/libcaja-gksu.so
# openSUSE doesn't provide gajim anymore, so we're wiping it out
if [ -f %{buildroot}%{_libdir}/caja-sendto/plugins/libnstgajim.so ]; then
   rm -rf %{buildroot}%{_libdir}/caja-sendto/plugins/libnstgajim.so
fi

if [ -d %{buildroot}%{_datadir}/MateConf ]; then
   rm -r %{buildroot}%{_datadir}/MateConf
fi

%post -n caja-open-terminal
%glib2_gsettings_schema_post

%post -n caja-sendto
%glib2_gsettings_schema_post

%postun -n caja-open-terminal
%glib2_gsettings_schema_postun

%postun -n caja-sendto
%glib2_gsettings_schema_postun

%files -n caja-image-converter
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog COPYING README
%{_libdir}/caja/extensions-2.0/libcaja-image-converter.so
%{_datadir}/caja-extensions/caja-image-resize.ui
%{_datadir}/caja-extensions/caja-image-rotate.ui

%files -n caja-open-terminal
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog COPYING README
%{_libdir}/caja/extensions-2.0/libcaja-open-terminal.so
%{_datadir}/glib-2.0/schemas/org.mate.caja-open-terminal.gschema.xml

%files -n caja-sendto
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog COPYING README
%dir %{_libdir}/caja-sendto
%dir %{_libdir}/caja-sendto/plugins
%{_bindir}/caja-sendto
%{_datadir}/caja-extensions/caja-sendto.ui
%{_datadir}/glib-2.0/schemas/org.mate.Caja.Sendto.gschema.xml
%{_libdir}/caja/extensions-2.0/libcaja-sendto.so
%{_libdir}/caja-sendto/plugins/libnstburn.so
%{_libdir}/caja-sendto/plugins/libnstremovable_devices.so
%{_libdir}/caja-sendto/plugins/libnstemailclient.so
%{_mandir}/man1/caja-sendto.1.gz

%files -n caja-sendto-pidgin
%defattr(-,root,root,-)
%{_libdir}/caja-sendto/plugins/libnstpidgin.so

%files -n caja-sendto-upnp
%defattr(-,root,root,-)
%{_libdir}/caja-sendto/plugins/libnstupnp.so

%files -n caja-sendto-devel
%defattr(-,root,root,-)
%{_includedir}/caja-sendto
%{_libdir}/pkgconfig/caja-sendto.pc
%{_datadir}/gtk-doc/html/caja-sendto

%files -n caja-share
%defattr(-,root,root) 
%doc AUTHORS ChangeLog COPYING README
%{_datadir}/caja-extensions/share-dialog.ui
%{_libdir}/caja/extensions-2.0/libcaja-share.so

%files common-lang -f %{name}.lang
%defattr(-,root,root,-)

%changelog
openSUSE Build Service is sponsored by