aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoramdmi3 <amdmi3@FreeBSD.org>2016-07-19 05:06:53 +0800
committeramdmi3 <amdmi3@FreeBSD.org>2016-07-19 05:06:53 +0800
commit22fd4460f9e49d52073cac871c1ea41e4bee5720 (patch)
tree8136e3665d3f74838a71b561ca553a5c5515eb4a
parente5b3c466eb20016857c9249595ca42f7270d048d (diff)
downloadfreebsd-ports-gnome-22fd4460f9e49d52073cac871c1ea41e4bee5720.tar.gz
freebsd-ports-gnome-22fd4460f9e49d52073cac871c1ea41e4bee5720.tar.zst
freebsd-ports-gnome-22fd4460f9e49d52073cac871c1ea41e4bee5720.zip
- Fix build after FreeTDS update by porting upstream commit ec46fea
PR: 210363 Reported by: ports@thelanman.net (maintainer), pkg-fallout Approved by: portmgr blanket
-rw-r--r--databases/py-pymssql/Makefile5
-rw-r--r--databases/py-pymssql/files/patch-__mssql.pyx16
-rw-r--r--databases/py-pymssql/files/patch-sqlfront.pxd10
3 files changed, 30 insertions, 1 deletions
diff --git a/databases/py-pymssql/Makefile b/databases/py-pymssql/Makefile
index bd02be4c66f7..04691c2a0bbc 100644
--- a/databases/py-pymssql/Makefile
+++ b/databases/py-pymssql/Makefile
@@ -19,8 +19,11 @@ LIB_DEPENDS= libsybdb.so:databases/freetds
USES= python
USE_PYTHON= autoplist distutils
+post-extract:
+ @${RM} -f ${WRKSRC}/_mssql.c
+
post-install:
- ${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/_mssql.so \
+ @${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/_mssql.so \
${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/pymssql.so
.include <bsd.port.mk>
diff --git a/databases/py-pymssql/files/patch-__mssql.pyx b/databases/py-pymssql/files/patch-__mssql.pyx
new file mode 100644
index 000000000000..28a1732da585
--- /dev/null
+++ b/databases/py-pymssql/files/patch-__mssql.pyx
@@ -0,0 +1,16 @@
+--- _mssql.pyx.orig 2014-10-24 22:03:00 UTC
++++ _mssql.pyx
+@@ -1677,12 +1677,10 @@ cdef int _tds_ver_str_to_constant(verstr
+ return DBVERSION_42
+ if verstr == u'7.0':
+ return DBVERSION_70
+- if verstr == u'7.1':
++ if verstr in (u'7.1', u'8.0'):
+ return DBVERSION_71
+ if verstr == u'7.2':
+ return DBVERSION_72
+- if verstr == u'8.0':
+- return DBVERSION_80
+ raise MSSQLException('unrecognized tds version: %s' % verstr)
+
+ #######################
diff --git a/databases/py-pymssql/files/patch-sqlfront.pxd b/databases/py-pymssql/files/patch-sqlfront.pxd
new file mode 100644
index 000000000000..896fb07854e8
--- /dev/null
+++ b/databases/py-pymssql/files/patch-sqlfront.pxd
@@ -0,0 +1,10 @@
+--- sqlfront.pxd.orig 2014-08-29 22:32:11 UTC
++++ sqlfront.pxd
+@@ -106,7 +106,6 @@ cdef extern from "sqlfront.h":
+ int DBVERSION_70
+ int DBVERSION_71
+ int DBVERSION_72
+- int DBVERSION_80
+
+ ## Type Constants ##
+ cdef enum: