firefox-patches/default.nix

43 lines
1.2 KiB
Nix
Raw Normal View History

2017-09-20 20:39:03 +02:00
{ pkgs ? import <nixpkgs> { } }:
let
firefox = pkgs.firefox-unwrapped.override {
gtk3Support = true;
enableOfficialBranding = true;
privacySupport = true;
pulseaudioSupport = false;
};
patched = firefox.overrideDerivation (base: {
2017-10-19 08:44:05 +02:00
patches = base.patches ++ [
2017-10-17 23:11:44 +02:00
./allow-anonymous-user-style.patch
2017-09-20 20:39:03 +02:00
./disable-datasharing-infobar.patch
./disable-locationservice.patch
./disable-sponsored-tiles.patch
2017-11-20 20:14:25 +01:00
./disable-system-addons.patch
2017-09-20 20:39:03 +02:00
./disable-telemetry.patch
./disable-reader.patch
./disable-pocket.patch
2017-11-20 20:14:25 +01:00
./disable-send-to-device.patch
./disable-dbus.patch
2017-09-20 20:39:03 +02:00
./preferences.patch
];
2017-11-20 20:14:25 +01:00
2017-09-20 20:39:03 +02:00
postPatch = ''
2017-11-20 20:14:25 +01:00
sed -e '/browser\/extensions/d' \
-e '/browser\/components\/Experiments/d' \
-e '/browser\/features/d' \
-e '/pdfjs/d' \
2017-09-20 20:39:03 +02:00
-i browser/installer/package-manifest.in
: > browser/extensions/moz.build
'';
configureFlags = base.configureFlags ++ [
"--disable-dbus"
"--disable-gconf"
"--disable-eme"
2017-11-20 20:14:25 +01:00
];
2017-09-20 20:39:03 +02:00
});
in
pkgs.wrapFirefox patched { }