mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-23 19:25:25 +03:00
this marginally increases install speed by not checking if it needs a rebuild. also remove --prefix=/usr as it defaults to /usr already. might break a build or two, will fix later
44 lines
1.2 KiB
Text
44 lines
1.2 KiB
Text
# Contributor: Leo <thinkabit.ukim@gmail.com>
|
|
# Maintainer:
|
|
pkgname=py3-bleach
|
|
pkgver=5.0.1
|
|
pkgrel=0
|
|
pkgdesc="whitelist-based HTML sanitizing library"
|
|
url="https://github.com/mozilla/bleach"
|
|
arch="noarch"
|
|
license="Apache-2.0"
|
|
depends="python3 py3-html5lib"
|
|
makedepends="py3-setuptools"
|
|
checkdepends="py3-pytest"
|
|
source="https://pypi.python.org/packages/source/b/bleach/bleach-$pkgver.tar.gz
|
|
0002-no_vendored_html5lib.patch
|
|
"
|
|
builddir="$srcdir/bleach-$pkgver"
|
|
|
|
# secfixes:
|
|
# 3.3.0-r0:
|
|
# - CVE-2021-23980
|
|
# 3.1.2-r0:
|
|
# - CVE-2020-6816
|
|
# 3.1.1-r0:
|
|
# - CVE-2020-6802
|
|
|
|
build() {
|
|
rm -rf bleach/_vendor
|
|
python3 setup.py build
|
|
}
|
|
|
|
check() {
|
|
python3 -m pytest \
|
|
--deselect tests/test_clean.py::test_uri_value_allowed_protocols
|
|
# https://github.com/mozilla/bleach/issues/611
|
|
}
|
|
|
|
package() {
|
|
python3 setup.py install --skip-build --root="$pkgdir"
|
|
}
|
|
|
|
sha512sums="
|
|
6c8e80eaf6db6f0e6d9066f3443192f44c489e079945b6d11b11e7eb270ea865011019e05d43c7896262dc11ca168e697630d9da8dca9f5bb48f0e2161fda6c8 bleach-5.0.1.tar.gz
|
|
f70c86bac63ed10ca8d822d8ef39290a778861f7b762bdd5482af752352e3a6c1abb5eb4cf2f107f92c2a221dbf2d76f323fb45c372b116c7d8316491adb2917 0002-no_vendored_html5lib.patch
|
|
"
|