summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-07-16 12:08:56 +0200
committerStefan Metzmacher <metze@samba.org>2009-07-16 12:08:56 +0200
commit98aba452fbddb9f05250a7e4dc8979990759f671 (patch)
tree0e045b072690f05fb711d7952119b6fb1fda039b
parent39684d2cbe1c8c69dc9ca5c6e05861e24091bb83 (diff)
downloadsamba-98aba452fbddb9f05250a7e4dc8979990759f671.tar.gz
samba-98aba452fbddb9f05250a7e4dc8979990759f671.tar.bz2
samba-98aba452fbddb9f05250a7e4dc8979990759f671.zip
s4:heimdal_build: try to fix the build on systems without ifaddrs.h
metze
-rw-r--r--source4/heimdal_build/ifaddrs.hin1
-rw-r--r--source4/heimdal_build/internal.m49
2 files changed, 10 insertions, 0 deletions
diff --git a/source4/heimdal_build/ifaddrs.hin b/source4/heimdal_build/ifaddrs.hin
new file mode 100644
index 0000000000..a50b03335b
--- /dev/null
+++ b/source4/heimdal_build/ifaddrs.hin
@@ -0,0 +1 @@
+#include "system/network.h"
diff --git a/source4/heimdal_build/internal.m4 b/source4/heimdal_build/internal.m4
index 5c8d78e56d..e7e7ae1842 100644
--- a/source4/heimdal_build/internal.m4
+++ b/source4/heimdal_build/internal.m4
@@ -46,6 +46,15 @@ dnl declarations will be correct). Phew!
AC_CHECK_HEADERS([err.h], [],
[ cp heimdal/lib/roken/err.hin heimdal_build/err.h ])
+dnl Not all systems have ifaddrs.h, so we provide a replacement. Heimdal
+dnl unconditionally #includes <ifaddrs.h>, so we need to create an ifaddrs.h,
+dnl but we can't just have a static one because we don't want to use
+dnl it on systems that have a real ifaddrs.h. If the system has a real
+dnl ifaddrs.h. We don't use heimdal's lib/roken/ifaddrs.hin because
+dnl our libreplace would conflict with it.
+AC_CHECK_HEADERS([ifaddrs.h], [],
+ [ cp heimdal_build/ifaddrs.hin heimdal_build/ifaddrs.h ])
+
AC_CHECK_HEADERS([ \
crypt.h \
curses.h \