When trying to build pdns-3.4.8, I encountered a problem during boost version detection, which looked something like this when ./configure (with all options I wanted, run)
... pdns: checking for Boost headers version >= 1.35.0... /usr/include pdns: checking for Boost's header version... pdns: configure: error: invalid value: boost_major_version='' ... I think I tracked down the cause of this to m4/boost.m4 See this section of code in m4/boost.m4: ... ---- cut here ---- dnl # 1 "conftest.cc" dnl # 1 "<built-in>" dnl # 1 "<command-line>" dnl # 1 "conftest.cc" dnl # 1 "/opt/local/include/boost/version.hpp" 1 3 dnl # 2 "conftest.cc" 2 dnl boost-lib-version = dnl # 2 "conftest.cc" 3 dnl "1_56" dnl dnl So get rid of the # lines, and glue the remaining ones together. (eval "$ac_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD | grep -v '#' | tr -d '\r' | tr -s '\n' ' ' | $SED -n -e "$1" >conftest.i 2>&1], [$3], [$4]) rm -rf conftest* AC_LANG_POP([C++])dnl ])# _BOOST_SED_CPP # BOOST_REQUIRE([VERSION], [ACTION-IF-NOT-FOUND]) ---- cut here ---- ... Notice the line: "rm -rf conftest*" This removes not only "conftest.$ac_ext" but also removes "conftest.i" But we still need "conftest.i" later in the script in this section: ... ---- cut here ---- AC_CACHE_CHECK([for Boost's header version], [boost_cv_lib_version], [m4_pattern_allow([^BOOST_LIB_VERSION$])dnl _BOOST_SED_CPP([[/^boost-lib-version = /{s///;s/[\" ]//g;p;q;}]], [#include <boost/version.hpp> boost-lib-version = BOOST_LIB_VERSION], [boost_cv_lib_version=`cat conftest.i`])]) ---- cut here ---- ... Without "conftest.i" present, the detected version ends up being '' (empty) A suggested change? ---- cut here ---- --- pdns-3.4.8-orig/m4/boost.m4 2016-02-02 20:31:19.000000000 +0000 +++ pdns-3.4.8/m4/boost.m4 2016-02-19 06:11:51.832492331 +0000 @@ -94,12 +94,10 @@ $SED -n -e "$1" >conftest.i 2>&1], [$3], [$4]) -rm -rf conftest* +rm -rf conftest.$ac_ext AC_LANG_POP([C++])dnl ])# _BOOST_SED_CPP - - # BOOST_REQUIRE([VERSION], [ACTION-IF-NOT-FOUND]) # ----------------------------------------------- # Look for Boost. If version is given, it must either be a literal of the form @@ -229,6 +227,7 @@ [#include <boost/version.hpp> boost-lib-version = BOOST_LIB_VERSION], [boost_cv_lib_version=`cat conftest.i`])]) + rm -rf conftest.* # e.g. "134" for 1_34_1 or "135" for 1_35 boost_major_version=`echo "$boost_cv_lib_version" | sed 's/_//;s/_.*//'` case $boost_major_version in #( ---- cut here ---- Feedback welcome. Hope this helps, -ME
_______________________________________________ Pdns-dev mailing list Pdns-dev@mailman.powerdns.com http://mailman.powerdns.com/mailman/listinfo/pdns-dev