[Pdns-dev] Compiling pdns 3.1-rc1 on NetBSD 6.0 BETA

Christof Meerwald cmeerw at cmeerw.org
Sun Apr 1 15:10:38 CEST 2012


just tried to compile pdns-3.1-rc1.20120327.2539 on NetBSD 6.0 beta
and encountered the following issues:

- several Makefile.am in modules don't include $(BOOST_CPPFLAGS) in
  AM_CPPFLAGS (when they should): geobackend, gsqlite3backend,
  gsqlitebackend and mongodbbackend

- net/ethernet.h isn't available on NetBSD - including net/if.h and
  net/if_ether.h instead seems to work (not sure if this would also
  apply to other BSDs)

diff -ur pdns-3.1-rc1.20120327.2539.orig/pdns/dnspcap.hh pdns-3.1-rc1.20120327.2539/pdns/dnspcap.hh
--- pdns-3.1-rc1.20120327.2539.orig/pdns/dnspcap.hh	2012-03-27 21:52:24.000000000 +0100
+++ pdns-3.1-rc1.20120327.2539/pdns/dnspcap.hh	2012-04-01 13:45:53.000000000 +0100
@@ -10,7 +10,12 @@
 #include <netinet/in_systm.h>
 #include <netinet/ip.h>
 #include <netinet/udp.h>
+#if defined(__NetBSD__)
+#include <net/if.h>
+#include <net/if_ether.h>
 #include <net/ethernet.h>
 #include <vector>
 #include <boost/format.hpp>
 #include "namespaces.hh"

- sys/endian.h needs to be included instead of endian.h on NetBSD
  (similar to FreeBSD and OpenBSD) in ext/polarssl-1.1./library/net.c:

diff -ur pdns-3.1-rc1.20120327.2539.orig/pdns/ext/polarssl-1.1.1/library/net.c pdns-3.1-rc1.20120327.2539/pdns/ext/polarssl-1.1.1/library/net.c
--- pdns-3.1-rc1.20120327.2539.orig/pdns/ext/polarssl-1.1.1/library/net.c	2012-03-27 21:55:08.000000000 +0100
+++ pdns-3.1-rc1.20120327.2539/pdns/ext/polarssl-1.1.1/library/net.c	2012-04-01 13:39:56.000000000 +0100
@@ -59,7 +59,7 @@
 #include <netdb.h>
 #include <errno.h>

-#if defined(__FreeBSD__) || defined(__OpenBSD__)
+#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
 #include <sys/endian.h>
 #elif defined(__APPLE__)
 #include <machine/endian.h>



http://cmeerw.org                              sip:cmeerw at cmeerw.org
mailto:cmeerw at cmeerw.org                   xmpp:cmeerw at cmeerw.org

More information about the Pdns-dev mailing list