#!/bin/sh # All comments and suggestions to Alak Trakru # # # $Id: MozillaFirefox.SlackBuild 30 2004-02-21 23:52:24Z freerock $ CWD=`pwd` if [ "$TMP" = "" ]; then TMP=/home/source/build fi PKG=$TMP/package-firefox VERSION=0.8 ARCH=i686 BUILD=2 if [ ! -d $TMP ]; then mkdir -p $TMP # location to build the source fi rm -rf $PKG mkdir -p $PKG cd $TMP tar xjvf $CWD/firefox-source-$VERSION.tar.bz2 cd mozilla cat $CWD/mozconfig > $TMP/mozilla/.mozconfig # CVS Builds: #cat $CWD/mozconfig > $CWD/mozilla/.mozconfig #cd $CWD/mozilla export MOZ_PHOENIX=1 ./configure make make install DESTDIR=$PKG # remove includes, should only build against official mozilla package # at this point ( cd $PKG/usr/local/ rm -rf include/ ) ( cd $PKG/usr/local/lib/ mv mozilla-1.6 MozillaFirefox ) ( cd $PKG/usr/local/share/idl mv mozilla-1.6 MozillaFirefox ) ( cd $PKG/usr/local/bin cp firefox firefox.orig sed -e 's#^moz_libdir=.*$#moz_libdir=/usr/local/lib/MozillaFirefox#' < firefox.orig > firefox rm -f firefox.orig ) chown -R root.bin $PKG/usr/local/bin # Remove things in common with Mozilla Suite package # Common things are not needed for runtime execution but are # needed to compile things against mozilla properly # # don't overwrite mozilla-config from mozilla suite rm -f $PKG/usr/local/bin/mozilla-config # remove aclocal.nspr.m4 rm -rf $PKG/usr/local/share/aclocal # remove pkgconfig stuff rm -rf $PKG/usr/local/lib/pkgconfig mkdir -p $PKG/usr/local/doc/MozillaFirefox-$VERSION cp -a LEGAL LICENSE README.txt \ $PKG/usr/local/doc/MozillaFirefox-$VERSION chmod 644 $PKG/usr/local/doc/MozillaFirefox-$VERSION/* chown root.root $PKG/usr/local/doc/MozillaFirefox-$VERSION/* mkdir -p $PKG/usr/share/gnome/apps/Internet cat $CWD/firefox.desktop > $PKG/usr/share/gnome/apps/Internet/firefox.desktop mkdir -p $PKG/usr/share/pixmaps cp $CWD/firefox-icon.png $PKG/usr/share/pixmaps find $PKG -type f | xargs file | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded gzip -9 $PKG/usr/local/man/*/* mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh cd $PKG makepkg -l y -c n $TMP/MozillaFirefox-$VERSION-$ARCH-$BUILD.tgz # Clean up the extra stuff: if [ "$1" = "--cleanup" ]; then rm -rf $TMP/mozilla rm -rf $PKG fi