From owner-freebsd-current Sat Jun 13 14:42:50 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA12754 for freebsd-current-outgoing; Sat, 13 Jun 1998 14:42:50 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from cimlogic.com.au (cimlog.lnk.telstra.net [139.130.51.31]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA12748 for ; Sat, 13 Jun 1998 14:42:46 -0700 (PDT) (envelope-from jb@cimlogic.com.au) Received: (from jb@localhost) by cimlogic.com.au (8.8.8/8.8.7) id HAA00949; Sun, 14 Jun 1998 07:47:38 +1000 (EST) (envelope-from jb) From: John Birrell Message-Id: <199806132147.HAA00949@cimlogic.com.au> Subject: Re: Undefined symbol `xxx' referenced (use libc_r ?) In-Reply-To: from Nanbor Wang at "Jun 13, 98 12:02:24 pm" To: nanbor@cs.wustl.edu (Nanbor Wang) Date: Sun, 14 Jun 1998 07:47:37 +1000 (EST) Cc: freebsd-current@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL40 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Nanbor Wang wrote: > Hi, > > nanbor@fennec build/threaded/tests> make > g++ -w -fno-strict-prototypes -D_THREAD_SAFE -O2 -g -fno-implicit-templates -I. -I/home/nanbor/ACE_wrappers/build/threaded -o Env_Value_Test .obj/Env_Value_Test.o -L/home/nanbor/ACE_wrappers/build/threaded/ace -L./ -lACE -lc_r -lstdc++ -lcompat > .obj/Env_Value_Test.o: Undefined symbol `_mkdir' referenced (use -lc_r ?) > ld: Spurious undefined symbols: # undefined symbols 1, reported 0 > gmake: *** [Env_Value_Test] Error 1 > > What does it mean? Any hints? Link with -pthread and don't add -lc_r in the middle of the libraries. You are linking partly against libc_r and partly against libc. Don't do that. -- John Birrell - jb@cimlogic.com.au; jb@freebsd.org http://www.cimlogic.com.au/ CIMlogic Pty Ltd, GPO Box 117A, Melbourne Vic 3001, Australia +61 418 353 137 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message