mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-17 06:09:02 +00:00
python3Packages.pygraphviz: unbreak on Darwin
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
replaceVars,
|
||||
stdenv,
|
||||
graphviz,
|
||||
coreutils,
|
||||
pkg-config,
|
||||
@@ -11,6 +12,10 @@
|
||||
pytest,
|
||||
}:
|
||||
|
||||
let
|
||||
# TODO: remove once #540793 makes it to master
|
||||
graphviz' = graphviz.override { withQuartz = stdenv.hostPlatform.isDarwin; };
|
||||
in
|
||||
buildPythonPackage (finalAttrs: {
|
||||
pname = "pygraphviz";
|
||||
version = "2.0";
|
||||
@@ -27,7 +32,7 @@ buildPythonPackage (finalAttrs: {
|
||||
# pygraphviz depends on graphviz executables and wc being in PATH
|
||||
(replaceVars ./path.patch {
|
||||
path = lib.makeBinPath [
|
||||
graphviz
|
||||
graphviz'
|
||||
coreutils
|
||||
];
|
||||
})
|
||||
@@ -38,19 +43,19 @@ buildPythonPackage (finalAttrs: {
|
||||
--replace-fail ', "swig>4.1.0"' ""
|
||||
'';
|
||||
|
||||
env.GRAPHVIZ_PREFIX = graphviz;
|
||||
env.GRAPHVIZ_PREFIX = graphviz';
|
||||
|
||||
build-system = [
|
||||
setuptools
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
graphviz # for dot
|
||||
graphviz' # for dot
|
||||
pkg-config
|
||||
swig
|
||||
];
|
||||
|
||||
buildInputs = [ graphviz ];
|
||||
buildInputs = [ graphviz' ];
|
||||
|
||||
nativeCheckInputs = [ pytest ];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user