Reputation: 6037
The installation of the hunspell python package (via pip) fails with the following error:
hunspell.c:21:22: fatal error: hunspell.h: No such file or directory
#include <hunspell.h>
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
Any idea what to do to solve this?
Upvotes: 4
Views: 5018
Reputation: 51
this worked for me
sudo apt-get install libhunspell-dev
python3 -m pip install hunspell
or use this
https://pypi.org/project/CyHunspell/
Upvotes: 0
Reputation: 133
Try:
sudo apt-get install libhunspell-dev
pip install hunspell
...as recommended in the same thread in pyhunspell's github page (provided by John D): https://github.com/blatinier/pyhunspell/issues/22
I couldn't install 'hunspell-dev', but I could install libhunspell-dev.
Upvotes: 6
Reputation: 6037
Try
sudo apt-get install hunspell-dev
and then try installing hunspell (or pyhunspell) again
This problem is referenced in an issue on pyhuspell's github page: https://github.com/blatinier/pyhunspell/issues/22
Upvotes: 1