Gold linker doesnt handle the typical svr4 option -G vfor creating shared objects. As this option (-G) is implemented for most systems in GNU libtool it can be a problem for some systems.
simple solution (not implementing the most complicated -G size as gnu ld, jusr -G as its used on a typical SVR4) options.h + DEFINE_bool(G, options::ONE_DASH, '\0', false, + N_("Generate shared library"), NULL); options.cc - if (this->Bshareable()) + if ( (this->Bshareable()) || (this->G()) ) + this->set_shared(true);
Thanks for the bug report. This has been fixed, and gold now supports -G.