Search
j0ke.net Open Build Service
>
Projects
>
mozilla
>
nspluginwrapper
> Changes
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
Changes of Revision 4
[-]
[+]
Added
nspluginwrapper.spec
@@ -0,0 +1,137 @@ +# +# spec file for package nspluginwrapper (Version 0.9.91.5) +# +# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. +# This file and all modifications and additions to the pristine +# package are under the same license as the package itself. +# +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + +# norootforbuild + +%ifarch x86_64 +Name: nspluginwrapper +%else +Name: nspluginwrapper-i386 +BuildRequires: gcc-c++ +%endif +BuildRequires: gtk2-devel +License: GPL +Version: 0.9.91.5 +Release: 1 +%ifarch x86_64 +Summary: A compatibility layer for Netscape 4 plugins +%else +Summary: A viewer for i386 compiled Netscape 4 plugins +%endif +Group: Productivity/Networking/Web/Browsers +Source0: nspluginwrapper-%{version}.tar.bz2 +Patch: plugin-dir.patch +Patch1: nspluginwrapper-%{version}-gthreads-init.patch +Url: http://www.gibix.net/projects/nspluginwrapper/ +# define 32-bit arch of multiarch platforms +%define arch_32 %{nil} +%ifarch x86_64 +%define arch_32 i386 +%endif +%ifarch x86_64 +Provides: %{name}-%{_arch} +Requires: %{name}-%{arch_32} +%else +%if %suse_version >= 1020 +Recommends: nspluginwrapper +%endif +%endif +BuildRoot: %{_tmppath}/%{name}-%{version}-build +%define pkglibdir %{_prefix}/lib/nspluginwrapper +%define plugindir %{_libdir}/browser-plugins + +%description +nspluginwrapper makes it possible to use Netscape 4 compatible plugins +compiled for %{arch_32} into Mozilla for another architecture, e.g. x86_64. + +This package consists in: + * npviewer: the plugin viewer + * npwrapper.so: the browser-side plugin + * nspluginwrapper: a tool to manage plugins installation and update + +%debug_package + +%prep +%setup -n nspluginwrapper-%{version} -q +%patch +%patch1 + +%build +export CFLAGS="$RPM_OPT_FLAGS -g" +export CXXFLAGS="$CFLAGS" +mkdir objs +pushd objs +../configure \ + --prefix=%{_prefix} \ + --without-biarch +make %{?jobs:-j%jobs} +popd + +%install +rm -rf $RPM_BUILD_ROOT +%ifarch x86_64 +make -C objs install DESTDIR=$RPM_BUILD_ROOT DONT_STRIP=yes +mkdir -p $RPM_BUILD_ROOT%{plugindir} +ln -s %{pkglibdir}/%{_arch}/linux/npwrapper.so $RPM_BUILD_ROOT%{plugindir}/npwrapper.so +%else +mkdir -p $RPM_BUILD_ROOT%{pkglibdir}/i386/linux +make -C objs install.viewer DESTDIR=$RPM_BUILD_ROOT DONT_STRIP=yes +make -C objs install.libxpcom DESTDIR=$RPM_BUILD_ROOT DONT_STRIP=yes +%endif + + +%clean +rm -rf $RPM_BUILD_ROOT + +%ifarch x86_64 +# Trigger on packages, which don't have x86_64 equivalent or its +# equivalent has less features. +# mplayerplug-in is a common name of third party package, that may be +# affected, too. +%triggerin -- RealPlayer acroread acroread_ja flash-player mplayerplug-in +%{_bindir}/nspluginwrapper -a -u + +%triggerpostun -- RealPlayer acroread acroread_ja flash-player mplayerplug-in +%{_bindir}/%{name} -a -u + +%post +if [ $1 = 1 ]; then + %{_bindir}/nspluginwrapper -a -i || : +else + %{_bindir}/nspluginwrapper -a -u || : +fi + +%preun +if [ $1 = 0 ]; then + %{_bindir}/nspluginwrapper -a -r || : +fi +%endif + +%files +%defattr(-,root,root) +%ifarch x86_64 +%doc README COPYING NEWS +%{plugindir}/npwrapper.so +%dir %{pkglibdir}/%{_arch} +%dir %{pkglibdir}/%{_arch}/linux +%{pkglibdir}/%{_arch}/linux/npconfig +%{pkglibdir}/%{_arch}/linux/npwrapper.so +%dir %{pkglibdir}/noarch +%{pkglibdir}/noarch/npviewer +%{pkglibdir}/noarch/mkruntime +%{_bindir}/nspluginwrapper +%else +%dir %{pkglibdir} +%dir %{pkglibdir}/i386 +%dir %{pkglibdir}/i386/linux +%{pkglibdir}/i386/linux/npviewer +%{pkglibdir}/i386/linux/npviewer.bin +%{pkglibdir}/i386/linux/libxpcom.so +%endif