相关疑难解决方法(0)

在OS X上使用pip安装bcrypt时出错:找不到ffi.h(已安装libffi)

尝试使用pip安装bcrypt时出现此错误.我在几个地方安装了libffi(Xcode OS X SDK和自制软件),但我不知道如何告诉pip寻找它.有什么建议?

Downloading/unpacking bcrypt==1.0.2 (from -r requirements.txt (line 41))
  Running setup.py egg_info for package bcrypt
    OS/X: confusion between 'cc' versus 'gcc' (see issue 123)
    will not use '__thread' in the C code
    c/_cffi_backend.c:14:10: fatal error: 'ffi.h' file not found
    #include <ffi.h>
             ^
    1 error generated.
    Traceback (most recent call last):
      File "<string>", line 16, in <module>
      File "/Users/cody/virtualenvs/analytics/build/bcrypt/setup.py", line 104, in <module>
        "Programming Language :: Python :: 3.3",
      File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 112, in setup
        _setup_distribution = dist = …
Run Code Online (Sandbox Code Playgroud)

python macos pip bcrypt libffi

36
推荐指数
3
解决办法
2万
查看次数

标签 统计

bcrypt ×1

libffi ×1

macos ×1

pip ×1

python ×1