summaryrefslogtreecommitdiffstats
path: root/abs/core
diff options
context:
space:
mode:
authorBritney Fransen <brfransen@gmail.com>2016-03-15 12:53:31 (GMT)
committerBritney Fransen <brfransen@gmail.com>2016-03-15 12:53:31 (GMT)
commit656e4e8cc115cd52675bd9b9754d9912ab0a2323 (patch)
treeb5385a95de53e0ba800b54acd4af3af405b08069 /abs/core
parent76fc068e082832f1721be260e11792f0a7df9b3a (diff)
downloadlinhes_pkgbuild-656e4e8cc115cd52675bd9b9754d9912ab0a2323.zip
linhes_pkgbuild-656e4e8cc115cd52675bd9b9754d9912ab0a2323.tar.gz
linhes_pkgbuild-656e4e8cc115cd52675bd9b9754d9912ab0a2323.tar.bz2
python-pycurl: update to 7.43
Diffstat (limited to 'abs/core')
-rw-r--r--abs/core/python_modules/python-pycurl/PKGBUILD87
-rw-r--r--abs/core/python_modules/python-pycurl/__changelog2
2 files changed, 72 insertions, 17 deletions
diff --git a/abs/core/python_modules/python-pycurl/PKGBUILD b/abs/core/python_modules/python-pycurl/PKGBUILD
index 9b70523..10f640e 100644
--- a/abs/core/python_modules/python-pycurl/PKGBUILD
+++ b/abs/core/python_modules/python-pycurl/PKGBUILD
@@ -1,22 +1,75 @@
-# $Id: PKGBUILD 150558 2012-02-18 14:39:59Z pierre $
-# Maintainer:
+# $Id$
+# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve>
-pkgname=python-pycurl
-pkgver=7.19.0
-pkgrel=6
-pkgdesc="A Python interface to libcurl"
+_pypiname=pycurl
+pkgbase=python-$_pypiname
+pkgname=('python2-pycurl')
+pkgver=7.43.0
+pkgrel=1
arch=('i686' 'x86_64')
-url="http://pycurl.sourceforge.net"
-license=('GPL')
-depends=('python2' 'curl')
-replaces=('pycurl')
-provides=('pycurl')
-source=("http://pycurl.sourceforge.net/download/pycurl-${pkgver}.tar.gz")
-md5sums=('919d58fe37e69fe87ce4534d8b6a1c7b')
-
-package() {
- cd "${srcdir}"/pycurl-${pkgver}
- python2 setup.py install --curl-config=/usr/bin/curl-config --prefix ${pkgdir}/usr
+url="http://pycurl.sourceforge.net/"
+license=('LGPL' 'MIT')
+makedepends=('python2' 'curl' 'git')
+checkdepends=('python2-bottle' 'python2-nose-show-skipped'
+ 'vsftpd' 'python2-flaky' 'python2-pyflakes')
+source=("git+https://github.com/pycurl/pycurl.git#tag=REL_${pkgver//./_}")
+sha1sums=('SKIP')
+
+prepare() {
+ cp -a $_pypiname{,-py2}
+
+ cd "$srcdir/$_pypiname"
+ find . -name '*.py' -exec sed -i -e "s|#! /usr/bin/env python|#!/usr/bin/env python3|" {} +
+ sed -i 's/"share", "doc", PACKAGE/"share", "doc", "python-pycurl"/' setup.py
+ sed -e "s/nosetests/nosetests3/" -e "s/python/python3/" -i tests/run.sh
+
+ cd "$srcdir/$_pypiname-py2"
+ find . -name '*.py' -exec sed -i -e "s|#! /usr/bin/env python|#!/usr/bin/env python2|" {} +
+ sed -i 's/"share", "doc", PACKAGE/"share", "doc", "python2-pycurl"/' setup.py
+ sed -e "s/nosetests/nosetests2/" -e "s/python/python2/" -i tests/run.sh
+ sed -e "s/pyflakes/pyflakes-python2/" -i Makefile
+}
+
+build() {
+# cd "$srcdir/$_pypiname"
+# make
+# python3 setup.py build --with-ssl
+
+ cd "$srcdir/$_pypiname-py2"
+ make
+ python2 setup.py build --with-ssl
+}
+
+check() {
+ export PYCURL_VSFTPD_PATH=vsftpd
+ # We don't have HTTP2 enabled
+
+ cd "$srcdir/$_pypiname"
+ PYTHONPATH="$PWD/build/lib.linux-$CARCH-3.5:$PYTHONPATH" make test || warning "Tests failed"
+
+ cd "$srcdir/$_pypiname-py2"
+ PYTHONPATH="$PWD/build/lib.linux-$CARCH-2.7:$PYTHONPATH" make PYTHON=python2 NOSETESTS=nosetests2 test || warning "Tests failed"
+}
+
+package_python-pycurl() {
+ pkgdesc="A Python 3.x interface to libcurl"
+ depends=('python' 'curl')
+
+ cd $_pypiname
+ python setup.py install -O1 --root="${pkgdir}"
+ install -D -m644 COPYING-MIT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
+
+package_python2-pycurl() {
+ pkgdesc="A Python 2.x interface to libcurl"
+ depends=('python2' 'curl')
+ provides=('python-pycurl')
+ replaces=('python-pycurl')
+ conflicts=('python-pycurl')
+
+ cd $_pypiname-py2
+ python2 setup.py install -O1 --root="${pkgdir}"
+ install -D -m644 COPYING-MIT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
diff --git a/abs/core/python_modules/python-pycurl/__changelog b/abs/core/python_modules/python-pycurl/__changelog
new file mode 100644
index 0000000..a7b93d7
--- /dev/null
+++ b/abs/core/python_modules/python-pycurl/__changelog
@@ -0,0 +1,2 @@
+PKGBUILD: rm py 3 stuff
+