mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-11 06:10:06 +02:00
64 lines
1.6 KiB
Bash
64 lines
1.6 KiB
Bash
SUMMARY="A library for installing Python wheels"
|
|
DESCRIPTION="This is a low-level library for installing a Python package from a wheel distribution.
|
|
It provides basic functionality and abstractions for handling wheels and installing packages from \
|
|
wheels.
|
|
|
|
- Logic for unpacking a wheel (i.e. installation).
|
|
- Abstractions for various parts of the unpacking process.
|
|
- Extensible simple implementations of the abstractions.
|
|
- Platform-independent Python script wrapper generation."
|
|
HOMEPAGE="https://pypi.org/project/installer/"
|
|
COPYRIGHT="2020 Pradyun Gedam"
|
|
LICENSE="MIT"
|
|
REVISION="4"
|
|
SOURCE_URI="https://pypi.io/packages/source/i/installer/installer-$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="a26d3e3116289bb08216e0d0f7d925fcef0b0194eedfa0c944bcaaa106c4b631"
|
|
|
|
ARCHITECTURES="any"
|
|
|
|
PROVIDES="
|
|
$portName = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku_devel
|
|
"
|
|
|
|
PYTHON_PACKAGES=(python39 python310)
|
|
PYTHON_VERSIONS=(3.9 3.10)
|
|
for i in "${!PYTHON_PACKAGES[@]}"; do
|
|
pythonPackage=${PYTHON_PACKAGES[i]}
|
|
pythonVersion=${PYTHON_VERSIONS[$i]}
|
|
|
|
eval "PROVIDES_${pythonPackage}=\"
|
|
${portName}_$pythonPackage = $portVersion
|
|
\""
|
|
eval "REQUIRES_$pythonPackage=\"
|
|
haiku
|
|
cmd:python$pythonVersion
|
|
\""
|
|
BUILD_REQUIRES+="
|
|
build_$pythonPackage
|
|
flit_core_$pythonPackage
|
|
"
|
|
BUILD_PREREQUIRES+="
|
|
cmd:python$pythonVersion
|
|
"
|
|
done
|
|
|
|
INSTALL()
|
|
{
|
|
for i in "${!PYTHON_PACKAGES[@]}"; do
|
|
python=python${PYTHON_VERSIONS[$i]}
|
|
|
|
$python -m build -wn --skip-dependency-check
|
|
PYTHONPATH=src $python -m installer --prefix=$prefix dist/*.whl
|
|
|
|
packageEntries ${PYTHON_PACKAGES[i]} \
|
|
$prefix/lib/python*
|
|
done
|
|
}
|