Another workaround for problems linking as a library.

Apply special hack to force linking of internal tests.
Without this, all tests where discarded silently by the linker.