Sourceware Bugzilla – Bug 14743
clock_gettime et al from -lrt always bring in libpthread
Last modified: 2013-01-15 14:34:56 UTC
Just using clock_gettime in a dynamically linked program requires -lrt.
librt.so depends on libpthread.so, so such programs wind up loading libpthread even if they have no need for it. This enables libstdc++ locking code and the like, slowing down single-threaded programs that only wanted clock_* calls.
Implemented. Cannot be backported.
*** Bug 14304 has been marked as a duplicate of this bug. ***