| From: | "Chuck McDevitt" <cmcdevitt(at)greenplum(dot)com> | 
|---|---|
| To: | "Andrew Dunstan" <andrew(at)dunslane(dot)net> | 
| Cc: | "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "PostgreSQL-development" <pgsql-hackers(at)postgresql(dot)org> | 
| Subject: | Re: Windows + IP6 progress | 
| Date: | 2005-08-18 23:53:15 | 
| Message-ID: | BB05A27C22288540A3A3E8F3749B45AB01500A21@MI8NYCMAIL06.Mi8.com | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
I think it's because it's __stdcall, and the name gets mangled to
include the number of parameters. 
> -----Original Message-----
> From: Andrew Dunstan [mailto:andrew(at)dunslane(dot)net]
> Sent: Thursday, August 18, 2005 4:44 PM
> To: Chuck McDevitt
> Cc: Tom Lane; PostgreSQL-development
> Subject: Re: [HACKERS] Windows + IP6 progress
> 
> 
> The mingw header has pretty much this with WINSOCK_API_LINKAGE IN OUT
> and FAR dissolved away.
> 
> The  standard test complains about it being an unresolved reference
when
> it is declared as "char getaddrinfo (); ". If we remove that and
instead
> include the header the test passes. I have no idea why that should be
> the case for this function and not for others.
> 
> cheers
> 
> andrew
> 
> 
> Chuck McDevitt wrote:
> 
> >The definition in WS2tcpip.h
> >
> >WINSOCK_API_LINKAGE
> >int
> >WSAAPI
> >getaddrinfo(
> >    IN const char FAR * nodename,
> >    IN const char FAR * servname,
> >    IN const struct addrinfo FAR * hints,
> >    OUT struct addrinfo FAR * FAR * res
> >    );
> >
> >
> >(IN, FAR, and OUT are #defined to empty string).
> >
> >WINSOCK_API_LINKAGE is __declspec(dllimport)
> >WSAAPI is __stdcall
> >
> >So, nothing magic with #defines of the name getaddrinfo.
> >
> >
> >
> >
> >>-----Original Message-----
> >>From: pgsql-hackers-owner(at)postgresql(dot)org [mailto:pgsql-hackers-
> >>owner(at)postgresql(dot)org] On Behalf Of Tom Lane
> >>Sent: Thursday, August 18, 2005 3:47 PM
> >>To: Andrew Dunstan
> >>Cc: PostgreSQL-development
> >>Subject: Re: [HACKERS] Windows + IP6 progress
> >>
> >>Andrew Dunstan <andrew(at)dunslane(dot)net> writes:
> >>
> >>
> >>>. what do we do about the getaddrinfo test? I'm almost inclined not
> >>>
> >>>
> >to
> >
> >
> >>>do it on windows, and assume that if we have ws2_32.dll we have it.
> >>>
> >>>
> >>There's something mighty fishy about that.  AC_REPLACE_FUNCS works
on
> >>Windows for the other cases it's used for (no?), so what's different
> >>about getaddrinfo?  Perhaps Microsoft has #define'd that name as
> >>something else, or some equally ugly crock?  It'd be useful to look
> >>
> >>
> >into
> >
> >
> >>their header files and see exactly how and where getaddrinfo is
> >>declared.
> >>
> >>			regards, tom lane
> >>
> >>---------------------------(end of
> >>
> >>
> >broadcast)---------------------------
> >
> >
> >>TIP 3: Have you checked our extensive FAQ?
> >>
> >>               http://www.postgresql.org/docs/faq
> >>
> >>
> >
> >
> >
> >
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andrew Dunstan | 2005-08-19 00:04:12 | Re: Windows + IP6 progress | 
| Previous Message | Andrew Dunstan | 2005-08-18 23:44:10 | Re: Windows + IP6 progress |