From: | Max Khon <fjoe(at)iclub(dot)nsu(dot)ru> |
---|---|
To: | Mindaugas Idzelis <mai3116(at)ritvax(dot)isc(dot)rit(dot)edu> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-interfaces(at)postgresql(dot)org |
Subject: | RE: bug in ODBC driver (and fix) |
Date: | 2001-01-23 08:41:29 |
Message-ID: | Pine.BSF.4.21.0101231438330.12474-100000@iclub.nsu.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-interfaces pgsql-odbc |
hi, there!
On Fri, 19 Jan 2001, Mindaugas Idzelis wrote:
> The ODBC driver I had problems with is found at:
> ftp://ftp.postgresql.org/pub/odbc/latest/postdrv.exe
>
> This is apparently revision v06-50-0000. I patched the sources to this
> particular version. I just realized that there is a copy of the odbc driver
> in the postgresql source tree. I'm going to try to compile that with visual
> c++ 6.0 now.
>
> <time warp>
>
> Got it to compile correctly, however, it doesn't link correctly. It's gettin
> some unresolved external symbols... by the looks of which look like its
> targeted to the unix platform.
>
> connection.obj : error LNK2001: unresolved external symbol _htonl(at)4
> socket.obj : error LNK2001: unresolved external symbol _htonl(at)4
> psqlodbc.obj : error LNK2001: unresolved external symbol _WSACleanup(at)0
> psqlodbc.obj : error LNK2001: unresolved external symbol _WSAStartup(at)8
> socket.obj : error LNK2001: unresolved external symbol _closesocket(at)4
> socket.obj : error LNK2001: unresolved external symbol _shutdown(at)8
> socket.obj : error LNK2001: unresolved external symbol _connect(at)12
> socket.obj : error LNK2001: unresolved external symbol _socket(at)12
> socket.obj : error LNK2001: unresolved external symbol _htons(at)4
> socket.obj : error LNK2001: unresolved external symbol _gethostbyname(at)4
> socket.obj : error LNK2001: unresolved external symbol _inet_addr(at)4
> socket.obj : error LNK2001: unresolved external symbol _ntohl(at)4
> socket.obj : error LNK2001: unresolved external symbol _ntohs(at)4
> socket.obj : error LNK2001: unresolved external symbol _send(at)16
> socket.obj : error LNK2001: unresolved external symbol _recv(at)16
> Debug/psqlodbc.dll : fatal error LNK1120: 14 unresolved externals
you should add wsock32.lib to list of libraries your driver will be
linked with. you should also add psqlodbc.rc and psqlodbc.def to your
project. please read readme.txt (it should be in the same directory with
ODBC driver sources)
I have built ODBC driver from CVS tree with Visual C++ 6.0 yesterday
successfully and now Visio successfully reverse-engineers our database
scheme (with foreign keys). That's really cool.
/fjoe
From | Date | Subject | |
---|---|---|---|
Next Message | Max Khon | 2001-01-23 09:12:34 | Re: Re: more odbc patches |
Previous Message | Thomas Lockhart | 2001-01-23 06:07:39 | Re: Newbe hacker, interface question on includes... |
From | Date | Subject | |
---|---|---|---|
Next Message | Max Khon | 2001-01-23 09:12:34 | Re: Re: more odbc patches |
Previous Message | Dave Page | 2001-01-23 08:20:39 | RE: Driver updates for 7.1 |