1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-26 09:46:09 +00:00

Fix build for the recent freetds library and unmark BROKEN.

This commit is contained in:
Hye-Shik Chang 2005-05-05 08:47:45 +00:00
parent 2af440166f
commit c94348debc
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=134647
2 changed files with 42 additions and 2 deletions

View File

@ -19,8 +19,6 @@ COMMENT= Python database interface for simple MS-SQL access
LIB_DEPENDS= sybdb.5:${PORTSDIR}/databases/freetds-msdblib
BROKEN= Does not compile
USE_PYTHON= yes
USE_PYDISTUTILS=yes
USE_REINPLACE= yes

View File

@ -0,0 +1,42 @@
--- mssqldbmodule.c.orig Thu May 5 17:32:37 2005
+++ mssqldbmodule.c Thu May 5 17:43:36 2005
@@ -18,9 +18,9 @@
#include <sqlfront.h>
#include <sqldb.h> // DB-LIB header file (should always be included)
#else
- #include <sybfront.h>
- #include <sybdb.h> // DB-LIB header file (should always be included)
- #include <dblib.h> // DB-LIB header file (should always be included)
+ #include <tds.h>
+ #define _FREETDS_LIBRARY_SOURCE 1
+ #include <sybdb.h>
#define SQLNUMERIC SYBNUMERIC
#define SQLDECIMAL SYBDECIMAL
@@ -115,7 +115,7 @@
DBUSMALLINT line;
{
- sprintf(_mssql_query_message,"SQL Server message %ld, state %d, severity %d:\n\t%s\n", msgno, msgstate, severity, msgtext);
+ sprintf(_mssql_query_message,"SQL Server message %ld, state %d, severity %d:\n\t%s\n", (long)msgno, msgstate, severity, msgtext);
return(0);
}
@@ -203,7 +203,7 @@
dberrhandle(err_handler);
dbmsghandle(msg_handler);
// Set port
- tds_set_port(login->tds_login, port);
+ //tds_set_port(login->tds_login, port);
#endif
@@ -757,7 +757,7 @@
DBDATEREC di;
char strdi[25]={0,};
dbdatecrack(dbproc, &di, (DBDATETIME*)data);
-#ifdef MS_WIN32
+#if 1
sprintf(strdi, "%02d-%02d-%02d %02d:%02d:%02d",
di.year,
di.month+1,