summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in6
1 files changed, 5 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index f8a3fa639..9497ce6bc 100644
--- a/configure.in
+++ b/configure.in
@@ -627,6 +627,8 @@ AC_DEFUN(AC_CHECK_SANITIZER_FLAG,
AC_MSG_CHECKING([whether $CC supports -fsanitize=$1])
OLD_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fsanitize=$1"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=$1"
AC_COMPILE_IFELSE(
[AC_LANG_SOURCE([int foo;])],
[
@@ -645,12 +647,14 @@ AC_DEFUN(AC_CHECK_SANITIZER_FLAG,
[
AC_MSG_RESULT([no])
CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
]
)
],
[
AC_MSG_RESULT([guessing no])
CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
]
)
]
@@ -677,7 +681,7 @@ if test "$enable_sanitize" != "no" ; then
AC_CHECK_SANITIZER_FLAG(nonnull-attribute)
AC_CHECK_SANITIZER_FLAG(returns-nonnull-attribute)
AC_CHECK_SANITIZER_FLAG(bool)
- AC_CHECK_SANITIZER_FLAG(enum, sanitize-undefined-trap-on-error)
+ AC_CHECK_SANITIZER_FLAG(enum)
AC_CHECK_SANITIZER_FLAG(vptr)
fi
fi