summaryrefslogtreecommitdiff
path: root/textproc
diff options
context:
space:
mode:
authorobache <obache@pkgsrc.org>2010-06-01 05:28:11 +0000
committerobache <obache@pkgsrc.org>2010-06-01 05:28:11 +0000
commit513ba113c196a38e727706dbc2fd491dcd6e6195 (patch)
treed63403ef7b2e574bbb109e576fd53466c4ed6893 /textproc
parent23ee368739e7d2df9b3302244f1b817aaf3b0823 (diff)
downloadpkgsrc-513ba113c196a38e727706dbc2fd491dcd6e6195.tar.gz
Update py-enchant to 1.6.2.
Based on PR#43384 by Wen Heping. * Migrated from SWIG to ctypes since 1.5.0: * Add dependency on devel/py-ctypes for python2.4 * Fix paths for libenchant to exactly load suitable one. * No need c compiler and buildlink with textproc/enchant. Changes: 1.6.2: * Upgraded bundled enchant to v1.6.0. * Fixed bug in printf() utility function; all input args are now converted to strings before printing. 1.6.1: * Fixed loading of enchant DLL on win32 without pkg_resources installed. * Fixed HTMLChunker to handle unescaped < and > characters that are clearly not part of a tag. 1.6.0: * Upgraded to enchant v1.5.0: * new Broker methods get_param() and set_param() allow runtime customisation of provider data * Added the concept of 'chunkers' to enchant.tokenize.get_tokenizer(). These serve split split the text into large chunks of checkable tokens. * implemented a simple HTMLChunker class * Moved error classes into 'enchant.errors' for easier importing * Moved testcases into separate files so they're not loaded by default * Allowed SpellChecker to use default language if none is specified * Improved compatibility with Python 3 1.5.3: * Fixed termination conditions in English tokenization loop. * Improved unicode detection in English tokenizer. * Made enchant spellcheck all of its docstrings as part of the unittest suite. 1.5.2: * Modify utils.get_resource_filename and utils.win32_data_files for compatibility with py2exe (which was broken in the move to ctypes). Thanks to Stephen George for the fix. 1.5.1: * SpellChecker.add_to_personal renamed to SpellChecker.add and fixed to use the corresponding Dict method. 1.5.0: * Migrated from SWIG to ctypes: * now runs under PyPy! * also opens possibilities for Jython, IronPython, ... * Compatibility updates for Python 3.0, mostly around unicode strings * Dropped compatibility with Python 2.2
Diffstat (limited to 'textproc')
-rw-r--r--textproc/py-enchant/Makefile34
-rw-r--r--textproc/py-enchant/PLIST22
-rw-r--r--textproc/py-enchant/distinfo10
-rw-r--r--textproc/py-enchant/patches/patch-aa17
-rw-r--r--textproc/py-enchant/patches/patch-ab14
5 files changed, 85 insertions, 12 deletions
diff --git a/textproc/py-enchant/Makefile b/textproc/py-enchant/Makefile
index c2197798330..201fb7edc11 100644
--- a/textproc/py-enchant/Makefile
+++ b/textproc/py-enchant/Makefile
@@ -1,19 +1,41 @@
-# $NetBSD: Makefile,v 1.2 2009/02/16 19:38:27 joerg Exp $
+# $NetBSD: Makefile,v 1.3 2010/06/01 05:28:11 obache Exp $
#
-DISTNAME= pyenchant-1.4.2
+DISTNAME= pyenchant-1.6.2
PKGNAME= ${DISTNAME:S/py/${PYPKGPREFIX}-/}
CATEGORIES= textproc
-MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=pyenchant/}
+MASTER_SITES= http://pypi.python.org/packages/source/p/pyenchant/
MAINTAINER= pkgsrc-users@NetBSD.org
-HOMEPAGE= http://pyenchant.sourceforge.net/
+HOMEPAGE= http://www.rfk.id.au/software/pyenchant/
COMMENT= Spellchecking library for Python
+LICENSE= gnu-lgpl-v2.1
PKG_DESTDIR_SUPPORT= user-destdir
-USE_LANGUAGES= c
+.include "../../lang/python/pyversion.mk"
+
+.if ${PYPACKAGE} && ${PYPACKAGE} == "python24"
+DEPENDS+= ${PYPKGPREFIX}-ctype-[0-9]*:../../devel/py-ctype
+.endif
+DEPENDS+= enchant-[0-9]*:../../textproc/enchant
+
+USE_LANGUAGES= # empty
+
+FIND_PREFIX:= ENCHANT_DIR=enchant
+.include "../../mk/find-prefix.mk"
+
+.include "../../mk/bsd.prefs.mk"
+
+DLEXT.dylib= dylib
+DLEXT= ${DLEXT.${_OPSYS_SHLIB_TYPE}:Uso}
+PYENCHANT_LIBRARY_PATH= ${ENCHANT_DIR}/lib/libenchant.${DLEXT}
+
+# fix the path of libenchant with patch-ab.
+SUBST_CLASSES+= dlpath
+SUBST_STAGE.dlpath= pre-configure
+SUBST_FILES.dlpath= enchant/_enchant.py
+SUBST_VARS.dlpath= PYENCHANT_LIBRARY_PATH
.include "../../lang/python/egg.mk"
-.include "../../textproc/enchant/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/textproc/py-enchant/PLIST b/textproc/py-enchant/PLIST
index ccfff73d002..ef0a2c77381 100644
--- a/textproc/py-enchant/PLIST
+++ b/textproc/py-enchant/PLIST
@@ -1,8 +1,10 @@
-@comment $NetBSD: PLIST,v 1.2 2009/06/14 18:17:25 joerg Exp $
+@comment $NetBSD: PLIST,v 1.3 2010/06/01 05:28:11 obache Exp $
${PYSITELIB}/enchant/__init__.py
${PYSITELIB}/enchant/__init__.pyc
${PYSITELIB}/enchant/__init__.pyo
-${PYSITELIB}/enchant/_enchant.so
+${PYSITELIB}/enchant/_enchant.py
+${PYSITELIB}/enchant/_enchant.pyc
+${PYSITELIB}/enchant/_enchant.pyo
${PYSITELIB}/enchant/checker/CmdLineChecker.py
${PYSITELIB}/enchant/checker/CmdLineChecker.pyc
${PYSITELIB}/enchant/checker/CmdLineChecker.pyo
@@ -12,18 +14,34 @@ ${PYSITELIB}/enchant/checker/GtkSpellCheckerDialog.pyo
${PYSITELIB}/enchant/checker/__init__.py
${PYSITELIB}/enchant/checker/__init__.pyc
${PYSITELIB}/enchant/checker/__init__.pyo
+${PYSITELIB}/enchant/checker/tests.py
+${PYSITELIB}/enchant/checker/tests.pyc
+${PYSITELIB}/enchant/checker/tests.pyo
${PYSITELIB}/enchant/checker/wxSpellCheckerDialog.py
${PYSITELIB}/enchant/checker/wxSpellCheckerDialog.pyc
${PYSITELIB}/enchant/checker/wxSpellCheckerDialog.pyo
+${PYSITELIB}/enchant/errors.py
+${PYSITELIB}/enchant/errors.pyc
+${PYSITELIB}/enchant/errors.pyo
+${PYSITELIB}/enchant/lib/enchant/README.txt
${PYSITELIB}/enchant/pypwl.py
${PYSITELIB}/enchant/pypwl.pyc
${PYSITELIB}/enchant/pypwl.pyo
+${PYSITELIB}/enchant/share/enchant/README.txt
+${PYSITELIB}/enchant/share/enchant/ispell/README.txt
+${PYSITELIB}/enchant/share/enchant/myspell/README.txt
+${PYSITELIB}/enchant/tests.py
+${PYSITELIB}/enchant/tests.pyc
+${PYSITELIB}/enchant/tests.pyo
${PYSITELIB}/enchant/tokenize/__init__.py
${PYSITELIB}/enchant/tokenize/__init__.pyc
${PYSITELIB}/enchant/tokenize/__init__.pyo
${PYSITELIB}/enchant/tokenize/en.py
${PYSITELIB}/enchant/tokenize/en.pyc
${PYSITELIB}/enchant/tokenize/en.pyo
+${PYSITELIB}/enchant/tokenize/tests.py
+${PYSITELIB}/enchant/tokenize/tests.pyc
+${PYSITELIB}/enchant/tokenize/tests.pyo
${PYSITELIB}/enchant/utils.py
${PYSITELIB}/enchant/utils.pyc
${PYSITELIB}/enchant/utils.pyo
diff --git a/textproc/py-enchant/distinfo b/textproc/py-enchant/distinfo
index b568e4983bd..e78def37ed7 100644
--- a/textproc/py-enchant/distinfo
+++ b/textproc/py-enchant/distinfo
@@ -1,5 +1,7 @@
-$NetBSD: distinfo,v 1.1.1.1 2008/10/08 09:42:47 wiz Exp $
+$NetBSD: distinfo,v 1.2 2010/06/01 05:28:11 obache Exp $
-SHA1 (pyenchant-1.4.2.tar.gz) = 97197d72a0197e459946805d254b3958a0e1de2e
-RMD160 (pyenchant-1.4.2.tar.gz) = 9107042d841ab920baeeef10643d88ff4e65bb7f
-Size (pyenchant-1.4.2.tar.gz) = 81230 bytes
+SHA1 (pyenchant-1.6.2.tar.gz) = 54937a31dfdd1023f588ff599135b541f7845eb8
+RMD160 (pyenchant-1.6.2.tar.gz) = 8dc31b837e33d2fe517b9346077060767526861b
+Size (pyenchant-1.6.2.tar.gz) = 57761 bytes
+SHA1 (patch-aa) = 4afb6e32c84efb177f47b94fca4b91bae459a10d
+SHA1 (patch-ab) = ff02e814ff0cf66eca54608c545ae6e95456231f
diff --git a/textproc/py-enchant/patches/patch-aa b/textproc/py-enchant/patches/patch-aa
new file mode 100644
index 00000000000..4018ee0e486
--- /dev/null
+++ b/textproc/py-enchant/patches/patch-aa
@@ -0,0 +1,17 @@
+$NetBSD: patch-aa,v 1.1 2010/06/01 05:28:11 obache Exp $
+
+avoid extra download of distribute-0.6.10.tar.gz.
+
+--- setup.py.orig 2010-05-29 04:14:59.000000000 +0000
++++ setup.py
+@@ -6,8 +6,8 @@
+ #
+
+
+-import distribute_setup
+-distribute_setup.use_setuptools()
++#import distribute_setup
++#distribute_setup.use_setuptools()
+ from setuptools import setup, find_packages, Extension
+
+ import sys
diff --git a/textproc/py-enchant/patches/patch-ab b/textproc/py-enchant/patches/patch-ab
new file mode 100644
index 00000000000..0cbcd3ef540
--- /dev/null
+++ b/textproc/py-enchant/patches/patch-ab
@@ -0,0 +1,14 @@
+$NetBSD: patch-ab,v 1.1 2010/06/01 05:28:11 obache Exp $
+
+fix path of libenchant.
+
+--- enchant/_enchant.py.orig 2010-03-06 07:27:42.000000000 +0000
++++ enchant/_enchant.py
+@@ -67,6 +67,7 @@ if sys.platform == "win32":
+
+ def _e_path_possibilities():
+ yield os.environ.get("PYENCHANT_LIBRARY_PATH")
++ yield "@PYENCHANT_LIBRARY_PATH@"
+ yield find_library("enchant")
+ yield find_library("libenchant")
+ yield find_library("libenchant-1")