So ... a while ago I "fixed" SConstruct to make the build libserf correctly link with the non-default OpenSSL libraries on OSX. I now find that the following patch produces the same result:
Index: SConstruct =================================================================== --- SConstruct (revision 1775283) +++ SConstruct (working copy) @@ -400,21 +400,7 @@ else: apr_libs = '' apu_libs = '' - env.Append(CPPPATH=['$ZLIB/include']) - env.Append(LIBPATH=['$ZLIB/lib']) - # MacOS ships ancient OpenSSL libraries, but no headers, so we can - # assume we're building with an OpenSSL installed outside the - # default include and link paths. To prevent accidentally linking to - # the old shared libraries, make sure that the OpenSSL paths are - # first in the search lists. - if sys.platform == 'darwin': - env.Prepend(CPPPATH=['$OPENSSL/include']) - env.Prepend(LIBPATH=['$OPENSSL/lib']) - else: - env.Append(CPPPATH=['$OPENSSL/include']) - env.Append(LIBPATH=['$OPENSSL/lib']) - # Check for OpenSSL functions which are only available in some of # the versions we support. Also handles forks like LibreSSL. conf = Configure(env) That is, /removing/ all the explicit handling of ZLIB and OpenSSL causes scons to find the right libraries and set the lib paths and RPATH in the correct order? I'm kind of scared to commit this because I don't understand how or why it works. But if this is the correct way to do things, it's a much nicer solution than the current hack. -- Brane