尝试从命令行安装uWSGI
pip install uwsgi
导致长堆栈跟踪的结果,以下是其结尾:
/usr/bin/x86_64-linux-gnu-ld: /usr/local/lib/python3.6/config-3.6m-x86_64-linux-gnu/libpython3.6m.a(parser.o):
relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object;
recompile with -fPIC
/usr/bin/x86_64-linux-gnu-ld: final link failed: Nonrepresentable section on output
collect2: error: ld returned 1 exit status
*** error linking uWSGI ***
----------------------------------------
Command "/home/user/venv/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ve0nx9k8/uwsgi/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-record-l_7f937a/install-record.txt --single-version-externally-managed --compile --install-headers /home/user/venv/include/site/python3.6/uwsgi" failed with error code 1 in /tmp/pip-install-ve0nx9k8/uwsgi/
我正在使用Python 3.6。Python 2可以工作,Python 3.7也可以工作,但不幸的是我需要使用Python 3.6。虚拟环境中没有其他内容,这是一个相当新的Ubuntu重新安装。