From 22037d5fba702d76b5df962bb3c08d1b20b9f27d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20B=C3=A9nard?= Date: Thu, 25 Apr 2013 00:27:25 +0200 Subject: configure: add a variable to allow openpty check to be cached Signed-off-by: Dengke Du --- configure.ac | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 8be542a..bc10726 100644 --- a/configure.ac +++ b/configure.ac @@ -269,15 +269,20 @@ AC_ARG_ENABLE(openpty, AC_MSG_NOTICE(Not using openpty) else AC_MSG_NOTICE(Using openpty if available) - AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY,1,[Have openpty() function])]) + AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes]) fi ], [ AC_MSG_NOTICE(Using openpty if available) - AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY)]) + AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes]) ] ) - + +if test "x$dropbear_cv_func_have_openpty" = "xyes"; then + AC_DEFINE(HAVE_OPENPTY,,Have openpty() function) + no_ptc_check=yes + no_ptmx_check=yes +fi AC_ARG_ENABLE(syslog, [ --disable-syslog Don't include syslog support], -- cgit v1.2.1