On Mon, 28 Apr 2008, Volker Lendecke wrote:

> On Mon, Apr 28, 2008 at 09:42:38AM -0400, Jason Mader wrote:
>> On Mon, 28 Apr 2008, Volker Lendecke wrote:
>>
>>> On Mon, Apr 28, 2008 at 08:41:58AM -0400, Jason Mader wrote:
>>>> "struct in_addr" is defined in
>>>>
>>>> (so is n_long)
>>>
>>> Can you try to add that header to the config program that
>>> failed?

>>
>> The conftest.c for needed:
>>
>> #include
>> #include

>
> Does this help for the problem you initially reported? Can
> you provide a patch?


Regressing to the way it was done in Samba 3.0.23:

AC_CHECK_HEADERS(netinet/ip.h,,,[[
#include
#if HAVE_SYS_SOCKET_H
#include
#endif
#include
#if HAVE_NETINET_IN_SYSTM_H
#include
#endif
]])

This line should change [lib/replace/libreplace.m4]:

AC_CHECK_HEADERS(netinet/ip.h netinet/tcp.h netinet/in_systm.h netinet/in_ip.h)

Here is my patch that worked on Irix:

--- lib/replace/libreplace.m4 2008-04-28 10:58:38.000000000 -0400
+++ lib/replace/libreplace.m4 2008-04-28 10:59:35.000000000 -0400
@@ -96,8 +96,18 @@
AC_CHECK_HEADERS(sys/syslog.h syslog.h)
AC_CHECK_HEADERS(sys/time.h time.h)
AC_CHECK_HEADERS(stdarg.h vararg.h)
-AC_CHECK_HEADERS(sys/socket.h netinet/in.h netdb.h arpa/inet.h)
-AC_CHECK_HEADERS(netinet/ip.h netinet/tcp.h netinet/in_systm.h netinet/in_ip.h)
+AC_CHECK_HEADERS(sys/socket.h netinet/in.h netinet/in_systm.h netdb.h arpa/inet.h)
+AC_CHECK_HEADERS(netinet/ip.h,,,[[
+#include
+#if HAVE_SYS_SOCKET_H
+#include
+#endif
+#include
+#if HAVE_NETINET_IN_SYSTM_H
+#include
+#endif
+]])
+AC_CHECK_HEADERS(netinet/tcp.h netinet/in_ip.h)
AC_CHECK_HEADERS(sys/sockio.h sys/un.h)
AC_CHECK_HEADERS(sys/mount.h mntent.h)