microsoft / ODBC-Specification

Microsoft ODBC Specification
Other
121 stars 40 forks source link

Getting "function declaration isn't a prototype [-Werror=strict-prototypes]" when compiling an application in C style using gcc compile #138

Open vnkbabu opened 5 years ago

vnkbabu commented 5 years ago

Hi, One of our customer is trying to compile the ODBC application using gcc compiler in C style, they are encountering the following errors, due to pre-Ansi declarations of empty parameter list functions and using -Werror=strict-prototypes option for compiling.

/vobs/tt/servers/DB2/db2_driver.c -o
/vobs/obj.dbg.RHAT7/servers/DB2/db2_driver_64.o
In file included from /dbms/DB2/9.7/LINUX3.10/include/sqlcli.h:981:0,
from /dbms/DB2/9.7/LINUX3.10/include/sqlcli1.h:45,
from /vobs/tt/servers/DB2/db2_driver.h:17,
from /vobs/tt/servers/DB2/db2_driver.c:35:
/dbms/DB2/9.7/LINUX3.10/include/sqlext.h:2132:1: error: function
declaration isn't a prototype [-Werror=strict-prototypes]
RETCODE SQL_API TraceCloseLogFile(); / Request to close a trace log / ^~~
/dbms/DB2/9.7/LINUX3.10/include/sqlext.h:2134:1: error: function
declaration isn't a prototype [-Werror=strict-prototypes]
DWORD SQL_API TraceVersion(); / Returns trace API version /
^~~~~
/dbms/DB2/9.7/LINUX3.10/include/sqlext.h:2152:1: error: function
declaration isn't a prototype [-Werror=strict-prototypes]
DWORD SQL_API ODBCGetTryWaitValue(); / In Milliseconds(!) /
^~~~~

Could you please fix this issue as customer who is using the strict-prototypes are getting impacted.