summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorTim Savannah2017-06-05 03:47:58 -0400
committerTim Savannah2017-06-05 03:47:58 -0400
commit9dddc7f5f0b16150d691f5728f4fffee62f2dd78 (patch)
tree66e2f8bf544985235b88683c741b86a956d06bd9
parente26c0046fd24252c4a0255a162b9889a6016176e (diff)
downloadaur-9dddc7f5f0b16150d691f5728f4fffee62f2dd78.tar.gz
Split the tools from AdvancedHTMLParser so python and python2 packages dont conflict
-rw-r--r--.SRCINFO7
-rw-r--r--PKGBUILD19
2 files changed, 22 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 42d0b185344..134adc1bd70 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = python-advancedhtmlparser
pkgdesc = Fast Indexed python HTML parser which builds a DOM node tree, providing common getElementsBy* functions for scraping, testing, modification, and formatting
pkgver = 7.2.0
- pkgrel = 1
+ pkgrel = 2
url = http://github.com/kata198/AdvancedHTMLParser
arch = any
license = LGPLv3
@@ -15,3 +15,8 @@ pkgbase = python-advancedhtmlparser
pkgname = python-advancedhtmlparser
+pkgname = python-advancedhtmlparser-tools
+ depends = python-advancedhtmlparser
+ optdepends =
+ conflicts = python2-advancedhtmlparser-tools
+
diff --git a/PKGBUILD b/PKGBUILD
index 24dd5d16b8b..82e54bd809b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,8 +1,8 @@
# Maintainer: Tim Savannah <kata198@gmail.com>
-pkgname=python-advancedhtmlparser
+pkgname=('python-advancedhtmlparser' 'python-advancedhtmlparser-tools')
pkgver=7.2.0
-pkgrel=1
+pkgrel=2
pkgdesc="Fast Indexed python HTML parser which builds a DOM node tree, providing common getElementsBy* functions for scraping, testing, modification, and formatting"
arch=('any')
license=('LGPLv3')
@@ -18,7 +18,20 @@ build() {
python setup.py build
}
-package() {
+package_python-advancedhtmlparser() {
cd AdvancedHTMLParser-$pkgver
python setup.py install --root="$pkgdir" --optimize=1 --skip-build
+
+ # Remove tools from lib package
+ rm -Rf "$pkgdir/usr/bin"
+}
+package_python-advancedhtmlparser-tools() {
+ depends=('python-advancedhtmlparser')
+ conflicts=('python2-advancedhtmlparser-tools')
+ optdepends=()
+ cd AdvancedHTMLParser-$pkgver
+ python setup.py install --root="$pkgdir" --optimize=1 --skip-build
+
+ # Remove lib from tools package
+ rm -Rf "${pkgdir}/usr/lib"
}