我试图通过命令将"gmpy2"安装到Google 上:
!pip3 install gmpy2我得到了错误:
Collecting gmpy2
Downloading gmpy2-2.0.8.zip (280 kB)
|████████████████████████████████| 280 kB 5.0 MB/s
Building wheels for collected packages: gmpy2
Building wheel for gmpy2 (setup.py) ... error
ERROR: Failed building wheel for gmpy2
Running setup.py clean for gmpy2
Failed to build gmpy2
Installing collected packages: gmpy2
Running setup.py install for gmpy2 ... error
ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-vgotfc49/gmpy2_497ebb8b22424194b2bbd366af5942b6/setup.py'"'"'; __file__='"'"'/tmp/pip-install-vgotfc49/gmpy2_497ebb8b22424194b2bbd366af5942b6/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-xvhw4sjx/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.7/gmpy2 Check the logs for full command output.Google的描述:Ubuntu18.04.5LTS代号:仿生型号名称: AMD EPYC 7B12
pip3 --version
pip 21.1.3 from /usr/local/lib/python3.7/dist-packages/pip (python 3.7)为什么我不能安装"gmpy2"?造成这一错误的原因是什么?
发布于 2021-09-14 14:37:02
下面是如何安装gmpy2
!apt install libmpc-dev
!pip install gmpy2https://stackoverflow.com/questions/69178324
复制相似问题