On Tue, 03 May 2011 09:32:29 -0000, Andrew Dunstan <and...@dunslane.net> wrote:

On 05/03/2011 02:46 AM, Johann 'Myrkraverk' Oskarsson wrote:

When compiling PG with mingw-w64 the PGDLLEXPORT macro is blank.

Here is a patch that "fixes it for me."  If this is correct, I'd
appreciate it will be applied to 9.0.x as well as HEAD.

AFAICT it's not broken and doesn't need fixing. We don't define this for the 32 bit MinGW compiler, so why should it be necessary in the 64 bit case?

I am using a different build procedure for 64bit than 32bit, as adviced
by the mingw-w64 team.  The final step I use is:
  ${CC} -shared -o ${plugin} ${OBJS} ${BE_DLLLIBS} -L. -ljvm

I guess that is my "issue."  Without __declspec(dllexport) in the magic
macro Pg_magic_func() isn't exported properly because of that, for ex-
ample.

Now while I can only blame myself for using something different/un-
supported, I have to ask, why was I told to use gcc in the final
link step by the mingw-w64 team while you (postgres) use something
else (I presume dlltool)?


--
  Johann Oskarsson                http://www.2ndquadrant.com/    |[]
  PostgreSQL Development, 24x7 Support, Training and Services  --+--
                                                                 |
  Blog: http://my.opera.com/myrkraverk/blog/

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to