summaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
authorobache <obache@pkgsrc.org>2011-10-05 07:43:12 +0000
committerobache <obache@pkgsrc.org>2011-10-05 07:43:12 +0000
commitb8ca74a9c8a9ffba1d240642eea5391b22c631ce (patch)
treeece2d3b1e8e40ad5b17a7cae36ed5a6b4fbc4cd3 /math
parent9743eabf9e5310e89240fe43ce2de8a6380fbf5d (diff)
downloadpkgsrc-b8ca74a9c8a9ffba1d240642eea5391b22c631ce.tar.gz
Import py-roman-1.4.0 as math/py-roman.
This Python module provides methods for converting Integer from/to Roman.
Diffstat (limited to 'math')
-rw-r--r--math/py-roman/DESCR1
-rw-r--r--math/py-roman/Makefile21
-rw-r--r--math/py-roman/PLIST9
-rw-r--r--math/py-roman/distinfo6
-rw-r--r--math/py-roman/patches/patch-src_roman.py15
5 files changed, 52 insertions, 0 deletions
diff --git a/math/py-roman/DESCR b/math/py-roman/DESCR
new file mode 100644
index 00000000000..06848b8c96f
--- /dev/null
+++ b/math/py-roman/DESCR
@@ -0,0 +1 @@
+This Python module provides methods for converting Integer from/to Roman.
diff --git a/math/py-roman/Makefile b/math/py-roman/Makefile
new file mode 100644
index 00000000000..fe63e0e7b80
--- /dev/null
+++ b/math/py-roman/Makefile
@@ -0,0 +1,21 @@
+# $NetBSD: Makefile,v 1.1.1.1 2011/10/05 07:43:12 obache Exp $
+#
+
+DISTNAME= roman-1.4.0
+PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
+CATEGORIES= math
+MASTER_SITES= http://pypi.python.org/packages/source/r/roman/
+
+MAINTAINER= obache@NetBSD.org
+HOMEPAGE= http://pypi.python.org/pypi/roman/
+COMMENT= Integer to Roman numerals converter for Python
+LICENSE= python-software-foundation
+
+CONFLICTS+= ${PYPKGPREFIX}-docutils<=0.7
+
+PKG_DESTDIR_SUPPORT= user-destdir
+
+USE_LANGUAGES= # none
+
+.include "../../lang/python/egg.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/math/py-roman/PLIST b/math/py-roman/PLIST
new file mode 100644
index 00000000000..4b2d385a884
--- /dev/null
+++ b/math/py-roman/PLIST
@@ -0,0 +1,9 @@
+@comment $NetBSD: PLIST,v 1.1.1.1 2011/10/05 07:43:12 obache Exp $
+${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
+${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
+${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
+${PYSITELIB}/${EGG_INFODIR}/top_level.txt
+${PYSITELIB}/${EGG_INFODIR}/zip-safe
+${PYSITELIB}/roman.py
+${PYSITELIB}/roman.pyc
+${PYSITELIB}/roman.pyo
diff --git a/math/py-roman/distinfo b/math/py-roman/distinfo
new file mode 100644
index 00000000000..2e976ad385b
--- /dev/null
+++ b/math/py-roman/distinfo
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1.1.1 2011/10/05 07:43:12 obache Exp $
+
+SHA1 (roman-1.4.0.tar.gz) = 3d9cf0c46a4e3558785a9f7c90cd96a2d31dc9b0
+RMD160 (roman-1.4.0.tar.gz) = 9c9f1d8de8e19f6dcab02a28b2a28a1a7f3dd546
+Size (roman-1.4.0.tar.gz) = 3033 bytes
+SHA1 (patch-src_roman.py) = 3cbe70896a19b5d177b329f18dcb37a051f0305a
diff --git a/math/py-roman/patches/patch-src_roman.py b/math/py-roman/patches/patch-src_roman.py
new file mode 100644
index 00000000000..b59e7002972
--- /dev/null
+++ b/math/py-roman/patches/patch-src_roman.py
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_roman.py,v 1.1.1.1 2011/10/05 07:43:12 obache Exp $
+
+* replace deprecated operator `<>' with `!='
+
+--- src/roman.py.orig 2009-07-23 16:34:18.000000000 +0000
++++ src/roman.py
+@@ -41,7 +41,7 @@ def toRoman(n):
+ """convert integer to Roman numeral"""
+ if not (0 < n < 5000):
+ raise OutOfRangeError, "number out of range (must be 1..4999)"
+- if int(n) <> n:
++ if int(n) != n:
+ raise NotIntegerError, "decimals can not be converted"
+
+ result = ""