[arch-commits] Commit in python-jsonpointer/trunk (PKGBUILD)

Felix Yan felixonmars at archlinux.org
Mon Sep 11 05:21:34 UTC 2017


    Date: Monday, September 11, 2017 @ 05:21:33
  Author: felixonmars
Revision: 256871

upgpkg: python-jsonpointer 1.12-1

Modified:
  python-jsonpointer/trunk/PKGBUILD

----------+
 PKGBUILD |   55 +++++++++++++++++++++++++++++++------------------------
 1 file changed, 31 insertions(+), 24 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-09-11 05:03:10 UTC (rev 256870)
+++ PKGBUILD	2017-09-11 05:21:33 UTC (rev 256871)
@@ -3,45 +3,52 @@
 # Contributor: Limao Luo <luolimao+AUR at gmail.com>
 
 pkgbase=python-jsonpointer
-_pkgname=jsonpointer
 pkgname=(python2-jsonpointer python-jsonpointer)
-pkgver=1.10
-pkgrel=2
+pkgver=1.12
+pkgrel=1
 pkgdesc="Identify specific nodes in a JSON document (RFC 6901)"
-arch=(any)
-url=https://github.com/stefankoegl/python-json-pointer
-license=(BSD)
-makedepends=(python2-setuptools python-setuptools)
-source=(http://pypi.python.org/packages/source/j/${pkgname#*-}/${pkgname#*-}-$pkgver.tar.gz
-    https://raw.github.com/stefankoegl/python-json-pointer/master/COPYING)
-sha256sums=('9fa5dcac35eefd53e25d6cd4c310d963c9f0b897641772cd6e5e7b89df7ee0b1'
-            'd8b24f15d472885f788a2d6e985850f264627b86012a17bb242c83f310d907e5')
-sha512sums=('b2df5f19b14b670825b18f7da4ca50b089beb2ccbb1c69acfc904eed82b5315ad19940b4aaa8f8504c2fc7d477778d65e31f492dd30ee8b5ba95ccfd0eaeb9b1'
+arch=('any')
+url="https://github.com/stefankoegl/python-json-pointer"
+license=('BSD')
+makedepends=('python2-setuptools' 'python-setuptools')
+source=("https://pypi.io/packages/source/j/jsonpointer/jsonpointer-$pkgver.tar.gz"
+        "https://raw.github.com/stefankoegl/python-json-pointer/master/COPYING")
+sha512sums=('9832752d93bc93c96293243ef703418e1b29b196809c70e9d1a669747d7cdb453a48288f90687b69a83f51b0859e9501286ea411edbc216c24ae72e7ceffe1f1'
             '6a4c6b57a9cfe227175852c67ab7536fcc23646761cd10d25800edfccf408b139b1f589313f6cf6717c5764ca2e554cc16921118e01aebfbdf3ddfada82c6bac')
 
-export LANG=en_US.UTF-8
 prepare(){
-    cp -a $_pkgname-$pkgver $_pkgname-$pkgver-2
-    find $_pkgname-$pkgver-2 -name \*.py -exec sed -i '1s/python$/&2/' {} +
+    cp -a jsonpointer-$pkgver jsonpointer-$pkgver-2
+    find jsonpointer-$pkgver-2 -name \*.py -exec sed -i '1s/python$/&2/' {} +
 }
 
 build() {
-    cd $srcdir/$_pkgname-$pkgver
+    cd "$srcdir"/jsonpointer-$pkgver
     python setup.py build
-    cd $srcdir/$_pkgname-$pkgver-2
+
+    cd "$srcdir"/jsonpointer-$pkgver-2
     python2 setup.py build
 }
 
+check() {
+    cd "$srcdir"/jsonpointer-$pkgver
+    python tests.py
+
+    cd "$srcdir"/jsonpointer-$pkgver-2
+    python2 tests.py
+}
+
 package_python-jsonpointer() {
-    cd $_pkgname-$pkgver
-    depends=(python)
+    depends=('python')
+
+    cd jsonpointer-$pkgver
     python setup.py install --prefix=/usr --root="$pkgdir"
-    install -Dm644 $SRCDEST/COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
+    install -Dm644 "$srcdir"/COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
 }
 package_python2-jsonpointer() {
-    cd $_pkgname-$pkgver-2
-    depends=(python2)
+    depends=('python2')
+
+    cd jsonpointer-$pkgver-2
     python2 setup.py install --prefix=/usr --root="$pkgdir"
-    mv $pkgdir/usr/bin/jsonpointer $pkgdir/usr/bin/jsonpointer2 
-    install -Dm644 $SRCDEST/COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
+    mv "$pkgdir"/usr/bin/jsonpointer{,2}
+    install -Dm644 "$srcdir"/COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
 }



More information about the arch-commits mailing list