2012-04-26 14:05:48 +04:00
|
|
|
dnl
|
|
|
|
dnl Internal editor support.
|
|
|
|
dnl
|
2013-06-15 12:55:16 +04:00
|
|
|
AC_DEFUN([MC_WITH_INTERNAL_EDIT], [
|
2012-04-26 14:05:48 +04:00
|
|
|
|
2013-06-15 12:55:16 +04:00
|
|
|
AC_ARG_WITH([internal_edit],
|
|
|
|
AS_HELP_STRING([--with-internal-edit], [Enable internal editor @<:@yes@:>@]))
|
2012-04-26 14:05:48 +04:00
|
|
|
|
2013-06-15 12:55:16 +04:00
|
|
|
if test x$with_internal_edit != xno; then
|
2012-04-26 14:05:48 +04:00
|
|
|
AC_DEFINE(USE_INTERNAL_EDIT, 1, [Define to enable internal editor])
|
2013-06-15 12:55:16 +04:00
|
|
|
use_internal_edit=yes
|
2012-04-26 14:05:48 +04:00
|
|
|
AC_MSG_NOTICE([using internal editor])
|
2013-06-15 12:55:16 +04:00
|
|
|
edit_msg="yes"
|
2012-04-26 14:05:48 +04:00
|
|
|
else
|
2013-06-15 12:55:16 +04:00
|
|
|
use_internal_edit=no
|
2012-04-26 14:05:48 +04:00
|
|
|
edit_msg="no"
|
|
|
|
fi
|
|
|
|
|
|
|
|
dnl ASpell support.
|
|
|
|
AC_ARG_ENABLE([aspell],
|
|
|
|
AS_HELP_STRING([--enable-aspell], [Enable aspell support for internal editor @<:@no@:>@]),
|
|
|
|
[
|
|
|
|
if test "x$enableval" = xno; then
|
|
|
|
enable_aspell=no
|
|
|
|
else
|
|
|
|
enable_aspell=yes
|
|
|
|
fi
|
|
|
|
],
|
|
|
|
[enable_aspell=no]
|
|
|
|
)
|
|
|
|
|
2013-06-15 12:55:16 +04:00
|
|
|
if test x$with_internal_edit != xno -a x$enable_aspell != xno; then
|
2012-04-26 14:05:48 +04:00
|
|
|
AC_CHECK_HEADERS([aspell.h], [], [
|
|
|
|
AC_ERROR([Could not find aspell development headers])
|
|
|
|
], [])
|
|
|
|
|
|
|
|
if test x"$g_module_supported" != x; then
|
|
|
|
AC_DEFINE(HAVE_ASPELL, 1, [Define to enable aspell support])
|
|
|
|
edit_msg="yes with aspell support"
|
|
|
|
AC_MSG_NOTICE([using aspell for internal editor])
|
|
|
|
else
|
|
|
|
enable_aspell=no
|
|
|
|
AC_MSG_NOTICE([aspell support is disabled because gmodule support is not available])
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
])
|