Debian Codegraph @

autoconf/ast_cxx_check_std.m4

raw
1 # AST_CXX_CHECK_STD([standard], [force latest std?])
2 # Check if the C++ compiler supprts a specific standard.
3 # If the second argument is "yes", forse the compiler to
4 # use the latest standard it supports by keeping the last
5 # -std=gnu++=XX option that worked.
6 AC_DEFUN([AST_CXX_CHECK_STD],
7 [
8 PBX_CXX$1=0
9 if test "$2" != "yes" ; then
10 ast_cxx_check_std_save_CXX="${CXX}"
11 ast_cxx_check_std_save_CXXCPP="${CXXCPP}"
12 fi
13 AX_CXX_COMPILE_STDCXX($1, , optional)
14 if test "$HAVE_CXX$1" = "1";
15 then
16 PBX_CXX$1=1
17 fi
18 AC_SUBST(PBX_CXX$1)
19 if test "$2" != "yes" ; then
20 CXX="${ast_cxx_check_std_save_CXX}"
21 CXXCPP="${ast_cxx_check_std_save_CXXCPP}"
22 fi
23 ])