[FFmpeg-devel] [PATCH] Enable proper IPv6 functions on windows

Martin Storsjö martin
Fri Jan 15 22:23:47 CET 2010

On Fri, 15 Jan 2010, Ramiro Polla wrote:

> > so instead of just killing win9x, now you've killed win2k too?
> >
> > cant we have both?
> >
> > if WINNT=0x0501 then use xp stuff
> > else if WINNT=0x0500 use win9x/2k stuff
> >
> > do the win2k users outnumber the ipv6 users?
> From what I understand win2k will still work with --disable-network
> (like in the documentation).
> Martin, would it be possible and not too ugly to #ifdef out the code
> that needs winxp so the current network support would still be
> possible with some configure option?

Well, as the next step, I intended to send a patch adding

    check_func_headers ws2tcpip.h getaddrinfo $network_extralibs

to the winsock part of the network section in configure. The point being 
that if _WIN32_WINNT=0x0501 is set, the check will succeed and we will 
link to the >= winxp getaddrinfo function, otherwise we'll set 
HAVE_GETADDRINFO to 0 and use our fallback wrapper instead.

So if we want pre-XP compatibility configurable, we would only add 
_WIN32_WINNT=0x0501 in that particular case - as in your initial win9x 
patch. So, your initial approach, but perhaps renaming the mingw32-win9x 
target os name into mingw32-win2k or something similar (mingw32-prexp?).

In my opinion, setting the platform define depending on what OS version 
we're targeting and letting the normal configure check find out what's 
supported and what's not is cleaner than adding even more platform 
specific ifdefs to the network code.

// Martin

More information about the ffmpeg-devel mailing list