Installing psycopg2 into virtualenv when PostgreSQL is not installed on development system

前端 未结 14 1080
一向
一向 2020-12-04 09:24

Is it possible to install psycopg2 into a virtualenv when PostgreSQL isn\'t installed on my development system—MacBook Pro with OS X 10.6?

When I run

相关标签:
14条回答
  • 2020-12-04 09:58
    brew install postgresql
    
    export LDFLAGS="-L/usr/local/opt/openssl/lib"
    
    export CPPFLAGS="-I/usr/local/opt/openssl/include"
    
    pip3 install psycopg2
    
    0 讨论(0)
  • 2020-12-04 09:59

    You don't need the complete PostgreSQL installed: you only need the client side libraries.

    0 讨论(0)
提交回复
热议问题