From: Roy Marples Date: Wed, 28 Aug 2019 12:55:02 +0000 (+0100) Subject: rbtree: Fix building from a DragonFlyBSD import X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=00c8d0e9848f9e1d3136e48a98aefd97eb90c694;p=thirdparty%2Fdhcpcd.git rbtree: Fix building from a DragonFlyBSD import --- diff --git a/compat/rb.c b/compat/rb.c index ed643e7b..e5fcaf6d 100644 --- a/compat/rb.c +++ b/compat/rb.c @@ -29,7 +29,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "common.h" +#include "config.h" #if !defined(_KERNEL) && !defined(_STANDALONE) #include diff --git a/compat/rbtree.h b/compat/rbtree.h index b0944a98..9d1b629f 100644 --- a/compat/rbtree.h +++ b/compat/rbtree.h @@ -32,7 +32,7 @@ #ifndef _SYS_RBTREE_H_ #define _SYS_RBTREE_H_ -#include "common.h" +#include "config.h" #if defined(_KERNEL) || defined(_STANDALONE) #include @@ -40,7 +40,11 @@ #include #include #endif +#ifdef HAVE_SYS_QUEUE_H +#include +#else #include "queue.h" +#endif #if !defined(__linux__) && !defined(__QNX__) && !defined(__sun) #include #else diff --git a/configure b/configure index b05b0241..a42e99db 100755 --- a/configure +++ b/configure @@ -1038,7 +1038,7 @@ EOF rm -f _rbtree.c _rbtree fi if [ "$RBTREE" = no ]; then - echo "CPPFLAGS+= -DRBTEST" >>$CONFIG_MK + echo "#define RBTEST" >>$CONFIG_H echo "COMPAT_SRCS+= compat/rb.c" >>$CONFIG_MK echo "#include \"compat/rbtree.h\"" >>$CONFIG_H else