SPECS: acroread.spec - browser-plugins v2 - proper %post/%postun f...

hawk hawk at pld-linux.org
Mon Jan 28 18:46:00 CET 2008


Author: hawk                         Date: Mon Jan 28 17:46:00 2008 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- browser-plugins v2
- proper %post/%postun for plugin subpackage
- release 2

---- Files affected:
SPECS:
   acroread.spec (1.83 -> 1.84) 

---- Diffs:

================================================================
Index: SPECS/acroread.spec
diff -u SPECS/acroread.spec:1.83 SPECS/acroread.spec:1.84
--- SPECS/acroread.spec:1.83	Mon Nov  5 23:06:55 2007
+++ SPECS/acroread.spec	Mon Jan 28 18:45:54 2008
@@ -13,7 +13,7 @@
 %else
 Name:		%{base_name}-installer
 %endif
-%define	_rel	1
+%define	_rel	2
 Version:	8.1.1
 Release:	%{_rel}%{?with_license_agreement:wla}
 Epoch:		1
@@ -34,7 +34,7 @@
 Source2:	%{base_name}.png
 URL:		http://www.adobe.com/products/acrobat/
 %if %{with license_agreement}
-BuildRequires:	rpmbuild(macros) >= 1.236
+BuildRequires:	rpmbuild(macros) >= 1.357
 Requires:	openldap-libs >= 2.4
 Requires:	openldap-libs < 2.5
 %else
@@ -44,12 +44,6 @@
 ExcludeArch:	i386
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define		_plugindir	%{_libdir}/browser-plugins
-
-# TODO: galeon and skipstone, konqueror, opera.
-# use macro, otherwise extra LF inserted along with the ifarch
-%define	browsers mozilla, mozilla-firefox, seamonkey
-
 %define		platform	intellinux
 %define		tar0		ILINXR.TAR
 %define		tar1		COMMON.TAR
@@ -81,7 +75,7 @@
 Summary(pl.UTF-8):	Wtyczka PDF dla przeglądarek zgodnych Mozilla
 Group:		X11/Applications
 Requires:	%{base_name} = %{epoch}:%{version}-%{release}
-Requires:	browser-plugins(%{_target_base_arch})
+Requires:	browser-plugins >= 2.0
 Obsoletes:	acroread-plugin
 Obsoletes:	mozilla-plugin-acroread
 
@@ -119,7 +113,7 @@
 install %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/%{base_name}
 
 %else
-install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}/%{base_name},%{_plugindir}} \
+install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}/%{base_name},%{_browserpluginsdir}} \
 	$RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
 
 # note: there're also AdobeReader/Adobe/Help{,Viewer}
@@ -129,7 +123,7 @@
 	'/^install_dir=/ {print "install_dir="INSTDIR; next} \
 	{print}' \
 	bin/%{base_name} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}
-install Browser/%{platform}/* $RPM_BUILD_ROOT%{_plugindir}
+install Browser/%{platform}/* $RPM_BUILD_ROOT%{_browserpluginsdir}
 install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
 install %{SOURCE2} $RPM_BUILD_ROOT%{_pixmapsdir}
 
@@ -148,44 +142,16 @@
 %if %{without license_agreement}
 %post
 %{_bindir}/%{base_name}.install
+%endif
 
-%else
-
-%triggerin -n browser-plugin-%{name} -- mozilla-firefox
-%nsplugin_install -d %{_libdir}/mozilla-firefox/plugins nppdf.so
-
-%triggerun -n browser-plugin-%{name} -- mozilla-firefox
-%nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins nppdf.so
-
-%triggerin -n browser-plugin-%{name} -- mozilla
-%nsplugin_install -d %{_libdir}/mozilla/plugins nppdf.so
-
-%triggerun -n browser-plugin-%{name} -- mozilla
-%nsplugin_uninstall -d %{_libdir}/mozilla/plugins nppdf.so
-
-%triggerin -n browser-plugin-%{name} -- seamonkey
-%nsplugin_install -d %{_libdir}/seamonkey/plugins nppdf.so
-
-%triggerun -n browser-plugin-%{name} -- seamonkey
-%nsplugin_uninstall -d %{_libdir}/seamonkey/plugins nppdf.so
-
-# % triggerin -n browser-plugin-%{name} -- konqueror
-# % nsplugin_install -d %{_libdir}/kde3/plugins/konqueror nppdf.so
-
-# % triggerun -n browser-plugin-%{name} -- konqueror
-# % nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror nppdf.so
-
-# % triggerin -n browser-plugin-%{name} -- opera
-# % nsplugin_install -d %{_libdir}/opera/plugins nppdf.so
-
-# % triggerun -n browser-plugin-%{name} -- opera
-# % nsplugin_uninstall -d %{_libdir}/opera/plugins nppdf.so
-
-# as rpm removes the old obsoleted package files after the triggers
-# above are ran, add another trigger to make the links there.
-%triggerpostun -n browser-plugin-%{name} -- mozilla-plugin-acroread, acroread-plugin
-%nsplugin_install -f -d %{_libdir}/mozilla/plugins nppdf.so
+%if %{with license_agreement}
+%post -n browser-plugin-%{name}
+%update_browser_plugins
 
+%postun -n browser-plugin-%{name}
+if [ "$1" = 0 ]; then
+	%update_browser_plugins
+fi
 %endif
 
 %files
@@ -230,7 +196,7 @@
 
 %files -n browser-plugin-%{name}
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_plugindir}/*
+%attr(755,root,root) %{_browserpluginsdir}/*
 %endif
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
@@ -239,6 +205,11 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.84  2008-01-28 17:45:54  hawk
+- browser-plugins v2
+- proper %post/%postun for plugin subpackage
+- release 2
+
 Revision 1.83  2007-11-05 22:06:55  qboosh
 - updated symlinks for openldap 2.4.x
 - hide private copies of old system libraries from rpm Provides
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/acroread.spec?r1=1.83&r2=1.84&f=u



More information about the pld-cvs-commit mailing list