]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Fix building BIND on DragonFly BSD (on both older an newer versions)
authorArtem Boldariev <artem@boldariev.com>
Mon, 16 Jan 2023 16:31:08 +0000 (18:31 +0200)
committerOndřej Surý <ondrej@isc.org>
Tue, 5 Sep 2023 08:33:51 +0000 (10:33 +0200)
This commit ensures that BIND and supplementary tools still can be
built on newer versions of DragonFly BSD. It used to be the case, but
somewhere between versions 6.2 and 6.4 the OS developers rearranged
headers and moved some function definitions around.

Before that the fact that it worked was more like a coincidence, this
time we, at least, looked at the related man pages included with the
OS.

No in depth testing has been done on this OS as we do not really
support this platform - so it is more like a goodwill act. We can,
however, use this platform for testing purposes, too. Also, we know
that the OS users do use BIND, as it is included in its ports
directory.

Building with './configure' and './configure --without-jemalloc' have
been fixed and are known to work at the time the commit is made.

(cherry picked from commit 942569a1bb104002215286dae5fed98d783519ad)

lib/isc/mem.c

index d9018f6dbeb78d84e47c437db4cec8a1358a366c..2abb91c7a239155e7cf41021083cbec0564aeb52 100644 (file)
 /* On DragonFly BSD the header does not provide jemalloc API */
 #if defined(HAVE_MALLOC_NP_H) && !defined(__DragonFly__)
 #include <malloc_np.h>
+#define JEMALLOC_API_SUPPORTED 1
 #elif defined(HAVE_JEMALLOC)
 #include <jemalloc/jemalloc.h>
+#define JEMALLOC_API_SUPPORTED 1
 
 #if JEMALLOC_VERSION_MAJOR < 4
 #define sdallocx(ptr, size, flags) dallocx(ptr, flags)