Peter Amstutz wrote:
> > (BTW: the getaddrinfo_wrapper function wasn't working at all on WIN32.
It
> > can't handle the case where "hints" is 0, and it doesn't look at
> "services."
> > Luckily, the windows SDK has a getaddrinfo function, so I removed all
that
> > WIN32 specific stuff and it worked fine. Same thing with freeaddrinfo
and
> > getnameinfo. It has a gai_strerror, too, but the documentation says it's
> not
> > threadsafe and to use WSAGetLastError instead, so I left that wrapper in
> > place. The only problem with these is compiling on windows2000 with
> MINGW -- 
> > the default MINGW headers only define them for WinXP or later. I found a
> > workaround for this, though, which I posted here
> > http://interreality.org/pipermail/vos-d/2006-November/002041.html )
>
> Hmm.  The wrapper was there because I've had problems with getaddrinfo
> not being available on Windows 2000.  Not as in not compiling, but
> missing such that even a binary install of VOS won't run due to a
> getaddrinfo missing DLL symbol error.  It's very annoying.
>

Yeah, that's because the getaddrinfo functions don't exist in the
windows2000 binary api. What microsoft did was implement their own wrappers
in wspiapi.h that get used if you compile with _WIN32_WINNT set for windows
2000. MinGW, however, doesn't include any wrappers so it just doesn't define
anything if you're compiling for windows2000. (BTW, if you want to ensure
windows 2000 support, you should probably make sure WINVER and _WIN32_WINNT
are set correctly, or else you may be getting some other weird WinXP stuff).
You can try my MinGW modification above, but it requires that you have the
MS SDK installed. It should be ok for GPL purposes, as it should fall under
the "normally distributed with the compiler" exception* (even though it's
distributed with a different compiler than the one you're using ;) ). You
would probably have to make the modified MinGW header available for full
compliance, though.

Or just get your own wrapper working :)

-Ken

*I like how the GPL assumes that the compiler is a "major component" of the
operating system. This is so not the case on windows, so the interpretation
needs a little flexibility.


_______________________________________________
vos-d mailing list
[email protected]
http://www.interreality.org/cgi-bin/mailman/listinfo/vos-d

Reply via email to