Commit 37cccbab authored by Ondřej Surý's avatar Ondřej Surý
Browse files

Fix the ${WRAP} -> $${WRAP} to allow static non-libtool linking again

parent 4302b4f3
Pipeline #18717 passed with stages
in 13 minutes and 36 seconds
...@@ -21467,7 +21467,6 @@ fi ...@@ -21467,7 +21467,6 @@ fi
LD_WRAP_TESTS=false LD_WRAP_TESTS=false
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for linker support for --wrap option" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for linker support for --wrap option" >&5
$as_echo_n "checking for linker support for --wrap option... " >&6; } $as_echo_n "checking for linker support for --wrap option... " >&6; }
if test "$use_libtool" = yes; then :
   
   
CCASFLAGS_wrap_ax_save_flags=$CCASFLAGS CCASFLAGS_wrap_ax_save_flags=$CCASFLAGS
...@@ -21538,12 +21537,12 @@ if test "$use_libtool" = yes; then : ...@@ -21538,12 +21537,12 @@ if test "$use_libtool" = yes; then :
   
   
   
LDFLAGS="-Wl,-wrap,exit" LDFLAGS="-Wl,-wrap,exit"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */ /* end confdefs.h. */
#include <stdlib.h> #include <stdlib.h>
void __real_exit (int status); void __real_exit (int status);
void __wrap_exit (int status) { __real_exit (status); } void __wrap_exit (int status) { __real_exit (status); }
   
int int
main () main ()
...@@ -21558,7 +21557,7 @@ if ac_fn_c_try_link "$LINENO"; then : ...@@ -21558,7 +21557,7 @@ if ac_fn_c_try_link "$LINENO"; then :
   
$as_echo "#define LD_WRAP 1" >>confdefs.h $as_echo "#define LD_WRAP 1" >>confdefs.h
   
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; } $as_echo "yes" >&6; }
else else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
...@@ -21619,10 +21618,6 @@ rm -f core conftest.err conftest.$ac_objext \ ...@@ -21619,10 +21618,6 @@ rm -f core conftest.err conftest.$ac_objext \
   
   
   
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no, libtool required" >&5
$as_echo "no, libtool required" >&6; }
fi
   
   
   
......
...@@ -2143,21 +2143,19 @@ AC_SUBST([KYUA]) ...@@ -2143,21 +2143,19 @@ AC_SUBST([KYUA])
LD_WRAP_TESTS=false LD_WRAP_TESTS=false
AC_MSG_CHECKING([for linker support for --wrap option]) AC_MSG_CHECKING([for linker support for --wrap option])
AS_IF([test "$use_libtool" = yes], AX_SAVE_FLAGS([wrap])
[AX_SAVE_FLAGS([wrap]) LDFLAGS="-Wl,-wrap,exit"
LDFLAGS="-Wl,-wrap,exit" AC_LINK_IFELSE(
AC_LINK_IFELSE( [AC_LANG_PROGRAM([[#include <stdlib.h>
[AC_LANG_PROGRAM([[#include <stdlib.h> void __real_exit (int status);
void __real_exit (int status); void __wrap_exit (int status) { __real_exit (status); }
void __wrap_exit (int status) { __real_exit (status); } ]],
]], [[exit (1);]])],
[[exit (1);]])], [LD_WRAP_TESTS=true
[LD_WRAP_TESTS=true AC_DEFINE([LD_WRAP], [1], [define if the linker supports --wrap option])
AC_DEFINE([LD_WRAP], [1], [define if the linker supports --wrap option]) AC_MSG_RESULT([yes])],
AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
[AC_MSG_RESULT([no])]) AX_RESTORE_FLAGS([wrap])
AX_RESTORE_FLAGS([wrap])],
[AC_MSG_RESULT([no, libtool required])])
AC_SUBST([LD_WRAP_TESTS]) AC_SUBST([LD_WRAP_TESTS])
......
...@@ -244,7 +244,7 @@ WRAP_OPTIONS = \ ...@@ -244,7 +244,7 @@ WRAP_OPTIONS = \
tkey_test@EXEEXT@: tkey_test.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS} tkey_test@EXEEXT@: tkey_test.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
if test "${LD_WRAP_TESTS}" = true; then WRAP="${WRAP_OPTIONS}"; fi; \ if test "${LD_WRAP_TESTS}" = true; then WRAP="${WRAP_OPTIONS}"; fi; \
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} \ ${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} \
${LDFLAGS} ${WRAP} -o $@ tkey_test.@O@ \ ${LDFLAGS} $${WRAP} -o $@ tkey_test.@O@ \
${DNSLIBS} ${ISCLIBS} ${LIBS} ${DNSLIBS} ${ISCLIBS} ${LIBS}
tsig_test@EXEEXT@: tsig_test.@O@ dnstest.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS} tsig_test@EXEEXT@: tsig_test.@O@ dnstest.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment