Most of the time these are dependency-issues.

Following the stack-trace of the gcc compiler one can see the missing files. Sometimes installing the Python development packages is not enough.

For example: I tried to do pip install requests[security] in my virtualenv foo. This is the result that the pip-installer gave me.

Failed building wheel for cryptography
Running setup.py bdist_wheel for cffi
Stored in directory: /root/.cache/pip/wheels/99/e7/9a/68b1c8ca6f6f92b5feebd4d9434f50712b84f6a66d1285ea21
Successfully built cffi
Failed to build cryptography
Installing collected packages: cffi, cryptography, pyOpenSSL, ndg-httpsclient, requests
Running setup.py install for cryptography
Complete output from command /opt/foo/django-cms-virtualenv/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-build-eZaLAG/cryptography/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-BwgYTp-record/install-record.txt --single-version-externally-managed --compile --install-headers /opt/foo/django-cms-virtualenv/include/site/python2.7/cryptography:
running install
running build
running build_py
running egg_info
writing requirements to src/cryptography.egg-info/requires.txt
writing src/cryptography.egg-info/PKG-INFO
writing top-level names to src/cryptography.egg-info/top_level.txt
writing dependency_links to src/cryptography.egg-info/dependency_links.txt
writing entry points to src/cryptography.egg-info/entry_points.txt
warning: manifest_maker: standard file '-c' not found reading manifest file 'src/cryptography.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
no previously-included directories found matching 'docs/_build'
warning: no previously-included files matching '*' found under directory 'vectors'
writing manifest file 'src/cryptography.egg-info/SOURCES.txt'
running build_ext
building '_Cryptography_cffi_a269d620xd5c405b7' extension
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_a269d620xd5c405b7.c -o build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_a269d620xd5c405b7.o
src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_a269d620xd5c405b7.c:217:25: fatal error: openssl/aes.h: Datei oder Verzeichnis nicht gefunden
#include <openssl/aes.h>
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

The important part is the: #include <openssl/aes.h>

The compiler makes pretty clear that it is demanding this file - but it is not there in the filesystem.

Knowing that, the only thing left to do is: install the needed libraries!

  1. Find out which package is needed for your distribution: e.g. for Ubuntu you can go to The Ubuntu Package Search Site and enter the missing file you are looking for. In this case "aes.h"
  2. Install the needed packages using your distributions package management tool: e.g. for Ubuntu:

    aptitude install libssl-dev

  3. Retry with pip in your virtualenv:

最新文章

  1. 微信小程序-关于post 过来服务器没有获取到数据问题
  2. java通过地址获取主机名
  3. HTTP 简介
  4. c#创建、保存excel正常执行
  5. PHP 学习笔记 (二)
  6. chrome_php logger 的实现原理
  7. Py3快速下载地址
  8. HTML滚动条
  9. What Is Your Grade?(水,排序)
  10. 初入ubuntu
  11. python内置函数-compile()
  12. Go实现海量日志收集系统(一)
  13. Struts源码之OgnlValueStack
  14. tensorflow 莫烦教程
  15. Linux平台 Oracle 18c RAC安装
  16. SharePoint PowerShell 启动工作流
  17. 图的M 着色问题
  18. 循环神经网络-LSTM
  19. Mybatis if标签判断大小
  20. VidLoc: A Deep Spatio-Temporal Model for 6-DoF Video-Clip Relocalization

热门文章

  1. hadoop学习;Streaming,aggregate;combiner
  2. AWR--service statistics
  3. Linux入门基础篇
  4. iOS LaunchScreen设置启动图片 启动页停留时间
  5. Mac 在启动eclipse时 Failed to load JavaHL Library解决方法
  6. Nodejs开发人脸识别系统-教你实现高大上的人工智能
  7. Python的开源人脸识别库:离线识别率高达99.38%
  8. Latex:表格制作全攻略
  9. 学习笔记:STL
  10. Dijkstra算法求最短路径(java)(转)