diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index 1f573d50f..d3405a135 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -14,13 +14,17 @@ AS_IF([test "$CC" = "gcc"], [ | |||
14 | HAVE_SPECTRE="yes" | 14 | HAVE_SPECTRE="yes" |
15 | $CC -mindirect-branch=thunk -c dummy.c || HAVE_SPECTRE="no" | 15 | $CC -mindirect-branch=thunk -c dummy.c || HAVE_SPECTRE="no" |
16 | rm -f dummy.o | 16 | rm -f dummy.o |
17 | EXTRA_CFLAGS+=" -mindirect-branch=thunk " | 17 | AS_IF([test "$HAVE_SPECTRE" = "yes"], [ |
18 | EXTRA_CFLAGS+=" -mindirect-branch=thunk " | ||
19 | ]) | ||
18 | ]) | 20 | ]) |
19 | AS_IF([test "$CC" = "clang"], [ | 21 | AS_IF([test "$CC" = "clang"], [ |
20 | HAVE_SPECTRE="yes" | 22 | HAVE_SPECTRE="yes" |
21 | $CC -mretpoline -c dummy.c || HAVE_SPECTRE="no" | 23 | $CC -mretpoline -c dummy.c || HAVE_SPECTRE="no" |
22 | rm -f dummy.o | 24 | rm -f dummy.o |
23 | EXTRA_CFLAGS+=" -mretpoline " | 25 | AS_IF([test "$HAVE_SPECTRE" = "yes"], [ |
26 | EXTRA_CFLAGS+=" -mretpoline " | ||
27 | ]) | ||
24 | ]) | 28 | ]) |
25 | AS_IF([test "$HAVE_SPECTRE" = "yes"], [ | 29 | AS_IF([test "$HAVE_SPECTRE" = "yes"], [ |
26 | AC_MSG_RESULT(yes) | 30 | AC_MSG_RESULT(yes) |