]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
fix LD_WRAP test in configure
authorEvan Hunt <each@isc.org>
Sat, 5 Sep 2020 19:10:35 +0000 (12:10 -0700)
committerEvan Hunt <each@isc.org>
Fri, 11 Sep 2020 19:17:03 +0000 (12:17 -0700)
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

index 12170df1bf2e36153cbf75320fbf6e3dc749a06b..9ddad8edf4547698816803f4f0deedd9d9bb6809 100644 (file)
@@ -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 <stdlib.h>
                       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