[MPlayer-dev-eng] [PATCH] configure: fix ws2tcpip.h header check bug
Diego Biurrun
diego at biurrun.de
Thu Oct 27 01:34:07 CEST 2011
On Thu, Oct 27, 2011 at 12:50:27AM +0200, Reimar Döffinger wrote:
> On 26 Oct 2011, at 22:49, Diego Biurrun <diego at biurrun.de> wrote:
> > On Wed, Oct 26, 2011 at 07:48:45PM +0200, Ingo Brückl wrote:
> >> Diego Biurrun wrote on Wed, 26 Oct 2011 19:08:40 +0200:
> >>
> >>>>> I have 1.7.x and AF_INET6 is also in /usr/include/cygwin/socket.h,
> >>>>
> >>>> Fine, but that's not the point.
> >>
> >>> The point is that you need to develop for current Cygwin releases, not
> >>> for the legacy ones.
> >>
> >> No, that isn't the point either.
> >>
> >> The point is that we currently check winsock2 headers even if configure has
> >> determined that we don't have winsock2 on the machine. Later in the build
> >> process we only include winsock2 headers if we really have winsock2.
> >>
> >> For that very reason there are #if HAVE_WINSOCK2_H conditions in various
> >> configure checks. Only for the headers, such a check is missing.
> >
> > Assuming that the situation you describe is a problem, your patch improves
> > nothing. You still check non-winsock2 headers first even if winsock2 is
> > available. In case those checks fail, we will 99% likely have winsock2
> > available, but you add some code to make sure that this is indeed the
> > case.
> >
> > What you need to describe is a scenario where current configure produces
> > wrong results, running an extra check or two is no big deal.
> >
> >> it would be nice if we could support more than just the very recent
> >> release of whatever.
> >
> > Supporting old Cygwin releases is not worth maintaining hacks.
>
> Not saying that it's worth it, but you can't really call it a hack.
> Checking whether a definition is available in ws2tcpip.h when we know
> that header will never be used is quite nonsensical.
We only fall through to that case if the first check fails, which with
99% likelihood is in a non-POSIX environment, i.e. Windows.
Anyway, this is a non-issue that is not worth extra code until a real
problem is presented.
Diego
More information about the MPlayer-dev-eng
mailing list