I think I got closer to the problem.I did clean install of PostgreSQL 8.0.8 on FreeBSD 5.4, then Apache 1.3.36, then PHP 5.1.4 - all compiled from ports. Till here it all works.
Now I install just the php5-pgsql extension. Restart Apache. All works. Reboot the FreeBSD - and Apache does core dump.
Obviously something happens during/after the reboot. Could somebody give me a hint.
Thanks, Iv