Ah!, like Erwin Lemmers said, you havent installed the libs in thier proper
places, so possably rerunning ldconfig is of no use at all with the lib in
the above directory.
I suggest you copy libpq.so.1 to /usr/lib or /usr/local/lib those dir's
should already be defined in /etc/ld.so.conf, now rerun ldconfig.
I doubt very much if the program will ever look in the above directory for
lib's, possably explaning why it cant find libpq.so.
When you have run ldconfig, you could also check to see if the libs are
linked with 'ldconfig -v >foo.txt', the file foo.txt will contain a large
list of libs and symlinks and in which directory they are located.
'ldd <program>' will tell you what libs are needed to run that program.
'man ldconfig' will explane what ldconfig does and where it looks for libs.
Hope this is of help.
-- Regards Richard. bas@innovate-it.ch