Skip to content

Commit

Permalink
python310Packages.mxnet: add numpy >=1.24 compatibility patch
Browse files Browse the repository at this point in the history
  • Loading branch information
oddlama committed Jul 29, 2023
1 parent 78faafa commit e98b498
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkgs/development/python-modules/mxnet/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,17 @@ buildPythonPackage {

LD_LIBRARY_PATH = lib.makeLibraryPath [ pkgs.mxnet ];

env.NIX_CFLAGS_COMPILE = toString [
# Needed with GCC 12
"-Wno-error=uninitialized"
];

doCheck = !isPy3k;

postPatch = ''
# Required to support numpy >=1.24 where np.bool is removed in favor of just bool
substituteInPlace python/mxnet/numpy/utils.py \
--replace "bool = onp.bool" "bool = bool"
substituteInPlace python/setup.py \
--replace "graphviz<0.9.0," "graphviz"
'';
Expand Down

0 comments on commit e98b498

Please sign in to comment.