commit:     358874f189c9f8d2e1532ba9933ee57ac8942a95
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 12 15:20:37 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jun 12 15:21:15 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=358874f1

dev-python/numpy: add 1.25.0_rc1

Closes: https://bugs.gentoo.org/907309
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-python/numpy/Manifest                          |   1 +
 .../numpy-1.25.0_rc1-meson-pyproject.toml.patch    | 392 +++++++++++++++++++++
 dev-python/numpy/numpy-1.25.0_rc1.ebuild           | 127 +++++++
 3 files changed, 520 insertions(+)

diff --git a/dev-python/numpy/Manifest b/dev-python/numpy/Manifest
index 03f5af123481..19af51f0f374 100644
--- a/dev-python/numpy/Manifest
+++ b/dev-python/numpy/Manifest
@@ -1,3 +1,4 @@
 DIST numpy-1.24.0.tar.gz 10897101 BLAKE2B 
59e2b913f90de76589d8fbb2f07e2d389012c7f6ce9bd641bc4837776465ce9c41c34f19f92bee55d4bae6245c1d2c84315b359ef0b089fd68d31cd7e7ec44b1
 SHA512 
3b4e6255b8d39e8504a50ecd3c2ba09d5b16d3f6c70b23b67e4dbf03d1fe390c55030f46090341d39a1ee8228c61ad6212fdc6e4579fcec9e26b4dbe70268661
 DIST numpy-1.24.2.tar.gz 10906862 BLAKE2B 
e48f65eab709f0c57ec378d813a7b65bcaca6d5960b559d6db1c60726e5cf12517f4b2e1636b0ff815a2109925edccba200270db5170fd0aff5fd635919165ac
 SHA512 
145fd7fb3919a185f75076d51b92c54a7fb1b776b637752ca15fdee15b239d6a517ef1bb8cded7c92e059cf6cda0146c24943c042d19b791e81125bc0ad4b820
 DIST numpy-1.24.3.tar.gz 10909904 BLAKE2B 
3b14f8b6a7bd484de43c3b0e57f161388d6226e05ed9bc3d1edfaafc713b9597c7574b9b9c20b4e3a6bd291d32a607d95c72d6e25fa346ffdaf97c94767bc315
 SHA512 
d4b5841cbe68ee6653f99018e4e0182f2e5519a1cd69c14e0a95aa180f878e6a6786ccf0a7c78bf0d511c53e7535d7144fee428572dec7a4b60b25c8a1c0c9e1
+DIST numpy-1.25.0rc1.tar.gz 10424626 BLAKE2B 
3f95bfd2f5524c35bb054b06ea697d06d217ec12a22b477b1b9bb8ba9c8e47e0463b662bf3854caf729f5202791ae4bc40ca684cfeee870a9f4c3b372bf6a9b9
 SHA512 
0dd7805d642549b59f2496fb1feb132b1bfc9457d7cb7c088161c8b330d11825541668dd3fba20901d68a3dfb86baf28961988993ef3c5ff2a8ed39f6fba616c

diff --git a/dev-python/numpy/files/numpy-1.25.0_rc1-meson-pyproject.toml.patch 
b/dev-python/numpy/files/numpy-1.25.0_rc1-meson-pyproject.toml.patch
new file mode 100644
index 000000000000..b42e6cec1c73
--- /dev/null
+++ b/dev-python/numpy/files/numpy-1.25.0_rc1-meson-pyproject.toml.patch
@@ -0,0 +1,392 @@
+https://github.com/numpy/numpy/pull/23838
+
+From 669c1a16f9e905b5b33017aa1a17cc59716ccfc7 Mon Sep 17 00:00:00 2001
+From: Ralf Gommers <[email protected]>
+Date: Mon, 29 May 2023 16:16:41 +0200
+Subject: [PATCH 01/11] BLD: default to using meson-python as build backend
+
+---
+ pyproject.toml                 | 137 ++++++++++++++++-----------------
+ 3 files changed, 66 insertions(+), 77 deletions(-)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index 759b538fb6e..9f03fa8d0e5 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -1,79 +1,72 @@
+ [build-system]
+-# Uncomment this line, the `meson-python` requires line, and the [project] and
+-# [project.urls] tables below in order to build with Meson by default
+-#build-backend = "mesonpy"
++build-backend = "mesonpy"
+ requires = [
+-    # setuptools, wheel and Cython are needed for the setup.py based build
+-    "setuptools==59.2.0",
+-    # `wheel` is needed for non-isolated builds, given that `meson-python`
+-    # doesn't list it as a runtime requirement (at least in 0.11.0) - it's
+-    # likely to be removed as a dependency in meson-python 0.12.0.
+-    "wheel==0.38.1",
+-    "Cython>=0.29.34,<3.0",
+-#    "meson-python>=0.10.0",
++    "Cython>=0.29.34",
++    "meson-python>=0.13.1",
+ ]
+ 
+-#[project]
+-#name = "numpy"
+-#
+-## Using https://peps.python.org/pep-0639/
+-## which is still in draft
+-#license = {text = "BSD-3-Clause"}
+-## Note: needed for Meson, but setuptools errors on it. Uncomment once Meson 
is default.
+-##license-files.paths = [
+-##    "LICENSE.txt",
+-##    "LICENSES_bundles.txt"
+-##]
+-#
+-#description = "Fundamental package for array computing in Python"
+-#authors = [{name = "Travis E. Oliphant et al."}]
+-#maintainers = [
+-#    {name = "NumPy Developers", email="[email protected]"},
+-#]
+-#requires-python = ">=3.9"
+-#readme = "README.md"
+-#classifiers = [
+-#    'Development Status :: 5 - Production/Stable',
+-#    'Intended Audience :: Science/Research',
+-#    'Intended Audience :: Developers',
+-#    'License :: OSI Approved :: BSD License',
+-#    'Programming Language :: C',
+-#    'Programming Language :: Python',
+-#    'Programming Language :: Python :: 3',
+-#    'Programming Language :: Python :: 3.9',
+-#    'Programming Language :: Python :: 3.10',
+-#    'Programming Language :: Python :: 3.11',
+-#    'Programming Language :: Python :: 3 :: Only',
+-#    'Programming Language :: Python :: Implementation :: CPython',
+-#    'Topic :: Software Development',
+-#    'Topic :: Scientific/Engineering',
+-#    'Typing :: Typed',
+-#    'Operating System :: Microsoft :: Windows',
+-#    'Operating System :: POSIX',
+-#    'Operating System :: Unix',
+-#    'Operating System :: MacOS',
+-#]
+-#dynamic = ["version", "scripts"]
+-#
+-#[project.scripts]
+-## Note: this is currently dynamic, see setup.py. Can we get rid of that?
+-##       see commit f22a33b71 for rationale for dynamic behavior
+-#'f2py = numpy.f2py.f2py2e:main'
+-#'f2py3 = numpy.f2py.f2py2e:main'
+-#'f2py3.MINOR_VERSION = numpy.f2py.f2py2e:main'
+-#
+-# When enabling this stanza, make sure to remove the meson-specific xfail from
+-# numpy/tests/test_public_api.py
+-#[project.entry-points]
+-#'array_api': 'numpy = numpy.array_api'
+-#'pyinstaller40': 'hook-dirs = numpy:_pyinstaller_hooks_dir'
+-#
+-#[project.urls]
+-#homepage = "https://numpy.org";
+-#documentation = "https://numpy.org/doc/";
+-#source = "https://github.com/numpy/numpy";
+-#download = "https://pypi.org/project/numpy/#files";
+-#tracker = "https://github.com/numpy/numpy/issues";
++[project]
++name = "numpy"
++version = "2.0.0.dev0"
++
++# Using https://peps.python.org/pep-0639/ which is still in draft
++license = {text = "BSD-3-Clause"}
++license-files.paths = [
++    "LICENSE.txt",
++    "LICENSES_bundles.txt"
++]
++
++description = "Fundamental package for array computing in Python"
++authors = [{name = "Travis E. Oliphant et al."}]
++maintainers = [
++    {name = "NumPy Developers", email="[email protected]"},
++]
++requires-python = ">=3.9"
++readme = "README.md"
++classifiers = [
++    'Development Status :: 5 - Production/Stable',
++    'Intended Audience :: Science/Research',
++    'Intended Audience :: Developers',
++    'License :: OSI Approved :: BSD License',
++    'Programming Language :: C',
++    'Programming Language :: Python',
++    'Programming Language :: Python :: 3',
++    'Programming Language :: Python :: 3.9',
++    'Programming Language :: Python :: 3.10',
++    'Programming Language :: Python :: 3.11',
++    'Programming Language :: Python :: 3.12',
++    'Programming Language :: Python :: 3 :: Only',
++    'Programming Language :: Python :: Implementation :: CPython',
++    'Topic :: Software Development',
++    'Topic :: Scientific/Engineering',
++    'Typing :: Typed',
++    'Operating System :: Microsoft :: Windows',
++    'Operating System :: POSIX',
++    'Operating System :: Unix',
++    'Operating System :: MacOS',
++]
++#dynamic = ["scripts"]
++
++[project.scripts]
++# TODO: this is currently dynamic for minor version support. See also the same
++# thing in setup.py. Can we get rid of that? see commit f22a33b71 for 
rationale
++# for dynamic behavior.
++f2py = 'numpy.f2py.f2py2e:main'
++f2py3 = 'numpy.f2py.f2py2e:main'
++#f2py3.MINOR_VERSION = 'numpy.f2py.f2py2e:main'
++
++[project.entry-points.array_api]
++numpy = 'numpy.array_api'
++
++[project.entry-points.pyinstaller40]
++hook-dirs = 'numpy:_pyinstaller_hooks_dir'
++
++[project.urls]
++homepage = "https://numpy.org";
++documentation = "https://numpy.org/doc/";
++source = "https://github.com/numpy/numpy";
++download = "https://pypi.org/project/numpy/#files";
++tracker = "https://github.com/numpy/numpy/issues";
+ 
+ [tool.towncrier]
+     # Do no set this since it is hard to import numpy inside the source 
directory
+
+From 02cae331443d6955dba8ce5e981c24a7b6c01ec6 Mon Sep 17 00:00:00 2001
+From: Ralf Gommers <[email protected]>
+Date: Mon, 29 May 2023 18:51:54 +0200
+Subject: [PATCH 04/11] BLD: fix bug with CMake fallback detection of
+ BLAS/LAPACK
+
+---
+ numpy/meson.build | 11 +++++++----
+ 1 file changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/numpy/meson.build b/numpy/meson.build
+index 7b85d8e92f5..ad1829a78db 100644
+--- a/numpy/meson.build
++++ b/numpy/meson.build
+@@ -198,10 +198,13 @@ foreach name, dep : dependency_map
+   if dep.found()
+     conf_data.set(name + '_VERSION', dep.version())
+     conf_data.set(name + '_TYPE_NAME', dep.type_name())
+-    conf_data.set(name + '_INCLUDEDIR', dep.get_variable('includedir'))
+-    conf_data.set(name + '_LIBDIR', dep.get_variable('libdir'))
+-    conf_data.set(name + '_OPENBLAS_CONFIG', 
dep.get_variable('openblas_config'))
+-    conf_data.set(name + '_PCFILEDIR', dep.get_variable('pcfiledir'))
++    if dep.type_name() == 'pkgconfig'
++      # CMake detection yields less info, so we need to leave it blank there
++      conf_data.set(name + '_INCLUDEDIR', dep.get_variable('includedir'))
++      conf_data.set(name + '_LIBDIR', dep.get_variable('libdir'))
++      conf_data.set(name + '_OPENBLAS_CONFIG', 
dep.get_variable('openblas_config'))
++      conf_data.set(name + '_PCFILEDIR', dep.get_variable('pcfiledir'))
++    endif
+   endif
+ endforeach
+ 
+
+From 84bea46fab251edd31bee8d8eae174cf2cb9315b Mon Sep 17 00:00:00 2001
+From: Ralf Gommers <[email protected]>
+Date: Mon, 29 May 2023 19:15:29 +0200
+Subject: [PATCH 06/11] CI: keep the Emscripten/Pyodide job on a setup.py-based
+ build
+
+---
+ pyproject.toml.setuppy           | 9 +++++++++
+ 2 files changed, 14 insertions(+), 1 deletion(-)
+ create mode 100644 pyproject.toml.setuppy
+
+diff --git a/pyproject.toml.setuppy b/pyproject.toml.setuppy
+new file mode 100644
+index 00000000000..b28d93c8d52
+--- /dev/null
++++ b/pyproject.toml.setuppy
+@@ -0,0 +1,9 @@
++# pyproject.toml needed to build with setup.py
++# This file is used temporarily to replace the main pyproject.toml when 
needing
++# to avoid building with Meson (e.g., in the Emscripten/Pyodide CI job)
++[build-system]
++requires = [
++    "setuptools==59.2.0",
++    "wheel==0.38.1",
++    "Cython>=0.29.34,<3.0",
++]
+
+From 027de0ab6d24e6336682ef6fa150ae09f007a5da Mon Sep 17 00:00:00 2001
+From: mattip <[email protected]>
+Date: Sun, 11 Jun 2023 16:11:34 +0300
+Subject: [PATCH 07/11] use MSVC and force 64-bit OpenBLAS interfaces
+
+---
+ pyproject.toml | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index 9f03fa8d0e5..6cef90c6962 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -167,6 +167,11 @@ environment = { OPENBLAS64_="openblas", OPENBLAS="", 
NPY_USE_BLAS_ILP64="1", CFL
+ select = "*-win32"
+ environment = { OPENBLAS64_="", OPENBLAS="openblas", NPY_USE_BLAS_ILP64="0", 
CFLAGS="-m32", LDFLAGS="-m32" }
+ 
++[tool.meson-python.args]
++setup = ['--vsenv']
++# This should not be set on 32-bit builds...
++compile = ['-DBLAS_SYMBOL_SUFFIX=64_']
++
+ [tool.spin]
+ package = 'numpy'
+ 
+
+From 9ce0d806a881c87a203efccf106cf5d3d6bb46e0 Mon Sep 17 00:00:00 2001
+From: mattip <[email protected]>
+Date: Sun, 11 Jun 2023 16:28:35 +0300
+Subject: [PATCH 08/11] drop rtools in wheel builds, do
+ -DDBLAS_SYMBOL_SUFFIX=64_ differently
+
+---
+ pyproject.toml               |  8 +++-----
+ 2 files changed, 3 insertions(+), 16 deletions(-)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index 6cef90c6962..a9d7f87b2b5 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -147,7 +147,7 @@ test-command = "bash 
{project}/tools/wheels/cibw_test_command.sh {project}"
+ manylinux-x86_64-image = "manylinux2014"
+ manylinux-aarch64-image = "manylinux2014"
+ musllinux-x86_64-image = "musllinux_1_1"
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing", 
LDFLAGS="-Wl,--strip-debug", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
RUNNER_OS="Linux" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DDBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="-Wl,--strip-debug", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux" }
+ 
+ [tool.cibuildwheel.macos]
+ # For universal2 wheels, we will need to fuse them manually
+@@ -158,10 +158,10 @@ environment = { CFLAGS="-std=c99 -fno-strict-aliasing", 
LDFLAGS="-Wl,--strip-deb
+ archs = "x86_64 arm64"
+ test-skip = "*_universal2:arm64"
+ # MACOS linker doesn't support stripping symbols
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", CC="clang", CXX = "clang++", 
RUNNER_OS="macOS" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DDBLAS_SYMBOL_SUFFIX=64_", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS" }
+ 
+ [tool.cibuildwheel.windows]
+-environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="", LDFLAGS="" }
++environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DDBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="" }
+ 
+ [[tool.cibuildwheel.overrides]]
+ select = "*-win32"
+@@ -169,8 +169,6 @@ environment = { OPENBLAS64_="", OPENBLAS="openblas", 
NPY_USE_BLAS_ILP64="0", CFL
+ 
+ [tool.meson-python.args]
+ setup = ['--vsenv']
+-# This should not be set on 32-bit builds...
+-compile = ['-DBLAS_SYMBOL_SUFFIX=64_']
+ 
+ [tool.spin]
+ package = 'numpy'
+
+From 067e51454eeff3ce302144803baef92add308668 Mon Sep 17 00:00:00 2001
+From: mattip <[email protected]>
+Date: Sun, 11 Jun 2023 17:05:02 +0300
+Subject: [PATCH 09/11] typo, install pkg-config on windows
+
+---
+ pyproject.toml               | 6 +++---
+ 2 files changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index a9d7f87b2b5..a0b645938d1 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -147,7 +147,7 @@ test-command = "bash 
{project}/tools/wheels/cibw_test_command.sh {project}"
+ manylinux-x86_64-image = "manylinux2014"
+ manylinux-aarch64-image = "manylinux2014"
+ musllinux-x86_64-image = "musllinux_1_1"
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DDBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="-Wl,--strip-debug", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="-Wl,--strip-debug", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux" }
+ 
+ [tool.cibuildwheel.macos]
+ # For universal2 wheels, we will need to fuse them manually
+@@ -158,10 +158,10 @@ environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DDBLAS_SYMBOL_SUFFIX=64_"
+ archs = "x86_64 arm64"
+ test-skip = "*_universal2:arm64"
+ # MACOS linker doesn't support stripping symbols
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DDBLAS_SYMBOL_SUFFIX=64_", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS" }
+ 
+ [tool.cibuildwheel.windows]
+-environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DDBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="" }
++environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="" }
+ 
+ [[tool.cibuildwheel.overrides]]
+ select = "*-win32"
+
+From 9999c3f3a8c7facef77dc9859a8a25f39f14f7fd Mon Sep 17 00:00:00 2001
+From: mattip <[email protected]>
+Date: Sun, 11 Jun 2023 22:18:57 +0300
+Subject: [PATCH 10/11] set PKG_CONFIG_PATH for windows, add CXXFLAGS
+
+---
+ pyproject.toml                    | 6 +++---
+ 2 files changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index a0b645938d1..32bde348d7d 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -147,7 +147,7 @@ test-command = "bash 
{project}/tools/wheels/cibw_test_command.sh {project}"
+ manylinux-x86_64-image = "manylinux2014"
+ manylinux-aarch64-image = "manylinux2014"
+ musllinux-x86_64-image = "musllinux_1_1"
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="-Wl,--strip-debug", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS="-Wl,--strip-debug", 
CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", 
OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux"}
+ 
+ [tool.cibuildwheel.macos]
+ # For universal2 wheels, we will need to fuse them manually
+@@ -158,10 +158,10 @@ environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_",
+ archs = "x86_64 arm64"
+ test-skip = "*_universal2:arm64"
+ # MACOS linker doesn't support stripping symbols
+-environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS" }
++environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ 
-DHAVE_BLAS_ILP64", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS"}
+ 
+ [tool.cibuildwheel.windows]
+-environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_", LDFLAGS="" }
++environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", 
CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS=""}
+ 
+ [[tool.cibuildwheel.overrides]]
+ select = "*-win32"
+
+From ffcd334bd9da7ce4779e79636ecd047e2f20dd5b Mon Sep 17 00:00:00 2001
+From: mattip <[email protected]>
+Date: Sun, 11 Jun 2023 23:17:00 +0300
+Subject: [PATCH 11/11] disable pypy builds, move PKG_CONFIG_PATH for windows
+
+---
+ pyproject.toml                    | 4 ++--
+ 3 files changed, 4 insertions(+), 5 deletions(-)
+
+diff --git a/pyproject.toml b/pyproject.toml
+index 32bde348d7d..55065d1362f 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -161,11 +161,11 @@ test-skip = "*_universal2:arm64"
+ environment = { CFLAGS="-std=c99 -fno-strict-aliasing 
-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ 
-DHAVE_BLAS_ILP64", OPENBLAS64_="/usr/local", NPY_USE_BLAS_ILP64="1", 
CC="clang", CXX = "clang++", RUNNER_OS="macOS"}
+ 
+ [tool.cibuildwheel.windows]
+-environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", 
CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS=""}
++environment = { OPENBLAS64_="openblas", OPENBLAS="", NPY_USE_BLAS_ILP64="1", 
CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", 
CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS="", 
PKG_CONFIG_PATH="D:\\a\\numpy\\numpy\\openblas\\lib\\pkgconfig;"}
+ 
+ [[tool.cibuildwheel.overrides]]
+ select = "*-win32"
+-environment = { OPENBLAS64_="", OPENBLAS="openblas", NPY_USE_BLAS_ILP64="0", 
CFLAGS="-m32", LDFLAGS="-m32" }
++environment = { OPENBLAS64_="", OPENBLAS="openblas", NPY_USE_BLAS_ILP64="0", 
CFLAGS="-m32", LDFLAGS="-m32", 
PKG_CONFIG_PATH="D:\\a\\numpy\\numpy\\openblas\\lib\\pkgconfig;"}
+ 
+ [tool.meson-python.args]
+ setup = ['--vsenv']

diff --git a/dev-python/numpy/numpy-1.25.0_rc1.ebuild 
b/dev-python/numpy/numpy-1.25.0_rc1.ebuild
new file mode 100644
index 000000000000..2851cc764551
--- /dev/null
+++ b/dev-python/numpy/numpy-1.25.0_rc1.ebuild
@@ -0,0 +1,127 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=meson-python
+PYTHON_COMPAT=( python3_{10..11} )
+PYTHON_REQ_USE="threads(+)"
+FORTRAN_NEEDED=lapack
+
+inherit distutils-r1 flag-o-matic fortran-2 multiprocessing pypi
+
+DESCRIPTION="Fast array and numerical python library"
+HOMEPAGE="
+       https://numpy.org/
+       https://github.com/numpy/numpy/
+       https://pypi.org/project/numpy/
+"
+
+LICENSE="BSD"
+SLOT="0"
+IUSE="doc lapack"
+if [[ ${PV} != *_rc* ]] ; then
+       KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc 
~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos 
~sparc-solaris ~x64-solaris ~x86-solaris"
+fi
+
+RDEPEND="
+       lapack? (
+               >=virtual/cblas-3.8
+               >=virtual/lapack-3.8
+       )
+"
+BDEPEND="
+       ${RDEPEND}
+       <dev-python/cython-3[${PYTHON_USEDEP}]
+       >=dev-python/cython-0.29.30[${PYTHON_USEDEP}]
+       lapack? (
+               virtual/pkgconfig
+       )
+       test? (
+               $(python_gen_cond_dep '
+                       >=dev-python/cffi-1.14.0[${PYTHON_USEDEP}]
+               ' 'python*')
+               dev-python/charset_normalizer[${PYTHON_USEDEP}]
+               >=dev-python/hypothesis-5.8.0[${PYTHON_USEDEP}]
+               dev-python/pytest-xdist[${PYTHON_USEDEP}]
+               >=dev-python/pytz-2019.3[${PYTHON_USEDEP}]
+       )
+"
+
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.25.0_rc1-meson-pyproject.toml.patch
+)
+
+distutils_enable_tests pytest
+
+python_prepare_all() {
+       append-flags -fno-strict-aliasing
+
+       distutils-r1_python_prepare_all
+}
+
+python_configure_all() {
+       DISTUTILS_ARGS=(
+               -Dblas=$(usev lapack cblas)
+               -Dlapack=$(usev lapack lapack)
+       )
+}
+
+python_test() {
+       local EPYTEST_DESELECT=(
+               # very disk-and-memory-hungry
+               lib/tests/test_io.py::test_large_zip
+
+               # precision problems
+               
core/tests/test_umath_accuracy.py::TestAccuracy::test_validate_transcendentals
+
+               # runs the whole test suite recursively, that's just crazy
+               core/tests/test_mem_policy.py::test_new_policy
+
+               typing/tests/test_typing.py
+       )
+
+       local EPYTEST_IGNORE=(
+               # very slow, unlikely to be practically useful
+               #typing/tests/test_typing.py
+       )
+
+       if use arm && [[ $(uname -m || echo "unknown") == "armv8l" ]] ; then
+               # Degenerate case. arm32 chroot on arm64.
+               # bug #774108
+               EPYTEST_DESELECT+=(
+                       
core/tests/test_cpu_features.py::Test_ARM_Features::test_features
+               )
+       fi
+
+       if use x86 ; then
+               EPYTEST_DESELECT+=(
+                       # https://github.com/numpy/numpy/issues/18388
+                       
core/tests/test_umath.py::TestRemainder::test_float_remainder_overflow
+                       # https://github.com/numpy/numpy/issues/18387
+                       
random/tests/test_generator_mt19937.py::TestRandomDist::test_pareto
+                       # more precision problems
+                       
core/tests/test_einsum.py::TestEinsum::test_einsum_sums_int16
+               )
+       fi
+
+       case "${ABI}" in
+               alpha|arm|hppa|m68k|o32|ppc|s390|sh|sparc|x86)
+                       EPYTEST_DESELECT+=(
+                               # too large for 32-bit platforms
+                               
core/tests/test_ufunc.py::TestUfunc::test_identityless_reduction_huge_array
+                       )
+                       ;;
+               *)
+                       ;;
+       esac
+
+       rm -rf numpy || die
+       epytest -n "$(makeopts_jobs)" --pyargs numpy
+}
+
+python_install_all() {
+       local DOCS=( LICENSE.txt README.md THANKS.txt )
+       distutils-r1_python_install_all
+}

Reply via email to