From owner-freebsd-bugs Fri Mar 15 7:10:18 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id DA1BC37B419 for ; Fri, 15 Mar 2002 07:10:01 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g2FFA1566047; Fri, 15 Mar 2002 07:10:01 -0800 (PST) (envelope-from gnats) Received: from milady.bbn.com (milady-de1.bbn.com [128.33.14.195]) by hub.freebsd.org (Postfix) with ESMTP id F3C8237B400 for ; Fri, 15 Mar 2002 07:05:28 -0800 (PST) Received: (from crodrigu@localhost) by milady.bbn.com (8.11.3/8.11.3) id g2FFPN634379; Fri, 15 Mar 2002 10:25:23 -0500 (EST) (envelope-from crodrigu) Message-Id: <200203151525.g2FFPN634379@milady.bbn.com> Date: Fri, 15 Mar 2002 10:25:23 -0500 (EST) From: Craig Rodrigues Reply-To: crodrigu@milady.bbn.com To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: misc/35924: signal.h does not check for _POSIX_REALTIME_SIGNALS Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 35924 >Category: misc >Synopsis: signal.h does not check for _POSIX_REALTIME_SIGNALS >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Mar 15 07:10:01 PST 2002 >Closed-Date: >Last-Modified: >Originator: Craig Rodrigues >Release: FreeBSD 4.3-RELEASE i386 >Organization: BBN >Environment: System: FreeBSD milady.bbn.com 4.3-RELEASE FreeBSD 4.3-RELEASE #0: Tue Sep 18 18:09:45 EDT 2001 crodrigu@milady.bbn.com:/usr/home/crodrigu/kame/freebsd4/sys/compile/CONFIGFILE i386 >Description: >How-To-Repeat: should only define sigqueue(), sigwaitinfo(), sigtimedwait() if _POSIX_REALTIME_SIGNALS is defined. This is a standard preprocessor constant mentioned in the latest POSIX standard: http://www.opengroup.org/onlinepubs/007904975/basedefs/unistd.h.html#tag_13_80 Right now, if I compile a program: #include int main(int argc, char *argv[]) { sigqueue(0,0,(union sigval)0); sigtimedwait((sigset_t *)0, (siginfo_t *)0, (struct timespec *)0); sigwaitinfo((sigset_t *)0, (siginfo_t *)0); return 0; } I get link-time errors. The solution to this problem was mentioned by Terry Lambert on freebsd-hackers: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=278142+0+current/freebsd-hackers I think that the FreeBSD signal.h should check for _POSIX_REALTIME_SIGNALS. It is defined in the POSIX standard, and when (if) POSIX RT signal support is fully integrated into FreeBSD, it can be defined. >Fix: Index: signal.h =================================================================== RCS file: /home/ncvs/src/include/signal.h,v retrieving revision 1.15 diff -u -r1.15 signal.h --- signal.h 2002/02/17 19:21:42 1.15 +++ signal.h 2002/03/15 14:56:54 @@ -66,7 +66,7 @@ int sigwait __P((const sigset_t *, int *)); -#ifdef _P1003_1B_VISIBLE +#ifdef _POSIX_REALTIME_SIGNALS __BEGIN_DECLS int sigqueue __P((_BSD_PID_T_, int, const union sigval)); >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message