Skip to content

Commit

Permalink
python312Packages.mercurial: fix build by upstream patch
Browse files Browse the repository at this point in the history
  • Loading branch information
vcunat committed Sep 12, 2024
1 parent 21a6190 commit b0b618e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions pkgs/applications/version-management/mercurial/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{ lib, stdenv, fetchurl, python3Packages, makeWrapper, gettext, installShellFiles
, fetchpatch
, re2Support ? true
# depends on rust-cpython which won't support python312
# https://github.com/dgrunwald/rust-cpython/commit/e815555629e557be084813045ca1ddebc2f76ef9
Expand Down Expand Up @@ -30,6 +31,14 @@ let
hash = "sha256-911qSnWCOht9cTpJZ+yi9Zb0ZuWPxrwG1yZCky/X4wc=";
};

patches = lib.optionals (!python3Packages.isPy311) [ # avoid rebuild on 3.11
(fetchpatch {
name = "circular-import.patch";
url = "https://foss.heptapod.net/mercurial/mercurial-devel/-/commit/63ede7a43a3731fecc7e5b535144c6bd59911284.diff";
hash = "sha256-qoqg1QCHhfzTXmp0sfJvsH2SCP+KRjuIy+TJZFHqAQw=";
})
];

format = "other";

passthru = { inherit python; }; # pass it so that the same version can be used in hg2git
Expand Down

0 comments on commit b0b618e

Please sign in to comment.