From dfa70f7c51676a4fd9693d561e183d0a55a0631b Mon Sep 17 00:00:00 2001 From: "Andrew J. Hesford" Date: Wed, 4 Oct 2023 09:32:55 -0400 Subject: [PATCH] fixup! python3-numpy: rebuild for Python 3.12 --- srcpkgs/python3-numpy/template | 33 ++++++++------------------------- 1 file changed, 8 insertions(+), 25 deletions(-) diff --git a/srcpkgs/python3-numpy/template b/srcpkgs/python3-numpy/template index 33689be81decb5..e9806e90987fd6 100644 --- a/srcpkgs/python3-numpy/template +++ b/srcpkgs/python3-numpy/template @@ -2,8 +2,13 @@ pkgname=python3-numpy version=1.26.0 revision=2 -build_style=python3-module -hostmakedepends="python3-setuptools python3-Cython gcc-fortran" +build_style=python3-pep517 +build_helper="meson qemu" +make_build_args="-Csetup-args=-Ddisable-svml=true + $(vopt_if openblas "" "-Csetup-args=-Dblas=blas -Csetup-args=-Dlapack=lapack") +" +hostmakedepends="python3-meson-python python3-pyproject-metadata + python3-setuptools pkg-config python3-Cython gcc-fortran" makedepends="python3-devel $(vopt_if openblas 'openblas-devel' 'lapack-devel cblas-devel')" depends="python3" @@ -34,9 +39,6 @@ if [ "$build_option_openblas" ]; then esac fi -# SVML AVX-512 functions have very limited support; disble for now -export NPY_DISABLE_SVML=1 - post_patch() { case "${XBPS_TARGET_MACHINE}" in armv5tel-musl) @@ -50,23 +52,6 @@ post_patch() { fi } -pre_build() { - # Build numpy in parallel - make_build_args+=" ${makejobs}" - - # Find the right linear algebra subroutines on the target arch - : > site.cfg - for _blaslib in $(vopt_if openblas openblas "lapack blas"); do - cat >> site.cfg <<-EOF - [$_blaslib] - libraries = ${_blaslib} - include_dirs = ${XBPS_CROSS_BASE}/usr/include - library_dirs = ${XBPS_CROSS_BASE}/usr/lib - runtime_library_dirs = ${XBPS_CROSS_BASE}/usr/lib - EOF - done -} - do_check() { local testjobs="-n $XBPS_MAKEJOBS" local _skip @@ -93,8 +78,6 @@ do_check() { } post_install() { - rm ${DESTDIR}/usr/bin/f2py - - rm ${DESTDIR}/${py3_sitelib}/numpy/LICENSE.txt + mv ${DESTDIR}/usr/bin/f2py{,3} vlicense LICENSE.txt LICENSE }