diff options
Diffstat (limited to 'libsanitizer/configure.ac')
-rw-r--r-- | libsanitizer/configure.ac | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libsanitizer/configure.ac b/libsanitizer/configure.ac index 72b13a10367..063b1d64c25 100644 --- a/libsanitizer/configure.ac +++ b/libsanitizer/configure.ac @@ -96,7 +96,7 @@ AM_CONDITIONAL(LSAN_SUPPORTED, [test "x$LSAN_SUPPORTED" = "xyes"]) AC_CHECK_FUNCS(clock_getres clock_gettime clock_settime) # Common libraries that we need to link against for all sanitizer libs. -link_sanitizer_common='-lpthread -ldl -lm' +link_sanitizer_common='-lpthread -lm' # At least for glibc, shm_open is in librt. But don't pull that # in if it still doesn't give us the function we want. This @@ -104,6 +104,10 @@ link_sanitizer_common='-lpthread -ldl -lm' AC_CHECK_LIB(rt, shm_open, [link_sanitizer_common="-lrt $link_sanitizer_common"]) +# Do a configure time check for -ldl +AC_CHECK_LIB(dl, dlsym, + [link_sanitizer_common="-ldl $link_sanitizer_common"]) + # Set up the set of additional libraries that we need to link against for libasan. link_libasan=$link_sanitizer_common AC_SUBST(link_libasan) |