diff --git a/configure.ac b/configure.ac index e64e3798..88fbb586 100644 --- a/configure.ac +++ b/configure.ac @@ -103,6 +103,15 @@ AC_ARG_ENABLE([fuzzing], #AC_SUBST([FUZZ_LIBS]) AM_CONDITIONAL([FUZZING], [test "$enable_fuzzing" = "yes"]) +dnl needed for some fuzzers +OLD_LIBS="$LIBS" +AC_SEARCH_LIBS([dlopen], [dl dld]) +if [[ "${ac_cv_search_dlopen#-l}" != "${ac_cv_search_dlopen}" ]]; then + FUZZ_LIBS="${ac_cv_search_dlopen}" + AC_SUBST([FUZZ_LIBS]) +fi +LIBS="$OLD_LIBS" + dnl Opie: Support for opie s/key FTP logins AC_ARG_ENABLE([opie], [AS_HELP_STRING([--disable-opie], [disable support for opie or s/key FTP login])], diff --git a/fuzz/Makefile.am b/fuzz/Makefile.am index b16badb0..5c0c8e17 100644 --- a/fuzz/Makefile.am +++ b/fuzz/Makefile.am @@ -6,7 +6,7 @@ LDADD = ../lib/libgnu.a \ $(LIBSOCKET) $(LIB_CLOCK_GETTIME) $(LIB_CRYPTO) $(LIB_GETLOGIN) $(LIB_NANOSLEEP) $(LIB_POLL) \ $(LIB_POSIX_SPAWN) $(LIB_PTHREAD_SIGMASK) $(LIB_SELECT) $(LIBICONV) $(LIBINTL) \ $(LIBMULTITHREAD) $(LIBTHREAD) $(SERVENT_LIB) @INTL_MACOSX_LIBS@ \ - -ldl + $(FUZZ_LIBS) WGET_TESTS = \ wget_css_fuzzer$(EXEEXT) \