From owner-freebsd-hackers Tue Apr 20 4: 6:27 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from cs.rpi.edu (mumble.cs.rpi.edu [128.213.8.16]) by hub.freebsd.org (Postfix) with ESMTP id 0FA391510C for ; Tue, 20 Apr 1999 04:06:25 -0700 (PDT) (envelope-from crossd@cs.rpi.edu) Received: from cs.rpi.edu (monica.cs.rpi.edu [128.213.7.2]) by cs.rpi.edu (8.9.1/8.9.1) with ESMTP id HAA14512; Tue, 20 Apr 1999 07:03:55 -0400 (EDT) Message-Id: <199904201103.HAA14512@cs.rpi.edu> To: Dan Moschuk Cc: "David E. Cross" , hackers@freebsd.org, crossd@cs.rpi.edu Subject: Re: -lpthread In-Reply-To: Message from Dan Moschuk of "Tue, 20 Apr 1999 02:06:55 EDT." <19990420020654.A51944@trinsec.com> Date: Tue, 20 Apr 1999 07:03:54 -0400 From: "David E. Cross" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > | Can we have it so that '-lpthread' accomplishes the same as '-lc_r' in > | terms of allowing threaded programs to link/run correctly? As was pointed > | out to me recently '-lc_r' for pthread support is a bit non-standard. > > What's wrong with the -pthread option to gcc? (egcs as well?) From FreeBSD: A FreeBSD specific option ... gcc -pthread .... ^^^^^^^^^^^^^^^^ From Solaris 2.6: POSIX cc [ flag ... ] file ... -lpthread [ library ... ] ^^^^^^^^^ From Irix 6.5.2f: cc -D_POSIX_C_SOURCE=199506L app.c -llib0 -llib1 ... -lpthread ^^^^^^^^^ It was just brought to my attention that our use of -lc_r was non-standard. Solaris, Irix, Linux, and I believe even AIX all use -lpthread. -- David Cross | email: crossd@cs.rpi.edu Systems Administrator/Research Programmer | Web: http://www.cs.rpi.edu/~crossd Rensselaer Polytechnic Institute, | Ph: 518.276.2860 Department of Computer Science | Fax: 518.276.4033 I speak only for myself. | WinNT:Linux::Linux:FreeBSD To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message