aspell がビルドできないので、hunspell を試しています。hunspell をビルドしました。次のように、.emacs をセットアップして、emacs が実行可能ファイルを見つけられるように (また実際に見つけられるように)、次のようにします。
;;; Spell checking using hunspell
(setq ispell-dictionary-alist
'((nil "[A-Za-z]" "[^A-Za-z]" "[']" t
("-d" "en_US" "-i" "utf-8") nil utf-8)
("american"
"[A-Za-z]" "[^A-Za-z]" "[']" nil
("-d" "en_US") nil utf-8)
("english"
"[A-Za-z]" "[^A-Za-z]" "[']" nil
("-d" "en_GB") nil utf-8)
("british"
"[A-Za-z]" "[^A-Za-z]" "[']" nil
("-d" "en_GB") nil utf-8)
("norsk"
"[A-Za-zÉÆØÅéæøå]" "[^A-Za-zÉÆØÅéæøå]" "[\"]" nil
("-d" "nb_NO") "~list" utf-8)))
(eval-after-load "ispell"
(progn
(setq ispell-dictionary "english"
ispell-extra-args '("-a" "-i" "utf-8")
ispell-silently-savep t)))
(setq ispell-dictionary "en_US")
(setq ispell-program-name "/usr/local/bin/hunspell")
これは私の .bash_profile にあります
export DICTIONARY=en_US
export DICPATH=/Users/myname/Applications/en_US
も試した
export DICTIONARY=en_US
export DICPATH=/Users/gpajer/Applications/
(辞書ファイルが存在するディレクトリ ~/Applications/en_US があります)
しかし ispell-buffer は次のようなものを返します
Can't open affix or dictionary flies for dictionary named "english".
@(#) International Ispell Version 3.2.06 (but really Hunspell 1.3.2)
@(#) International Ispell Version 3.2.06 (but really Hunspell 1.3.2)
hunspell は辞書を見つけられませんか? 辞書を置くべき特別な場所はありますか? または、辞書を探す場所を emacs/hunspell に伝えるにはどうすればよいですか?