Forum OpenACS Q&A: Response to postgres driver won't load, missing crypt; HELP!

The dependency on libcrypt has existed since at least 6.5beta under RedHat Linux.

This is becoming a FAQ.

It is easy enough to add -lcrypt to the makefile (which, IIRC, is done for the Redhat lines I added that are commented out, OR you can statically link libpq and libcrypt by adding' /usr/lib/libpq.a' and' /usr/lib/libcrypt.a' to the link line that makes the .so.

Note that statically linking libraries that were not compiled with -fPIC is not recommended due to performance and portability reasons! IE, the statically linked postgres.so from above will possibly be significantly slower on Intel, and likely will not work AT ALL on non-Intel platforms.

To summarize, adding -lcyrpt is required on RedHat Linux in particular, and has been the case since at least 6.5beta -- the build scripts and makefiles were changed at that time to do smoother dynamic libs -- unfortunately, this is one area that a wart still exists. I've had to compile the postgres driver this way for well over a year, with -lcrypt.

--
Lamar Owen
WGCR Internet Radio
1 Peter 4:11