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@:>@],
24 dnl Default: enable the subshell support
28 AC_MSG_RESULT([$result])
30 if test "x$result" != xno; then
31 AC_DEFINE(ENABLE_SUBSHELL, 1, [Define to enable subshell support])
33 dnl openpty() can simplify opening of master/slave devices for subshell
34 AC_CHECK_HEADERS([pty.h libutil.h util.h])
35 AC_CHECK_FUNCS(openpty,,
36 AC_CHECK_LIB(util,openpty,
37 [AC_DEFINE(HAVE_OPENPTY)
42 if test "x$result" = xoptional; then
43 AC_DEFINE(SUBSHELL_OPTIONAL, 1, [Define to make subshell support optional])
49 AM_CONDITIONAL(ENABLE_SUBSHELL, [test "x$result" != xno])