diff --git a/databases/Makefile b/databases/Makefile index 5c80eee62aa0..ca485c77a700 100644 --- a/databases/Makefile +++ b/databases/Makefile @@ -691,6 +691,7 @@ SUBDIR += py-cql SUBDIR += py-dbf SUBDIR += py-dbutils + SUBDIR += py-fdb SUBDIR += py-firebirdsql SUBDIR += py-flask-sqlalchemy SUBDIR += py-forgetsql diff --git a/databases/py-fdb/Makefile b/databases/py-fdb/Makefile new file mode 100644 index 000000000000..701d69255cac --- /dev/null +++ b/databases/py-fdb/Makefile @@ -0,0 +1,33 @@ +# Created by: Jose Jachuf +# $FreeBSD$ + +PORTNAME= fdb +PORTVERSION= 0.9.1 +CATEGORIES= databases python +MASTER_SITES= CHEESESHOP +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= jjachuf@gmail.com +COMMENT= Firebird RDBMS bindings for Python + +LICENSE= BSD + +LIB_DEPENDS= fbclient:${PORTSDIR}/databases/firebird25-client + +USE_PYTHON= yes +USE_PYDISTUTILS=easy_install + +.include + +.if ${PYTHON_REL} >= 320 +.include "${FILESDIR}/py3k-fix-pkg-plist.inc" +.endif + +post-patch: + @${ECHO_MSG} + @${ECHO_MSG} "Please make sure that your firebird-client installation" + @${ECHO_MSG} "is built with command make -DPACKAGE_BUILDING." + @${ECHO_MSG} "The build of py-fdb will fail otherwise." + @${ECHO_MSG} + +.include diff --git a/databases/py-fdb/distinfo b/databases/py-fdb/distinfo new file mode 100644 index 000000000000..aa72c4094860 --- /dev/null +++ b/databases/py-fdb/distinfo @@ -0,0 +1,2 @@ +SHA256 (fdb-0.9.1.tar.gz) = 01dffb6a4638d980f2cbc7c785c48435919d88361b3472c1c9758ae8145daf65 +SIZE (fdb-0.9.1.tar.gz) = 468175 diff --git a/databases/py-fdb/files/py3k-fix-pkg-plist.inc b/databases/py-fdb/files/py3k-fix-pkg-plist.inc new file mode 100644 index 000000000000..93acb972e248 --- /dev/null +++ b/databases/py-fdb/files/py3k-fix-pkg-plist.inc @@ -0,0 +1,14 @@ +# When Python version is 3.2+ we rewrite all the filenames +# of TMPPLIST that end with .py[co], so that they conform +# to PEP 3147 (see http://www.python.org/dev/peps/pep-3147/) +PYMAGICTAG= ${PYTHON_CMD} -c 'import imp; print(imp.get_tag())' +add-plist-post: + @${AWK} '\ + /\.py[co]$$/ && !($$0 ~ "/" pc "/") {id = match($$0, /\/[^\/]+\.py[co]$$/); if (id != 0) {d = substr($$0, 1, RSTART - 1); dirs[d] = 1}; sub(/\.py[co]$$/, "." mt "&"); sub(/[^\/]+\.py[co]$$/, pc "/&"); print; next} \ + /^@dirrm / {d = substr($$0, 8); if (d in dirs) {print $$0 "/" pc}; print $$0; next} \ + {print} \ + END {if (sp in dirs) {print "@dirrm " sp "/" pc}} \ + ' \ + pc="__pycache__" mt="$$(${PYMAGICTAG})" sp="${PYTHON_SITELIBDIR:S,${PYTHONBASE}/,,g}" \ + ${TMPPLIST} > ${TMPPLIST}.pyc_tmp + @${MV} ${TMPPLIST}.pyc_tmp ${TMPPLIST} diff --git a/databases/py-fdb/pkg-descr b/databases/py-fdb/pkg-descr new file mode 100644 index 000000000000..c58ac71d5497 --- /dev/null +++ b/databases/py-fdb/pkg-descr @@ -0,0 +1,5 @@ +Firebird RDBMS bindings for Python. +fdb package is a set of Firebird RDBMS bindings for python. +It works on Python 2.6+ and Python 3.x + +WWW: http://www.firebirdsql.org/en/python-devel-status/ diff --git a/databases/py-fdb/pkg-plist b/databases/py-fdb/pkg-plist new file mode 100644 index 000000000000..e324cd6468ca --- /dev/null +++ b/databases/py-fdb/pkg-plist @@ -0,0 +1,21 @@ +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/__init__.py +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/__init__.pyc +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/__init__.pyo +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/fbcore.py +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/fbcore.pyc +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/fbcore.pyo +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/ibase.py +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/ibase.pyc +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/ibase.pyo +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/services.py +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/services.pyc +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb/services.pyo +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/PKG-INFO +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/SOURCES.txt +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/dependency_links.txt +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/entry_points.txt +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/not-zip-safe +%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO/top_level.txt +@dirrm %%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/fdb +@dirrm %%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/EGG-INFO +@dirrm %%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%