错误消息:
src/pyfasttext.cpp:648:10: fatal error :找不到“随机”文件
#包括 。
^~~~~~~~ 。
生成 1 个警告和 1 个错误。
错误:命令“gcc”失败,退出状态为 1
已经安装了 gcc 和 LLVM...
UK-xxxx:verheng$ gcc --version
配置为: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM 版本 10.0.0 (clang-1000.10.40.1)
目标:x86_64-apple-darwin17.7.0
线程模型:posix
安装目录:/Library/Developer/CommandLineTools/usr/bin
尝试过这个:https://github.com/vrasneur/pyfasttext/issues/24
没有帮助
谢谢
最佳答案
首先,安装 Cython 以便通过以下命令安装 fasttext:
pip install Cython --install-option="--no-cython-compile"
现在使用以下命令安装 fasttext:
pip install fasttext
关于c++ - Mac OS 上 Pyfasttest 安装失败 : fatal error: 'random' file not found,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51824905/