我已经使用Flask创建了简单的Web应用程序,并希望在Heroku上部署它,但在部署时发现此错误:
Complete output from command /app/.heroku/python/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-yc_idc80/gmpy2/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-dh_wvxtt-record/install-record.txt --single-version-externally-managed --compile: running install running build running build_ext building 'gmpy2' extension creating build creating build/temp.linux-x86_64-3.6 creating build/temp.linux-x86_64-3.6/src gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DWITHMPFR -DWITHMPC -I/app/.heroku/python/include/python3.6m -c src/gmpy2.c -o build/temp.linux-x86_64-3.6/src/gmpy2.o In file included from src/gmpy2.c:426:0: src/gmpy.h:252:20: fatal error: mpfr.h: No such file or directory compilation terminated. error: command 'gcc' failed with exit status 1 ----------------------------------------
答案 0 :(得分:0)
我在gmpy2
上遇到了同样的问题,今天我解决了:
apt install libgmp-dev libmpfr-dev libmpc-dev