From: Otto Moerbeek Date: Mon, 20 Jul 2020 07:56:15 +0000 (+0200) Subject: Fix compilation on OpenBSD/amd64 X-Git-Tag: dnsdist-1.5.0~8^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F9346%2Fhead;p=thirdparty%2Fpdns.git Fix compilation on OpenBSD/amd64 The readline lib on OpenBSD redefines __attribute__ to empty if __STRICT_ANSI__... --- diff --git a/pdns/dnsdist-console.cc b/pdns/dnsdist-console.cc index 9b3255db48..d016f880dd 100644 --- a/pdns/dnsdist-console.cc +++ b/pdns/dnsdist-console.cc @@ -25,6 +25,8 @@ #include #if defined (__OpenBSD__) || defined(__NetBSD__) +// If this is not undeffed, __attribute__ wil be redefined by /usr/include/readline/rlstdc.h +#undef __STRICT_ANSI__ #include #include #else diff --git a/pdns/dnsdist.cc b/pdns/dnsdist.cc index b7c3832b26..00526b167a 100644 --- a/pdns/dnsdist.cc +++ b/pdns/dnsdist.cc @@ -32,6 +32,8 @@ #include #if defined (__OpenBSD__) || defined(__NetBSD__) +// If this is not undeffed, __attribute__ wil be redefined by /usr/include/readline/rlstdc.h +#undef __STRICT_ANSI__ #include #else #include