Firefox Packages on Slackware

Annika Backstrom
in misc, on 27 March 2005. It is tagged #Linux, #Scripting, and #Web.

One of the strengths of Slackware Linux is the easy-to-understand packaging system. The slackware ".tgz" format is what it looks like: a compressed archive in Tar/Gzip format. It can get slightly more complicated, but that's the foundation of all packages. The adoption of such a widely-used format allows system administrators to create working packages with very little learning curve.

I try to use packages when possible. Some pieces of software lend themselves to packages better than others, and Firefox is one of those packages. Firefox is available as a .tar.gz of files (as opposed to a graphical installer). The following script (download version) works nicely:


rm -rf $PKG


mkdir -p $PKG/usr/lib $PKG/usr/bin
cd $PKG/usr/lib

tar xzfv $CWD/firefox-$VERSION.tar.gz

cd $PKG/usr/bin
ln -s ../lib/firefox/firefox ./firefox

mkdir -p $PKG/usr/share/pixmaps
cp $CWD/Firefox.png $PKG/usr/share/pixmaps/Firefox.png

chown -R root:root $PKG
chown root.bin $PKG/usr/lib/firefox/firefox-bin

cd $PKG
makepkg -l y -c n ../firefox-$VERSION-$ARCH-$BUILD.tgz

Run this as root, and in no time at all you'll have a Slackware package that can be installed, uninstalled, and upgraded. This package requires the Firefox archive as well as the following image file, all stored in the same directory:

Firefox icon

You can download the whole package base (sans Firefox itself) if you please.