Files
haikuports/dev-python/pyyaml/pyyaml-6.0.recipe
OscarL 70ac5cadda python3.8: bulk removal of now obsolete "_python38" packages. (#9328)
* python3.8: bulk removal of now obsolete "_python38" packages.

Done via scripting. No functional change intended or expected.

Some manual tweaks will follow.

* python3.8: further manual tweaks after bulk-3.8-removal.

Unlike the previous commit with automated changes,
I've tested builds for *these* recipes in beta4 64 bits.
2023-09-01 18:19:50 +00:00

74 lines
1.9 KiB
Bash

SUMMARY="YAML parser and emitter for Python"
DESCRIPTION="YAML is a data serialization format designed for human readability \
and interaction with scripting languages. \
PyYAML is a YAML parser and emitter for Python.
PyYAML features a complete YAML 1.1 parser, Unicode support, \
pickle support, capable extension API, and sensible error messages. \
PyYAML supports standard YAML tags and \
provides Python-specific tags that allow to represent an arbitrary Python object.
PyYAML is applicable for a broad range of tasks from \
complex configuration files to object serialization and persistance."
HOMEPAGE="https://pyyaml.org/"
COPYRIGHT="2017-2021 Ingy döt Net
2006-2016 Kirill Simonov"
LICENSE="MIT"
REVISION="3"
SOURCE_URI="https://github.com/yaml/pyyaml/archive/refs/tags/$portVersion.tar.gz"
CHECKSUM_SHA256="f33eaba25d8e0c1a959bbf00655198c287dfc5868f5b7b01e401eaa1796cc778"
SOURCE_FILENAME="pyyaml-$portVersion.tar.gz"
ARCHITECTURES="any"
PROVIDES="
$portName = $portVersion
"
REQUIRES="
haiku
"
BUILD_REQUIRES="
haiku_devel
"
BUILD_PREREQUIRES="
cmd:gcc
"
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\
\"; \
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]}
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
}