test "$with_hunspell" = "no" && lyx_use_hunspell=false
if $lyx_use_hunspell ; then
- AC_CHECK_HEADERS(hunspell/hunspell.hxx,
- [lyx_use_hunspell=true; break;],
+ AC_CHECK_HEADERS(hunspell/hunspell.hxx,
+ [AC_SEARCH_LIBS(Hunspell_spell,
+ [hunspell hunspell-1.2],, [lyx_use_hunspell=false])],
[lyx_use_hunspell=false])
- AC_CHECK_LIB(hunspell, main, LIBS="-lhunspell $LIBS", lyx_use_hunspell=false)
-
+ fi
AC_MSG_CHECKING([whether to use hunspell])
if $lyx_use_hunspell ; then
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
fi
- fi
])
+
### Check if we want spell libraries, prefer new aspell or hunspell
AC_DEFUN([LYX_CHECK_SPELL_ENGINES],
[
- lyx_use_aspell=false
CHECK_WITH_ASPELL
-
AM_CONDITIONAL(USE_ASPELL, $lyx_use_aspell)
- lyx_use_enchant=false
CHECK_WITH_ENCHANT
-
AM_CONDITIONAL(USE_ENCHANT, $lyx_use_enchant)
- lyx_use_hunspell=false
CHECK_WITH_HUNSPELL
-
AM_CONDITIONAL(USE_HUNSPELL, $lyx_use_hunspell)
])