[arch-commits] Commit in python-chardet/trunk (PKGBUILD)
Jelle van der Waa
jelle at gemini.archlinux.org
Mon Nov 29 18:59:03 UTC 2021
Date: Monday, November 29, 2021 @ 18:59:02
Author: jelle
Revision: 429462
Drop python2-chardet
Modified:
python-chardet/trunk/PKGBUILD
----------+
PKGBUILD | 37 +++++++------------------------------
1 file changed, 7 insertions(+), 30 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2021-11-29 18:53:02 UTC (rev 429461)
+++ PKGBUILD 2021-11-29 18:59:02 UTC (rev 429462)
@@ -2,53 +2,30 @@
# Contributor: Ionut Biru <ibiru at archlinux.org>
# Contributor: William Rea <sillywilly at gmail.com>
-pkgbase=python-chardet
-pkgname=('python-chardet' 'python2-chardet')
+pkgname=python-chardet
pkgver=4.0.0
-pkgrel=2
+pkgrel=3
arch=('any')
url="https://github.com/chardet/chardet"
license=('LGPL')
-makedepends=('python-setuptools' 'python2-setuptools')
-checkdepends=('python-pytest' 'python2-pytest')
+depends=('python')
+pkgdesc="Python3 module for character encoding auto-detection"
+makedepends=('python-setuptools')
+checkdepends=('python-pytest')
source=("https://pypi.io/packages/source/c/chardet/chardet-${pkgver}.tar.gz")
sha512sums=('ebd7f420e1094445270db993f6373ffe7370419e002b0bb13299dc6c9b0f7c4e77b0f44f871fba6371e6869e7c86728514367db377e3137487a3acf50cb81e96')
-prepare() {
- cp -a chardet-$pkgver{,-py2}
-}
-
build() {
cd "$srcdir"/chardet-$pkgver
python setup.py build
-
- cd "$srcdir"/chardet-$pkgver-py2
- python2 setup.py build
}
check() {
cd "$srcdir"/chardet-$pkgver
python -m pytest
-
- cd "$srcdir"/chardet-$pkgver-py2
- python2 -m pytest
}
-package_python-chardet() {
- depends=('python')
- pkgdesc="Python3 module for character encoding auto-detection"
-
+package() {
cd chardet-$pkgver
python setup.py install --root="$pkgdir" --optimize=1
}
-
-package_python2-chardet() {
- depends=('python2-setuptools')
- pkgdesc="Python2 module for character encoding auto-detection"
-
- cd chardet-$pkgver-py2
- python2 setup.py install --root="$pkgdir" --optimize=1
-
- # To avoid file conflict with the python3 version
- mv "$pkgdir"/usr/bin/chardetect{,-py2}
-}
More information about the arch-commits
mailing list