aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py-beautifulsoup4
diff options
context:
space:
mode:
authorFabian Affolter <fabian@affolter-engineering.ch>2016-11-09 08:05:21 +0000
committerTimo Teräs <timo.teras@iki.fi>2016-12-27 09:49:37 +0200
commitcc221f4962b8c9aedd584c84889149d5868bbd67 (patch)
tree6722a73fef06343c8f086a93b1e367dcab94eaaf /testing/py-beautifulsoup4
parent0a8a70dcadb28906c2c83b8413edc0e20def30a0 (diff)
downloadaports-cc221f4962b8c9aedd584c84889149d5868bbd67.tar.bz2
aports-cc221f4962b8c9aedd584c84889149d5868bbd67.tar.xz
testing/py-beautifulsoup4: upgrade to 4.5.1 and enable py3
Diffstat (limited to 'testing/py-beautifulsoup4')
-rw-r--r--testing/py-beautifulsoup4/APKBUILD56
1 files changed, 32 insertions, 24 deletions
diff --git a/testing/py-beautifulsoup4/APKBUILD b/testing/py-beautifulsoup4/APKBUILD
index 50272762eb..12ad5e407a 100644
--- a/testing/py-beautifulsoup4/APKBUILD
+++ b/testing/py-beautifulsoup4/APKBUILD
@@ -2,40 +2,48 @@
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py-beautifulsoup4
_pkgname=beautifulsoup4
-pkgver=4.3.2
+pkgver=4.5.1
pkgrel=0
pkgdesc="A Python HTML/XML parser"
url="http://www.crummy.com/software/BeautifulSoup/index.html"
arch="noarch"
license="MIT"
-depends="python2"
-depends_dev=""
-makedepends="python2-dev py-setuptools"
-install=""
-subpackages=""
-source="http://www.crummy.com/software/BeautifulSoup/bs4/download/${pkgver:0:3}/$_pkgname-$pkgver.tar.gz"
-
-_builddir="$srcdir"/$_pkgname-$pkgver
-prepare() {
- local i
- cd "$_builddir"
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
-}
+makedepends="python2-dev py-setuptools python3-dev"
+subpackages="py3-$_pkgname:_py3 py2-$_pkgname:_py2"
+source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
+builddir="$srcdir"/$_pkgname-$pkgver
build() {
- cd "$_builddir"
+ cd "$builddir"
python2 setup.py build || return 1
+ python3 setup.py build || return 1
}
package() {
- cd "$_builddir"
- python2 setup.py install --prefix=/usr --root="$pkgdir" || return 1
+ mkdir -p "$pkgdir"
+}
+
+_py2() {
+ replaces="$pkgname"
+ depends="${depends//py-/py2-}"
+ _py python2
+}
+
+_py3() {
+ depends="${depends//py-/py3-}"
+ _py python3
+}
+
+_py() {
+ local python="$1"
+ pkgdesc="$pkgdesc (for $python)"
+ depends="$depends $python"
+ install_if="$pkgname=$pkgver-r$pkgrel $python"
+
+ cd "$builddir"
+ $python setup.py install --prefix=/usr --root="$subpkgdir"
}
-md5sums="b8d157a204d56512a4cc196e53e7d8ee beautifulsoup4-4.3.2.tar.gz"
-sha256sums="a2b29bd048ca2fe54a046b29770964738872a9747003a371344a93eedf7ad58e beautifulsoup4-4.3.2.tar.gz"
-sha512sums="3d55e553a1a2109378e2961a0feb23a8f038f4ff7bd335a21a26d588d39761f6735888e6ca2d001587e9a6a3b8259a1a09b92b310aa17e9b76fd85601a1ca592 beautifulsoup4-4.3.2.tar.gz"
+md5sums="994abd90e691beaf7d42c00ffb2f3a67 beautifulsoup4-4.5.1.tar.gz"
+sha256sums="3c9474036afda9136aac6463def733f81017bf9ef3510d25634f335b0c87f5e1 beautifulsoup4-4.5.1.tar.gz"
+sha512sums="d560d7f743507084ec546708d29bb3764512f5b2c380004280dde813350bf48d1697fddce3bd3f95186407bf5142941d7adc7d0de8e7962eb5ca1278dbc7e93f beautifulsoup4-4.5.1.tar.gz"