(tree_move): fix coding style.
[midnight-commander.git] / m4.include / mc-with-internal-edit.m4
bloba801e1d68c339c668c84d7d2683fbd5f5fac67bb
1 dnl
2 dnl Internal editor support.
3 dnl
4 AC_DEFUN([mc_WITH_INTERNAL_EDIT], [
6     AC_ARG_WITH([internal_edit],
7         AS_HELP_STRING([--with-internal-edit], [Enable internal editor @<:@yes@:>@]))
9     if test x$with_internal_edit != xno; then
10             AC_DEFINE(USE_INTERNAL_EDIT, 1, [Define to enable internal editor])
11             use_internal_edit=yes
12             AC_MSG_NOTICE([using internal editor])
13             edit_msg="yes"
14     else
15             use_internal_edit=no
16             edit_msg="no"
17     fi
19     dnl ASpell support.
20     AC_ARG_ENABLE([aspell],
21         AS_HELP_STRING([--enable-aspell], [Enable aspell support for internal editor @<:@no@:>@]),
22         [
23             if test "x$enableval" = xno; then
24                 enable_aspell=no
25             else
26                 enable_aspell=yes
27             fi
28         ],
29         [enable_aspell=no]
30     )
32     if test x$with_internal_edit != xno -a x$enable_aspell != xno; then
33             AC_CHECK_HEADERS([aspell.h], [], [
34                 AC_MSG_ERROR([Could not find aspell development headers])
35             ], [])
37             if test x"$g_module_supported" != x; then
38                 AC_DEFINE(HAVE_ASPELL, 1, [Define to enable aspell support])
39                 edit_msg="yes with aspell support"
40                 AC_MSG_NOTICE([using aspell for internal editor])
41             else
42                 enable_aspell=no
43                 AC_MSG_NOTICE([aspell support is disabled because gmodule support is not available])
44             fi
45     fi