从Github下载源包tar.gz后解压
想要通过python setup.py install
安装
报错:
[Errno 13] Permission denied: '/usr/local/python3/lib/python3.9/site-packages/test-easy-install-19853.write-test'
The installation directory you specified (via --install-dir, --prefix, or
the distutils default setting) was:
/usr/local/python3/lib/python3.9/site-packages/
Perhaps your account does not have write access to this directory? If the
installation directory is a system-owned directory, you may need to sign in
as the administrator or "root" account. If you do not have administrative
access to this machine, you may wish to choose a different installation
directory, preferably one that is listed in your PYTHONPATH environment
variable.
原因:账号没有root权限
最简单的方法:
python setup.py install --user
即在个人目录下安装
网友评论