wok-undigest rev 945
firefox: update bdeps
author | Dominique Corbex <domcox@slitaz.org> |
---|---|
date | Sat Mar 09 16:03:41 2013 +0100 (2013-03-09) |
parents | d695cc826ef1 |
children | 712bdfdeea10 |
files | firefox/receipt |
line diff
1.1 --- a/firefox/receipt Sat Mar 09 15:57:48 2013 +0100 1.2 +++ b/firefox/receipt Sat Mar 09 16:03:41 2013 +0100 1.3 @@ -1,120 +1,157 @@ 1.4 # SliTaz package receipt. 1.5 1.6 PACKAGE="firefox" 1.7 -VERSION="10.0.2" 1.8 +VERSION="17.0.3esr" 1.9 CATEGORY="network" 1.10 SHORT_DESC="User friendly, secure and fast web browser." 1.11 MAINTAINER="pankso@slitaz.org" 1.12 TARBALL="$PACKAGE-$VERSION.source.tar.bz2" 1.13 WEB_SITE="http://www.mozilla.org/" 1.14 -#WGET_URL="http://releases.mozilla.org/pub/mozilla.org/firefox/releases/$VERSION/source/$TARBALL" 1.15 WGET_URL="ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/$VERSION/source/$TARBALL" 1.16 CONFIG_FILES="/etc/firefox" 1.17 TAGS="browser" 1.18 1.19 DEPENDS="gtk+ sqlite dbus dbus-glib glib jpeg xorg-libX11 xorg-libXdamage \ 1.20 -alsa-lib xorg-libXt libfirefox libevent libvpx" 1.21 +alsa-lib xorg-libXt libevent libvpx pango nss sqlite mozilla-common \ 1.22 +gstreamer gst-plugins-base" 1.23 BUILD_DEPENDS="zip libIDL coreutils findutils wireless_tools-dev \ 1.24 perl python yasm alsa-lib-dev mesa-dev libevent-dev libvpx-dev dbus-dev \ 1.25 -dbus-glib-dev gtk+-dev glib-dev" 1.26 +dbus-glib-dev gtk+-dev glib-dev pango-dev nss-dev sqlite-dev tar gzip \ 1.27 +gstreamer-dev gst-plugins-base-dev" 1.28 1.29 # Rules to configure and make the package. 1.30 # 1.31 # A long compile time... dont forget to build libidl before and check the 1.32 # .mozconfig file from the stuff and the stuff/README document. 1.33 # 1.34 +# WARNING: 1GB RAM minimum. Additional RAM will significantly decrease 1.35 +# build time. 1.36 +# At least 600 MB free disk space (1 GB recommended) 1.37 + 1.38 + 1.39 compile_rules() 1.40 { 1.41 - cp -a $stuff/firefox.mozconfig $src/.mozconfig 1.42 cd $src 1.43 - patch -Np1 -i $stuff/mozilla-firefox-1.0-lang.patch 1.44 - patch -Np1 -i $stuff/firefox-install-dir.patch 1.45 + # load mozconfig 1.46 + cp -a $stuff/mozconfig $src 1.47 1.48 - # Fix PRE_RELEASE_SUFFIX 1.49 - sed -i '/^PRE_RELEASE_SUFFIX := ""/s/ ""//' \ 1.50 - browser/base/Makefile.in 1.51 + # build firefox and create a firefox tarball 1.52 + make -f client.mk && 1.53 + make -C obj-firefox/browser/installer 1.54 1.55 - # Don't generate startup cache. Unbreaks build 1.56 - sed -i 's/^GENERATE_CACHE ?=.*/GENERATE_CACHE = true/' \ 1.57 - toolkit/mozapps/installer/packager.mk 1.58 - ./configure $CONFIGURE_ARGS && 1.59 - make $MAKEFLAGS && 1.60 - make DESTDIR=$DESTDIR install && 1.61 - cp -a xpcom/typelib $DESTDIR 1.62 + # install 1.63 + # locate tarball 1.64 + local tarball tarpath fn1 fn2 1.65 + tarpath=$src/obj-firefox/dist 1.66 + fn1="$tarpath/firefox-${VERSION%esr}.en-US.linux-$ARCH.tar.bz2" 1.67 + fn2="$tarpath/firefox-${VERSION%esr}.en-US.linux-$(uname -m).tar.bz2" 1.68 + [ -e "$fn1" ] && tarball="$fn1" && echo "$ARCH tarball found" 1.69 + [ -e "$fn2" ] && tarball="$fn2" && echo "$(uname -m) tarball found" 1.70 + [ -z "$tarball" ] && echo "ERROR: tarball not found" && exit 1 1.71 + # extract tarball 1.72 + mkdir -p $install/usr/lib/firefox-$VERSION && 1.73 + tar -xvf $tarball -C $install/usr/lib/firefox-$VERSION \ 1.74 + --strip-components=1 && 1.75 + chown -R -v root:root $install/usr/lib/firefox-$VERSION && 1.76 + chmod -v 755 $install/usr/lib/firefox-$VERSION/libxpcom.so && 1.77 + # install symlink in /usr/bin 1.78 + mkdir -p $install/usr/bin && 1.79 + ln -sfv ../lib/firefox-$VERSION/firefox $install/usr/bin && 1.80 + # install symlink for plugins 1.81 + mkdir -p $install/usr/lib/mozilla/plugins && 1.82 + ln -sfv ../mozilla/plugins $install/usr/lib/firefox-$VERSION 1.83 } 1.84 1.85 # Rules to gen a SliTaz package suitable for Tazpkg. 1.86 genpkg_rules() 1.87 { 1.88 - mkdir -p $fs/usr/lib/$PACKAGE \ 1.89 - $fs/usr/share $fs/etc/$PACKAGE/profile/chrome 1.90 + # program 1.91 + printf "Installing program.." 1.92 + mkdir -p $fs/usr/lib && 1.93 + cp -a $install/usr/lib/$PACKAGE-$VERSION $fs/usr/lib && 1.94 + cp -a $install/usr/lib/mozilla $fs/usr/lib && 1.95 cp -a $install/usr/bin $fs/usr 1.96 - cp -a $install/usr/lib/$PACKAGE $fs/usr/lib 1.97 + status 1.98 1.99 - # Home page, bookmarks file and branding. 1.100 - cp -a $stuff/browserconfig.properties $fs/etc/$PACKAGE 1.101 - cp -a $stuff/bookmarks.html \ 1.102 - $fs/etc/$PACKAGE/profile 1.103 - mkdir -p $fs/etc/$PACKAGE/pref 1.104 - cp -a $stuff/firefox-branding.js \ 1.105 - $fs/etc/$PACKAGE/pref/firefox.js 1.106 + # search Plugin (by: oddball) 1.107 + printf "Installing SliTaz search plugins.." 1.108 + cp -a $stuff/searchplugins $fs/usr/lib/$PACKAGE-$VERSION 1.109 + status 1.110 1.111 - # User preference. 1.112 - cp -a $stuff/prefs.js $fs/etc/$PACKAGE/profile 1.113 - cp -a $stuff/userChrome.css \ 1.114 - $fs/etc/$PACKAGE/profile/chrome 1.115 + # prefs 1.116 + printf "Installing SliTaz preferences.." 1.117 + mkdir -p $fs/usr/lib/$PACKAGE-$VERSION/distribution && 1.118 + cp -a $stuff/distribution.ini $fs/usr/lib/$PACKAGE-$VERSION/distribution 1.119 + status 1.120 1.121 - # added firefox-l10n.js to stuff to make sure its copyed for langpacks 1.122 - cp -a $stuff/firefox-l10n.js \ 1.123 - $fs/etc/$PACKAGE/pref/firefox-l10n.js 1.124 + # mozilla-common files 1.125 + # dictionaries 1.126 + printf "Installing common dictionnaries.." 1.127 + rm -rf $fs/usr/lib/$PACKAGE-$VERSION/dictionaries && 1.128 + ln -sf ../mozilla-common-$VERSION/dictionaries \ 1.129 + $fs/usr/lib/$PACKAGE-$VERSION/dictionaries 1.130 + status 1.131 + # plugin-container 1.132 + printf "Installing common plugin-container" 1.133 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/plugin-container && 1.134 + ln -sf ../mozilla-common-$VERSION/plugin-container \ 1.135 + $fs/usr/lib/$PACKAGE-$VERSION/plugin-container 1.136 + status 1.137 + # mozilla-xremote-client 1.138 + printf "Installing common mozilla-xremote-client" 1.139 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/mozilla-xremote-client && 1.140 + ln -sf ../mozilla-common-$VERSION/mozilla-xremote-client \ 1.141 + $fs/usr/lib/$PACKAGE-$VERSION/mozilla-xremote-client 1.142 + status 1.143 + # components/libdbusservice.so 1.144 + # components/libmozgnome.so 1.145 + for file in libdbusservice.so libmozgnome.so; do 1.146 + printf "Installing common components/$file" 1.147 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/components/$file && 1.148 + ln -sf ../../mozilla-common-$VERSION/components/$file \ 1.149 + $fs/usr/lib/$PACKAGE-$VERSION/components/$file 1.150 + status 1.151 + done 1.152 + # chrome.manifest 1.153 + printf "Installing common chrome.manifest" 1.154 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/chrome.manifest && 1.155 + ln -sf ../mozilla-common-$VERSION/chrome.manifest \ 1.156 + $fs/usr/lib/$PACKAGE-$VERSION/chrome.manifest 1.157 + status 1.158 1.159 - rm -rf $fs/usr/lib/$PACKAGE/defaults 1.160 + # run-mozilla.sh 1.161 + printf "Installing common run-mozilla.sh" 1.162 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/run-mozilla.sh && 1.163 + ln -sf ../mozilla-common-$VERSION/run-mozilla.sh \ 1.164 + $fs/usr/lib/$PACKAGE-$VERSION/run-mozilla.sh 1.165 + status 1.166 1.167 - ln -sf /etc/$PACKAGE/browserconfig.properties $fs/usr/lib/$PACKAGE 1.168 - ln -sf /etc/$PACKAGE $fs/usr/lib/$PACKAGE/defaults 1.169 + # libmozalloc.so 1.170 + printf "Installing common libmozalloc.so" 1.171 + rm -f $fs/usr/lib/$PACKAGE-$VERSION/libmozalloc.so && 1.172 + ln -sf ../mozilla-common-$VERSION/libmozalloc.so \ 1.173 + $fs/usr/lib/$PACKAGE-$VERSION/libmozalloc.so 1.174 + status 1.175 1.176 - # EULA is accepted by SliTaz project. 1.177 - sed -i s:'pref("browser.EULA.3.accepted", false);':'pref("browser.EULA.3.accepted", true);': \ 1.178 - $fs/etc/firefox/pref/firefox.js 1.179 - 1.180 - # Search Plugin (by: oddball) 1.181 - cp -a $stuff/searchplugins $fs/usr/lib/firefox/ 1.182 chown -R root.root $fs 1.183 - 1.184 - # Remove unnecessary files. 1.185 - rm -rf $fs/usr/lib/$PACKAGE/dictionaries/* 1.186 - rm -rf $fs/usr/lib/$PACKAGE/icons 1.187 - # split firefox libs 1.188 - rm -rf $fs/usr/lib/$PACKAGE/*.so 1.189 - #retain big firefox libs 1.190 - cp -a $install/usr/lib/$PACKAGE/libxul.so \ 1.191 - $fs/usr/lib/$PACKAGE 1.192 - #workaround for now 1.193 - #https://bugzilla.mozilla.org/show_bug.cgi?id=658850 1.194 - ln -sf firefox $fs/usr/lib/$PACKAGE/firefox-bin 1.195 } 1.196 1.197 # Pre - Post install command to set default locale. 1.198 pre_install() 1.199 { 1.200 - local root 1.201 - root=$1 1.202 - # Get old plugins 1.203 + local root="$1" 1.204 + # backup plugins 1.205 mkdir /tmp/firefox-plugins-$$ 1.206 cp -a $root/usr/lib/firefox/plugins/* /tmp/firefox-plugins-$$ 2> /dev/null 1.207 - # Remove old libs and configs 1.208 + # remove old libs and configs 1.209 rm -rf $root/usr/lib/firefox/plugins 1.210 rm -rf $root/usr/lib/firefox/dictionaries 1.211 - rm -rf $root/etc/firefox 1.212 } 1.213 + 1.214 post_install() 1.215 { 1.216 - local root 1.217 - root=$1 1.218 - if grep -q "fr_*" $root/etc/locale.conf 2>/dev/null; then 1.219 - sed -i 's/en-US/fr/' \ 1.220 - $root/etc/firefox/pref/firefox-l10n.js 1.221 - fi 1.222 + local root="$1" 1.223 + # restore plugins 1.224 for i in /tmp/firefox-plugins-$$/* ; do 1.225 [ -e $i ] || continue 1.226 [ -e /usr/lib/firefox/plugins/$(basename $i) ] && continue