Image may be NSFW.
Clik here to view.
I have got pgAdminIII-1.14 source code from the official website.
Now I’m trying to compile it, on a Debian Squeeze machine.
At first I did:
./configure
and I got this error:
configure: error: you must specify a valid PostgreSQL 8.4+ installation with --with-pgsql=DIR
I don’t know which one is the directory it requires, I tried with:
/usr/lib/postgresql/9.1/bin
which is the directory in which I have “psql”, but it is not the good one.
How can I solve?
Image may be NSFW.
Clik here to view.
Probably you have to set --with-pgsql=/usr/lib/postgresql/9.1
How did you installed postgresql server? Using repository or from sources?
On the other hand this problem may occour while you are missing pg_config (which ,.configure is looking for)
Please execute which pg_config
and if it’s missing – install additional pacakges
sudo apt-get install libpq-dev
If it doesn’t help you – try moving/copy/link /usr/bin/pg_config
to /usr/lib/postgresql/9.1/bin/.
Then probably
configure: error: Could not find your wxWidgets installation. You might need to use the --with-wx=DIR configure option
error will occure.
Fix it with
apt-get install libwxgtk2.8-dev libwxgtk2.8-dbg
Next one is configure: error: Could not find your libxml2 installation. You might need to use the --with-libxml2=DIR configure option
Fix – apt-get install libxml2-dev
Once again – configure: error: Could not find your libxslt installation. You might need to use the --with-libxslt=DIR configure option
Fix – apt-get install libxslt1-dev
After that make fails
gcc -DHAVE_CONFIG_H -I. -I.. -DDATA_DIR=\"/usr/local/pgadmin3/share/pgadmin3/\" -I../pgadmin/include -I/usr/include /postgresql -I/usr/include/postgresql/9.1/server -I/usr/include/postgresql -DSSL -DHAVE_CONNINFO_PARSE -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DEMBED_XRC -I/usr/include/libxml2 -I/usr/include/libxml2 -O2 -MT keywords.o -MD -MP -MF .deps/keywords.Tpo -c -o keywords.o `test -f './db/keywords.c' || echo './'`./db/keywords.c
./db/keywords.c:33:27: fatal error: parser/kwlist.h: Nie ma takiego pliku ani katalogu compilation terminated. make[3]: *** [keywords.o]
Błąd 1 make[3]: Opuszczenie katalogu `/home/pkieszcz/pgadmin3-1.14.3/pgadmin' make[2]: *** [all] Błąd 2
make[2]: Opuszczenie katalogu `/home/pkieszcz/pgadmin3-1.14.3/pgadmin'
make[1]: *** [all-recursive] Błąd 1 make[1]: Opuszczenie katalogu
`/home/pkieszcz/pgadmin3-1.14.3' make: *** [all] Błąd 2
Make parser folder and wget this file here – http://www.markmcfadden.net/files/kwlist.h
Then finally – make and make install went well.
TL, DR;
apt-get install libxslt1-dev libxml2-dev libwxgtk2.8-dev libwxgtk2.8-dbg libpq-dev
cp /usr/bin/pg_config /usr/lib/postgresql/9.1/bin/.
./configure
mkdir parser
cd parser
wget http://www.markmcfadden.net/files/kwlist.h
make
make install
Check more discussion of this question.