From owner-freebsd-current Wed Oct 30 15:42:44 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3141B37B407 for ; Wed, 30 Oct 2002 15:42:43 -0800 (PST) Received: from anchor-post-33.mail.demon.net (anchor-post-33.mail.demon.net [194.217.242.91]) by mx1.FreeBSD.org (Postfix) with ESMTP id A15AD43E4A for ; Wed, 30 Oct 2002 15:42:38 -0800 (PST) (envelope-from dfr@nlsystems.com) Received: from mailgate.nlsystems.com ([62.49.251.130] helo=herring.nlsystems.com) by anchor-post-33.mail.demon.net with esmtp (Exim 3.35 #1) id 1872Tt-000Hr9-0X; Wed, 30 Oct 2002 23:42:37 +0000 Received: from herring (herring [10.0.0.2]) by herring.nlsystems.com (8.12.6/8.12.4) with ESMTP id g9UNgaj0032726; Wed, 30 Oct 2002 23:42:37 GMT (envelope-from dfr@nlsystems.com) Date: Wed, 30 Oct 2002 23:42:36 +0000 (GMT) From: Doug Rabson To: Terry Lambert Cc: Daniel Eischen , Subject: Re: [PATCH: libc]Re: gnome on current In-Reply-To: <3DC0698B.8066CCD5@mindspring.com> Message-ID: <20021030234026.M22480-100000@herring.nlsystems.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 30 Oct 2002, Terry Lambert wrote: > Doug Rabson wrote: > > > I think the only sensible solution to this problem is for libraries which > > > provide an actual pthreads implementation (rather than a set of stubs) to > > > define strong symbols. Wierd debugging wrappers can still be achieved via > > > some dlopen/dlsym hackery. > > > > For what its worth, doing this (defining strong pthread_* symbols in > > libc_r) makes everything work fine, with or without libXThrStub. > > No, this would be bad. There's some justification for not > doing this, in allowing programs linked againts libraries linked > against threaded libraries to link against alternate threads > libraries. If the symbols are stong, then this is not possible. Wrong. Either link the app to libc_r or to libpthread or to libmyOwnThreads. > > Maybe the workaround for now is to make the symbols in libXThrStub.so > weak? They *are* weak Terry. The problem is that every bloody definition is weak so the linker has no way of picking the one definition which will actually work. The real problem is that the actual working threads library doesn't provide strong symbols to allow it to override all the other stubs. -- Doug Rabson Mail: dfr@nlsystems.com Phone: +44 20 8348 6160 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message