From owner-freebsd-current Wed Oct 30 15:20:34 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 AF36437B407 for ; Wed, 30 Oct 2002 15:20:32 -0800 (PST) Received: from pintail.mail.pas.earthlink.net (pintail.mail.pas.earthlink.net [207.217.120.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id E6BA243E77 for ; Wed, 30 Oct 2002 15:20:31 -0800 (PST) (envelope-from tlambert2@mindspring.com) Received: from pool0465.cvx40-bradley.dialup.earthlink.net ([216.244.43.210] helo=mindspring.com) by pintail.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 18728Q-0006lr-00; Wed, 30 Oct 2002 15:20:26 -0800 Message-ID: <3DC068EE.D04E207C@mindspring.com> Date: Wed, 30 Oct 2002 15:19:10 -0800 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Doug Rabson Cc: Daniel Eischen , current@freebsd.org Subject: Re: [PATCH: libc]Re: gnome on current References: <20021030220614.R22480-100000@herring.nlsystems.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit 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 Doug Rabson wrote: > > You need to link the library against libc_r.so instead of libXThrStub.so. > > Probably not. Doing that breaks the existing 'feature' of being able to > use X11 in entirely non-threaded programs. I'm not sure whether that is > acceptable. It also stops programs from being able to select between > several thread implementations, of which -current has two. > > 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. OK... I guess I don't understand the problem. If you are not compiling threaded programs for use with X, and X itself is not threaded, then why the heck was the threads stuff there in the first place? If X itself uses threads, then you need to use threads: there's no option in the matter. If libX11.so does not reference, the threads symbols, who cares? If libX11.so *does* reference the threads symbols, then they need to be there. You can't have a library that's sort of threaded and sort of not threaded: pick one. If you want a seperate libdlopen, then I can help you: I did some of the code necessary to implement this already, but stopped because there needs to be a change to the constructor arguments to pass the address of the arg list down to the constructors, so you can use a constructor section in a linker set to do the init that's necessary to get at the symbols. I didn't want to have to fight the rest of you to get that mod into libc and the crt0 code. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message