Search Postgresql Archives

Re: linker

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You need to link with wsock32.lib.

//Magnus 

> -----Original Message-----
> From: pgsql-general-owner@xxxxxxxxxxxxxx 
> [mailto:pgsql-general-owner@xxxxxxxxxxxxxx] On Behalf Of srinivasa.n
> Sent: Thursday, May 04, 2006 2:33 PM
> To: pgsql-general@xxxxxxxxxxxxxx
> Subject: [GENERAL] linker
> 
> Hi I am new to postgre sql I am trying to execute the sample 
> c code which are connecting to postgre data base
> 
> It is postgre web site, I am not bale to compile that code it 
> is generating linker error 
> 
> Could any body tell how to set lib and dill which are 
> required to exec cute the following is the 
> 
> Error I am getting 
> 
>  
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _closesocket@4 referenced in function _connectDBStart
> 
> libpq.lib(fe-misc.obj) : error LNK2001: unresolved external 
> symbol _closesocket@4
> 
> libpq.lib(fe-protocol3.obj) : error LNK2001: unresolved 
> external symbol _closesocket@4
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _getsockname@12 referenced in function _PQconnectPoll
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _getsockopt@20 referenced in function _PQconnectPoll
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _WSAGetLastError@0 referenced in function 
> _PQconnectPoll
> 
> libpq.lib(getaddrinfo.obj) : error LNK2001: unresolved 
> external symbol _WSAGetLastError@0
> 
> libpq.lib(fe-misc.obj) : error LNK2001: unresolved external 
> symbol _WSAGetLastError@0
> 
> libpq.lib(thread.obj) : error LNK2001: unresolved external 
> symbol _WSAGetLastError@0
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _connect@12 referenced in function _PQconnectPoll
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _socket@12 referenced in function _PQconnectPoll
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _ioctlsocket@12 referenced in function 
> _connectMakeNonblocking
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _setsockopt@20 referenced in function _connectNoDelay
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _WSASetLastError@4 referenced in function 
> _makeEmptyPGconn
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _WSAStartup@8 referenced in function _makeEmptyPGconn
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _recv@16 referenced in function _PQrequestCancel
> 
> libpq.lib(fe-secure.obj) : error LNK2001: unresolved external 
> symbol _recv@16
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _send@16 referenced in function _PQrequestCancel
> 
> libpq.lib(fe-secure.obj) : error LNK2001: unresolved external 
> symbol _send@16
> 
> libpq.lib(fe-protocol2.obj) : error LNK2001: unresolved 
> external symbol _htonl@4
> 
> libpq.lib(fe-protocol3.obj) : error LNK2001: unresolved 
> external symbol _htonl@4
> 
> libpq.lib(inet_aton.obj) : error LNK2001: unresolved external 
> symbol _htonl@4
> 
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved 
> external symbol _htonl@4 referenced in function _PQrequestCancel
> 
> libpq.lib(ip.obj) : error LNK2001: unresolved external symbol _htonl@4
> 
> libpq.lib(getaddrinfo.obj) : error LNK2001: unresolved 
> external symbol _htonl@4
> 
> libpq.lib(fe-misc.obj) : error LNK2001: unresolved external 
> symbol _htonl@4
> 
> libpq.lib(getaddrinfo.obj) : error LNK2019: unresolved 
> external symbol _htons@4 referenced in function _pg_getaddrinfo
> 
> libpq.lib(fe-misc.obj) : error LNK2019: unresolved external 
> symbol _htons@4 referenced in function _pqGetc
> 
> libpq.lib(getaddrinfo.obj) : error LNK2019: unresolved 
> external symbol _ntohs@4 referenced in function _pg_getnameinfo
> 
> libpq.lib(fe-misc.obj) : error LNK2001: unresolved external 
> symbol _ntohs@4
> 
> libpq.lib(getaddrinfo.obj) : error LNK2019: unresolved 
> external symbol _inet_ntoa@4 referenced in function _pg_getnameinfo
> 
> libpq.lib(fe-misc.obj) : error LNK2019: unresolved external 
> symbol _ntohl@4 referenced in function _pqGetInt
> 
> libpq.lib(fe-misc.obj) : error LNK2019: unresolved external 
> symbol _select@20 referenced in function _pqSocketPoll
> 
> libpq.lib(thread.obj) : error LNK2019: unresolved external 
> symbol _gethostbyname@4 referenced in function _pqGethostbyname
> 
> Debug/a.exe : fatal error LNK1120: 19 unresolved externals
> 
>  
> 
> Advance thanks
> 
>  
> 
> Regards,
> 
>  
> 
> Srinivasa,
> 
>  
> 
>  
> 
>  
> 
> 


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux