From cfa4ea64bc06685f210a4187dcc05cc0aac84851 Mon Sep 17 00:00:00 2001 From: Evan Hunt Date: Sat, 5 Sep 2020 12:10:35 -0700 Subject: [PATCH] fix LD_WRAP test in configure The LD_WRAP test in configure was broken, and failed to indicate LD_WRAP support correctly, resulting in some unit tests failing to run. --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 12170df1bf..9ddad8edf4 100644 --- a/configure.ac +++ b/configure.ac @@ -1320,11 +1320,11 @@ AM_CONDITIONAL([HAVE_CMOCKA], [test "$with_cmocka" = "yes"]) LD_WRAP_TESTS=false AC_MSG_CHECKING([for linker support for --wrap option]) AX_SAVE_FLAGS([wrap]) -LDFLAGS="-Wl,-wrap,exit" +LDFLAGS="-Wl,--wrap,exit" AC_RUN_IFELSE( [AC_LANG_PROGRAM([[#include void __real_exit (int status); - void __wrap_exit (int status) { __real_exit (status); } + void __wrap_exit (int status) { __real_exit (0); } ]], [[exit (1);]])], [LD_WRAP_TESTS=true