The majority of Unix platforms don't allow inheriting LDFLAGS from DSOs. Therefore, the core must dynamically link against OpenSSL and OpenLDAP not the modules. The run-time linker gets its search paths from the executable not the DSOs.This is a bug in the way Apache autoconf's... OpenSSL and OpenLDAP should never be linked to the core... they should have been detected and added only to the modules/ssl and modules/ldap makefiles' CFLAGS/LDFLAGS.
So, I don't think you can do that portably.
APR thread support is always enabled if the platform has it (not sure why you think it doesn't).Let's expect to fix that before releasing 2.2. And maybe consider always enabling APR thread support while we are at it.
We've disabled it by default on FreeBSD because we know the thread libraries still has subtle quirks (user is free to override us by passing --enable-threads). We're trying to find someone with 5.0 and see if it is fixed. I believe Tony Finch has hinted that 5.1 might have the real fixes we need for FreeBSD. -- justin