X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=acinclude.m4;h=cbf927aad0cf60cec556282c0f52b9c562ad81fc;hb=db5b7f9dc9c86ae607f8bcbacaf49065b8cdcbae;hp=812f4d44f8950932cbe6fd7da050ac6364ad05f5;hpb=f606d3c31ea117f7b9cb187f3521c7051a8db2ba;p=pspp-builds.git diff --git a/acinclude.m4 b/acinclude.m4 index 812f4d44..cbf927aa 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -103,7 +103,7 @@ AC_DEFUN([PSPP_READLINE], dnl Add $INCREADLINE to CPPFLAGS before performing the following checks, dnl because if the user has installed libreadline and not disabled its use - dnl via --without-libreadline-prefix, he wants to use it. The AC_TRY_LINK + dnl via --without-libreadline-prefix, he wants to use it. The AC_LINK_IFELSE dnl will then succeed. am_save_CPPFLAGS="$CPPFLAGS" AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCREADLINE $INCHISTORY]) @@ -121,11 +121,9 @@ AC_DEFUN([PSPP_READLINE], if test -n "$extra_lib"; then LIBS="$LIBS -l$extra_lib" fi - AC_TRY_LINK([#include + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include #include -#include ], - [readline((char*)0); add_history((char*)0);], - gl_cv_lib_readline=yes) +#include ]], [[readline((char*)0); add_history((char*)0);]])],[gl_cv_lib_readline=yes],[]) if test "$gl_cv_lib_readline" = yes; then if test -n "$extra_lib"; then LIBREADLINE="$LIBREADLINE $LIBHISTORY -l$extra_lib"