Errors compiling psqlodbc - Mailing list pgsql-odbc

From Rich Silva
Subject Errors compiling psqlodbc
Date
Msg-id 20041016225900.QWOH3551.lakecmmtao01.coxmail.com@CALICOBASS
Whole thread Raw
Responses Re: Errors compiling psqlodbc
Re: Errors compiling psqlodbc
List pgsql-odbc

 

 

Hmmm, I was building the latest (07.03.0200) sources for a Linux system and I found first one then another issue…

 

First issue (and already submitted as a bug): The default ODBCVER is not 0x0300, but 0x0250. Configure does not set ODBCVER unless the –with-odbcver option is used… In psqlodbc.h, if ODBCVER is not set it defaults to 0x0250. I’m now using the configure line:

 

./configure --with-unixodbc --prefix=/usr --sysconfdir=/etc --with-odbcver=0x0300 

 

Second issue (and still diagnosing), once I’ve configured with that define the project will not compile, generating the following errors:

convert.c: In function `copy_and_convert_field':

convert.c:1194: incompatible types in assignment

convert.c:1196: incompatible types in assignment

convert.c:1202: incompatible types in assignment

convert.c:1204: incompatible types in assignment

(example line: *((SQLBIGINT *) rgbValueBindRow) = ATOI64(neut_str);)

 

odbcapi.c: In function `SQLFetch':

odbcapi.c:349: warning: initialization from incompatible pointer type

(line: SQLINTEGER *pcRow = irdopts->rowsFetched;)

 

odbcapi30.c: In function `SQLFetchScroll':

odbcapi30.c:204: warning: initialization from incompatible pointer type

(line: SQLINTEGER *pcRow = irdopts->rowsFetched, bkmarkoff = 0;)

 

pgapi30.c: In function `IRDSetField':

pgapi30.c:755: warning: assignment from incompatible pointer type

(example: opts->rowsFetched = (SQLUINTEGER *) Value;)

pgapi30.c: In function `IPDSetField':

pgapi30.c:811: warning: assignment from incompatible pointer type

pgapi30.c: In function `PGAPI_GetStmtAttr':

pgapi30.c:1424: warning: assignment from incompatible pointer type

pgapi30.c:1440: warning: assignment from incompatible pointer type

pgapi30.c:1448: warning: assignment from incompatible pointer type

pgapi30.c:1460: warning: assignment from incompatible pointer type

pgapi30.c: In function `PGAPI_SetStmtAttr':

pgapi30.c:1685: warning: assignment from incompatible pointer type

pgapi30.c:1697: warning: assignment from incompatible pointer type

pgapi30.c:1703: warning: assignment from incompatible pointer type

pgapi30.c:1712: warning: assignment from incompatible pointer type

 

Now, I’m not yet claiming to be a programmer, so I’m hoping that someone has tackled these before…

 

Thanx for the help!

Rich Silva

 

pgsql-odbc by date:

Previous
From: Mike Fahey
Date:
Subject: Lots of write errors with foreign key references :(
Next
From: Robert Treat
Date:
Subject: Re: cannot connect from Windows 2000