From owner-freebsd-current@FreeBSD.ORG Tue Sep 23 23:01:03 2003 Return-Path: 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 229F916A4BF; Tue, 23 Sep 2003 23:01:03 -0700 (PDT) Received: from pcwin002.win.tue.nl (pcwin002.win.tue.nl [131.155.71.72]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3FB5C44011; Tue, 23 Sep 2003 23:01:01 -0700 (PDT) (envelope-from stijn@pcwin002.win.tue.nl) Received: from pcwin002.win.tue.nl (localhost [127.0.0.1]) by pcwin002.win.tue.nl (8.12.10/8.12.10) with ESMTP id h8O61ZLY000166; Wed, 24 Sep 2003 08:01:35 +0200 (CEST) (envelope-from stijn@pcwin002.win.tue.nl) Received: (from stijn@localhost) by pcwin002.win.tue.nl (8.12.10/8.12.10/Submit) id h8O61Znv000165; Wed, 24 Sep 2003 08:01:35 +0200 (CEST) (envelope-from stijn) Date: Wed, 24 Sep 2003 08:01:35 +0200 From: Stijn Hoop To: Daniel Eischen Message-ID: <20030924060135.GB95116@pcwin002.win.tue.nl> References: <20030924053413.GA28722@wombat.localnet> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="XOIedfhf+7KOe/yw" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.1i X-Bright-Idea: Let's abolish HTML mail! cc: ports@freebsd.org cc: jb@freebsd.org cc: current@freebsd.org cc: Kris Kennaway Subject: Re: Initial list of ports that fail due to -pthread X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Sep 2003 06:01:03 -0000 --XOIedfhf+7KOe/yw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 24, 2003 at 01:49:50AM -0400, Daniel Eischen wrote: > If FreeBSD wants to take the simple approach and only support > one thread library in ports (-pthread =3D=3D -lpthread) and not > make it selectable via PTHREAD_LIBS, then its not a problem. > It would be nice to be able to support all our thread > libraries, but I grow weary. Just an idea (I hope this hasn't been said before in the mega thread but at least I didn't get it this way): - fix all ports to respect PTHREAD_LIBS _ON THE LINKING STAGE_ (so no global search & replace, for it shouldn't be used in compile command line= s) - keep '-pthread' as a compiler option, which maps to a NOOP for compiling and '-lpthread' (aka libkse) for linking - set PTHREAD_LIBS to the default value of -pthread - allow PTHREAD_LIBS to be set to something other, e.g. '-lthr', in /etc/make.conf (or the make command line) What is the problem with this approach? You get both a 'standard' -pthread knob, _and_ the ability to select your threads library using ports. Third party apps that use -pthread will work. The only case in which some work has to be done by a FreeBSD user is when they want to link a non-ported third-party app with a library other than libpthread (libkse). --Stijn --=20 "Linux has many different distributions, meaning that you can probably find one that is exactly what you want (I even found one that looked like a Unix system)." -- Mike Meyer, from a posting at questions@freebsd.org --XOIedfhf+7KOe/yw Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (FreeBSD) iD8DBQE/cTM/Y3r/tLQmfWcRAjXTAJ90joiJrbS+t2lOnzXqCh0raCaC3gCfQscN kq+ntX2jVxm6LqwY846kBEg= =SCsI -----END PGP SIGNATURE----- --XOIedfhf+7KOe/yw--