Bug 8443 - <setjmp.h> missing prototypes with -DPOSIX_C_SOURCE=199506
<setjmp.h> missing prototypes with -DPOSIX_C_SOURCE=199506
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: glibc (Show other bugs)
6.1
All Linux
medium Severity medium
: ---
: ---
Assigned To: Cristian Gafton
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-01-13 09:54 EST by Jay Turner
Modified: 2016-11-24 07:26 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-01-14 15:33:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Glen Foster 2000-01-13 09:54:21 EST
According to the OpenGroup VSX-PCTS suite, <setjmp.h> should have function
prototypes for longjmp() and siglongjmp() in the compilation namespace
when #including the file and using the following sets of compiler flags:
	(a) -DPOSIX_C_SOURCE=199506
	(b) -DPOSIX_C_SOURCE=199506 -DPOSIX_SOURCE

Appropriate excerpts from the test journal are as follows:
=====================================================================
200|4 3 17:56:44|TP Start
520|4 3 00005885 4 1|Feature test macros: -D_POSIX_C_SOURCE=199506
520|4 3 00005885 4 2|Compiler or run-time messages or results:
520|4 3 00005885 4 3|missing prototype for longjmp()
520|4 3 00005885 7 1|Feature test macros: -D_POSIX_C_SOURCE=199506
-D_POSIX_SOURCE
520|4 3 00005885 7 2|Compiler or run-time messages or results:
520|4 3 00005885 7 3|missing prototype for longjmp()
220|4 3 1 17:56:44|FAIL
200|4 4 17:56:44|TP Start
520|4 4 00005885 4 1|Feature test macros: -D_POSIX_C_SOURCE=199506
520|4 4 00005885 4 2|Compiler or run-time messages or results:
520|4 4 00005885 4 3|missing prototype for siglongjmp()
520|4 4 00005885 7 1|Feature test macros: -D_POSIX_C_SOURCE=199506
-D_POSIX_SOURCE
520|4 4 00005885 7 2|Compiler or run-time messages or results:
520|4 4 00005885 7 3|missing prototype for siglongjmp()
Comment 1 Cristian Gafton 2000-01-14 15:33:59 EST
This again works for me:

alien (gafton):~/src/glibc/proto>cat proto.c
#define POSIX_C_SOURCE 199506
#include <setjmp.h>

alien (gafton):~/src/glibc/proto>gcc -E proto.c -c | grep "longjmp"
extern void longjmp  (jmp_buf __env, int __val)
extern void _longjmp  (jmp_buf __env, int __val)
extern void siglongjmp  (sigjmp_buf __env, int __val)

Note You need to log in before you can comment on or make changes to this bug.