diff --git a/dev-python/pygame/pygame-2.0.0.recipe b/dev-python/pygame/pygame-2.0.0.recipe index 0ebad435e..6f49ff31b 100644 --- a/dev-python/pygame/pygame-2.0.0.recipe +++ b/dev-python/pygame/pygame-2.0.0.recipe @@ -8,7 +8,7 @@ COPYRIGHT="2000-2004, 2007 Pete Shinners 2007 Richard Goedeken 2007-2008 Marcus von Appen" LICENSE="GNU LGPL v2.1" -REVISION="4" +REVISION="5" SOURCE_URI="https://files.pythonhosted.org/packages/source/p/pygame/pygame-$portVersion.tar.gz" CHECKSUM_SHA256="63b038da116a643046181b02173fd894d87d2f85ecfd6aa7d5ece73c6ef501e9" SOURCE_DIR="pygame-$portVersion" @@ -17,8 +17,10 @@ PATCHES="pygame-$portVersion.patchset" ARCHITECTURES="all !x86_gcc2" SECONDARY_ARCHITECTURES="x86" -pythonVersion=3.10 -pythonPackage="python${pythonVersion//.}" +PYTHON_PACKAGES=(python310) +PYTHON_VERSIONS=(3.10) +pythonPackage=${PYTHON_PACKAGES[i]} +pythonVersion=${PYTHON_VERSIONS[$i]} PROVIDES=" pygame$secondaryArchSuffix = $portVersion @@ -79,18 +81,17 @@ BUILD() { # don't build without features # to build against SDL2 remove -sdl1 from the next line - echo "y" | $portPackageLinksDir/cmd~python3/bin/python3 setup.py build -auto -sdl1 || exit 1 + python=python$pythonVersion + echo "y" | $python setup.py build -auto -sdl1 || exit 1 } INSTALL() { # GENERIC: all python_setuptools-based installs need this - python=$portPackageLinksDir/cmd~python3/bin/python3 - pythonVersion=$($python --version 2>&1 | sed 's/Python //' | head -c3) - installLocation=$prefix/lib/python$pythonVersion/vendor-packages/ - export PYTHONPATH=$installLocation:$PYTHONPATH - mkdir -p $installLocation - - echo "y" | $portPackageLinksDir/cmd~python3/bin/python3 setup.py \ - build install --prefix $prefix || exit 1 + python=python$pythonVersion + installLocation=$prefix/lib/$python/vendor-packages/ + export PYTHONPATH=$installLocation:$PYTHONPATH + mkdir -p $installLocation + $python setup.py build install \ + --root=/ --prefix=$prefix }