diff --git a/pkgs/applications/networking/browsers/firefox/3.5.nix b/pkgs/applications/networking/browsers/firefox/3.5.nix index 6e544e47ca9..e223021f3e2 100644 --- a/pkgs/applications/networking/browsers/firefox/3.5.nix +++ b/pkgs/applications/networking/browsers/firefox/3.5.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, pkgconfig, gtk, pango, perl, python, zip, libIDL , libjpeg, libpng, zlib, cairo, dbus, dbus_glib, bzip2, xlibs -, freetype, fontconfig, file, alsaLib +, freetype, fontconfig, file, alsaLib, nspr , # If you want the resulting program to call itself "Firefox" instead # of "Deer Park", enable this option. However, those binaries may @@ -29,10 +29,12 @@ rec { "--with-system-jpeg" "--with-system-zlib" "--with-system-bz2" + "--with-system-nspr" # "--with-system-png" # <-- "--with-system-png won't work because the system's libpng doesn't have APNG support" "--enable-system-cairo" #"--enable-system-sqlite" # <-- this seems to be discouraged "--disable-crashreporter" + "--disable-tests" ]; @@ -45,7 +47,7 @@ rec { [ pkgconfig gtk perl zip libIDL libjpeg libpng zlib cairo bzip2 python dbus dbus_glib pango freetype fontconfig xlibs.libXi xlibs.libX11 xlibs.libXrender xlibs.libXft xlibs.libXt file - alsaLib + alsaLib nspr ]; configureFlags = @@ -63,8 +65,6 @@ rec { postInstall = '' export dontPatchELF=1 - make -C nsprpub install - # Fix some references to /bin paths in the Xulrunner shell script. substituteInPlace $out/bin/xulrunner \ --replace /bin/pwd "$(type -tP pwd)" \ @@ -102,7 +102,7 @@ rec { buildInputs = [ pkgconfig gtk perl zip libIDL libjpeg zlib cairo bzip2 python - dbus dbus_glib pango freetype fontconfig alsaLib + dbus dbus_glib pango freetype fontconfig alsaLib nspr ]; propagatedBuildInputs = [xulrunner]; @@ -110,7 +110,6 @@ rec { configureFlags = [ "--enable-application=browser" "--with-libxul-sdk=${xulrunner}/lib/xulrunner-devel-${xulrunner.version}" - "--with-system-nspr" ] ++ commonConfigureFlags ++ stdenv.lib.optional enableOfficialBranding "--enable-official-branding"; diff --git a/pkgs/development/libraries/nspr/default.nix b/pkgs/development/libraries/nspr/default.nix new file mode 100644 index 00000000000..3895a6fbc89 --- /dev/null +++ b/pkgs/development/libraries/nspr/default.nix @@ -0,0 +1,21 @@ +{stdenv, fetchurl}: + +let version = "4.8"; in + +stdenv.mkDerivation { + name = "nspr-${version}"; + + src = fetchurl { + url = "http://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v${version}/src/nspr-${version}.tar.gz"; + sha256 = "1znvc7fb4f6318kbn1w86p134r4cslij25sg7kcspfx746m89pm2"; + }; + + preConfigure = "cd mozilla/nsprpub"; + + configureFlags = "--enable-optimize --disable-debug"; + + meta = { + homepage = http://www.mozilla.org/projects/nspr/; + description = "Netscape Portable Runtime, a platform-neutral API for system-level and libc-like functions"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ee331ad1330..a3dddee5b34 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3886,6 +3886,10 @@ let inherit fetchurl stdenv; }; + nspr = import ../development/libraries/nspr { + inherit fetchurl stdenv; + }; + nss = import ../development/libraries/nss { inherit fetchurl stdenv perl zip; }; @@ -6291,7 +6295,8 @@ let firefox35Pkgs = lowPrio (import ../applications/networking/browsers/firefox/3.5.nix { inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo - python dbus dbus_glib freetype fontconfig bzip2 xlibs file alsaLib; + python dbus dbus_glib freetype fontconfig bzip2 xlibs file alsaLib + nspr; inherit (gtkLibs) gtk pango; inherit (gnome) libIDL; });