mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
zope-interface, bump version, drop python2.7, add python3.10 (#7199)
This commit is contained in:
69
dev-python/zope-interface/zope_interface-5.4.0.recipe
Normal file
69
dev-python/zope-interface/zope_interface-5.4.0.recipe
Normal file
@@ -0,0 +1,69 @@
|
||||
SUMMARY="Interfaces for Python"
|
||||
DESCRIPTION="
|
||||
This package provides an implementation of 'object interfaces' for Python. \
|
||||
Interfaces are a mechanism for labeling objects as conforming to a given \
|
||||
API or contract. So, this package can be considered as implementation of the \
|
||||
Design By Contract methodology support in Python.
|
||||
|
||||
For detailed documentation, please see http://docs.zope.org/zope.interface"
|
||||
HOMEPAGE="http://pypi.python.org/pypi/zope.interface"
|
||||
COPYRIGHT="2004-2014 Zope Foundation and Contributors"
|
||||
LICENSE="ZPL 2.1"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://pypi.io/packages/source/z/zope.interface/zope.interface-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="5dba5f530fec3f0988d83b78cc591b58c0b6eb8431a85edd1569a0539a8a5a0e"
|
||||
SOURCE_DIR="zope.interface-$portVersion"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc
|
||||
"
|
||||
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\
|
||||
\"; \
|
||||
REQUIRES_$pythonPackage=\"\
|
||||
haiku\n\
|
||||
cmd:python$pythonVersion\
|
||||
\""
|
||||
BUILD_REQUIRES="$BUILD_REQUIRES
|
||||
setuptools_$pythonPackage"
|
||||
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
||||
cmd:python$pythonVersion"
|
||||
done
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
python=python$pythonVersion
|
||||
pythonVersion=$($python --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
rm -rf build
|
||||
$python setup.py build install \
|
||||
--root=/ --prefix=$prefix
|
||||
|
||||
packageEntries $pythonPackage \
|
||||
$prefix/lib/python*
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user