Unverified Commit dd0e1ee3 authored by Vladimír Čunát's avatar Vladimír Čunát
Browse files

thunderbird: refactor (prepare for version 128)

parent 4d9989e5
Loading
Loading
Loading
Loading
+17 −10
Original line number Diff line number Diff line
{ stdenv, lib, buildMozillaMach, callPackage, fetchurl, fetchpatch, nixosTests, icu73, fetchpatch2, config }:

rec {
  thunderbird = thunderbird-115;

  thunderbird-115 = (buildMozillaMach rec {
let
  common = { version, sha512, updateScript }: (buildMozillaMach rec {
    pname = "thunderbird";
    version = "115.12.2";
    inherit version updateScript;
    application = "comm/mail";
    applicationName = "Mozilla Thunderbird";
    binaryName = pname;
    src = fetchurl {
      url = "mirror://mozilla/thunderbird/releases/${version}/source/thunderbird-${version}.source.tar.xz";
      sha512 = "182f35e8e5ece98d18dfefe106c73bc97fbc619f59772d9b3455b7c8af412021ecc5eae97a12515224e91deb814abb7a6ef7f538c450e9e77fdfd84078678038";
      inherit sha512;
    };
    extraPatches = [
      # The file to be patched is different from firefox's `no-buildconfig-ffx90.patch`.
@@ -30,10 +28,6 @@ rec {
                                             # not in `badPlatforms` because cross-compilation on 64-bit machine might work.
      license = licenses.mpl20;
    };
    updateScript = callPackage ./update.nix {
      attrPath = "thunderbird-unwrapped";
      versionPrefix = "115";
    };
  }).override {
    geolocationSupport = false;
    webrtcSupport = false;
@@ -51,6 +45,19 @@ rec {
      })];
    });
  };

in rec {
  thunderbird = thunderbird-115;

  thunderbird-115 = common {
    version = "115.12.2";
    sha512 = "182f35e8e5ece98d18dfefe106c73bc97fbc619f59772d9b3455b7c8af412021ecc5eae97a12515224e91deb814abb7a6ef7f538c450e9e77fdfd84078678038";

    updateScript = callPackage ./update.nix {
      attrPath = "thunderbirdPackages.thunderbird-115";
      versionPrefix = "115";
    };
  };
}
 // lib.optionalAttrs config.allowAliases {
  thunderbird-102 = throw "Thunderbird 102 support ended in September 2023";
+1 −1
Original line number Diff line number Diff line
@@ -3,5 +3,5 @@
}@args:

callPackage ../../browsers/firefox/update.nix ({
  baseUrl = "http://archive.mozilla.org/pub/thunderbird/releases/";
  baseUrl = "https://archive.mozilla.org/pub/thunderbird/releases/";
} // (builtins.removeAttrs args ["callPackage"]))