gpt4 book ai didi

python - gcc错误安装python密码centos 7 64

转载 作者:行者123 更新时间:2023-12-04 19:37:21 26 4
gpt4 key购买 nike

我有一个 Centos 7 64 位更新。
我正在尝试使用以下命令安装 python 加密:

 pip install cryptography

但我收到了这个错误信息:
Failed to build cryptography
Installing collected packages: cryptography
Running setup.py install for cryptography ... error
Complete output from command /usr/bin/python3.4 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-lulu_cn7/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-2t0eqhin-record/install-record.txt --single-version-externally-managed --compile:

gcc -pthread -Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python3.4m -c build/temp.linux-x86_64-3.4/_openssl.c -o build/temp.linux-x86_64-3.4/build/temp.linux-x86_64-3.4/_openssl.o
build/temp.linux-x86_64-3.4/_openssl.c:12:24: fatal error: pyconfig.h: No such file or directory
# include <pyconfig.h>
^
compilation terminated.
error: command 'gcc' failed with exit status 1

----------------------------------------
Command "/usr/bin/python3.4 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-lulu_cn7/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-2t0eqhin-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-lulu_cn7/cryptography/

我到处寻找解决方案,但没有运气
这是我的软件包的版本:

Python 2.7.5
Python 3.4.5
来自/usr/lib/python3.4/site-packages 的 pip 9.0.1 (python 3.4)

最佳答案

yum install -y python34-devel ,因为您缺少它提供的库。如果您没有该软件包,则您的存储库中可能没有 EPEL。添加 yum install epel-release .

关于python - gcc错误安装python密码centos 7 64,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42063468/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com