summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBritney Fransen <brfransen@gmail.com>2014-04-29 22:42:54 (GMT)
committerBritney Fransen <brfransen@gmail.com>2014-04-29 22:42:54 (GMT)
commitb31bcace672a8a7cfbe28ef51411ab8fbd077cf1 (patch)
tree538e101f3524a91838c242e6e4db09a80031e8b7
parentbfd89de7d3d8c84844d3649f598cb119bae7a1a5 (diff)
downloadlinhes_pkgbuild-b31bcace672a8a7cfbe28ef51411ab8fbd077cf1.zip
linhes_pkgbuild-b31bcace672a8a7cfbe28ef51411ab8fbd077cf1.tar.gz
linhes_pkgbuild-b31bcace672a8a7cfbe28ef51411ab8fbd077cf1.tar.bz2
python-setuptools: initial inclusion
-rw-r--r--abs/core/python_modules/python-setuptools/PKGBUILD70
-rw-r--r--abs/core/python_modules/python-setuptools/__changelog1
2 files changed, 71 insertions, 0 deletions
diff --git a/abs/core/python_modules/python-setuptools/PKGBUILD b/abs/core/python_modules/python-setuptools/PKGBUILD
new file mode 100644
index 0000000..44701e9
--- /dev/null
+++ b/abs/core/python_modules/python-setuptools/PKGBUILD
@@ -0,0 +1,70 @@
+# $Id$
+# Maintainer: Angel Velasquez <angvp@archlinux.org>
+# Maintainer: Felix Yan <felixonmars@gmail.com>
+
+pkgbase=python-setuptools
+pkgname=('python2-setuptools')
+pkgver=3.4.4
+pkgrel=1
+pkgdesc="Easily download, build, install, upgrade, and uninstall Python packages"
+arch=('any')
+license=('PSF')
+url="http://pypi.python.org/pypi/setuptools"
+makedepends=('python2')
+checkdepends=('python-pytest' 'python2-pytest')
+source=("http://pypi.python.org/packages/source/s/setuptools/setuptools-${pkgver}.tar.gz")
+md5sums=('6ca9e8377b65233c2ff3a1752406a22d')
+
+check() {
+ # Disabled python 3.x tests for setuptools 3.4.1:
+ # https://bitbucket.org/pypa/setuptools/issue/180/34-release-fails-tests
+
+ # Check python3 module
+ cd "${srcdir}"/setuptools-${pkgver}
+ #python3 setup.py test
+
+ # Check python2 module
+ cd "${srcdir}"/setuptools-${pkgver}-python2
+ python2 setup.py test
+}
+
+prepare() {
+ cp -a setuptools-${pkgver}{,-python2}
+
+ cd "${srcdir}"/setuptools-${pkgver}
+ sed -i -e "s|^#\!.*/usr/bin/python|#!/usr/bin/python3|" setuptools/tests/test_resources.py
+ sed -i -e "s|^#\!.*/usr/bin/env python|#!/usr/bin/env python3|" setuptools/command/easy_install.py
+
+ cd "${srcdir}"/setuptools-${pkgver}-python2
+ sed -i -e "s|^#\!.*/usr/bin/python|#!/usr/bin/python2|" setuptools/tests/test_resources.py
+ sed -i -e "s|^#\!.*/usr/bin/env python|#!/usr/bin/env python2|" setuptools/command/easy_install.py
+}
+
+build() {
+ # Build python 3 module
+ #cd "${srcdir}"/setuptools-${pkgver}
+ #python3 setup.py build
+
+ # Build python 2 module
+ cd "${srcdir}"/setuptools-${pkgver}-python2
+ python2 setup.py build
+}
+
+#package_python-setuptools() {
+ #depends=('python>=3.4')
+ #provides=('python-distribute')
+ #replaces=('python-distribute')
+
+ #cd "${srcdir}/setuptools-${pkgver}"
+ #python3 setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1 --skip-build
+#}
+
+package_python2-setuptools() {
+ depends=('python2>=2.7')
+ provides=('python2-distribute' 'setuptools')
+ replaces=('python2-distribute' 'setuptools')
+
+ cd "${srcdir}/setuptools-${pkgver}-python2"
+ python2 setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1 --skip-build
+ rm "${pkgdir}/usr/bin/easy_install"
+}
diff --git a/abs/core/python_modules/python-setuptools/__changelog b/abs/core/python_modules/python-setuptools/__changelog
new file mode 100644
index 0000000..9715c21
--- /dev/null
+++ b/abs/core/python_modules/python-setuptools/__changelog
@@ -0,0 +1 @@
+PKGBUILD - comment out all python 3 stuff and only build for py 2