mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
70 lines
1.6 KiB
Bash
70 lines
1.6 KiB
Bash
SUMMARY="Handles managing your Python package versions in SCM"
|
|
DESCRIPTION="setuptools_scm handles managing your Python package versions \
|
|
in SCM metadata instead of declaring them as the version argument \
|
|
or in a SCM managed file."
|
|
HOMEPAGE="https://github.com/pypa/setuptools_scm"
|
|
COPYRIGHT="2015-2022 Ronny Pfannschmidt"
|
|
LICENSE="MIT"
|
|
REVISION="5"
|
|
SOURCE_URI="https://pypi.io/packages/source/s/setuptools_scm/setuptools_scm-$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="6c508345a771aad7d56ebff0e70628bf2b0ec7573762be9960214730de278f27"
|
|
|
|
ARCHITECTURES="any"
|
|
|
|
PROVIDES="
|
|
$portName = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku_devel
|
|
"
|
|
|
|
PYTHON_VERSIONS=(3.10)
|
|
|
|
for pythonVersion in ${PYTHON_VERSIONS[@]}; do
|
|
pythonPackage=python${pythonVersion//.}
|
|
|
|
eval "PROVIDES_$pythonPackage=\"
|
|
${portName}_$pythonPackage = $portVersion
|
|
\""
|
|
eval "REQUIRES_$pythonPackage=\"
|
|
haiku
|
|
packaging_$pythonPackage
|
|
setuptools_$pythonPackage
|
|
tomli_$pythonPackage # only for Python < 3.11
|
|
typing_extensions_$pythonPackage # only for Python < 3.11
|
|
cmd:git
|
|
cmd:python$pythonVersion
|
|
\""
|
|
BUILD_REQUIRES="$BUILD_REQUIRES
|
|
packaging_$pythonPackage
|
|
setuptools_$pythonPackage
|
|
"
|
|
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
|
cmd:python$pythonVersion
|
|
"
|
|
done
|
|
|
|
INSTALL()
|
|
{
|
|
for pythonVersion in ${PYTHON_VERSIONS[@]}; do
|
|
pythonPackage=python${pythonVersion//.}
|
|
|
|
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
|
|
|
|
packageEntries $pythonPackage \
|
|
$prefix/lib/python*
|
|
done
|
|
}
|