From: Reini Urban <rurban@x-ray.at>
To: Maciej Grygorcewicz <maciekgrygorcewicz@gmail.com>
Cc: pgsql-cygwin@postgresql.org
Subject: Re: Problem with compiling C function
Date: Wed, 9 Jan 2008 19:41:13 -0500
Message-ID: <6910a60801091641r3f28af97i7a474ed706d4b06b@mail.gmail.com> (raw)
In-Reply-To: <e57e8a580801090923s692944a0q2d59c063b48cbacc@mail.gmail.com>
References: <e57e8a580801090917p15147473re133613db9958125@mail.gmail.com>
<e57e8a580801090923s692944a0q2d59c063b48cbacc@mail.gmail.com>
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.
> I tried to build almost the same code but in C++ style DLL.
> DLL file was created succesfully , but on the other hand postgreSQL couldn't
> find exported function...
> DLL was in non-undernstadable format for postgresql.
for c++ you have to wrap the postgresql functions into extern "C".
--
Reini Urban
http://phpwiki.org/http://murbreak.at/http://spacemovie.mur.at/http://helsinki.at/
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-cygwin@postgresql.org
Cc: rurban@x-ray.at, maciekgrygorcewicz@gmail.com
Subject: Re: Problem with compiling C function
In-Reply-To: <6910a60801091641r3f28af97i7a474ed706d4b06b@mail.gmail.com>
References: <e57e8a580801090917p15147473re133613db9958125@mail.gmail.com> <e57e8a580801090923s692944a0q2d59c063b48cbacc@mail.gmail.com> <6910a60801091641r3f28af97i7a474ed706d4b06b@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox