mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
cython, bump version, drop python2.7, add python3.10, cleanup (#7218)
This commit is contained in:
83
dev-python/cython/cython-0.29.32.recipe
Normal file
83
dev-python/cython/cython-0.29.32.recipe
Normal file
@@ -0,0 +1,83 @@
|
||||
SUMMARY="Optimising static compiler for Python"
|
||||
DESCRIPTION="Cython is an optimising static compiler for both the Python \
|
||||
programming language and the extended Cython programming language (based on \
|
||||
Pyrex). It makes writing C extensions for Python as easy as Python itself."
|
||||
HOMEPAGE="https://cython.org/"
|
||||
COPYRIGHT="2007-2020 Stefan Behnel, Robert Bradshaw, et al."
|
||||
LICENSE="Apache v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="3f53fbe1398666e77fd4ce388f939309a11efd273d16f20f58f0df7b03d6b4cc"
|
||||
SOURCE_FILENAME="cython-$portVersion.tar.gz"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python3 python38 python39 python310)
|
||||
PYTHON_VERSIONS=(3.7 3.8 3.9 3.10)
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
eval "PROVIDES_${pythonPackage}=\"\
|
||||
${portName}_$pythonPackage = $portVersion\n\
|
||||
cmd:cygdb$pythonVersion\n\
|
||||
cmd:cython$pythonVersion\n\
|
||||
cmd:cythonize$pythonVersion\n\
|
||||
\"; \
|
||||
REQUIRES_$pythonPackage=\"\
|
||||
haiku\n\
|
||||
cmd:python$pythonVersion\
|
||||
\""
|
||||
if [ "$targetArchitecture" = "x86_gcc2" ]; then
|
||||
eval "PROVIDES_${pythonPackage}+=\"\n\
|
||||
cython_$pythonPackage = $portVersion\
|
||||
\""
|
||||
fi
|
||||
BUILD_REQUIRES="$BUILD_REQUIRES
|
||||
setuptools_$pythonPackage
|
||||
"
|
||||
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:python$pythonVersion
|
||||
"
|
||||
done
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
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"
|
||||
|
||||
for file in cygdb cython cythonize; \
|
||||
do mv "$prefix"/bin/$file "$prefix"/bin/${file}$pythonVersion ; \
|
||||
done
|
||||
install -m 755 -d "$docDir"
|
||||
install -m 644 -t "$docDir" README.rst
|
||||
|
||||
packageEntries $pythonPackage \
|
||||
"$prefix"/lib/$python \
|
||||
"$prefix"/bin \
|
||||
"$docDir"
|
||||
done
|
||||
}
|
||||
|
||||
@@ -1,64 +0,0 @@
|
||||
SUMMARY="Optimising static compiler for Python"
|
||||
DESCRIPTION="Cython is an optimising static compiler for both the Python \
|
||||
programming language and the extended Cython programming language (based on \
|
||||
Pyrex). It makes writing C extensions for Python as easy as Python itself."
|
||||
HOMEPAGE="https://cython.org/"
|
||||
COPYRIGHT="2007-2020 Stefan Behnel, Robert Bradshaw, et al."
|
||||
LICENSE="Apache v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e2e38e1f0572ca54d6085df3dec8b607d20e81515fb80215aed19c81e8fe2079"
|
||||
SOURCE_FILENAME="cython-$portVersion.tar.gz"
|
||||
SOURCE_DIR="cython-$portVersion"
|
||||
|
||||
ARCHITECTURES="all ?x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
cython_python$secondaryArchSuffix = $portVersion
|
||||
cmd:cygdb2$secondaryArchSuffix
|
||||
cmd:cygdb2.7$secondaryArchSuffix
|
||||
cmd:cython2$secondaryArchSuffix
|
||||
cmd:cython2.7$secondaryArchSuffix
|
||||
cmd:cythonize2$secondaryArchSuffix
|
||||
cmd:cythonize2.7$secondaryArchSuffix
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python2
|
||||
"
|
||||
REPLACES="
|
||||
python_cython
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
setuptools_python
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc
|
||||
cmd:make
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python2/bin/python2 setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
pythonVersion=$(python2 --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
$portPackageLinksDir/cmd~python2/bin/python2 setup.py install \
|
||||
--root=/ --prefix=$prefix --skip-build
|
||||
|
||||
mkdir -p $binDir
|
||||
for file in cygdb cython cythonize; \
|
||||
do mv $prefix/bin/$file $binDir/${file}2 ; \
|
||||
done
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
SUMMARY="Optimising static compiler for Python"
|
||||
DESCRIPTION="Cython is an optimising static compiler for both the Python \
|
||||
programming language and the extended Cython programming language (based on \
|
||||
Pyrex). It makes writing C extensions for Python as easy as Python itself."
|
||||
HOMEPAGE="https://cython.org/"
|
||||
COPYRIGHT="2007-2020 Stefan Behnel, Robert Bradshaw, et al."
|
||||
LICENSE="Apache v2"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e2e38e1f0572ca54d6085df3dec8b607d20e81515fb80215aed19c81e8fe2079"
|
||||
SOURCE_FILENAME="cython-$portVersion.tar.gz"
|
||||
SOURCE_DIR="cython-$portVersion"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
cython_python3$secondaryArchSuffix = $portVersion
|
||||
cmd:cygdb3$secondaryArchSuffix
|
||||
cmd:cygdb3.7$secondaryArchSuffix
|
||||
cmd:cython3$secondaryArchSuffix
|
||||
cmd:cython3.7$secondaryArchSuffix
|
||||
cmd:cythonize3$secondaryArchSuffix
|
||||
cmd:cythonize3.7$secondaryArchSuffix
|
||||
"
|
||||
if [ "$targetArchitecture" = "x86_gcc2" ]; then
|
||||
PROVIDES+="
|
||||
cython_python3 = $portVersion
|
||||
"
|
||||
fi
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python3
|
||||
"
|
||||
REPLACES="
|
||||
python3_cython
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
setuptools_python3
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:python3
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python3/bin/python3 setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
pythonVersion=$(python3 --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
$portPackageLinksDir/cmd~python3/bin/python3 setup.py install \
|
||||
--prefix=$prefix --skip-build
|
||||
|
||||
mkdir -p $binDir
|
||||
for file in cygdb cython cythonize; \
|
||||
do mv $prefix/bin/$file $binDir/${file}3 ; \
|
||||
done
|
||||
}
|
||||
@@ -1,63 +0,0 @@
|
||||
SUMMARY="Optimising static compiler for Python"
|
||||
DESCRIPTION="Cython is an optimising static compiler for both the Python \
|
||||
programming language and the extended Cython programming language (based on \
|
||||
Pyrex). It makes writing C extensions for Python as easy as Python itself."
|
||||
HOMEPAGE="https://cython.org/"
|
||||
COPYRIGHT="2007-2020 Stefan Behnel, Robert Bradshaw, et al."
|
||||
LICENSE="Apache v2"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e2e38e1f0572ca54d6085df3dec8b607d20e81515fb80215aed19c81e8fe2079"
|
||||
SOURCE_FILENAME="cython-$portVersion.tar.gz"
|
||||
SOURCE_DIR="cython-$portVersion"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
cython_python38$secondaryArchSuffix = $portVersion
|
||||
cmd:cygdb3.8$secondaryArchSuffix
|
||||
cmd:cython3.8$secondaryArchSuffix
|
||||
cmd:cythonize3.8$secondaryArchSuffix
|
||||
"
|
||||
if [ "$targetArchitecture" = "x86_gcc2" ]; then
|
||||
PROVIDES+="
|
||||
cython_python38 = $portVersion
|
||||
"
|
||||
fi
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python3.8
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
setuptools_python38
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:python3.8
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python3.8/bin/python3.8 setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
pythonVersion=$(python3 --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
$portPackageLinksDir/cmd~python3.8/bin/python3.8 setup.py install \
|
||||
--prefix=$prefix --root=/ --skip-build
|
||||
|
||||
mkdir -p $binDir
|
||||
for file in cygdb cython cythonize; \
|
||||
do mv $prefix/bin/$file $binDir/${file}3.8 ; \
|
||||
done
|
||||
}
|
||||
@@ -1,63 +0,0 @@
|
||||
SUMMARY="Optimising static compiler for Python"
|
||||
DESCRIPTION="Cython is an optimising static compiler for both the Python \
|
||||
programming language and the extended Cython programming language (based on \
|
||||
Pyrex). It makes writing C extensions for Python as easy as Python itself."
|
||||
HOMEPAGE="https://cython.org/"
|
||||
COPYRIGHT="2007-2020 Stefan Behnel, Robert Bradshaw, et al."
|
||||
LICENSE="Apache v2"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e2e38e1f0572ca54d6085df3dec8b607d20e81515fb80215aed19c81e8fe2079"
|
||||
SOURCE_FILENAME="cython-$portVersion.tar.gz"
|
||||
SOURCE_DIR="cython-$portVersion"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
cython_python39$secondaryArchSuffix = $portVersion
|
||||
cmd:cygdb3.9$secondaryArchSuffix
|
||||
cmd:cython3.9$secondaryArchSuffix
|
||||
cmd:cythonize3.9$secondaryArchSuffix
|
||||
"
|
||||
if [ "$targetArchitecture" = "x86_gcc2" ]; then
|
||||
PROVIDES+="
|
||||
cython_python39 = $portVersion
|
||||
"
|
||||
fi
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python3.9
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
setuptools_python39
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:python3.9
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python3.9/bin/python3.9 setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
pythonVersion=$(python3 --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
$portPackageLinksDir/cmd~python3.9/bin/python3.9 setup.py install \
|
||||
--prefix=$prefix --root=/ --skip-build
|
||||
|
||||
mkdir -p $binDir
|
||||
for file in cygdb cython cythonize; \
|
||||
do mv $prefix/bin/$file $binDir/${file}3.9 ; \
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user