ncursesw split of the library introduced the notion of ld script for
the a files, this is not supported by macOS ar command, so bootstrapping
fails there if a lib in the the bootstap process of buildworld.
libcrypt usage of libmd introduce such a case.
Instrument the build system to know about libraries which produces ld
script for a files, so that when used to static link programs like what
is done in the boostrap it actually links against the _real.a with the
dependencies that it needs instead of linking against the ld script.