我正在尝试使用cmake在Ubuntu 16.04上运行build dlib。我之前曾使用过它,但是最近遇到了问题,因此我卸载了cmake并尝试重新安装。但是,每当我尝试使用cmake或通过以下方式检查版本时:
cmake --version
但是出现以下错误:
Traceback (most recent call last):
File "/usr/local/bin/cmake", line 11, in <module>
load_entry_point('cmake==3.13.3', 'console_scripts', 'cmake')()
File "/usr/local/lib/python2.7/dist-packages/cmake-3.13.3-py2.7-linux-x86_64.egg/cmake/__init__.py", line 34, in cmake
raise SystemExit(_program('cmake', sys.argv[1:]))
File "/usr/local/lib/python2.7/dist-packages/cmake-3.13.3-py2.7-linux-x86_64.egg/cmake/__init__.py", line 30, in _program
return subprocess.call([os.path.join(CMAKE_BIN_DIR, name)] + args)
File "/usr/lib/python2.7/subprocess.py", line 523, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1343, in _execute_child
raise child_exception
OSError: [Errno 13] Permission denied
我通过以下方式重新安装并获得资源:
sudo apt-get remove cmake cmake-data
sudo -E add-apt-repository -y ppa:george-edison55/cmake-3.x
sudo -E apt-get update
sudo apt-get install cmake
. ~/.bashrc
然后我卸载了它,但并未通过以下方式将其完全删除:
sudo apt-get remove cmake
,然后通过以下方式重新安装:
sudo apt-get install cmake
请让我知道是否需要其他信息。
已解决: