Re: pgevent warnings on mingw - Mailing list pgsql-hackers

From Hiroshi Saito
Subject Re: pgevent warnings on mingw
Date
Msg-id 7025F44AA6D4480DA49FBE931EEAF1E3@HIRO57887DE653
Whole thread Raw
In response to pgevent warnings on mingw  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
Hi.

I am checking that consider sufficient test as Marko-san and it is satisfactory.
However, That there is a portion which does not suit the solution of MSVC
also understands. Therefore, How is this proposal?

1. )remove pgevent.def
It is always generated.

2.) improvement of the Makefile and Solution.pm

What do you think?

Regards,
Hiroshi Saito

----- Original Message -----
From: "Marko Kreen" <markokr@gmail.com>

> On 1/31/09, Marko Kreen <markokr@gmail.com> wrote:
>> On 1/31/09, Magnus Hagander <magnus@hagander.net> wrote:
>>  > Hiroshi Saito wrote:
>>  >  > Hi.
>>  >  >
>>  >  >>> dllwrap --def pgevent.def -o pgevent.dll pgevent.o pgmsgevent.o
>>  >  >>> Warning: resolving _DllUnregisterServer by linking to
>>  >  >>> _DllUnregisterServer@0
>>  >  >>> Use --enable-stdcall-fixup to disable these warnings
>>  >  >>> Use --disable-stdcall-fixup to disable these fixups
>>  >  >>> Warning: resolving _DllRegisterServer by linking to _DllRegisterServer@0
>>  >  >>> Warning: resolving _DllUnregisterServer by linking to
>>  >  >>> _DllUnregisterServer@0
>>  >  >>> Use --enable-stdcall-fixup to disable these warnings
>>  >  >>> Use --disable-stdcall-fixup to disable these fixups
>>  >  >>> Warning: resolving _DllRegisterServer by linking to _DllRegisterServer@0
>>  >  >>>
>>  >  >>> What do we have to do to clean this stuff up?
>>  >  >
>>  >  > I was solved for Marko-san at the time of the work of pgbouncer, and
>>  >  > obtained the solution.
>>  >  > The patch is this.
>>  >
>>  >
>>  > This appears to be exactly what you are *not* supposed to do. Which is
>>  >  assign an ordinal. See:
>>  >  http://msdn.microsoft.com/en-us/library/8e705t74(VS.71).aspx
>>
>>
>> AFAICS by default the mingw assigns the ordinal anyway?
>>
>>  So whats your point?
>
> FWIW, I experimented with various approaches on DLL generation,
> and my theory is now that numeric slot is mandatory for export,
> name slot optional.  And what the above link above warns about
> is that if you manually assign a numeric slot, you may create gaps in
> slot table, thus resulting in larger image.  But this assumes
> you already have slots that are manually assigned, which should
> not happen with pgevent.dll.
>
> Does it sound sane?
>
> With pgbouncer I used "dlltool --export-all-symbols -A" to generate
> the .def file, thus the slots are actually assigned automatically
> by dlltool, so no gap problems should arise.  As Postgres does not
> generate .def automatically, thus Hiroshi simply posted the resulting
> .def file, which should not have gap problems.
>
> But such detailed .def avoids the confusing warnings from dllwrap.
> If you are worried about gap problems I suggest instead doing the
> same and making the .def file auto-generated.
>
> --
> marko
>
> ps.  I suggest also tagging the "g_module" as static.
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
Attachment

pgsql-hackers by date:

Previous
From: Grzegorz Jaskiewicz
Date:
Subject: Re: adding stuff to parser, question
Next
From: Andrew Dunstan
Date:
Subject: Re: adding stuff to parser, question