python3-numpy: update to 1.22.2.

This commit is contained in:
Andrew J. Hesford 2022-02-01 10:31:55 -05:00
parent deb0ea8b11
commit 2baa0002af
3 changed files with 31 additions and 36 deletions

View file

@ -1,34 +0,0 @@
From 50d5f1af8406165128a8567b0796ce244542f70c Mon Sep 17 00:00:00 2001
From: "Andrew J. Hesford" <ajh@sideband.org>
Date: Sat, 1 Jan 2022 10:48:33 -0500
Subject: [PATCH] BLD: Add NPY_DISABLE_SVML env var to opt out of SVML
---
numpy/core/setup.py | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/numpy/core/setup.py b/numpy/core/setup.py
index 0f2f3c21020..a67a4cab6a2 100644
--- a/numpy/core/setup.py
+++ b/numpy/core/setup.py
@@ -24,6 +24,11 @@
NPY_RELAXED_STRIDES_DEBUG = (os.environ.get('NPY_RELAXED_STRIDES_DEBUG', "0") != "0")
NPY_RELAXED_STRIDES_DEBUG = NPY_RELAXED_STRIDES_DEBUG and NPY_RELAXED_STRIDES_CHECKING
+# Set NPY_DISABLE_SVML=1 in the environment to disable the vendored SVML
+# library. This option only has significance on a Linux x86_64 host and is most
+# useful to avoid improperly requiring SVML when cross compiling.
+NPY_DISABLE_SVML = (os.environ.get('NPY_DISABLE_SVML', "0") == "1")
+
# XXX: ugly, we use a class to avoid calling twice some expensive functions in
# config.h/numpyconfig.h. I don't see a better way because distutils force
# config.h generation inside an Extension class, and as such sharing
@@ -68,6 +73,8 @@ def can_link_svml():
"""SVML library is supported only on x86_64 architecture and currently
only on linux
"""
+ if NPY_DISABLE_SVML:
+ return False
machine = platform.machine()
system = platform.system()
return "x86_64" in machine and system == "Linux"

View file

@ -0,0 +1,29 @@
From 7ed13c0e43c679dac4575f9911581665c62e6ad2 Mon Sep 17 00:00:00 2001
From: "Andrew J. Hesford" <ajh@sideband.org>
Date: Tue, 1 Feb 2022 10:18:42 -0500
Subject: [PATCH] Revert "MAINT: Raise RuntimeError if setuptools version is
too recent."
This reverts commit eb6be7c4765665724cd12431bfefb050ba0f2d4b.
---
setup.py | 4 ----
1 file changed, 4 deletions(-)
diff --git a/setup.py b/setup.py
index 06170df51..703fe79e1 100755
--- a/setup.py
+++ b/setup.py
@@ -80,10 +80,6 @@
# so that it is in sys.modules
import numpy.distutils.command.sdist
import setuptools
-if int(setuptools.__version__.split('.')[0]) >= 60:
- raise RuntimeError(
- "Setuptools version is '{}', version < '60.0.0' is required. "
- "See pyproject.toml".format(setuptools.__version__))
# Initialize cmdclass from versioneer
from numpy.distutils.core import numpy_cmdclass
--
2.35.0

View file

@ -1,6 +1,6 @@
# Template file for 'python3-numpy'
pkgname=python3-numpy
version=1.22.1
version=1.22.2
revision=1
wrksrc="numpy-${version}"
build_style=python3-module
@ -13,7 +13,7 @@ maintainer="Andrew J. Hesford <ajh@sideband.org>"
license="BSD-3-Clause"
homepage="https://www.numpy.org/"
distfiles="https://github.com/numpy/numpy/archive/v${version}.tar.gz"
checksum=7d916a1882a1a54e4121d96ca8ed67846a92bfb1f3ad65a314a3cb307432ccc9
checksum=8dfb2aa643bf9bc5b673006f60e2b7bfe4bcecb0686234e6f4902eb0596a32cc
alternatives="numpy:f2py:/usr/bin/f2py3"
# Tests do not function propery in a build directory
make_check="no"