Skip site navigation (1) Skip section navigation (2)

Re :Problem with Compiling C function

From: "Maciej Grygorcewicz" <maciekgrygorcewicz(at)gmail(dot)com>
To: pgsql-cygwin(at)postgresql(dot)org
Subject: Re :Problem with Compiling C function
Date: 2008-01-14 22:26:21
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-cygwin
2008/1/9, Maciej Grygorcewicz :
>> But linker threw such errors:
> >"
>>  Unresolved External: _pgwin32_fopen referended from .... // and so on
>  >Unresolved External: _pg_sprintfl referended from .... // and so on "
>> Why???? I have included postgres.h , and all other required files .

>-lpgport is needed.

Thanks for the response. But I have few questions
Is this a compiler / linker switch . Can I turn it on on Builder . or have I
to use gcc or g++??

> I tried to build almost the same code but in C++ style DLL.
> DLL file was created succesfully , but on the other hand postgreSQL
> find exported function...
> DLL was in non-undernstadable format for postgresql.

>for c++ you have to wrap the postgresql functions into extern "C".
Yes , I am wrapping exported functions in extern "C" . But it doesn't work.
Maybe I have to wrapp all functions , but this is  never ending work - I
have in project many files from Jpeglib library...

Maciej Grygorcewicz
maciekgrygorcewicz(at)gmail(dot)com ,
GG 1638280


pgsql-cygwin by date

Next:From: Reini UrbanDate: 2008-01-15 00:18:16
Subject: Re: Re :Problem with Compiling C function
Previous:From: Reini UrbanDate: 2008-01-10 00:41:13
Subject: Re: Problem with compiling C function

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group