4

ERROR MESSAGES:
src/pyfasttext.cpp:648:10: fatal error: 'random' file not found
#include . ^~~~~~~~ . 1 warning and 1 error generated.
error: command 'gcc' failed with exit status 1


Have installed gcc and LLVM...
UK-xxxx:vercheng$ gcc --version
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 10.0.0 (clang-1000.10.40.1)
Target: x86_64-apple-darwin17.7.0 Thread model: posix InstalledDir: /Library/Developer/CommandLineTools/usr/bin


tried this: https://github.com/vrasneur/pyfasttext/issues/24
didn't help

Thanks

Ben
  • 3,981
  • 2
  • 25
  • 34
Veronica Cheng
  • 447
  • 4
  • 13

1 Answers1

0

First, install Cython in order to install fasttext by this command:

pip install Cython --install-option="--no-cython-compile"

Now install fasttext using this command:

pip install fasttext

Lucky Sunda
  • 53
  • 1
  • 8