From owner-freebsd-current Fri Jan 7 16:36:16 2000 Delivered-To: freebsd-current@freebsd.org Received: from lor.watermarkgroup.com (lor.watermarkgroup.com [207.202.73.33]) by hub.freebsd.org (Postfix) with ESMTP id CD41714C13 for ; Fri, 7 Jan 2000 16:36:12 -0800 (PST) (envelope-from luoqi@watermarkgroup.com) Received: (from luoqi@localhost) by lor.watermarkgroup.com (8.8.8/8.8.8) id TAA05054; Fri, 7 Jan 2000 19:36:11 -0500 (EST) (envelope-from luoqi) Date: Fri, 7 Jan 2000 19:36:11 -0500 (EST) From: Luoqi Chen Message-Id: <200001080036.TAA05054@lor.watermarkgroup.com> To: current@FreeBSD.ORG, jasone@canonware.com Subject: Re: __sigisempty() undefined if "cc -g" used. Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > In an effort to chase down a libc_r bug, I compiled libc_r with CFLAGS=-g > (and later CFLAGS=-g3), but ran into linker problems as a result. > > blitz:~> gcc poll.c -pthread > /usr/lib/libc_r.so: undefined reference to `__sigisempty' > > Even the simplest of C programs will get this linker error if using the > -pthread option. > > So, __sigisempty is an inline function, defined in > /usr/include/sys/signalvar.h: > > extern __inline int > __sigisempty(sigset_t *set) > { > int i; > > for (i = 0; i < _SIG_WORDS; i++) { > if (set->__bits[i]) > return (0); > } > return (1); > } > It doesn't make much sense to have an "extern" inline function, gcc probably was confused by this, change "extern" to "static" and try again. -lq To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message