Context:FREEBSD 5.4, postgresql 8.0.3
I'm not a C newbye and I'm
having a go at compiling my first, simple C(++) program:
#include
<libpq-fe.h>
int main()
{
PGconn *psql;
psql = PQconnectdb("hostaddr =
'127.0.0.1' port = '' dbname = 'curve' user = 'vi
return 0;
}
But
when
I compile it the following message pops up:
vicbsd# gcc -I
/usr/local/include prova.cpp -o prova
/var/tmp//cceNJFrs.o(.text+0x25):
In function `main':
: undefined reference to `PQconnectdb'
/var/tmp//cceNJFrs.o(.eh_frame+0x11): undefined reference to
`__gxx_personality_v0'
What's wrong with it?
Ciao
Vittorio