我试图将Python.h放入我的/usr/include/python2.7目录,所以我运行
$ sudo apt install python-dev
它告诉我将安装这些: libpython-dev libpython2.7 libpython2.7-dev python2.7-dev
到目前为止,太好了。然后我得到以下输出:
Err:1 http://us.archive.ubuntu.com/ubuntu bionic-updates/main amd64 libpython2.7 amd64 2.7.15-4ubuntu4~18.04.1
404 Not Found [IP: 91.189.91.24 80]
Err:2 http://us.archive.ubuntu.com/ubuntu bionic-updates/main amd64 libpython2.7-dev amd64 2.7.15-4ubuntu4~18.04.1
404 Not Found [IP: 91.189.91.24 80]
Err:3 http://us.archive.ubuntu.com/ubuntu bionic-updates/main amd64 python2.7-dev amd64 2.7.15-4ubuntu4~18.04.1
404 Not Found [IP: 91.189.91.24 80]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/p/python2.7/libpython2.7_2.7.15-4ubuntu4~18.04.1_amd64.deb 404 Not Found [IP: 91.189.91.24 80]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/p/python2.7/libpython2.7-dev_2.7.15-4ubuntu4~18.04.1_amd64.deb 404 Not Found [IP: 91.189.91.24 80]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/p/python2.7/python2.7-dev_2.7.15-4ubuntu4~18.04.1_amd64.deb 404 Not Found [IP: 91.189.91.24 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
所以我用--fix-missing选项运行它:
$ sudo apt install python-dev --fix-missing
并获得相同的输出,但最后是这样:
E:中止安装。
我该如何解决?