diff --git a/Makefile.am b/Makefile.am index 64ee234..1cb40b3 100644 --- a/Makefile.am +++ b/Makefile.am @@ -20,6 +20,12 @@ banner: # 'nothing to be done for test'. By forwarding test to check we work around it. test: check +# recurse all make devs just +dev: + $(MAKE) dev -C tools/tokenisers + $(MAKE) dev -C tools/grammarcheckers + $(MAKE) dev -C tools/tts + # Remove html tables created by some of the developer tools: clean-local: rm -f *.html diff --git a/m4/giella-macros.m4 b/m4/giella-macros.m4 index 7b41780..4cec2db 100644 --- a/m4/giella-macros.m4 +++ b/m4/giella-macros.m4 @@ -88,7 +88,7 @@ AC_MSG_RESULT([$GIELLA_CORE]) ############################################################### ### This is the version of the Giella Core that we require. ### ### UPDATE AS NEEDED. -_giella_core_min_version=0.22.2 +_giella_core_min_version=0.23.0 # GIELLA_CORE/GTCORE env. variable, required by the infrastructure to find scripts: AC_ARG_VAR([GIELLA_CORE], [directory for the Giella infra core scripts and other required resources]) @@ -162,21 +162,7 @@ AS_IF([test "x$enable_yamltests" = "xcheck"], AM_CONDITIONAL([CAN_YAML_TEST], [test "x$enable_yamltests" != xno]) -################ LXML or pip ################ -AS_IF([test "x$enable_grammarchecker" != "xno"], - [AM_PATH_PYTHON([3.5],, [:]) - AX_PYTHON_MODULE(lxml) - AX_PYTHON_MODULE(pip) - AC_MSG_CHECKING([whether we can use lxml]) - AS_IF([test "x$HAVE_PYMOD_LXML" != "xyes"], - AS_IF([test "x$HAVE_PYMOD_PIP" != "xno"], - AC_MSG_RESULT(no) - AC_MSG_WARN([lxml or pip is needed for grammarcheckers]), - AC_MSG_RESULT([no but using pip])), - AC_MSG_RESULT(yes))]) - -AM_CONDITIONAL([CAN_LXML], [test "x$HAVE_PYMOD_LXML" != xno]) -AM_CONDITIONAL([CAN_PIP], [test "x$HAVE_PYMOD_LXML" != xno]) + ################ Generated documentation ################ # Check for awk with required feature: AC_CACHE_CHECK([for awk that supports gensub], [ac_cv_path_GAWK], @@ -676,6 +662,18 @@ AS_IF([test "x$enable_grammarchecker" = "xyes" -a "x$gt_prog_vislcg3" = "xno"], AS_IF([test "x$enable_ci" = "xyes" -a "x$enableval" = "x"], [enable_grammarchecker=no]) AM_CONDITIONAL([WANT_GRAMCHECK], [test "x$enable_grammarchecker" != xno]) enableval='' +################ gtgramtool for grammarchecking ################ +AC_PATH_PROG([GTGRAMTOOL], [gtgramtool], [false]) +AS_IF([test "x$enable_grammarchecker" != "xno"], + AX_PYTHON_MODULE(pip) + AC_MSG_CHECKING([whether we have gtgramtool]) + AS_IF([test x$GTGRAMTOOL = xfalse], + [AC_MSG_ERROR([gtgramtool is needed for --enable grammarchecker. + on debian/ubuntu: sudo apt update; sudo apt install pipx; pipx ensurepath + on macbrew: brew install pipx; pipx ensurepath + then: pipx install git+https://github.com/divvun/giellaltgramtools + ])]), + AC_MSG_RESULT(yes)) # Enable all spellers - default is 'no' AC_ARG_ENABLE([spellers], @@ -1048,7 +1046,6 @@ cd .. git clone git@github.com:giellalt/$gt_SHARED_FAILS cd $gt_SHARED_FAILS ./autogen.sh && ./configure && make])]) -AC_MSG_WARN([January 2024: the lexc files and fsts have been moved up to src/fst/morphology]) ]) # gt_PRINT_FOOTER # vim: set ft=config: diff --git a/test/tools/spellcheckers/fstbased/desktop/hfst/accept-all-lemmas.sh.in b/test/tools/spellcheckers/fstbased/desktop/hfst/accept-all-lemmas.sh.in index eceb38a..40e857f 100755 --- a/test/tools/spellcheckers/fstbased/desktop/hfst/accept-all-lemmas.sh.in +++ b/test/tools/spellcheckers/fstbased/desktop/hfst/accept-all-lemmas.sh.in @@ -32,6 +32,10 @@ checked_lemmas=checked_lemmas.txt --exclude "(CmpN/Only|ShCmp|\+Cmp\/SplitR| Rreal | R | Rnoun |\+V\+|NOT-TO-LEMMATEST)" \ $source_files > $lemmas +if ! test -f $speller_dir/${GIELLA_LANG}.zhfst ; then + echo missing $speller_dir/${GIELLA_LANG}.zhfst +fi + ####### Start testing: ####### $ospell $speller_dir/${GIELLA_LANG}.zhfst < $lemmas > $checked_lemmas @@ -39,6 +43,8 @@ $ospell $speller_dir/${GIELLA_LANG}.zhfst < $lemmas > $checked_lemmas grep 'is NOT in the lexicon' $checked_lemmas > $rejected_lemmas if [ -s $rejected_lemmas ] ; then + head $rejected_lemmas + echo see $rejected_lemmas for more exit 1 fi