Search
j0ke.net Open Build Service
>
Projects
>
mozilla
>
mozilla-xulrunner181
> mozilla-xulrunner181.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File mozilla-xulrunner181.spec of Package mozilla-xulrunner181 (Revision 9)
Currently displaying revision
9
,
show latest
# # spec file for package mozilla-xulrunner181 (Version 1.8.1.12) # # Copyright (c) 2008 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 Name: mozilla-xulrunner181 BuildRequires: gcc-c++ java-devel libgnomeui-devel libidl-devel update-desktop-files zip License: LGPL, MPL Version: 1.8.1.12 Release: 1 Summary: Mozilla Runtime Environment 1.8.1.x URL: http://www.mozilla.org/ Group: Productivity/Other Provides: gecko181 %if %suse_version > 1010 Obsoletes: mozilla-xulrunner # For upgrade from 10.2 betas: Obsoletes: mozilla-xulrunner180 %endif %if %suse_version == 1020 %define ga_version 1.8.1b2 Provides: mozilla-xulrunner181 = 1.8.0.99 %endif %if %suse_version == 1030 %define ga_version 1.8.1.4 Provides: mozilla-xulrunner181 = %{ga_version} %endif Source: xulrunner-source-%{version}.tar.bz2 Source1: l10n-%{version}.tar.bz2 Patch1: abuild.patch Patch2: nss-opt.patch Patch3: mozilla-gcc4.3-fixes.patch Patch4: idldir.patch Patch5: mozilla-path_len.patch Patch6: gcc-undefined-ops.patch Patch7: xulrunner-apilibdir.patch Patch8: nsIPermission.patch Patch9: rpath.patch Patch10: system-proxies.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build PreReq: libstdc++ expat pango xorg-x11-libs fontconfig freetype2 PreReq: gtk2 atk glib2 update-alternatives ### build configuration ### %define has_system_cairo 0 %define has_system_nspr 0 %define has_system_nss 0 %define pango 0 %if %suse_version > 930 || 0%{opensuse_bs} %define has_system_cairo 1 %define has_system_nspr 1 %endif %if 0%{is_plus} || %suse_version >= 930 %define pango 1 %endif %if %suse_version > 1010 || 0%{opensuse_bs} # NSS version on 10.1 is too old %define has_system_nss 1 %endif %define releasedate 2008020500 %define apiversion 1.8.1 %define uaweight 181120 ### configuration end ### %define my_provides %{_tmppath}/my-provides %define my_requires %{_tmppath}/my-requires %if %has_system_nspr BuildRequires: mozilla-nspr-devel PreReq: mozilla-nspr >= %( echo `rpm -q --queryformat '%{VERSION}' mozilla-nspr`) %endif %if %has_system_nss BuildRequires: mozilla-nss-devel PreReq: mozilla-nss %endif %description XULRunner is a single installable package that can be used to bootstrap multiple XUL+XPCOM applications that are as rich as Firefox and Thunderbird. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %package devel Summary: XULRunner/Gecko SDK 1.8.1.x Group: Development/Libraries/Other %if %suse_version > 1010 Obsoletes: gecko-sdk # For upgrade from 10.2 betas: Obsoletes: mozilla-xulrunner180-devel %endif %if %has_system_nspr Requires: mozilla-nspr-devel >= %( echo `rpm -q --queryformat '%{VERSION}' mozilla-nspr-devel`) %endif %if %has_system_nss Requires: mozilla-nss-devel >= %( echo `rpm -q --queryformat '%{VERSION}' mozilla-nss-devel`) %endif PreReq: %{name} = %{version} %description devel Software Development Kit to embed XUL or Gecko into other applications. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %package l10n Summary: Translations for XULRunner 1.8.1.x Group: Productivity/Other PreReq: %{name} = %{version} %if %suse_version > 1010 # For upgrade from 10.2 betas: Obsoletes: mozilla-xulrunner180-l10n %endif %description l10n XULRunner is a single installable package that can be used to bootstrap multiple XUL+XPCOM applications that are as rich as Firefox and Thunderbird. This package contains all supported languages but en-US which is delivered in the main package. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %debug_package %prep %setup -n mozilla -b 1 -q %patch1 %patch2 %patch3 %patch4 %patch5 -p1 %patch6 %patch7 %patch8 %patch9 %patch10 %build %ifarch %x86 %if %suse_version <= 1010 export JAVA_HOME=/usr/lib/jvm/java-1.4.2-sun %endif %endif export MOZ_BUILD_DATE=%{releasedate} export LD_LIBRARY_PATH=$RPM_BUILD_DIR/mozilla/dist/bin export CFLAGS="$RPM_OPT_FLAGS -g -Os -fno-strict-aliasing" %if %suse_version > 1000 export CFLAGS="$CFLAGS -fstack-protector" %endif %ifarch ppc64 export CFLAGS="$CFLAGS -mminimal-toc" %endif export CXXFLAGS="$CFLAGS" #%if %suse_version > 1020 #export ac_cv_visibility_hidden="no" #%endif export RPATH="-Wl,-rpath -Wl,%{_libdir}/xulrunner-%{version}" export MOZCONFIG=$RPM_BUILD_DIR/mozconfig export MOZILLA_OFFICIAL=1 export BUILD_OFFICIAL=1 export MOZ_MILESTONE_RELEASE=1 # cat << EOF > $MOZCONFIG mk_add_options MOZILLA_OFFICIAL=1 mk_add_options BUILD_OFFICIAL=1 mk_add_options MOZ_MILESTONE_RELEASE=1 mk_add_options MOZ_MAKE_FLAGS=%{?jobs:-j%jobs} . \$topsrcdir/xulrunner/config/mozconfig ac_add_options --prefix=%{_prefix} ac_add_options --libdir=%{_libdir} ac_add_options --sysconfdir=%{_sysconfdir} ac_add_options --mandir=%{_mandir} ac_add_options --includedir=%{_includedir} ac_add_options --enable-optimize ac_add_options --enable-extensions=default,cookie,permissions ac_add_options --with-system-jpeg ac_add_options --with-system-png ac_add_options --with-system-zlib ac_add_options --enable-default-toolkit=gtk2 ac_add_options --enable-xft ac_add_options --disable-freetype2 ac_add_options --enable-svg ac_add_options --enable-canvas ac_add_options --disable-tests ac_add_options --disable-installer EOF %if %pango cat << EOF >> $MOZCONFIG ac_add_options --enable-pango EOF %endif %if %has_system_nspr cat << EOF >> $MOZCONFIG ac_add_options --with-system-nspr EOF %endif %if %has_system_nss cat << EOF >> $MOZCONFIG ac_add_options --with-system-nss EOF %endif %if %has_system_cairo cat << EOF >> $MOZCONFIG ac_add_options --enable-system-cairo EOF %endif make -f client.mk build %install make -C xulrunner/installer STRIP=/bin/true mkdir -p $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version} mkdir -p $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/extensions mkdir -p $RPM_BUILD_ROOT/usr/bin cp -rf dist/xulrunner/* $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/ # GRE mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/gre.d/ # SDK mkdir -p $RPM_BUILD_ROOT%{_includedir}/xulrunner-%{version} mkdir -p $RPM_BUILD_ROOT%{_libdir}/pkgconfig mkdir -p $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/bin/ cp -rL dist/sdk/bin/* $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/ cp -rL dist/sdk/lib/*.a $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/ cp -rL dist/sdk/lib/*.jar $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{version}/ cp -rL dist/sdk/idl/* $RPM_BUILD_ROOT%{_includedir}/xulrunner-%{version}/ cp -rL dist/include/* $RPM_BUILD_ROOT%{_includedir}/xulrunner-%{version}/ cp -rL dist/sdk/include/* $RPM_BUILD_ROOT%{_includedir}/xulrunner-%{version}/ cp -rL dist/bin/xulrunner-config $RPM_BUILD_ROOT%{_bindir}/ install -m 755 $RPM_BUILD_DIR/mozilla/build/unix/xulrunner-*.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig/ %if %has_system_nss rm $RPM_BUILD_ROOT%{_libdir}/pkgconfig/xulrunner-nss.pc ln -sf nss.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig/xulrunner-nss.pc %endif # XPI example cp -rL dist/xpi-stage/simple $RPM_BUILD_ROOT/%{_libdir}/xulrunner-%{version}/ # ghosts touch $RPM_BUILD_ROOT/%{_libdir}/xulrunner-%{version}/global.reginfo # install additional locales rm -f %{_tmppath}/translations.list for locale in $(cat toolkit/locales/all-locales); do make -C toolkit/locales libs-$locale cp dist/xpi-stage/locale-$locale/chrome/$locale.jar \ $RPM_BUILD_ROOT/%{_libdir}/xulrunner-%{version}/chrome cp dist/xpi-stage/locale-$locale/chrome/$locale.manifest \ $RPM_BUILD_ROOT/%{_libdir}/xulrunner-%{version}/chrome echo %{_libdir}/xulrunner-%{version}/chrome/$locale.jar \ >> %{_tmppath}/translations.list echo %{_libdir}/xulrunner-%{version}/chrome/$locale.manifest \ >> %{_tmppath}/translations.list done # API symlink ln -sf xulrunner-%{version} $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{apiversion} # compat links %if 0%{?ga_version:1} touch $RPM_BUILD_ROOT%{_libdir}/xulrunner-%{ga_version} %endif # modify provides and requires lists %if %has_system_nspr && !%has_system_nss cat << EOF > %{my_provides} grep -vE "libnss3.so|libnssckbi.so|libsmime3.so|libsoftokn3.so|libssl3.so|libfreebl3.so" | %{__find_provides} EOF chmod 755 %{my_provides} %define __find_provides %{my_provides} cat << EOF > %{my_requires} grep -vE "libnss3.so|libnssckbi.so|libsmime3.so|libsoftokn3.so|libssl3.so|libfreebl3.so|libpipnss.so" | %{__find_requires} EOF chmod 755 %{my_requires} %define __find_requires %{my_requires} %endif %clean rm -rf $RPM_BUILD_ROOT %if %has_system_nspr && !%has_system_nss rm -f %{my_provides} rm -f %{my_requires} %endif rm -rf %{_tmppath}/translations.list %pre # if an update we need to unregister the old version now if [ "$1" = "2" ]; then %ifarch x86_64 ppc64 s390x /usr/lib64/xulrunner-%{apiversion}/xulrunner --unregister-global || : %else /usr/lib/xulrunner-%{apiversion}/xulrunner --unregister-global || : %endif fi exit 0 %post /usr/sbin/update-alternatives --install %{_bindir}/xulrunner \ xulrunner %{_libdir}/xulrunner-%{version}/xulrunner %{uaweight} || : %{_libdir}/xulrunner-%{version}/xulrunner --register-global || : # needed for updates which transition directory to symlink %if 0%{?ga_version:1} %posttrans #if [ "$1" = "1" ]; then test -d %{_libdir}/xulrunner-%{ga_version} && rm -rf %{_libdir}/xulrunner-%{ga_version} ln -sf xulrunner-%{version} %{_libdir}/xulrunner-%{ga_version} #fi exit 0 %endif %preun if [ "$1" = "0" ]; then # deinstallation %{_libdir}/xulrunner-%{version}/xulrunner --unregister-global # that's not quite nice since old versions should be removed on update as well # but that's problematic for updates w/o raising the version number /usr/sbin/update-alternatives --remove xulrunner %{_libdir}/xulrunner-%{version}/xulrunner fi exit 0 %files %defattr(-,root,root) %dir %{_libdir}/xulrunner-%{version}/ %dir %{_libdir}/xulrunner-%{version}/chrome/ %dir %{_libdir}/xulrunner-%{version}/extensions/ %{_libdir}/xulrunner-%{version}/chrome/classic.* %{_libdir}/xulrunner-%{version}/chrome/comm.* %{_libdir}/xulrunner-%{version}/chrome/en-US.* %{_libdir}/xulrunner-%{version}/chrome/pippki.* %{_libdir}/xulrunner-%{version}/chrome/toolkit.* %{_libdir}/xulrunner-%{version}/chrome/chromelist.txt %{_libdir}/xulrunner-%{version}/chrome/icons/ %{_libdir}/xulrunner-%{version}/components/ %{_libdir}/xulrunner-%{version}/defaults/ %{_libdir}/xulrunner-%{version}/greprefs/ %{_libdir}/xulrunner-%{version}/icons/ %{_libdir}/xulrunner-%{version}/plugins/ %{_libdir}/xulrunner-%{version}/res/ %{_libdir}/xulrunner-%{version}/*.so %{_libdir}/xulrunner-%{version}/LICENSE %{_libdir}/xulrunner-%{version}/README.txt %{_libdir}/xulrunner-%{version}/dependentlibs.list %{_libdir}/xulrunner-%{version}/mozilla-xremote-client %if !%has_system_nss %{_libdir}/xulrunner-%{version}/libsoftokn3.chk %{_libdir}/xulrunner-%{version}/libfreebl3.chk %endif %{_libdir}/xulrunner-%{version}/run-mozilla.sh %{_libdir}/xulrunner-%{version}/updater %{_libdir}/xulrunner-%{version}/xpicleanup %{_libdir}/xulrunner-%{version}/xulrunner %{_libdir}/xulrunner-%{version}/xulrunner-bin %{_libdir}/xulrunner-%{version}/xulrunner-stub %{_libdir}/xulrunner-%{version}/javaxpcom.jar %ghost %{_libdir}/xulrunner-%{version}/global.reginfo # GRE %dir %{_sysconfdir}/gre.d/ # example %{_libdir}/xulrunner-%{version}/simple/ # API symlink %{_libdir}/xulrunner-%{apiversion} # compat symlinks %if 0%{?ga_version:1} %ghost %{_libdir}/xulrunner-%{ga_version} %endif %files devel %defattr(-,root,root) %{_libdir}/xulrunner-%{version}/*.a %{_libdir}/xulrunner-%{version}/MozillaInterfaces* %{_libdir}/xulrunner-%{version}/regxpcom %{_libdir}/xulrunner-%{version}/xpidl %{_libdir}/xulrunner-%{version}/xpt_dump %{_libdir}/xulrunner-%{version}/xpt_link %{_bindir}/xulrunner-config %attr(644,root,root) %{_libdir}/pkgconfig/* %{_includedir}/xulrunner-%{version}/ %files l10n -f %{_tmppath}/translations.list %defattr(-,root,root)