mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
58 lines
1.4 KiB
Bash
58 lines
1.4 KiB
Bash
SUMMARY="Core utilities for Python packages"
|
|
DESCRIPTION="The 'packaging' project includes the following: \
|
|
version handling, specifiers, markers, requirements, tags, utilities."
|
|
HOMEPAGE="https://pypi.python.org/pypi/packaging"
|
|
COPYRIGHT="2014-2021 Donald Stufft and individual contributors"
|
|
LICENSE="Apache v2"
|
|
REVISION="1"
|
|
SOURCE_URI="https://pypi.io/packages/source/${portName:0:1}/$portName/$portName-$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="b6ad297f8907de0fa2fe1ccbd26fdaf387f5f47c7275fedf8cce89f99446cf97"
|
|
|
|
ARCHITECTURES="any"
|
|
|
|
PROVIDES="
|
|
$portName = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku_devel
|
|
"
|
|
|
|
PYTHON_PACKAGES=(python38 python39 python310)
|
|
PYTHON_VERSIONS=(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\n\
|
|
\""
|
|
BUILD_REQUIRES="$BUILD_REQUIRES
|
|
build_$pythonPackage
|
|
flit_core_$pythonPackage
|
|
installer_$pythonPackage"
|
|
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
|
cmd:python$pythonVersion"
|
|
done
|
|
|
|
INSTALL()
|
|
{
|
|
for i in "${!PYTHON_PACKAGES[@]}"; do
|
|
pythonPackage=${PYTHON_PACKAGES[i]}
|
|
pythonVersion=${PYTHON_VERSIONS[$i]}
|
|
|
|
python=python$pythonVersion
|
|
$python -m build -wn
|
|
$python -m installer --prefix=$prefix dist/*.whl
|
|
|
|
packageEntries ${PYTHON_PACKAGES[i]} \
|
|
$prefix/lib/python*
|
|
done
|
|
}
|