Build: Fix issue with HAVE_MAPFILE test on Solaris We have to link the test code into a shared library, or else the mapfile prevents necessary libc symbols from being exposed.