poezio: switch to Python 3.10. (#9696)

This commit is contained in:
OscarL
2023-10-28 06:35:25 -03:00
committed by GitHub
parent 747e4f9672
commit e9f8213dd3

View File

@@ -14,14 +14,17 @@ HOMEPAGE="https://poez.io"
COPYRIGHT="2010-2020 Florent Le Coz, Mathieu Pasquet"
LICENSE="Zlib"
REVISION="1"
SOURCE_URI="https://pypi.io/packages/source/p/poezio/poezio-$portVersion.tar.gz"
SOURCE_URI="https://files.pythonhosted.org/packages/source/p/poezio/poezio-$portVersion.tar.gz"
CHECKSUM_SHA256="d9b8a3e22fa39a8683a9a289229f23d922e63c938a76b9897b77f3278bb3a420"
SOURCE_DIR="poezio-$portVersion"
PATCHES="poezio-$portVersion.patchset"
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
# Set here which Python version we will use:
pythonVersion=3.10
pythonPackage=python${pythonVersion//.}
PROVIDES="
poezio$secondaryArchSuffix = $portVersion
cmd:poezio = $portVersion
@@ -29,37 +32,36 @@ PROVIDES="
"
REQUIRES="
haiku$secondaryArchSuffix
aiodns_python39
pyasn1_modules_python39
pyasn1_python39
pycares_python39
slixmpp_python39 >= 1.8.2
typing_extensions_python39
cmd:python3.9
aiodns_$pythonPackage
pyasn1_modules_$pythonPackage
pyasn1_$pythonPackage
pycares_$pythonPackage
slixmpp_$pythonPackage >= 1.8.2
typing_extensions_$pythonPackage
cmd:python$pythonVersion
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
setuptools_$pythonPackage
"
BUILD_PREREQUIRES="
setuptools_python39
cmd:gcc$secondaryArchSuffix
cmd:pkg_config$secondaryArchSuffix
"
BUILD()
{
python3.9 setup.py build
python$pythonVersion setup.py build
}
INSTALL()
{
# GENERIC: all python_setuptools-based installs need this
pythonVersion=$(python3.9 --version 2>&1 | sed 's/Python //' | head -c3)
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
export PYTHONPATH=$installLocation:$PYTHONPATH
mkdir -p $installLocation
python3.9 setup.py install \
python$pythonVersion setup.py install \
--root=$prefix --prefix=. --skip-build
}