c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
Posted yunweigo
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory相关的知识,希望对你有一定的参考价值。
安装 pryptography 报错
pip install cryptography
creating build/temp.linux-x86_64-3.7/c
gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -DTHREAD_STACK_SIZE=0x100000 -fPIC -DUSE__THREAD -DHAVE_SYNC_SYNCHRONIZE -I/usr/include/ffi -I/usr/include/libffi -I/usr/local/include/python3.7m -c c/_cffi_backend.c -o build/temp.linux-x86_64-3.7/c/_cffi_backend.o
c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
15 | #include <ffi.h>
| ^~~~~~~
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /usr/local/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-qcmb4oth/cffi_a7b9f8e81675464f9055c874d965c3ae/setup.py'"'"'; __file__='"'"'/tmp/pip-install-qcmb4oth/cffi_a7b9f8e81675464f9055c874d965c3ae/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\\r\\n'"'"', '"'"'\\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-9_t20f28/install-record.txt --single-version-externally-managed --prefix /tmp/pip-build-env-ei9r_wr9/overlay --compile --install-headers /tmp/pip-build-env-ei9r_wr9/overlay/include/python3.7m/cffi Check the logs for full command output.
关键错误信息
c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
安装相关软件
apk add libffi-dev
以上是关于c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory的主要内容,如果未能解决你的问题,请参考以下文章