On Nov 26, 2007 6:44 PM, Martin Evans <[EMAIL PROTECTED]> wrote: > > Jergen Dutch wrote: > > Hello, > > > > I am building DBD::ODBC without unicode support. > > > > In dbdimp.c, I have: > > > > case SQL_VARCHAR: return "VARCHAR"; > > case SQL_WCHAR: return "UNICODE CHAR"; > > #ifdef SQL_WVARCHAR > > case SQL_WVARCHAR: return "UNICODE VARCHAR"; /* added for > > SQLServer 7 ntext type 2/24/2000 */ > > #endif > > > > Shouldn't SQL_WCHAR be included too? i.e. > > > > case SQL_VARCHAR: return "VARCHAR"; > > #ifdef SQL_WVARCHAR > > case SQL_WCHAR: return "UNICODE CHAR"; > > case SQL_WVARCHAR: return "UNICODE VARCHAR"; /* added for > > SQLServer 7 ntext type 2/24/2000 */ > > #endif > > > > I get the following error otherwise: > > > > dbdimp.c: In function 'odbc_describe': > > dbdimp.c:1780: error: 'SQL_WCHAR' undeclared (first use in this function) > > dbdimp.c:1780: error: (Each undeclared identifier is reported only once > > dbdimp.c:1780: error: for each function it appears in.) > > dbdimp.c:1781: error: 'SQL_WVARCHAR' undeclared (first use in this function) > > dbdimp.c:1782: error: 'SQL_C_WCHAR' undeclared (first use in this function) > > dbdimp.c:1784: error: 'WCHAR' undeclared (first use in this function) > > dbdimp.c: In function 'odbc_st_fetch': > > dbdimp.c:2401: error: 'SQL_C_WCHAR' undeclared (first use in this function) > > dbdimp.c:2402: error: 'SQL_WCHAR' undeclared (first use in this function) > > dbdimp.c:2404: error: 'WCHAR' undeclared (first use in this function) > > dbdimp.c:2404: error: 'p' undeclared (first use in this function) > > dbdimp.c:2404: error: expected expression before ')' token > > dbdimp.c:2409: error: expected expression before ')' token > > dbdimp.c:2409: error: too few arguments to function 'sv_setwvn' > > dbdimp.c: In function '_dbd_get_param_type': > > dbdimp.c:2601: error: 'SQL_WCHAR' undeclared (first use in this function) > > dbdimp.c:2602: error: 'SQL_WVARCHAR' undeclared (first use in this function) > > dbdimp.c:2603: error: 'SQL_WLONGVARCHAR' undeclared (first use in this > > function) > > dbdimp.c:2604: error: 'SQL_C_WCHAR' undeclared (first use in this function) > > dbdimp.c: In function '_dbd_rebind_ph': > > dbdimp.c:2657: error: 'WCHAR' undeclared (first use in this function) > > dbdimp.c:2694: error: 'SQL_C_WCHAR' undeclared (first use in this function) > > dbdimp.c:2887: error: expected expression before ')' token > > make: *** [dbdimp.o] Error 1 > > > > To get it to compile, I made the above change, as well as commenting > > out line 1585: > > s_c(SQL_C_WCHAR); > > Not the right approach, but it got me going. > > > > Is this a bug, or have I done something monstrously wrong? > > > > Thanks. > > > > > Could you please tell me which ODBC driver manager or driver you were > building with and its version. i.e. What did you set -o (or ODBCHOME to) > and what driver/driver_manager is at that location? Some of this is > output during perl Makefile.PL stage. > > Thanks. > > Martin > -- > Martin J. Evans > Easysoft Limited > http://www.easysoft.com >
Sure: intersystems cache. I extracted dist/ODBC/ODBC-8206-lnxrhx86.tar.Z from 5.2.0MV.8206.0_lnxrhx86_su.tar.gz and used: perl Makefile.PL -o /usr/cacheodbc/dev/odbc/redist/iodbc Some of the tests from make test fail, I can post these if you want.
