Since
isl-0.22.1-359-g8b9f94f262 (build extract_interface
using build compiler, Thu May 21 14:55:46 2020 +0200),
the default C++ compiler is overridden by the build C++ compiler
inside interface. This was meant to ensure that the clang
configure checks are performed using the right compiler,
but those checking for libraries were being performed by
the (host) C compiler instead. Use the (build) C++ compiler
there as well.
Signed-off-by: Sven Verdoolaege <sven.verdoolaege@gmail.com>
@@ -72,9 +72,10 @@ if test "x$found_header" != "xyes"; then
fi
CC="$SAVE_CC"
+AC_LANG_PUSH(C++)
+
SAVE_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CLANG_CXXFLAGS $CPPFLAGS"
-AC_LANG_PUSH(C++)
AC_CHECK_HEADER([clang/Basic/SourceLocation.h], [],
[AC_ERROR([clang header file not found])])
AC_EGREP_HEADER([getDefaultTargetTriple], [llvm/Support/Host.h], [],
@@ -216,7 +217,6 @@ AC_TRY_COMPILE([
AC_CHECK_HEADER([llvm/Option/Arg.h],
[AC_DEFINE([HAVE_LLVM_OPTION_ARG_H], [],
[Define if llvm/Option/Arg.h exists])])
-AC_LANG_POP
CPPFLAGS="$SAVE_CPPFLAGS"
SAVE_LDFLAGS="$LDFLAGS"
fi
LDFLAGS="$SAVE_LDFLAGS"
+
+AC_LANG_POP
])