Hi Curan,

Look up select() in the MSVC++ help file. It should list the libraries 
that you should link to in order to get this function, I think it's 
something like winsock.lib and ws2_32.lib.

Cheers,
Bart

Curran Schiefelbein wrote:
> Hi,
> 
> I am trying to get a basic program up and running on WinXP. I have 
> compiled postgresql (8.2.1) and libpqxx (2.6.8 stable) from source using 
> MS Visual Studio 2005. My test program is linking libpqxx_staticD.lib 
> and has no trouble finding its dependencies (and yes I'm using /MDd).
> 
> However, there's an undefined symbol in libpqxx_staticD.lib:
> 
> libpqxx_staticD.lib(connection_base.obj) : error LNK2019: unresolved 
> external symbol [EMAIL PROTECTED] referenced in function 
> [EMAIL PROTECTED]@pqxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]
> 
> Looking at the source, I see a select call in the else block (lines 378-384:
> 
> #ifdef PQXX_HAVE_POLL
>        sel = poll(&pfd, 1, 0);
> #else
>        timeval nowait = { 0, 0 };
>        set_fdbit(fd, &errs);
>        sel = select(fd+1, 0, 0, &errs, &nowait);
> #endif
> 
> But config-internal-compiler.h correctly comments out the definition of 
> PQXX_HAVE_SYS_SELECT_H. So it should be using the select from winsock2, 
> correct?
> 
> (I'm not that familiar with the win32 libraries; unfortunately this must 
> be compiled on windows to integrate with a third-party device API.)
> 
> Any help you can give would be wonderful.
> 
> Curran
> _______________________________________________
> Libpqxx-general mailing list
> [email protected]
> http://gborg.postgresql.org/mailman/listinfo/libpqxx-general

_______________________________________________
Libpqxx-general mailing list
[email protected]
http://gborg.postgresql.org/mailman/listinfo/libpqxx-general

Reply via email to