http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57740
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> --- gthr-posix.h uses weakrefs and that is the right thing to do, the APIs are meant to be used regardless of whether libpthread has been linked in or not. The only reliable way to statically link libpthread.a from my experience is what we do in Fedora, i.e. ld -r the whole content of libpthread.a into libpthread.o and include that only in libpthread.a. While some libpthread.a objects have some dependencies, they have just a fraction of the needed ones.