summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-11-12 18:19:11 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-11-13 10:29:05 +0100
commitb957190edfc40e1fea99e4781c95aea0bd6fce5e (patch)
tree6debc60f64df67ec0e8cbe78fae16d1955ca8e40 /configure.ac
parent9b421ef6dee41c33d1a82fc8a8ec6983f13fe2a7 (diff)
Work around clang-cl -FIIntrin.h workaround
Change-Id: I71e0de9e13718c1a6cd11339aba740effa2e0476
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac14
1 files changed, 13 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 5737d68d3dac..58a6ad769a46 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3684,7 +3684,19 @@ if test "$_os" = "WINNT"; then
dnl localized
AC_MSG_CHECKING([the dependency generation prefix (cl.exe -showIncludes)])
echo "#include <stdlib.h>" > conftest.c
- SHOWINCLUDES_PREFIX=`$CC $CFLAGS -c -showIncludes conftest.c 2>/dev/null | \
+ dnl Filter out -FIIntrin.h when CC points at clang-cl.exe and needs to
+ dnl explicitly state that argument:
+ my_CC=
+ for i in $CC; do
+ case $i in
+ -FIIntrin.h)
+ ;;
+ *)
+ my_CC="$my_CC $i"
+ ;;
+ esac
+ done
+ SHOWINCLUDES_PREFIX=`$my_CC $CFLAGS -c -showIncludes conftest.c 2>/dev/null | \
grep 'stdlib\.h' | head -n1 | sed 's/ [[[:alpha:]]]:.*//'`
rm -f conftest.c conftest.obj
if test -z "$SHOWINCLUDES_PREFIX"; then