From: Francis Dupont Date: Wed, 2 Jan 2019 14:33:59 +0000 (+0100) Subject: [380-unexpected-boost-include-capture] Added a protection against capture from extra... X-Git-Tag: 161-move-hooks-subdirectory-under-kea-own-directory_base~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d63b68b35559fb882a86e819663ed37b7e329a37;p=thirdparty%2Fkea.git [380-unexpected-boost-include-capture] Added a protection against capture from extra boost in include path --- diff --git a/m4macros/ax_boost_for_kea.m4 b/m4macros/ax_boost_for_kea.m4 index 59f462a560..0d172cb238 100644 --- a/m4macros/ax_boost_for_kea.m4 +++ b/m4macros/ax_boost_for_kea.m4 @@ -79,6 +79,14 @@ AC_CHECK_HEADERS([boost/shared_ptr.hpp boost/foreach.hpp boost/interprocess/sync AC_CHECK_HEADERS(boost/asio/coroutine.hpp,,AC_MSG_RESULT(not found, using built-in header.)) +# Verify that the path does not capture standard headers. +AC_TRY_COMPILE([ +#include +#ifdef BOOST_RE_REGEX_H +#error "boost/regex.h" +#endif],,, +[AC_MSG_ERROR([${boost_include_path}/regex.h is used in place of /usr/include/regex.h: please remove the extra boost at the end of the include path.])]) + # clang can cause false positives with -Werror without -Qunused-arguments. # it can be triggered if used with ccache. AC_CHECK_DECL([__clang__], [CLANG_CXXFLAGS="-Qunused-arguments"], [])