[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
12/19: gnu: Add python-anyjson.
From: |
Christopher Allan Webber |
Subject: |
12/19: gnu: Add python-anyjson. |
Date: |
Mon, 15 Feb 2016 19:23:14 +0000 |
cwebber pushed a commit to branch wip-mediagoblin
in repository guix.
commit e1876a986a8124068ee24bd63f8bc3b1a47732c9
Author: Christopher Allan Webber <address@hidden>
Date: Sun Feb 14 12:16:49 2016 -0800
gnu: Add python-anyjson.
* gnu/packages/python.scm (python-anyjson, python2-anyjson): New variables.
---
gnu/packages/python.scm | 39 +++++++++++++++++++++++++++++++++++++++
1 files changed, 39 insertions(+), 0 deletions(-)
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index bfcf4f5..ae40ab2 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -7854,3 +7854,42 @@ file.")
(inherit webtest)
(inputs `(("python2-setuptools" ,python2-setuptools)
,@(package-inputs webtest))))))
+
+(define-public python-anyjson
+ (package
+ (name "python-anyjson")
+ (version "0.3.3")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "anyjson" version))
+ (sha256
+ (base32
+ "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
+ (build-system python-build-system)
+ (arguments
+ `(;; We could possibly get tests working, but on Python 3 it's not so
easy.
+ ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
+ ;; whatever) so this transformation needs to be done before the tests
+ ;; can be run. Maybe we could add a build step to transform beforehand
+ ;; but it could be annoying/difficult.
+ ;; We can enable tests for the Python 2 version, though, and do below.
+ #:tests? #f))
+ (home-page "http://bitbucket.org/runeh/anyjson/")
+ (synopsis
+ "Wraps best available JSON implementation in a common interface.")
+ (description
+ "Anyjson loads whichever is the fastest JSON module installed
+and provides a uniform API regardless of which JSON implementation is used.")
+ (license bsd-3)
+ (properties `((python2-variant . ,(delay python2-anyjson))))))
+
+(define-public python2-anyjson
+ (package
+ (inherit (package-with-python2
+ (strip-python2-variant python-anyjson)))
+ (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
+ #:tests? #t
+ #:python ,python-2))
+ (inputs `(("python2-setuptools" ,python2-setuptools)
+ ("python2-nose" ,python2-nose)))))
- 02/19: gnu: Add python-alembic., (continued)
- 02/19: gnu: Add python-alembic., Christopher Allan Webber, 2016/02/15
- 03/19: gnu: Add python2-apipkg., Christopher Allan Webber, 2016/02/15
- 04/19: gnu: Add python2-execnet., Christopher Allan Webber, 2016/02/15
- 05/19: gnu: Add python-pytest-xdist., Christopher Allan Webber, 2016/02/15
- 06/19: gnu: Add python-beautifulsoup4, Christopher Allan Webber, 2016/02/15
- 07/19: gnu: Add python-waitress., Christopher Allan Webber, 2016/02/15
- 08/19: gnu: Add python-wsgiproxy2., Christopher Allan Webber, 2016/02/15
- 09/19: gnu: Add python-pastedeploy, Christopher Allan Webber, 2016/02/15
- 10/19: gnu: Add python-pyquery, Christopher Allan Webber, 2016/02/15
- 11/19: gnu: Add python-webtest., Christopher Allan Webber, 2016/02/15
- 12/19: gnu: Add python-anyjson.,
Christopher Allan Webber <=
- 13/19: gnu: Add python-amqp., Christopher Allan Webber, 2016/02/15
- 14/19: gnu: Add python-kombu., Christopher Allan Webber, 2016/02/15
- 15/19: gnu: Add python-billiard., Christopher Allan Webber, 2016/02/15
- 16/19: gnu: Add python2-celery., Christopher Allan Webber, 2016/02/15
- 17/19: gnu: Add python-translitcodec., Christopher Allan Webber, 2016/02/15
- 18/19: gnu: Add python-editor., Christopher Allan Webber, 2016/02/15
- 19/19: gnu: Add mediagoblin., Christopher Allan Webber, 2016/02/15