freebsd-dev/secure
Konstantin Belousov a9e285b047 Fix order of libthr and libc in the global dso list for sshd, by
explicitely linking main binary with -lpthread.  Before, libthr
appeared in the list due to dependency of one of the kerberos libs.
Due to the change in ld(1) behaviour of not copying NEEDED entries
from direct dependencies into the link results, the order becomes
reversed.

The libthr must appear before libc to properly interpose libc symbols
and provide working rtld locks implementation.  The symptom was sshd
hanging on rtld bind lock during nested symbol binding from a signal
handler.

Approved by:	des (openssh maintainer)
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
2014-04-27 05:28:14 +00:00
..
lib Add placeholder Kyuafiles for various top-level hierarchies. 2014-04-21 21:39:25 +00:00
libexec Add placeholder Kyuafiles for various top-level hierarchies. 2014-04-21 21:39:25 +00:00
tests Add placeholder Kyuafiles for various top-level hierarchies. 2014-04-21 21:39:25 +00:00
usr.bin Add placeholder Kyuafiles for various top-level hierarchies. 2014-04-21 21:39:25 +00:00
usr.sbin Fix order of libthr and libc in the global dso list for sshd, by 2014-04-27 05:28:14 +00:00
Makefile Add placeholder Kyuafiles for various top-level hierarchies. 2014-04-21 21:39:25 +00:00
Makefile.inc Remove references to MK_IDEA. 2013-04-27 05:44:39 +00:00