https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54304
--- Comment #16 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Just to let everyone know this is how Darin's ld work. It searches for shared libraries through all of the library patches and then if it does not find one, it searches for a static library. So for Darwin, you need to supply the full path to the static library or name the static library slightly different. This behavior is different from all other Unix ld's too. It might be too hard to solve and really happens with projects too where it depends on standard Unix ld behavior.