[arch-commits] Commit in python-jsonschema/repos/community-any (PKGBUILD PKGBUILD)

Felix Yan felixonmars at archlinux.org
Tue Dec 26 01:23:33 UTC 2017


    Date: Tuesday, December 26, 2017 @ 01:23:32
  Author: felixonmars
Revision: 276079

archrelease: copy trunk to community-any

Added:
  python-jsonschema/repos/community-any/PKGBUILD
    (from rev 276078, python-jsonschema/trunk/PKGBUILD)
Deleted:
  python-jsonschema/repos/community-any/PKGBUILD

----------+
 PKGBUILD |  104 ++++++++++++++++++++++++++++++++++++++-----------------------
 1 file changed, 66 insertions(+), 38 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2017-12-26 01:23:17 UTC (rev 276078)
+++ PKGBUILD	2017-12-26 01:23:32 UTC (rev 276079)
@@ -1,38 +0,0 @@
-# $Id$
-# Maintainer: Daniel Wallace <danielwallace at gtmanfred.com>
-# Contributor: Bogdan Szczurek <thebodzio at gmail.com>
-# Contributor: Ismo Toijala <ismo.toijala at gmail.com>
-
-pkgbase=python-jsonschema
-_pkgname=jsonschema
-pkgname=(python-jsonschema python2-jsonschema)
-pkgver=2.6.0
-pkgrel=1
-pkgdesc="An implementation of JSON Schema validation for Python"
-arch=(any)
-url="http://pypi.python.org/pypi/jsonschema"
-license=('MIT')
-makedepends=(python-setuptools python2-setuptools)
-source=("https://pypi.io/packages/source/j/jsonschema/${pkgname:7}-$pkgver.tar.gz")
-md5sums=('50c6b69a373a8b55ff1e0ec6e78f13f4')
-
-prepare(){
-    cp -a $_pkgname-$pkgver $_pkgname-$pkgver-2
-    find $_pkgname-$pkgver-2 -name \*.py -exec sed -i '1s/python$/&2/' {} +
-}
-
-package_python-jsonschema() {
-  cd "$srcdir/$_pkgname-$pkgver"
-  python setup.py install --root="$pkgdir/" --optimize=1
-  depends=(python)
-  install -D -m644 json/LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE
-}
-
-package_python2-jsonschema() {
-  cd "$srcdir/$_pkgname-$pkgver-2"
-  python2 setup.py install --root="$pkgdir/" --optimize=1
-  depends=(python2-functools32)
-  install -D -m644 json/LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE
-  mv $pkgdir/usr/bin/jsonschema{,2}
-}
-

Copied: python-jsonschema/repos/community-any/PKGBUILD (from rev 276078, python-jsonschema/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2017-12-26 01:23:32 UTC (rev 276079)
@@ -0,0 +1,66 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Daniel Wallace <danielwallace at gtmanfred.com>
+# Contributor: Bogdan Szczurek <thebodzio at gmail.com>
+# Contributor: Ismo Toijala <ismo.toijala at gmail.com>
+
+pkgbase=python-jsonschema
+pkgname=('python-jsonschema' 'python2-jsonschema')
+pkgver=2.6.0
+pkgrel=2
+pkgdesc="An implementation of JSON Schema validation for Python"
+arch=('any')
+url="http://pypi.python.org/pypi/jsonschema"
+license=('MIT')
+makedepends=('python-setuptools' 'python2-setuptools' 'python2-functools32' 'python-vcversioner'
+             'python2-vcversioner')
+checkdepends=('python-twisted' 'python2-twisted' 'python-mock' 'python2-mock'
+              'python-strict-rfc3339' 'python2-strict-rfc3339' 'python-rfc3987' 'python2-rfc3987'
+              'python-webcolors' 'python2-webcolors')
+source=("$pkgbase-$pkgver.tar.bz2::https://github.com/Julian/jsonschema/archive/v$pkgver.tar.gz")
+sha512sums=('863888fa70d7ae000530dcb405455d370a42c75b1e72970724d56397a1364da9198adb655ddebb6e8570b4bcf6ee17d26b712db86ddad15f65132dc9774e7255')
+
+prepare() {
+  echo -n "$pkgver-0-UNKNOWN" > jsonschema-$pkgver/version.txt
+  cp -a jsonschema-$pkgver{,-py2}
+  find jsonschema-$pkgver-py2 -name \*.py -exec sed -i '1s/python$/&2/' {} +
+}
+
+build() {
+  cd "$srcdir"/jsonschema-$pkgver
+  python setup.py build
+
+  cd "$srcdir"/jsonschema-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  cd "$srcdir"/jsonschema-$pkgver
+  PYTHONPATH="$PWD/build/lib" JSON_SCHEMA_TEST_SUITE=json trial3 jsonschema
+  python -m doctest README.rst
+
+  cd "$srcdir"/jsonschema-$pkgver-py2
+  PYTHONPATH="$PWD/build/lib" JSON_SCHEMA_TEST_SUITE=json trial jsonschema
+  # TODO: figure out why
+  rm -r build/lib/jsonschema/__pycache__
+  python2 -m doctest README.rst
+}
+
+package_python-jsonschema() {
+  depends=('python-setuptools')
+
+  cd jsonschema-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1
+  install -D -m644 json/LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-jsonschema() {
+  depends=('python2-setuptools' 'python2-functools32')
+
+  cd jsonschema-$pkgver-py2
+  python2 setup.py install --root="$pkgdir" --optimize=1
+  install -D -m644 json/LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+
+  mv "$pkgdir"/usr/bin/jsonschema{,2}
+}
+



More information about the arch-commits mailing list