blob: cef158a9c9a4fc5f159b82b2046e3b3449a64ed8 (
plain)
1 # Description: Core utilities for Python packages.
2 # URL: https://pypi.python.org/pypi/packaging/
3 # Maintainer: Danny Rawlins, crux at romster dot me
4 # Depends on: python-pyparsing python-six
5
6 name=python-packaging
7 version=16.8
8 release=1
9 source=(https://files.pythonhosted.org/packages/source/${name:7:1}/$name/$name-$version.tar.gz
10 https://bootstrap.pypa.io/get-pip.py)
11
12 build() {
13 cd ${name#*-}-$version
14
15 if [ "$(pkginfo -i | egrep -c '^python-(setuptools|appdirs|pyparsing|six|pip|packaging) ')" != 6 ]; then
16 install -d build
17 /usr/bin/python $SRC/get-pip.py --root=$SRC/build
18
19 local PYTHONVERSION=$(/usr/bin/python -c 'import sys; print("%s.%s" % sys.version_info[:2])')
20
21 PYTHONPATH=$SRC/build/usr/lib/python$PYTHONVERSION/site-packages \
22 /usr/bin/python setup.py build
23
24 PYTHONPATH=$SRC/build/usr/lib/python$PYTHONVERSION/site-packages \
25 /usr/bin/python setup.py install \
26 --prefix=/usr --root=$PKG --optimize=1
27 else
28
29 /usr/bin/python setup.py build
30
31 /usr/bin/python setup.py install \
32 --prefix=/usr --root=$PKG --optimize=1
33 fi
34 }
|