Make OpenBSD compile again
authorTilghman Lesher <tilghman@meg.abyt.es>
Thu, 19 Jun 2008 20:25:37 +0000 (20:25 +0000)
committerTilghman Lesher <tilghman@meg.abyt.es>
Thu, 19 Jun 2008 20:25:37 +0000 (20:25 +0000)
(reported by mvanbaak via IRC -dev)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@124102 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/netsock.c

index 0ffb5a5..2bdf9cc 100644 (file)
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
+#if defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD__) || defined(__Darwin__)
+#include <net/if_dl.h>
+#endif
+
 #if defined (SOLARIS)
 #include <sys/sockio.h>
 #if defined (SOLARIS)
 #include <sys/sockio.h>
+#elif defined(HAVE_GETIFADDRS)
+#include <ifaddrs.h>
 #endif
 
 #include "asterisk/netsock.h"
 #endif
 
 #include "asterisk/netsock.h"