From owner-freebsd-current Wed Jan 24 10:39: 8 2001 Delivered-To: freebsd-current@freebsd.org Received: from blizzard.sabbo.net (ns.sabbo.net [193.193.218.18]) by hub.freebsd.org (Postfix) with ESMTP id 7F51F37B400; Wed, 24 Jan 2001 10:38:16 -0800 (PST) Received: from vic.sabbo.net (root@vic.sabbo.net [193.193.218.112]) by blizzard.sabbo.net (8.10.1/8.10.1) with ESMTP id f0OIbmT02809; Wed, 24 Jan 2001 20:37:51 +0200 Received: from FreeBSD.org (big_brother.vega.com [192.168.1.1]) by vic.sabbo.net (8.11.1/8.9.3) with ESMTP id f0OIbp603173; Wed, 24 Jan 2001 20:37:51 +0200 (EET) (envelope-from sobomax@FreeBSD.org) Message-ID: <3A6F20EE.15B78584@FreeBSD.org> Date: Wed, 24 Jan 2001 20:37:34 +0200 From: Maxim Sobolev Organization: Vega International Capital X-Mailer: Mozilla 4.76 [en] (WinNT; U) X-Accept-Language: uk,ru,en MIME-Version: 1.0 To: Dan Nelson Cc: Daniel Eischen , Alfred Perlstein , current@FreeBSD.org, ports@FreeBSD.org Subject: Re: HEADS UP: libc/libc_r changes require rebuild of threaded apps References: <20010124084058.S26076@fw.wintelcom.net> <20010124123147.A2215@dan.emsphone.com> Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Dan Nelson wrote: > In the last episode (Jan 24), Daniel Eischen said: > > On Wed, 24 Jan 2001, Alfred Perlstein wrote: > > > * Daniel M. Eischen [010124 05:26] wrote: > > > > As discussed a few days ago, I've just committed the changes to libc > > > > and libc_r to allow them to be linked together via -lc_r. If you're > > > > running -current and have any threaded apps built using libc_r.so.5, > > > > you'll need to rebuild them without the -pthread option using -lc_r. > > > > > > > > For porters, the __FreeBSD_version has been bumped to 500016 to > > > > reflect the above change. > > > > > > This is ambiguous, can you provide old/new examples of how to > > > compile/link a single C source file? > > > > What's not clear ;-) Use -lc_r instead of -pthread. > > > > gcc -Wall -o foo foo.c -lc_r > > > > The old way was: > > > > gcc -Wall -D_THREAD_SAFE -o foo foo.c -pthread > > I thought the old way was just -pthread, and it would handle > everything. I did a quick scan of the devel/ and net/ branches of our > ports tree, and of 43 thread-using ports, 36 of the ports simply add > -pthread. Only 7 also add -D_THREAD_SAFE. It's not a very accurate estimate, as the magic can be in the distfile itself, i.e. properly written configure script or makefile may know that FreeBSD need a -pthread and -D_THREAD_SAFE. -Maxim To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message