mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-15 00:00:07 +02:00
PycURL: do not depend on any particular minor version of Python.
A REVISION bump was not necessary because the resulting packages
are the same except that REQUIRES_python{,3} are now sorted. But
let's kick a rebuild, after all.
This commit is contained in:
@@ -10,7 +10,7 @@ COPYRIGHT="2001-2008 by Kjetil Jacobsen
|
||||
2013-2018 by Oleg Pudeyev"
|
||||
LICENSE="GNU LGPL v2.1
|
||||
MIT"
|
||||
REVISION="1"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://dl.bintray.com/pycurl/pycurl/pycurl-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="0f0cdfc7a92d4f2a5c44226162434e34f7d6967d3af416a6f1448649c09a25a4"
|
||||
|
||||
@@ -48,20 +48,26 @@ BUILD_PREREQUIRES="
|
||||
cmd:make
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python python3)
|
||||
PYTHON_VERSIONS=(2.7 3.6)
|
||||
PYTHON_PACKAGES=()
|
||||
PYTHON_LIBSUFFIXES=()
|
||||
PYTHON_VERSIONS=()
|
||||
# We don't have python2 for secondaryArch,
|
||||
# and gcc2 doesn't support the flags passed by python3
|
||||
if [ -n "$secondaryArchSuffix" ]; then
|
||||
unset PYTHON_PACKAGES[0]
|
||||
unset PYTHON_VERSIONS[0]
|
||||
elif [ "$effectiveTargetArchitecture" = x86_gcc2 ]; then
|
||||
unset PYTHON_PACKAGES[1]
|
||||
unset PYTHON_VERSIONS[1]
|
||||
if [ -z "$secondaryArchSuffix" ]; then
|
||||
PYTHON_PACKAGES+=(python)
|
||||
PYTHON_LIBSUFFIXES+=("")
|
||||
fi
|
||||
# gcc2 does not support the flags passed by python3
|
||||
if [ "$effectiveTargetArchitecture" != x86_gcc2 ]; then
|
||||
PYTHON_PACKAGES+=(python3)
|
||||
PYTHON_LIBSUFFIXES+=(m)
|
||||
fi
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
pythonLibSuffix=${PYTHON_LIBSUFFIXES[$i]}
|
||||
pythonVersion="`$pythonPackage --version 2>&1 | sed \
|
||||
-e "s/Python \([[:digit:]]*\.[[:digit:]]*\)\..*/\1/"`"
|
||||
PYTHON_VERSIONS+=($pythonVersion)
|
||||
|
||||
eval "\
|
||||
PROVIDES_${pythonPackage}=\"\n\
|
||||
${portName}_$pythonPackage = $portVersion\n\
|
||||
@@ -72,6 +78,7 @@ for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
lib:libcrypto$secondaryArchSuffix\n\
|
||||
lib:libcurl$secondaryArchSuffix\n\
|
||||
lib:libnghttp2$secondaryArchSuffix\n\
|
||||
lib:libpython$pythonVersion$pythonLibSuffix$secondaryArchSuffix\n\
|
||||
lib:libssl$secondaryArchSuffix\n\
|
||||
lib:libz$secondaryArchSuffix\n\
|
||||
\"\
|
||||
@@ -79,29 +86,13 @@ for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
|
||||
BUILD_REQUIRES="$BUILD_REQUIRES
|
||||
setuptools_$pythonPackage
|
||||
devel:libpython$pythonVersion$pythonLibSuffix$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
||||
cmd:python$pythonVersion
|
||||
"
|
||||
done
|
||||
|
||||
if [ -z "$secondaryArchSuffix" ]; then
|
||||
REQUIRES_python+="
|
||||
lib:libpython${PYTHON_VERSIONS[0]}
|
||||
"
|
||||
BUILD_PREREQUIRES+="
|
||||
devel:libpython${PYTHON_VERSIONS[0]}
|
||||
"
|
||||
fi
|
||||
if [ "$effectiveTargetArchitecture" != x86_gcc2 ]; then
|
||||
REQUIRES_python3+="
|
||||
lib:libpython${PYTHON_VERSIONS[1]}m$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES+="
|
||||
devel:libpython${PYTHON_VERSIONS[1]}m$secondaryArchSuffix
|
||||
"
|
||||
fi
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
|
||||
Reference in New Issue
Block a user