安装psycopg2 linux " x86_64 linux-gnu-gcc:错误:无法识别的命令行选项' -群众化参数' "

时间:2021-12-20 23:18:38

Good day. I'm trying to install in a virtual environment. I tried different tips, but the error persists. My system is Ubuntu 14.04.

美好的一天。我想在虚拟环境中安装。我尝试了不同的技巧,但错误仍然存在。我的系统是Ubuntu 14.04。

(.env)volody@volody-MVG:~/program/MyProject/eveportal$ pip install psycopg2
Collecting psycopg2
   Using cached psycopg2-2.6.1.tar.gz
Installing collected packages: psycopg2
   Running setup.py install for psycopg2
 Complete output from command /home/volody/program/MyProject/eveportal/.env/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-build-8OJou3/psycopg2/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-29kcwo-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/volody/program/MyProject/eveportal/.env/include/site/python2.7/psycopg2:
 ...
 copying tests/test_async.py -> build/lib.linux-x86_64-2.7/psycopg2/tests
running build_ext
building 'psycopg2._psycopg' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/psycopg
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -fPIC -DHAVE_MXDATETIME=1 -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.1 (dt dec mx pq3 ext lo64)" -DPG_VERSION_HEX=0x09030A -DHAVE_LO64=1 -I/usr/include/python2.7/mx -I/usr/include/python2.7 -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/psycopgmodule.c -o build/temp.linux-x86_64-2.7/psycopg/psycopgmodule.o -Wdeclaration-after-statement
x86_64-linux-gnu-gcc: error: unrecognized command line option ‘-Qunused-arguments’
x86_64-linux-gnu-gcc: error: unrecognized command line option ‘-Qunused-arguments’
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

1 个解决方案

#1


0  

»» option ‘-Qunused-arguments’ «« : Seems to be a "pip" thing.

»选项' -群居参数'«:似乎是一个“pip”的东西。

`psycopg2-2.6.1' can easily be installed on Ubuntu 14.04 - 64bits with:

“psycopg2-2.6.1”可以很容易地安装在Ubuntu 14.04 - 64位上:

$ cd psycopg2-2.6.1/ && sudo python setup.py install

#1


0  

»» option ‘-Qunused-arguments’ «« : Seems to be a "pip" thing.

»选项' -群居参数'«:似乎是一个“pip”的东西。

`psycopg2-2.6.1' can easily be installed on Ubuntu 14.04 - 64bits with:

“psycopg2-2.6.1”可以很容易地安装在Ubuntu 14.04 - 64位上:

$ cd psycopg2-2.6.1/ && sudo python setup.py install