mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-10-22 07:21:21 +00:00
build system: test for -std=gnu++14/-std=gnu++11 as well
For clang using gnu++14/11 results in a dummy type being defined for __float128. That, in turn, allows compilation with unmodified libstdc++ and clang.
This commit is contained in:
parent
6af604ae2d
commit
fef12cc386
18
ac/c++11.m4
18
ac/c++11.m4
@ -4,17 +4,17 @@ AC_DEFUN([AX_CXX_STD_CXX_FLAG],[
|
||||
AC_LANG_PUSH(C++)
|
||||
CXXFLAGS_SAVED="$CXXFLAGS"
|
||||
|
||||
CXXFLAGS="$CXXFLAGS_SAVED -std=c++14"
|
||||
AC_TRY_COMPILE([], [true;], [ax_cv_std_cxx_flag="-std=c++14"], [ax_cv_std_cxx_flag="undecided"])
|
||||
for flag in gnu++14 c++14 gnu++11 c++11 c++0x; do
|
||||
CXXFLAGS="$CXXFLAGS_SAVED -std=$flag"
|
||||
AC_TRY_COMPILE([], [true;], [ax_cv_std_cxx_flag="-std=$flag"], [ax_cv_std_cxx_flag="undecided"])
|
||||
|
||||
if test x"$ax_cv_std_cxx_flag" != xundecided ; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if test x"$ax_cv_std_cxx_flag" = xundecided ; then
|
||||
CXXFLAGS="$CXXFLAGS_SAVED -std=c++11"
|
||||
AC_TRY_COMPILE([], [true;], [ax_cv_std_cxx_flag="-std=c++11"], [ax_cv_std_cxx_flag="undecided"])
|
||||
fi
|
||||
|
||||
if test x"$ax_cv_std_cxx_flag" = xundecided ; then
|
||||
CXXFLAGS="$CXXFLAGS_SAVED -std=c++0x"
|
||||
AC_TRY_COMPILE([], [true;], [ax_cv_std_cxx_flag="-std=c++0x"], [ax_cv_std_cxx_flag="no"])
|
||||
ax_cv_std_cxx_flag="no"
|
||||
fi
|
||||
|
||||
AC_LANG_POP
|
||||
|
Loading…
Reference in New Issue
Block a user