SPECS (DEVEL): mozilla-firefox.spec - merged from HEAD - up to 2.0...

czarny czarny at pld-linux.org
Sun Oct 1 16:06:29 CEST 2006


Author: czarny                       Date: Sun Oct  1 14:06:29 2006 GMT
Module: SPECS                         Tag: DEVEL
---- Log message:
- merged from HEAD
- up to 2.0rc1
- added config options
- reverted not appliable nss patches
- forced sysnss via .mozconfig
- tweaked .mozconfig generation
- reverted official mozilla build (we can't do that!)
- updated name.patch
- overall fixes
- added TODO
- NFY

---- Files affected:
SPECS:
   mozilla-firefox.spec (1.95.2.26 -> 1.95.2.27) 

---- Diffs:

================================================================
Index: SPECS/mozilla-firefox.spec
diff -u SPECS/mozilla-firefox.spec:1.95.2.26 SPECS/mozilla-firefox.spec:1.95.2.27
--- SPECS/mozilla-firefox.spec:1.95.2.26	Sun Jan 22 17:49:33 2006
+++ SPECS/mozilla-firefox.spec	Sun Oct  1 16:06:24 2006
@@ -1,10 +1,16 @@
 # $Revision$, $Date$
-#
 # TODO:
+# - with new gcc version (it is possible that)
+#   - -fvisibility=hiddenn and ac_cv_visibility_pragma=no can be removed
+# - with new firefox version (it is possible that)
+#   - -fno-strict-aliasing can be removed (needs to be tested carefuly,
+#      not to be fixed soon, imho)
 # - handle locales differently (runtime, since it's possible to do)
 # - see ftp://ftp.debian.org/debian/pool/main/m/mozilla-firefox/*diff*
 #   for hints how to make locales and other stuff like extensions working
-# - rpm upgrade is broken. First you need uninstall Firefox 1.0.x. 
+# - rpm upgrade is broken. First you need uninstall Firefox 1.0.x.
+# - check if nss patches realy aren't neaded, as it seems
+#
 # Conditional build:
 %bcond_with	tests	# enable tests (whatever they check)
 %bcond_without	gnome	# disable all GNOME components (gnomevfs, gnome, gnomeui)
@@ -12,12 +18,12 @@
 Summary:	Mozilla Firefox web browser
 Summary(pl):	Mozilla Firefox - przeglądarka WWW
 Name:		mozilla-firefox
-Version:	1.5
-Release:	2.5
+Version:	2.0
+Release:	0.rc1
 License:	MPL/LGPL
 Group:		X11/Applications/Networking
-Source0:	http://ftp.mozilla.org/pub/mozilla.org/firefox/releases/%{version}/source/firefox-%{version}-source.tar.bz2
-# Source0-md5:	fa915ddcadecda30ed3e13694f26a779
+Source0:	ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/%{version}rc1/source/firefox-%{version}rc1-source.tar.bz2
+# Source0-md5:	2c5edae90512c0d59e378e60e3016c6d
 Source1:	%{name}.desktop
 Source2:	%{name}.sh
 Patch0:		%{name}-nss.patch
@@ -25,41 +31,47 @@
 Patch2:		%{name}-nss-system-nspr.patch
 Patch3:		%{name}-nopangoxft.patch
 Patch4:		%{name}-name.patch
-Patch5:		%{name}-lang.patch
+Patch5:		%{name}-fonts.patch
 # UPDATE or DROP?
-#PatchX:		%{name}-searchplugins.patch
+#PatchX:	%{name}-searchplugins.patch
 URL:		http://www.mozilla.org/projects/firefox/
 %{?with_gnome:BuildRequires:	GConf2-devel >= 1.2.1}
 BuildRequires:	automake
 BuildRequires:	cairo-devel >= 1.0.0
+%{?with_gnome:BuildRequires:	gnome-vfs2-devel >= 2.0}
 BuildRequires:	gtk+2-devel >= 1:2.0.0
 BuildRequires:	heimdal-devel >= 0.7.1
-%{?with_gnome:BuildRequires:	gnome-vfs2-devel >= 2.0}
 BuildRequires:	libIDL-devel >= 0.8.0
 %{?with_gnome:BuildRequires:	libgnome-devel >= 2.0}
 %{?with_gnome:BuildRequires:	libgnomeui-devel >= 2.2.0}
 BuildRequires:	libjpeg-devel >= 6b
-BuildRequires:	libpng-devel >= 1.2.0
+BuildRequires:	libpng-devel >= 1.2.7
 BuildRequires:	libstdc++-devel
-BuildRequires:	nspr-devel >= 1:4.6-0.20041030.1
-BuildRequires:	nss-devel >= 3.8
+BuildRequires:	nspr-devel >= 1:4.6.1-2
+BuildRequires:	nss-devel >= 1:3.11.3
 BuildRequires:	pango-devel >= 1:1.6.0
 BuildRequires:	perl-modules >= 5.004
 BuildRequires:	pkgconfig
+BuildRequires:	xorg-lib-libXext-devel
+BuildRequires:	xorg-lib-libXft-devel >= 2.1
+BuildRequires:	xorg-lib-libXinerama-devel
+BuildRequires:	xorg-lib-libXp-devel
+BuildRequires:	xorg-lib-libXt-devel
 BuildRequires:	zip
+BuildRequires:	zlib-devel >= 1.2.3
 Requires:	%{name}-lang-resources = %{version}
-Requires:	nspr >= 1:4.6-0.20041030.1
-Requires:	nss >= 3.8
-# for /etc/ld.so.conf.d
-Requires:	glibc >= 6:2.3.5-7.6
-Requires(post,postun):	/sbin/ldconfig
+Requires:	nspr >= 1:4.6.1-2
+Requires:	nss >= 1:3.11.3
+Requires(post):	mktemp >= 1.5-18
+Provides:	wwwbrowser
 Obsoletes:	mozilla-firebird
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define		_firefoxdir	%{_libdir}/%{name}
 # mozilla and firefox provide their own versions
 %define		_noautoreqdep		libgkgfx.so libgtkembedmoz.so libgtkxtbin.so libjsj.so libmozjs.so libxpcom.so libxpcom_compat.so
-%define		_noautoprovfiles	libplc4.so libplds4.so
+
+%define		specflags	-fno-strict-aliasing
 
 %description
 Mozilla Firefox is an open-source web browser, designed for standards
@@ -71,21 +83,21 @@
 
 %package devel
 Summary:	Headers for developing programs that will use Mozilla Firefox
-Summary(pl):	Mozilla Firefox - pliki nagłówkowe i biblioteki
+Summary(pl):	Mozilla Firefox - pliki nagłówkowe
 Group:		X11/Development/Libraries
-Obsoletes:	mozilla-devel
 Requires:	%{name} = %{epoch}:%{version}-%{release}
-Requires:	nspr-devel >= 1:4.6-0.20041030.1
+Requires:	nspr-devel >= 1:4.6.1-2
+Obsoletes:	mozilla-devel
 
 %description devel
-Mozilla development package.
+Mozilla Firefox development package.
 
 %description devel -l pl
-Biblioteki i pliki nagłówkowe.
+Pliki nagłówkowe przeglądarki Mozilla Firefox.
 
 %package lang-en
-Summary:	English resources for Mozilla-firefox
-Summary(pl):	Anglojęzyczne zasoby dla Mozilla-FireFox
+Summary:	English resources for Mozilla Firefox
+Summary(pl):	Anglojęzyczne zasoby dla przeglądarki Mozilla Firefox
 Group:		X11/Applications/Networking
 Requires(post,postun):	%{name} = %{version}-%{release}
 Requires(post,postun):	textutils
@@ -93,22 +105,25 @@
 Provides:	%{name}-lang-resources = %{version}-%{release}
 
 %description lang-en
-English resources for Mozilla-firefox
+English resources for Mozilla Firefox.
 
 %description lang-en -l pl
-Anglojęzyczne zasoby dla Mozilla-FireFox
+Anglojęzyczne zasoby dla przeglądarki Mozilla Firefox.
 
 %prep
-%setup -q -n mozilla
-%patch0 -p1
+%setup -qc
+cd mozilla
+#%patch0 -p1
 %patch1 -p1
-%patch2 -p1
+#%patch2 -p1
 %patch3 -p1
 %patch4 -p1
 %patch5 -p1
+
 sed -i 's/\(-lgss\)\(\W\)/\1disable\2/' configure
 
 %build
+cd mozilla
 rm -f .mozconfig
 export CFLAGS="%{rpmcflags} `%{_bindir}/pkg-config mozilla-nspr --cflags-only-I`"
 export CXXFLAGS="%{rpmcflags} `%{_bindir}/pkg-config mozilla-nspr --cflags-only-I`"
@@ -119,13 +134,14 @@
 
 LIBIDL_CONFIG="%{_bindir}/libIDL-config-2"; export LIBIDL_CONFIG
 
-cat << EOF > .mozconfig
-. \$topsrcdir/browser/config/mozconfig
+cat << 'EOF' > .mozconfig
+. $topsrcdir/browser/config/mozconfig
 
-export BUILD_OFFICIAL=1
-export MOZILLA_OFFICIAL=1
-mk_add_options BUILD_OFFICIAL=1
-mk_add_options MOZILLA_OFFICIAL=1
+# We're not allowed to do that!
+#export BUILD_OFFICIAL=1
+#export MOZILLA_OFFICIAL=1
+#mk_add_options BUILD_OFFICIAL=1
+#mk_add_options MOZILLA_OFFICIAL=1
 
 ac_add_options --prefix=%{_prefix}
 ac_add_options --exec-prefix=%{_exec_prefix}
@@ -148,6 +164,13 @@
 ac_add_options --disable-debug
 ac_add_options --disable-debug-modules
 %endif
+%if %{with gnome}
+ac_add_options --enable-gnomevfs
+ac-add-options --enable-gnomeui
+%else
+ac_add_options --disable-gnomevfs
+ac_add_options --disable-gnomeui
+%endif
 %if %{with tests}
 ac_add_options --enable-tests
 %else
@@ -163,24 +186,37 @@
 ac_add_options --disable-profilesharing
 ac_add_options --disable-xprint
 ac_add_options --enable-canvas
+ac_add_options --enable-coockies
 ac_add_options --enable-crypto
 ac_add_options --enable-default-toolkit=gtk2
+ac_add_options --enable-image-encoder=all
+ac_add_options --enable-image-decoder=all
 ac_add_options --enable-mathml
 ac_add_options --enable-pango
+ac_add_options --enable-places
+ac_add_options --enable-postscript
 ac_add_options --enable-reorder
+# Some init scripts are broken with this
+#ac_add_options --enable-safe-browsing
 ac_add_options --enable-single-profile
+ac_add_options --enable-storage
 ac_add_options --enable-strip
 ac_add_options --enable-strip-libs
 ac_add_options --enable-svg
 ac_add_options --enable-system-cairo
+ac_add_options --enable-url-classifier
+ac_add_options --enable-view-source
 ac_add_options --enable-xft
 ac_add_options --enable-xinerama
 ac_add_options --enable-xpctools
+ac_add_options --with-distribution-id="PLD Linux"
 ac_add_options --with-pthreads
 ac_add_options --with-system-jpeg
 ac_add_options --with-system-nspr
+ac_add_options --with-system-nss
 ac_add_options --with-system-png
 ac_add_options --with-system-zlib
+ac_cv_visibility_pragma=no
 EOF
 
 %{__make} -j1 -f client.mk build \
@@ -189,20 +225,23 @@
 
 %install
 rm -rf $RPM_BUILD_ROOT
+cd mozilla
 install -d \
 	$RPM_BUILD_ROOT{%{_bindir},%{_sbindir},%{_libdir}{,extensions}} \
 	$RPM_BUILD_ROOT{%{_pixmapsdir},%{_desktopdir}} \
 	$RPM_BUILD_ROOT{%{_includedir}/%{name}/idl,%{_pkgconfigdir}}
 # extensions dir is needed (it can be empty)
-	
+
+ln -s mozilla-firefox $RPM_BUILD_ROOT%{_bindir}/firefox
+
 %{__make} -C xpinstall/packager \
 	MOZ_PKG_APPNAME="mozilla-firefox" \
 	MOZILLA_BIN="\$(DIST)/bin/firefox-bin" \
 	EXCLUDE_NSPR_LIBS=1
 
-install %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}/mozilla-firefox
+sed 's, at LIBDIR@,%{_libdir},' %{SOURCE2} > $RPM_BUILD_ROOT%{_bindir}/mozilla-firefox
 
-tar -xvz -C $RPM_BUILD_ROOT%{_libdir} -f dist/mozilla-firefox-*linux*.tar.gz
+tar -xvz -C $RPM_BUILD_ROOT%{_libdir} -f dist/mozilla-firefox-*.tar.gz
 
 install other-licenses/branding/firefox/content/icon64.png $RPM_BUILD_ROOT%{_pixmapsdir}/mozilla-firefox.png
 #install -m0644 bookmarks.html $RPM_BUILD_ROOT%{_firefoxdir}/defaults/profile/
@@ -210,9 +249,6 @@
 
 install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
 
-#grep locale $RPM_BUILD_ROOT%{_firefoxdir}/chrome/installed-chrome.txt > $RPM_BUILD_ROOT%{_firefoxdir}/chrome/%{name}-en-US-installed-chrome.txt
-#grep -v locale $RPM_BUILD_ROOT%{_firefoxdir}/chrome/installed-chrome.txt > $RPM_BUILD_ROOT%{_firefoxdir}/chrome/%{name}-misc-installed-chrome.txt
-
 rm -rf US classic comm embed-sample en-{US,mac,unix,win} modern pipnss pippki
 rm -f en-win.jar en-mac.jar embed-sample.jar modern.jar
 
@@ -227,7 +263,7 @@
 
 ln -sf %{_includedir}/mozilla-firefox/necko/nsIURI.h \
 	$RPM_BUILD_ROOT%{_includedir}/mozilla-firefox/nsIURI.h
-	
+
 # CA certificates
 ln -s %{_libdir}/libnssckbi.so $RPM_BUILD_ROOT%{_firefoxdir}/libnssckbi.so
 
@@ -243,15 +279,13 @@
 sed -i -e 's#firefox-nspr =.*#mozilla-nspr#g' -e 's#irefox-nss =.*#mozilla-nss#g' \
 	$RPM_BUILD_ROOT%{_pkgconfigdir}/*.pc
 
-# includedir/dom CFLAGS		
+# includedir/dom CFLAGS
 sed -i -e '/Cflags:/{/{includedir}\/dom/!s,$, -I${includedir}/dom,}' \
 	$RPM_BUILD_ROOT%{_pkgconfigdir}/firefox-plugin.pc
-	
+
 cat << 'EOF' > $RPM_BUILD_ROOT%{_sbindir}/firefox-chrome+xpcom-generate
 #!/bin/sh
 umask 022
-#There is no such files (*-installed-chrome.txt). IMO obsolete.
-#cat %{_firefoxdir}/chrome/*-installed-chrome.txt > %{_firefoxdir}/chrome/installed-chrome.txt
 rm -f %{_firefoxdir}/chrome/{chrome.rdf,overlayinfo/*/*/*.rdf}
 rm -f %{_firefoxdir}/components/{compreg,xpti}.dat
 MOZILLA_FIVE_HOME=%{_firefoxdir}
@@ -266,51 +300,37 @@
 export LD_LIBRARY_PATH
 
 unset TMPDIR TMP || :
+export HOME=$(mktemp -d)
 MOZILLA_FIVE_HOME=%{_firefoxdir} %{_firefoxdir}/regxpcom
 MOZILLA_FIVE_HOME=%{_firefoxdir} %{_firefoxdir}/firefox -register
+rm -rf $HOME
 EOF
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %post
-/sbin/ldconfig
 %{_sbindir}/firefox-chrome+xpcom-generate
 
-# TODO: rather remove the cause than use this banner.
-%banner %{name} -e <<EOF
-NOTICE:
-If you have problem with upgrade old mozilla-firefox 1.0.x, You should
-remove it first:
-rpm -e mozilla-firefox
-poldek -u mozilla-firefox
-EOF
-
 %postun
-/sbin/ldconfig
-if [ "$1" != "0" ]; then
-	%{_sbindir}/firefox-chrome+xpcom-generate
-fi
-
-%preun
-if [ "$1" == "0" ]; then
+if [ "$1" = "0" ]; then
 	rm -rf %{_firefoxdir}/chrome/overlayinfo
 	rm -f  %{_firefoxdir}/chrome/*.rdf
 	rm -rf %{_firefoxdir}/components
 	rm -rf %{_firefoxdir}/extensions
 fi
 
-#%post lang-en
-#umask 022
-#cat %{_firefoxdir}/chrome/*-installed-chrome.txt >%{_firefoxdir}/chrome/installed-chrome.txt
-
-#%postun lang-en
-#umask 022
-#cat %{_firefoxdir}/chrome/*-installed-chrome.txt >%{_firefoxdir}/chrome/installed-chrome.txt
+%triggerpostun -- %{name} < 1.5
+%banner %{name} -e <<EOF
+NOTICE:
+If you have problem with upgrade from old mozilla-firefox 1.0.x,
+you should remove it first and reinstall %{name}-%{version}
+EOF
 
 %files
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/mozilla*
+%attr(755,root,root) %{_bindir}/firefox
 %attr(755,root,root) %{_sbindir}/*
 %dir %{_firefoxdir}
 %{_firefoxdir}/res
@@ -318,7 +338,8 @@
 %attr(755,root,root) %{_firefoxdir}/components/*.so
 %{_firefoxdir}/components/*.js
 %{_firefoxdir}/components/*.xpt
-%{_firefoxdir}/plugins
+%dir %{_firefoxdir}/plugins
+%attr(755,root,root) %{_firefoxdir}/plugins/*.so
 %{_firefoxdir}/searchplugins
 %{_firefoxdir}/icons
 %{_firefoxdir}/defaults
@@ -340,12 +361,13 @@
 # -chat subpackage?
 #%{_firefoxdir}/chrome/chatzilla.jar
 #%{_firefoxdir}/chrome/content-packs.jar
-# -dom-inspector subpackage?
-#%{_firefoxdir}/chrome/inspector.jar
-#%{_firefoxdir}/chrome/mozilla-firefox-misc-installed-chrome.txt
 %dir %{_firefoxdir}/chrome/icons
 %{_firefoxdir}/chrome/icons/default
 
+# -dom-inspector subpackage?
+%dir %{_firefoxdir}/extensions/inspector at mozilla.org
+%{_firefoxdir}/extensions/inspector at mozilla.org/*
+
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/regxpcom
@@ -359,7 +381,6 @@
 %defattr(644,root,root,755)
 %{_firefoxdir}/chrome/en-US.jar
 %{_firefoxdir}/chrome/en-US.manifest
-#%{_firefoxdir}/chrome/mozilla-firefox-en-US-installed-chrome.txt
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -367,6 +388,19 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.95.2.27  2006/10/01 14:06:24  czarny
+- merged from HEAD
+- up to 2.0rc1
+- added config options
+- reverted not appliable nss patches
+- forced sysnss via .mozconfig
+- tweaked .mozconfig generation
+- reverted official mozilla build (we can't do that!)
+- updated name.patch
+- overall fixes
+- added TODO
+- NFY
+
 Revision 1.95.2.26  2006/01/22 16:49:33  glen
 - make post message more understandable (and discard the stupid box)
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/mozilla-firefox.spec?r1=1.95.2.26&r2=1.95.2.27&f=u



More information about the pld-cvs-commit mailing list