4 AC_DEFUN([mc_SUBSHELL], [
6 AC_MSG_CHECKING([for subshell support])
8 [ --with-subshell Compile in concurrent subshell @<:@yes@:>@
9 --with-subshell=optional Don't run concurrent shell by default @<:@no@:>@],
12 if test x$withval = xoptional; then
13 AC_DEFINE(SUBSHELL_OPTIONAL, 1, [Define to make subshell support optional])
16 if test x$withval = xyes; then
21 dnl Default: enable the subshell support
25 if test "x$result" != xno; then
26 AC_DEFINE(ENABLE_SUBSHELL, 1, [Define to enable subshell support])
28 dnl openpty() can simplify opening of master/slave devices for subshell
29 AC_CHECK_HEADERS([pty.h libutil.h util.h])
30 AC_CHECK_FUNCS(openpty,,
31 AC_CHECK_LIB(util,openpty,
32 [AC_DEFINE(HAVE_OPENPTY)
38 AC_MSG_RESULT([$result])
41 AM_CONDITIONAL(ENABLE_SUBSHELL, [test "x$result" != xno])