2008-06-17 12:53:08 +02:00
|
|
|
{ stdenv, fetchurl, pkgconfig, gtk, pango, perl, python, zip, libIDL
|
2008-10-30 14:00:50 +01:00
|
|
|
, libjpeg, zlib, cairo, dbus, dbus_glib, bzip2
|
|
|
|
, freetype, fontconfig, xulrunner
|
2008-06-17 12:53:08 +02:00
|
|
|
|
|
|
|
, # If you want the resulting program to call itself "Firefox" instead
|
|
|
|
# of "Deer Park", enable this option. However, those binaries may
|
|
|
|
# not be distributed without permission from the Mozilla Foundation,
|
|
|
|
# see http://www.mozilla.org/foundation/trademarks/.
|
|
|
|
enableOfficialBranding ? false
|
|
|
|
|
|
|
|
}:
|
2008-02-13 11:36:53 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2009-01-05 18:34:32 +01:00
|
|
|
name = "firefox-3.0.5";
|
2008-02-13 11:36:53 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2009-01-05 18:34:32 +01:00
|
|
|
url = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.0.5/source/firefox-3.0.5-source.tar.bz2;
|
|
|
|
sha1 = "f934e073efaad3d4dde847c8491fa9529564d5d2";
|
2008-02-13 11:36:53 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [
|
2008-10-30 14:00:50 +01:00
|
|
|
pkgconfig gtk perl zip libIDL libjpeg zlib cairo bzip2
|
2008-06-17 12:53:08 +02:00
|
|
|
python dbus dbus_glib pango freetype fontconfig
|
2008-02-13 11:36:53 +01:00
|
|
|
];
|
|
|
|
|
2008-10-30 14:00:50 +01:00
|
|
|
propagatedBuildInputs = [xulrunner];
|
|
|
|
|
2008-02-13 11:36:53 +01:00
|
|
|
configureFlags = [
|
|
|
|
"--enable-application=browser"
|
|
|
|
"--enable-optimize"
|
|
|
|
"--disable-debug"
|
|
|
|
"--enable-strip"
|
|
|
|
"--with-system-jpeg"
|
|
|
|
"--with-system-zlib"
|
2008-06-17 12:53:08 +02:00
|
|
|
"--with-system-bz2"
|
|
|
|
# "--with-system-png" # <-- "--with-system-png won't work because the system's libpng doesn't have APNG support"
|
2008-09-04 11:33:59 +02:00
|
|
|
"--enable-system-cairo"
|
2008-06-17 12:53:08 +02:00
|
|
|
#"--enable-system-sqlite" # <-- this seems to be discouraged
|
|
|
|
"--disable-crashreporter"
|
2008-10-30 14:00:50 +01:00
|
|
|
"--with-libxul-sdk=${xulrunner}/lib/xulrunner-devel-${xulrunner.version}"
|
2008-02-13 11:36:53 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
2008-10-30 14:00:50 +01:00
|
|
|
# Strip some more stuff.
|
2008-02-13 11:36:53 +01:00
|
|
|
strip -S $out/lib/*/* || true
|
|
|
|
|
|
|
|
libDir=$(cd $out/lib && ls -d firefox-[0-9]*)
|
|
|
|
test -n "$libDir"
|
2008-10-30 14:00:50 +01:00
|
|
|
|
|
|
|
ln -s ${xulrunner}/lib/xulrunner-${xulrunner.version} $out/lib/$libDir/xulrunner
|
2008-02-13 11:36:53 +01:00
|
|
|
|
2008-10-30 14:00:50 +01:00
|
|
|
# Register extensions etc. !!! is this needed anymore?
|
2008-02-13 11:36:53 +01:00
|
|
|
echo "running firefox -register..."
|
2008-10-30 14:00:50 +01:00
|
|
|
$out/bin/firefox -register
|
2008-02-13 11:36:53 +01:00
|
|
|
''; # */
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Mozilla Firefox - the browser, reloaded";
|
|
|
|
homepage = http://www.mozilla.com/en-US/firefox/;
|
|
|
|
};
|
|
|
|
|
2008-10-30 14:00:50 +01:00
|
|
|
passthru = {
|
|
|
|
inherit gtk;
|
|
|
|
isFirefox3Like = true;
|
|
|
|
};
|
2008-02-13 11:36:53 +01:00
|
|
|
}
|
|
|
|
|
2008-03-16 09:01:31 +01:00
|
|
|
|