Re: compile a program witn libpq64 (error LIBCMT.Lib...)

From: Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>
To: elekis <elekis(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: compile a program witn libpq64 (error LIBCMT.Lib...)
Date: 2010-03-18 14:16:19
Message-ID: 8cf965d31003180716h7a522d7gfe2c347b35f0c738@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Try to use libpqdll.lib instead of libpq.lib.

--
Ashesh Vashi
EnterpriseDB INDIA: Enterprise Postgres Company<http://www.enterprisedb.com>

On Thu, Mar 18, 2010 at 7:30 PM, elekis <elekis(at)gmail(dot)com> wrote:

> hi all,
>
>
> I try to create a dll that use postgres
>
> in 32 bit, there is no problem, but in 64 , I have errors
>
>
> cl /W3 /LDd runtime\rcqpgsql.obj runtime\pgsql_function_utility.obj
> runtime\rc
> qsql.obj C:\yafl\CT\bignum.obj C:\yafl\CT\CT_convert.obj runtime\error.obj
> runti
> me\profiler.obj runtime\rcqstruct.obj runtime\utils.obj -DPROFILER_MODE
> -D_CRT_S
> ECURE_NO_DEPRECATE -Zi "c:\Program Files\PostgreSQL\libpq64\lib\libpq.lib"
> -DL_
> RCQ_DLL
> Microsoft (R) C/C++ Optimizing Compiler Version 15.00.21022.08 for x64
> Copyright (C) Microsoft Corporation. All rights reserved.
>
> Microsoft (R) Incremental Linker Version 9.00.21022.08
> Copyright (C) Microsoft Corporation. All rights reserved.
>
> /out:rcqpgsql.dll
> /dll
> /implib:rcqpgsql.lib
> /debug
> runtime\rcqpgsql.obj
> runtime\pgsql_function_utility.obj
> runtime\rcqsql.obj
> C:\yafl\CT\bignum.obj
> C:\yafl\CT\CT_convert.obj
> runtime\error.obj
> runtime\profiler.obj
> runtime\rcqstruct.obj
> runtime\utils.obj
> "c:\Program Files\PostgreSQL\libpq64\lib\libpq.lib"
> LIBCMT.lib(dosmap.obj) : error LNK2005: _dosmaperr already defined in
> libpq.lib(
> win32error.obj)
> MSVCRT.lib(MSVCR90.dll) : error LNK2005: _time64 already defined in
> LIBCMT.lib(t
> ime64.obj)
>
>
> and later
>
> Creating library rcqpgsql.lib and object rcqpgsql.exp
> LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other
> libs; us
> e /NODEFAULTLIB:library
> libpq.lib(thread.obj) : error LNK2001: unresolved external symbol
> __imp_WSAGetLa
> stError
> libpq.lib(fe-connect.obj) : error LNK2019: unresolved external symbol
> __imp_WSAG
> etLastError referenced in function connectNoDelay
> libpq.lib(fe-secure.obj) : error LNK2001: unresolved external symbol
> __imp_WSAGe
> tLastError
> libpq.lib(fe-misc.obj) : error LNK2001: unresolved external symbol
> __imp_WSAGetL
>
>
>
>
> how to do to compile (and link with libpq64).
>
> thanks
>
>
> a++
>
>
>
>
>
> --
> http://twoji.deviantart.com/
> http://www.flickr.com/elekis
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Vick Khera 2010-03-18 14:37:57 Re: tables getting bloated
Previous Message elekis 2010-03-18 14:00:40 compile a program witn libpq64 (error LIBCMT.Lib...)