[freetds] [0.95rc2] Unit Tests / Unicode

Frediano Ziglio freddy77 at gmail.com
Fri May 15 13:53:47 EDT 2015


2015-05-15 8:49 GMT+01:00 Sergio NNX <sfhacker at hotmail.com>:
>   CC       long_error.o
> In file included from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> sql.h:19:0,
>                  from common.h:24,
>                  from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/sqltypes.h:87:29: erro
> r: conflicting types for 'TCHAR'
> In file included from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windef.h:239:0,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windows.h:60,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> winsock2.h:40,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> ws2tcpip.h:41,
>                  from common.h:3,
>                  from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/winnt.h:136:15: note:
> previous declaration of 'TCHAR' was here
> In file included from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> sql.h:19:0,
>                  from common.h:24,
>                  from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/sqltypes.h:111:29: err
> or: conflicting types for 'LPTSTR'
> In file included from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windef.h:239:0,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windows.h:60,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> winsock2.h:40,
>                  from c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> ws2tcpip.h:41,
>                  from common.h:3,
>                  from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/winnt.h:154:30: note:
> previous declaration of 'LPTSTR' was here
> make[1]: *** [long_error.o] Error 1
>

This looks like an header but in your MingW.
Try including windows.h before winsock2.h.
Or sqlucode.h before sql.h.
On Ubuntu I have a cross MingW with gcc 4.8.2 is is working correctly.
Also Visual Studio 8.0 has no problems compiling it.

Frediano


More information about the FreeTDS mailing list