mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-19 19:34:06 +00:00
python311Packages.numba: 2023-08-11 -> 0.58.0rc2
This commit is contained in:
parent
2e597489bd
commit
12ff8fb6bc
@ -12,7 +12,6 @@
|
||||
, importlib-metadata
|
||||
, substituteAll
|
||||
, runCommand
|
||||
, fetchpatch
|
||||
|
||||
, config
|
||||
|
||||
@ -29,15 +28,15 @@ let
|
||||
in buildPythonPackage rec {
|
||||
# Using an untagged version, with numpy 1.25 support, when it's released
|
||||
# also drop the versioneer patch in postPatch
|
||||
version = "unstable-2023-08-11";
|
||||
version = "0.58.0rc2";
|
||||
pname = "numba";
|
||||
format = "setuptools";
|
||||
disabled = pythonOlder "3.6" || pythonAtLeast "3.11";
|
||||
disabled = pythonOlder "3.6" || pythonAtLeast "3.12";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "numba";
|
||||
repo = "numba";
|
||||
rev = "6f0c5060a69656319ab0bae1d8bb89484cd5631f";
|
||||
rev = "refs/tags/${version}";
|
||||
# Upstream uses .gitattributes to inject information about the revision
|
||||
# hash and the refname into `numba/_version.py`, see:
|
||||
#
|
||||
@ -50,7 +49,7 @@ in buildPythonPackage rec {
|
||||
# use `forceFetchGit = true;`.` If in the future we'll observe the hash
|
||||
# changes too often, we can always use forceFetchGit, and inject the
|
||||
# relevant strings ourselves, using `sed` commands, in extraPostFetch.
|
||||
hash = "sha256-34qEn/i2X6Xu1cjuiRrmrm/HryNoN+Am4A4pJ90srAE=";
|
||||
hash = "sha256-ktFBjzd2vEahdr86lhVLVFEadCIhPP3hRF/EuZhHCC4=";
|
||||
};
|
||||
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isDarwin "-I${lib.getDev libcxx}/include/c++/v1";
|
||||
|
||||
@ -78,13 +77,6 @@ in buildPythonPackage rec {
|
||||
cuda_toolkit_lib_path = cudatoolkit.lib;
|
||||
})
|
||||
];
|
||||
# with untagged version we need to specify the correct version ourselves
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py --replace "version=versioneer.get_version()" "version='0.57.1'"
|
||||
substituteInPlace numba/_version.py \
|
||||
--replace 'git_refnames = " (HEAD -> main)"' 'git_refnames = "tag: 0.57.1"'
|
||||
'';
|
||||
|
||||
postFixup = lib.optionalString cudaSupport ''
|
||||
find $out -type f \( -name '*.so' -or -name '*.so.*' \) | while read lib; do
|
||||
|
Loading…
Reference in New Issue
Block a user