* Brian Barrett wrote on Wed, Jan 11, 2006 at 05:28:55AM CET:
> On Jan 10, 2006, at 12:15 PM, Ralf Wildenhues wrote:
> > * Greg Watson wrote on Tue, Jan 10, 2006 at 05:58:35PM CET:
> >> Running configure from 1.0.2a3 on OSX 10.4.3:
> >>
> >> configure: WARNING: net/if.h: present but cannot be compiled
> >> configure: WARNING: net/if.h:     check for missing prerequisite
> >> headers?
> >
> > Yes.  The test is broken.  You need to
> >   #include <sys/socket.h>
> > first.  See
> >
> >   info Autoconf "Header Portability"
> > under `net/if.h' for a complete description.
> 
> But as I understand it, this isn't anything we can do anything about,  
> right?  I mean, other than report it to the AC developers?

Erm, no.  Quoting the complete description:
| `net/if.h'
|      On Darwin, this file requires that `sys/socket.h' be included
|      beforehand.  One should run:
| 
|           AC_CHECK_HEADERS([sys/socket.h])
|           AC_CHECK_HEADERS([net/if.h], [], [],
|           [#include <stdio.h>
|           #if STDC_HEADERS
|           # include <stdlib.h>
|           # include <stddef.h>
|           #else
|           # if HAVE_STDLIB_H
|           #  include <stdlib.h>
|           # endif
|           #endif
|           #if HAVE_SYS_SOCKET_H
|           # include <sys/socket.h>
|           #endif
|           ])

Do exactly as told (in both configure.ac/your macro, and also use the
header order in the code that uses net/if.h).  If the error persists,
_then_ there is reason to report an Autoconf bug.

Cheers,
Ralf

Reply via email to