sys-libs/libtermcap-compat lacks preplib after doing dosym for a .so library, thus lacking /lib/libtermcap.so.2 after emerge. ldconfig hand-fixes it, some apps looks apparently broken without it otherwise, and the users shouldn't need to do this. Can also be fixed with an extra dosym.
postgresql 7.4.5 doesn't build because of this. config.log contains this: configure:13552: checking test program configure:13564: gcc -o conftest -march=i686 -O2 -pipe -fno-strict-aliasing -D_GNU_SOURCE conftest.c -lpam -lssl -lcrypto -lz -lreadline -ltermcap -lcrypt -lresolv -lnsl -ldl -lm -lbsd >&5 configure:13567: $? = 0 configure:13569: ./conftest ./conftest: error while loading shared libraries: libtermcap.so.2: cannot open shared object file: No such file or directory
Oh OK, forget about this. This seems to be a postgresql-bug.
we want to punt libtermcap, not fix it ;)