https://bugs.openldap.org/show_bug.cgi?id=9213
--- Comment #2 from Howard Chu hyc@openldap.org --- (In reply to Ryan Tandy from comment #1)
If linking libldap explicitly doesn't cause problems (only case I can think of is if slapd and libldap get out-of-sync), any reason to not just add it for all of them, regardless of --enable-dynamic?
This will only work if the static libldap was compiled as PIC. Which is generally an odd thing to do for a static library. The static and dynamic libldap's will each have their own separate copies of global options, which might get confusing.
Way back in the past, we built symdummy.c for non-Windows builds (not just for Windows builds), to force slapd to reference the rest of libldap, for this reason. We dropped all this when we started trying to move to less hacked up local copies of the build tools.
We probably should just prevent using --enable-modules without --enable-dynamic.