mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 02:22:13 +08:00
41 lines
1.5 KiB
Bash
41 lines
1.5 KiB
Bash
pkgbase=python-beautifulsoup4
|
|
pkgname=('python2-beautifulsoup4' 'python3-beautifulsoup4')
|
|
pkgver=4.6.0
|
|
pkgrel=1
|
|
pkgdesc="A Python HTML/XML parser designed for quick turnaround projects like screen-scraping."
|
|
arch=('x86_64')
|
|
url="http://www.crummy.com/software/BeautifulSoup/index.html"
|
|
license=('PSF')
|
|
makedepends=('python2-setuptools' 'python3-setuptools')
|
|
source=("http://www.crummy.com/software/BeautifulSoup/bs4/download/${pkgver%.*}/${pkgbase#*-}-${pkgver}.tar.gz")
|
|
sha512sums=('1a7eee4218e58cc3852e71fe4f0892f673bb46a851941264766a38eff8ef05d612d88b4641fcb478ce8f66ac50dc987ca039923c4bbb11867c74813289f7e578')
|
|
|
|
build() {
|
|
cd "${srcdir}"
|
|
cp -a beautifulsoup4-${pkgver}{,-python2}
|
|
|
|
# Build python 3 module
|
|
cd "${srcdir}/beautifulsoup4-${pkgver}"
|
|
python3 setup.py build
|
|
|
|
# Build python 2 module
|
|
cd "${srcdir}/beautifulsoup4-${pkgver}-python2"
|
|
python2 setup.py build
|
|
}
|
|
|
|
package_python2-beautifulsoup4() {
|
|
optdepends=('python2-chardet: universal encoding detector'
|
|
'python2-lxml: pythonic binding for the libxml2 and libxslt libraries')
|
|
|
|
cd "${srcdir}/beautifulsoup4-${pkgver}-python2"
|
|
python2 setup.py install --root="${pkgdir}/" --optimize=1 --skip-build
|
|
}
|
|
|
|
package_python3-beautifulsoup4() {
|
|
optdepends=('python3-chardet: universal encoding detector'
|
|
'python3-lxml: pythonic binding for the libxml2 and libxslt libraries')
|
|
|
|
cd "${srcdir}/beautifulsoup4-${pkgver}"
|
|
python3 setup.py install --root="${pkgdir}/" --optimize=1 --skip-build
|
|
}
|