error: command 'gcc' failed with exit status when installing psycopg2

前端 未结 12 1960
情深已故
情深已故 2020-12-15 03:59

i need to install psycopg2 for openerp installation process, but i always found that error. i\'ve already used pip and easy_inst

12条回答
  •  忘掉有多难
    2020-12-15 04:46

    For Ubuntu 14.04, from Docker image python:3.4.3-slim this combination worked for me:

    sudo apt-get update
    sudo apt-get install -y build-essential
    sudo apt-get install -y python3.4-dev
    sudo apt-get install -y libpq-dev
    
    pip3 install psycopg2
    

    Note build-essential package. It was crucial in my case.

提交回复
热议问题