SPECS: librsvg.spec - release 2 - browser plugin support merged fr...

blues blues at pld-linux.org
Sun May 14 15:58:34 CEST 2006


Author: blues                        Date: Sun May 14 13:58:34 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- release 2 - browser plugin support merged from AC-branch

---- Files affected:
SPECS:
   librsvg.spec (1.102 -> 1.103) 

---- Diffs:

================================================================
Index: SPECS/librsvg.spec
diff -u SPECS/librsvg.spec:1.102 SPECS/librsvg.spec:1.103
--- SPECS/librsvg.spec:1.102	Sun Apr  2 23:29:46 2006
+++ SPECS/librsvg.spec	Sun May 14 15:58:29 2006
@@ -1,6 +1,6 @@
 # $Revision$, $Date$
 # TODO
-# - mozilla_firefox bcond/subpackage
+# - check what browsers can be supported by browser plugin
 #
 # Conditional build
 %bcond_without	apidocs		# disable gtk-doc
@@ -10,14 +10,14 @@
 %bcond_without	gnomevfs	# build without gnome-vfs support
 %bcond_without	mozilla		# do not build mozilla plugin
 #
-Summary:	Raph's SVG library
+Summary:	A Raph's Library for Rendering SVG Data
 Summary(pl):	Biblioteka Raph's SVG
 Summary(pt_BR):	Biblioteca SVG
 Summary(ru):	SVG ÂÉÂĚÉĎÔĹËÁ
 Summary(uk):	SVG ÂŚÂĚŚĎÔĹËÁ
 Name:		librsvg
 Version:	2.14.3
-Release:	1
+Release:	2
 Epoch:		1
 License:	LGPL v2+
 Vendor:		GNOME
@@ -37,6 +37,7 @@
 BuildRequires:	libtool
 BuildRequires:	libxml2-devel >= 1:2.6.22
 %{?with_mozilla:BuildRequires:	mozilla-devel}
+%{?with_mozilla:BuildRequires:	rpmbuild(macros) >= 1.236}
 BuildRequires:	popt-devel >= 1.5
 BuildRequires:	pkgconfig
 BuildRequires:	rpm-pythonprov
@@ -51,10 +52,13 @@
 Obsoletes:	librsvg0
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define		mozilladir	%{_libdir}/mozilla
+%define		_plugindir	%{_libdir}/browser-plugins
+
+# list of supported browsers, in free form text
+%define		browsers	mozilla, mozilla-firefox, netscape, seamonkey
 
 %description
-An SVG library based upon libart.
+An library to render SVG (scalable vector graphics), databased upon libart.
 
 %description -l pl
 Biblioteka do obsługi grafiki wektorowej.
@@ -122,21 +126,27 @@
 Bibliotecas estáticas para o desenvolvimento de aplicaçőes com
 librsvg.
 
-%package -n mozilla-plugin-rsvg
-Summary:	Mozilla SVG plugin using librsvg
-Summary(pl):	Wtyczka Mozilli do SVG wykorzystująca librsvg
+%package -n browser-plugin-%{name}
+Summary:	SVG browse plugin using librsvg
+Summary(pl):	Wtyczka SVG do przeglądarski WWW wykorzystująca librsvg
 Group:		X11/Applications/Multimedia
+Requires:	browser-plugins(%{_target_base_arch})
 Requires:	%{name} = %{epoch}:%{version}-%{release}
-Requires:	mozilla
+Provides:	mozilla-plugin-rsvg
+Obsoletes:	mozilla-plugin-rsvg
 
-%description -n mozilla-plugin-rsvg
+%description -n browser-plugin-%{name}
 This plugin allows Mozilla-family browsers to view Scalable Vector
 Graphics content using librsvg.
 
-%description -n mozilla-plugin-rsvg -l pl
+Supported browsers: %{browsers}.
+
+%description -n browser-plugin-%{name} -l pl
 Ta wtyczka pozwala na oglądanie grafiki w formacie SVG (Scalable
 Vector Graphics) w przeglądarkach z rodziny Mozilli.
 
+Supported browsers: %{browsers}.
+
 %prep
 %setup -q
 
@@ -159,10 +169,11 @@
 
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT \
+	plugindir=%{_plugindir} \
 	pkgconfigdir=%{_pkgconfigdir}
 
 rm -f $RPM_BUILD_ROOT%{_libdir}/gtk-2.0/2.*/{engines,loaders}/*.{la,a}
-rm -f $RPM_BUILD_ROOT%{mozilladir}/plugins/*.{la,a}
+-rm -f $RPM_BUILD_ROOT%{_plugindir}/*.{la,a}
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -177,6 +188,35 @@
 umask 022
 gdk-pixbuf-query-loaders > %{_sysconfdir}/gtk-2.0/gdk-pixbuf.loaders
 
+%triggerin -n browser-plugin-%{name} -- mozilla
+%nsplugin_install -d %{_libdir}/mozilla/plugins libmozsvgdec.so
+
+%triggerun -n browser-plugin-%{name} -- mozilla
+%nsplugin_uninstall -d %{_libdir}/mozilla/plugins libmozsvgdec.so
+
+%triggerin -n browser-plugin-%{name} -- mozilla-firefox
+%nsplugin_install -d %{_libdir}/mozilla-firefox/plugins libmozsvgdec.so
+
+%triggerun -n browser-plugin-%{name} -- mozilla-forefox
+%nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins libmozsvgdec.so
+
+%triggerin -n browser-plugin-%{name} -- netscape-common
+%nsplugin_install -d %{_libdir}/netscape/plugins libmozsvgdec.so
+
+%triggerun -n browser-plugin-%{name} -- netscape-common
+%nsplugin_uninstall -d %{_libdir}/netscape/plugins libmozsvgdec.so
+
+%triggerin -n browser-plugin-%{name} -- seamonkey
+%nsplugin_install -d %{_libdir}/seamonkey/plugins libmozsvgdec.so
+
+%triggerun -n browser-plugin-%{name} -- seamonkey
+%nsplugin_uninstall -d %{_libdir}/seamonkey/plugins libmozsvgdec.so
+
+# as rpm removes the old obsoleted package files after the triggers
+# are ran, add another trigger to make the links there.
+%triggerpostun -n browser-plugin-%{name} -- mozilla-plugin-rsvg
+%nsplugin_install -f -d %{_libdir}/mozilla/plugins libmozsvgdec.so
+
 %files
 %defattr(644,root,root,755)
 %doc ChangeLog AUTHORS NEWS
@@ -200,9 +240,9 @@
 %{_libdir}/lib*.a
 
 %if %{with mozilla}
-%files -n mozilla-plugin-rsvg
+%files -n browser-plugin-%{name}
 %defattr(644,root,root,755)
-%attr(755,root,root) %{mozilladir}/plugins/*.so
+%attr(755,root,root) %{_plugindir}/*.so
 %endif
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
@@ -211,6 +251,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.103  2006/05/14 13:58:29  blues
+- release 2 - browser plugin support merged from AC-branch
+
 Revision 1.102  2006/04/02 21:29:46  qboosh
 - removed indirect X deps (all are required by gtk+2-devel; the only one used by
   librsvg configure is libX11, which is required by gtk+2-devel anyway
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/librsvg.spec?r1=1.102&r2=1.103&f=u



More information about the pld-cvs-commit mailing list