Here I am on a GNU/Linux machine.
I have installed hunspell 1.7.0-3 and hunspell-es_MX and a lot of the english dictionaries as well. If I type
hunspell -D I get, along others:
/usr/share/hunspell/es_MX And if i check the files I can see that I have a aff file in the mentioned directory. In my .emacs file I have:
(setenv "DICPATH" "/usr/share/hunspell") ;; Tell ispell-mode to use hunspell. (setq ispell-program-name "hunspell") (setq ispell-local-dictionary "es_MX") (setq ispell-local-dictionary-alist '(("es_MX" "[[:alpha:]]" "[^[:alpha:]]" "[']" nil nil nil utf-8))) as I saw in other questions here.
But If i run the spell checker it fails, printing:
Can't find Hunspell dictionary with a .aff affix file I am completely lost here.
More info: My Emacs is 27.2 and the output of the command pointed by rplium, hunspell -D -a /dev/null, is:
SEARCH PATH: .::/usr/share/hunspell:/usr/share/myspell:/usr/share/myspell/dicts:/Library/Spelling:/home/karel/.openoffice.org/3/user/wordbook:/home/karel/.openoffice.org2/user/wordbook:/home/karel/.openoffice.org2.0/user/wordbook:/home/karel/Library/Spelling:/opt/openoffice.org/basis3.0/share/dict/ooo:/usr/lib/openoffice.org/basis3.0/share/dict/ooo:/opt/openoffice.org2.4/share/dict/ooo:/usr/lib/openoffice.org2.4/share/dict/ooo:/opt/openoffice.org2.3/share/dict/ooo:/usr/lib/openoffice.org2.3/share/dict/ooo:/opt/openoffice.org2.2/share/dict/ooo:/usr/lib/openoffice.org2.2/share/dict/ooo:/opt/openoffice.org2.1/share/dict/ooo:/usr/lib/openoffice.org2.1/share/dict/ooo:/opt/openoffice.org2.0/share/dict/ooo:/usr/lib/openoffice.org2.0/share/dict/ooo AVAILABLE DICTIONARIES (path is not mandatory for -d option): /usr/share/hunspell/en_SG /usr/share/hunspell/en_AG /usr/share/hunspell/en_US /usr/share/hunspell/en_BS /usr/share/hunspell/en_GB /usr/share/hunspell/es_MX /usr/share/hunspell/en_HK /usr/share/hunspell/en_NG /usr/share/hunspell/en_GB-large /usr/share/hunspell/en_BZ /usr/share/hunspell/en_ZA /usr/share/hunspell/en_NZ /usr/share/hunspell/en_NA /usr/share/hunspell/en_ZW /usr/share/hunspell/en_IN /usr/share/hunspell/en_GH /usr/share/hunspell/en_JM /usr/share/hunspell/en_BW /usr/share/hunspell/en_TT /usr/share/hunspell/en_DK /usr/share/hunspell/en_IE /usr/share/hunspell/en_US-large /usr/share/myspell/dicts/en_SG /usr/share/myspell/dicts/en_AG /usr/share/myspell/dicts/en_US /usr/share/myspell/dicts/en_BS /usr/share/myspell/dicts/en_GB /usr/share/myspell/dicts/es_MX /usr/share/myspell/dicts/en_HK /usr/share/myspell/dicts/en_NG /usr/share/myspell/dicts/en_GB-large /usr/share/myspell/dicts/en_BZ /usr/share/myspell/dicts/en_ZA /usr/share/myspell/dicts/en_NZ /usr/share/myspell/dicts/en_NA /usr/share/myspell/dicts/en_ZW /usr/share/myspell/dicts/en_IN /usr/share/myspell/dicts/en_GH /usr/share/myspell/dicts/en_JM /usr/share/myspell/dicts/en_BW /usr/share/myspell/dicts/en_TT /usr/share/myspell/dicts/en_DK /usr/share/myspell/dicts/en_IE /usr/share/myspell/dicts/en_US-large Can't open affix or dictionary files for dictionary named "es_ES"
hunspell -D -a /dev/nulloutput?DICTIONARY=es_MX hunspell -D -a /dev/nulllists a.afffile (and if so, see if you can change the default dictionary for hunspell to be "es_MX")