[arch-commits] Commit in (4 files)

Felix Yan felixonmars at archlinux.org
Mon Apr 29 11:39:48 UTC 2019


    Date: Monday, April 29, 2019 @ 11:39:47
  Author: felixonmars
Revision: 456037

addpkg: python-purl 1.5-1

Added:
  python-purl/
  python-purl/repos/
  python-purl/trunk/
  python-purl/trunk/PKGBUILD

----------+
 PKGBUILD |   50 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 50 insertions(+)

Added: python-purl/trunk/PKGBUILD
===================================================================
--- python-purl/trunk/PKGBUILD	                        (rev 0)
+++ python-purl/trunk/PKGBUILD	2019-04-29 11:39:47 UTC (rev 456037)
@@ -0,0 +1,50 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-purl
+pkgname=('python-purl' 'python2-purl')
+pkgver=1.5
+pkgrel=1
+pkgdesc="An immutable URL class for easy URL-building and manipulation"
+arch=('any')
+license=('MIT')
+url="https://github.com/codeinthehole/purl"
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-nose' 'python2-nose')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/codeinthehole/purl/archive/$pkgver.tar.gz")
+sha512sums=('c034e563d25f4270d4aa9731e87df23203a1c6fc09d2df60fd6038e88c17341e2b30b04a9fba177a04a2552ce3ee0f2d9e34bf4aad6675eb23d2c7bd047d3813')
+
+prepare() {
+  cp -a purl-$pkgver{,-py2}
+}
+
+build() {
+  cd "$srcdir"/purl-$pkgver
+  python setup.py build
+
+  cd "$srcdir"/purl-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  cd "$srcdir"/purl-$pkgver
+  python setup.py nosetests
+
+  cd "$srcdir"/purl-$pkgver-py2
+  python2 setup.py nosetests
+}
+
+package_python-purl() {
+  depends=('python-six')
+
+  cd purl-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
+}
+
+package_python2-purl() {
+  depends=('python2-six')
+
+  cd purl-$pkgver-py2
+  python2 setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
+}


More information about the arch-commits mailing list