mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-21 19:20:08 +02:00
numpy, bump version (#5647)
This commit is contained in:
133
dev-python/numpy/numpy-1.20.0.recipe
Normal file
133
dev-python/numpy/numpy-1.20.0.recipe
Normal file
@@ -0,0 +1,133 @@
|
||||
SUMMARY="Array processing for numbers, strings, records, and objects"
|
||||
DESCRIPTION="NumPy is a general-purpose array-processing package designed to \
|
||||
efficiently manipulate large multi-dimensional arrays of arbitrary records \
|
||||
without sacrificing too much speed for small multi-dimensional arrays.
|
||||
NumPy is built on the Numeric code base and adds features introduced by \
|
||||
numarray as well as an extended C-API and the ability to create arrays of \
|
||||
arbitrary type which also makes NumPy suitable for interfacing with \
|
||||
general-purpose data-base applications."
|
||||
HOMEPAGE="https://www.numpy.org/"
|
||||
COPYRIGHT="2005-2021 Travis E. Oliphant et al."
|
||||
LICENSE="BSD (3-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/numpy/numpy/releases/download/v$portVersion/numpy-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="67b630745a71b541ff6517d6f3d62b00690dc8ba0684cad0d7b0ac55aec1de53"
|
||||
SOURCE_DIR="numpy-$portVersion"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
# lib:libamd$secondaryArchSuffix
|
||||
lib:libblis$secondaryArchSuffix
|
||||
lib:libexecinfo$secondaryArchSuffix
|
||||
# lib:libfftw3$secondaryArchSuffix
|
||||
lib:liblapack$secondaryArchSuffix
|
||||
lib:libopenblas$secondaryArchSuffix
|
||||
# lib:libumfpack$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
# devel:cblas$secondaryArchSuffix
|
||||
# devel:libamd$secondaryArchSuffix
|
||||
devel:libblis$secondaryArchSuffix
|
||||
devel:libexecinfo$secondaryArchSuffix
|
||||
# devel:libfftw3$secondaryArchSuffix
|
||||
devel:liblapack$secondaryArchSuffix
|
||||
devel:libopenblas$secondaryArchSuffix
|
||||
# devel:libumfpack$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python3 python38)
|
||||
PYTHON_VERSIONS=(3.7 3.8)
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
eval "PROVIDES_${pythonPackage}=\"\
|
||||
${portName}_$pythonPackage = $portVersion\n\
|
||||
cmd:f2py${pythonVersion%.*}\n\
|
||||
cmd:f2py$pythonVersion\n\
|
||||
\"; \
|
||||
REQUIRES_$pythonPackage=\"\
|
||||
haiku$secondaryArchSuffix\n\
|
||||
numpy$secondaryArchSuffix\n\
|
||||
cmd:cython$pythonVersion$secondaryArchSuffix\n\
|
||||
cmd:python$pythonVersion\
|
||||
\""
|
||||
BUILD_REQUIRES="$BUILD_REQUIRES
|
||||
setuptools_$pythonPackage
|
||||
"
|
||||
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
||||
cmd:cython$pythonVersion$secondaryArchSuffix
|
||||
cmd:git
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:gfortran$secondaryArchSuffix
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python$pythonVersion
|
||||
"
|
||||
done
|
||||
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# Check at every update in site.cfg.example!
|
||||
cat > site.cfg << EOF
|
||||
[ALL]
|
||||
libraries = execinfo,lapack,openblas
|
||||
library_dirs = /system/$relativeDevelopLibDir
|
||||
include_dirs = /system/$relativeIncludeDir
|
||||
runtime_library_dirs = /system/$relativeLibDir
|
||||
[openblas]
|
||||
libraries = openblas
|
||||
library_dirs = /system/$relativeDevelopLibDir
|
||||
include_dirs = /system/$relativeIncludeDir
|
||||
runtime_library_dirs = /system/$relativeLibDir
|
||||
[blis]
|
||||
libraries = blis
|
||||
library_dirs = /system/$relativeDevelopLibDir
|
||||
include_dirs = /system/$relativeIncludeDir/blis
|
||||
runtime_library_dirs = /system/$relativeLibDir
|
||||
#[amd]
|
||||
#amd_libs = amd
|
||||
#[umfpack]
|
||||
#umfpack_libs = umfpack
|
||||
#[fftw]
|
||||
#libraries = fftw3
|
||||
EOF
|
||||
|
||||
rm -rf doc/sphinxext/.git
|
||||
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
python=python$pythonVersion
|
||||
installLocation=$prefix/lib/$python/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
rm -rf build
|
||||
$python setup.py build install \
|
||||
--root=/ --prefix=$prefix
|
||||
rm -rf $prefix/bin/f2py
|
||||
|
||||
packageEntries $pythonPackage \
|
||||
$prefix/lib/python* \
|
||||
$prefix/bin
|
||||
done
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
python=python$pythonVersion
|
||||
$python runtests.py
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user