nixpkgs/pkgs/applications/networking/browsers/firefox/packages.nix
2021-06-16 19:35:54 +09:00

59 lines
2.3 KiB
Nix

{ stdenv, lib, callPackage, fetchurl, fetchpatch, nixosTests }:
let
common = opts: callPackage (import ./common.nix opts) {};
in
rec {
firefox = common rec {
pname = "firefox";
ffversion = "89.0.1";
src = fetchurl {
url = "mirror://mozilla/firefox/releases/${ffversion}/source/firefox-${ffversion}.source.tar.xz";
sha512 = "67da387b3b6c5a110c83208f9a15d6064adf423bbebfb0fcad2d85f6c4b615b27da0cbd5486b817f0d5e040bc3e70d74d9af72599b24384397fef1dd153bd3f3";
};
meta = {
description = "A web browser built from Firefox source tree";
homepage = "http://www.mozilla.com/en-US/firefox/";
maintainers = with lib.maintainers; [ eelco lovesegfault hexa ];
platforms = lib.platforms.unix;
badPlatforms = lib.platforms.darwin;
broken = stdenv.buildPlatform.is32bit; # since Firefox 60, build on 32-bit platforms fails with "out of memory".
# not in `badPlatforms` because cross-compilation on 64-bit machine might work.
license = lib.licenses.mpl20;
};
tests = [ nixosTests.firefox ];
updateScript = callPackage ./update.nix {
attrPath = "firefox-unwrapped";
versionKey = "ffversion";
};
};
firefox-esr-78 = common rec {
pname = "firefox-esr";
ffversion = "78.11.0esr";
src = fetchurl {
url = "mirror://mozilla/firefox/releases/${ffversion}/source/firefox-${ffversion}.source.tar.xz";
sha512 = "d02fc2eda587155b1c54ca12a6c5cde220a29f41f154f1c9b71ae8f966d8cc9439201a5b241e03fc0795b74e2479f7aa5d6b69f70b7639432e5382f321f7a6f4";
};
meta = {
description = "A web browser built from Firefox Extended Support Release source tree";
homepage = "http://www.mozilla.com/en-US/firefox/";
maintainers = with lib.maintainers; [ eelco hexa ];
platforms = lib.platforms.unix;
badPlatforms = lib.platforms.darwin;
broken = stdenv.buildPlatform.is32bit; # since Firefox 60, build on 32-bit platforms fails with "out of memory".
# not in `badPlatforms` because cross-compilation on 64-bit machine might work.
license = lib.licenses.mpl20;
};
tests = [ nixosTests.firefox-esr ];
updateScript = callPackage ./update.nix {
attrPath = "firefox-esr-78-unwrapped";
versionSuffix = "esr";
versionKey = "ffversion";
};
};
}