ports/opt (3.3): python ports: FS#1380 - fix for python-pip related packages
commit f00e8cd02ebadcbf8a07e8c3a01cbe9232f16e4d Author: Danny Rawlins <monster.romster@gmail.com> Date: Sat Mar 4 14:21:01 2017 +1100 python ports: FS#1380 - fix for python-pip related packages diff --git a/python-appdirs/Pkgfile b/python-appdirs/Pkgfile index b5e0ed0..24e1568 100644 --- a/python-appdirs/Pkgfile +++ b/python-appdirs/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python-packaging/Pkgfile b/python-packaging/Pkgfile index 8eb7111..a92789d 100644 --- a/python-packaging/Pkgfile +++ b/python-packaging/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python-pip/Pkgfile b/python-pip/Pkgfile index 71ec730..1013a87 100644 --- a/python-pip/Pkgfile +++ b/python-pip/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python-pyparsing/Pkgfile b/python-pyparsing/Pkgfile index a851141..527df49 100644 --- a/python-pyparsing/Pkgfile +++ b/python-pyparsing/Pkgfile @@ -12,13 +12,13 @@ source=(https://files.pythonhosted.org/packages/source/${name:7:1}/${name#*-}/${ build() { cd ${name#*-}-$version - local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') - if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then - install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build + local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') + PYTHONPATH=$SRC/build/usr/lib/python$PYTHONVERSION/site-packages \ /usr/bin/python setup.py build @@ -32,5 +32,6 @@ build() { --prefix=/usr --root=$PKG --optimize=1 fi + local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') find $PKG/usr/lib/python$PYTHONVERSION/site-packages -type f -exec chmod go-w {} + } diff --git a/python-setuptools/Pkgfile b/python-setuptools/Pkgfile index 380a903..60e40d1 100644 --- a/python-setuptools/Pkgfile +++ b/python-setuptools/Pkgfile @@ -16,6 +16,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python-six/Pkgfile b/python-six/Pkgfile index d359a3f..781fdfb 100644 --- a/python-six/Pkgfile +++ b/python-six/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python3-appdirs/Pkgfile b/python3-appdirs/Pkgfile index 8ac18b4..cbb51a5 100644 --- a/python3-appdirs/Pkgfile +++ b/python3-appdirs/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python3-packaging/Pkgfile b/python3-packaging/Pkgfile index a38a91f..39ef727 100644 --- a/python3-packaging/Pkgfile +++ b/python3-packaging/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python3-pip/Pkgfile b/python3-pip/Pkgfile index c77ed7c..8313bc7 100644 --- a/python3-pip/Pkgfile +++ b/python3-pip/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python3-pyparsing/Pkgfile b/python3-pyparsing/Pkgfile index 8ffd381..a7ad86d 100644 --- a/python3-pyparsing/Pkgfile +++ b/python3-pyparsing/Pkgfile @@ -12,12 +12,13 @@ source=(https://files.pythonhosted.org/packages/source/${name:8:1}/${name#*-}/${ build() { cd ${name#*-}-$version - local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') - if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build + local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') + PYTHONPATH=$SRC/build/usr/lib/python$PYTHONVERSION/site-packages \ /usr/bin/python3 setup.py build @@ -31,5 +32,6 @@ build() { --prefix=/usr --root=$PKG --optimize=1 fi + local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') find $PKG/usr/lib/python$PYTHONVERSION/site-packages -type f -exec chmod go-w {} + } diff --git a/python3-setuptools/Pkgfile b/python3-setuptools/Pkgfile index a28f13d..c58b734 100644 --- a/python3-setuptools/Pkgfile +++ b/python3-setuptools/Pkgfile @@ -16,6 +16,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') diff --git a/python3-six/Pkgfile b/python3-six/Pkgfile index d4a18ce..7b0b65d 100644 --- a/python3-six/Pkgfile +++ b/python3-six/Pkgfile @@ -14,6 +14,7 @@ build() { if [ "$(pkginfo -i | egrep -c '^python3-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then install -d build + sed -i 's/"--upgrade"/"--upgrade", "--upgrade-strategy", "only-if-needed"/' $SRC/get-pip.py /usr/bin/python3 $SRC/get-pip.py --root=$SRC/build local PYTHONVERSION=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])')
participants (1)
-
crux@crux.nu