From owner-freebsd-questions Sun Mar 9 14:50:23 2003 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CCB2737B401 for ; Sun, 9 Mar 2003 14:50:22 -0800 (PST) Received: from smtp.web.de (smtp02.web.de [217.72.192.151]) by mx1.FreeBSD.org (Postfix) with ESMTP id D3FF843F3F for ; Sun, 9 Mar 2003 14:50:21 -0800 (PST) (envelope-from coolaz@web.de) Received: from [213.191.79.140] (helo=thunderBSD.tld) by smtp.web.de with esmtp (WEB.DE(Exim) 4.97 #53) id 18s9cU-0001Bo-00; Sun, 09 Mar 2003 23:50:14 +0100 Received: by thunderBSD.tld (Postfix, from userid 1001) id 03ED9A7EE; Sun, 9 Mar 2003 23:53:38 +0100 (CET) Date: Sun, 9 Mar 2003 23:53:37 +0100 From: Martin Kulas To: Aaron Walker Cc: freebsd-questions@freebsd.org Subject: Re: undefined reference to 'pthread_detach' Message-ID: <20030309225337.GA636@thunderBSD> Reply-To: coolaz@web.de Mail-Followup-To: Aaron Walker , freebsd-questions@freebsd.org References: <1047120959.3805.4.camel@ka0ttic> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1047120959.3805.4.camel@ka0ttic> User-Agent: Mutt/1.4i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Mar 08, 2003 at 05:55:58AM -0500, Aaron Walker wrote: > I was writing a little test threads program, and when I try to compile I > get this: > > $gcc -o mttest mttest.c -lpthread > /tmp/cco18ppz.o: In function `thread_func': > /tmp/cco18ppz.o(.text+0xd2): undefined reference to `pthread_detach' > There is no lib called pthread: use -pthread instead (see man pthread for more) martin To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message