summary refs log tree commit diff
path: root/gnu
diff options
context:
space:
mode:
authorRicardo Wurmus <ricardo.wurmus@mdc-berlin.de>2015-09-23 12:50:13 +0200
committerRicardo Wurmus <ricardo.wurmus@mdc-berlin.de>2015-10-12 16:08:18 +0200
commitcd6e5189c8845b29a7a57916bbb87eb67df51c41 (patch)
tree386989f76323d6ce8bc65f6423f564511211c7a1 /gnu
parent0d34e01b62ea451e6584010c7c7a6db8e6e211ed (diff)
downloadguix-cd6e5189c8845b29a7a57916bbb87eb67df51c41.tar.gz
gnu: Add python-simplegeneric.
* gnu/packages/python.scm (python-simplegeneric, python2-simplegeneric):
  New variables.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/python.scm30
1 files changed, 29 insertions, 1 deletions
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 41b08cfde7..beebd630ea 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -32,7 +32,7 @@
   #:use-module ((guix licenses)
                 #:select (asl2.0 bsd-4 bsd-3 bsd-2 non-copyleft cc0 x11 x11-style
                           gpl2 gpl2+ gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ agpl3+
-                          isc psfl public-domain x11-style))
+                          isc psfl public-domain x11-style zpl2.1))
   #:use-module ((guix licenses) #:select (expat zlib) #:prefix license:)
   #:use-module (gnu packages)
   #:use-module (gnu packages attr)
@@ -3882,6 +3882,34 @@ PickleShare.")
 (define-public python2-pickleshare
   (package-with-python2 python-pickleshare))
 
+(define-public python-simplegeneric
+  (package
+    (name "python-simplegeneric")
+    (version "0.8.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://pypi.python.org/packages/source/s/"
+                           "simplegeneric/simplegeneric-" version ".zip"))
+       (sha256
+        (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("unzip" ,unzip)))
+    (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
+    (synopsis "Python module for simple generic functions")
+    (description
+     "The simplegeneric module lets you define simple single-dispatch generic
+functions, akin to Python’s built-in generic functions like @code{len()},
+@code{iter()} and so on.  However, instead of using specially-named methods,
+these generic functions use simple lookup tables, akin to those used by
+e.g. @code{pickle.dump()} and other generic functions found in the Python
+standard library.")
+    (license zpl2.1)))
+
+(define-public python2-simplegeneric
+  (package-with-python2 python-simplegeneric))
+
 (define-public python-ipython
   (package
     (name "python-ipython")