unixODBC/odbcint64-config.patch

27 lines
961 B
Diff
Raw Normal View History

Fix output of odbc_config --header, per bug #518623.
This error results in SQLBIGINT and SQLUBIGINT being misdefined as
int, where they need to be [unsigned] long or long long.
diff -Naur unixODBC-2.2.14.orig/exe/odbc-config.c unixODBC-2.2.14/exe/odbc-config.c
--- unixODBC-2.2.14.orig/exe/odbc-config.c 2008-05-20 08:58:17.000000000 -0400
+++ unixODBC-2.2.14/exe/odbc-config.c 2009-08-21 14:15:35.000000000 -0400
@@ -66,12 +66,15 @@
printf( "#ifndef HAVE_LONG_LONG\n #define HAVE_LONG_LONG\n#endif\n" );
#endif
+#define xstr(s) str(s)
+#define str(s) #s
+
#ifdef ODBCINT64
- printf( "#ifndef ODBCINT64\n #define ODBCINT64\n#endif\n" );
+ printf( "#ifndef ODBCINT64\n #define ODBCINT64 %s\n#endif\n", xstr(ODBCINT64) );
#endif
#ifdef UODBCINT64
- printf( "#ifndef UODBCINT64\n #define UODBCINT64\n#endif\n" );
+ printf( "#ifndef UODBCINT64\n #define UODBCINT64 %s\n#endif\n", xstr(UODBCINT64) );
#endif
#ifdef DISABLE_INI_CACHING