Unable to install psycopg2 module in amazon linux


#1

Hi All,

I am trying to install psycopg2 module in amazon linux server, it is throwing an error as below:

./psycopg/psycopg.h:31:22: fatal error: libpq-fe.h: No such file or directory
#include <libpq-fe.h>
^
compilation terminated.
error: Setup script exited with error: command ‘gcc’ failed with exit status 1

I checked postgresql-libs , -devel, python-dev are installed already.
can any one suggest on this asap, it is a production server.


#2

I’m not a pro but it looks like either there’s a file that’s not there, which could mean you have to either install or re-install a certain package or group of packages in order to get the file needed to finish compiling the command. The hard part will be finding which package you need to work with in order to find that missing file. Hope this helps.

EGO II


#3

Hi Eddie,

Thanks fro your reply, since it is a prod server, i am not able to install any new rpm’s on it. Still getting same error and not able to find a way…