VSX-PCTS finds a problem with <stdio.h> - similar to defect #8443 and #8444. The test expects to see functional prototypes for abort(), abs(), and exit() when compiling with the following 2 option sets: (a) -DPOSIX_C_SOURCE=199506 (b) -DPOSIX_C_SOURCE=199506 -DPOSIX_SOURCE Appropriate lines from testing journal are as follows: ====================================================================== 520|7 4 00002477 4 1|Feature test macros: -D_POSIX_C_SOURCE=199506 520|7 4 00002477 4 2|Compiler or run-time messages or results: 520|7 4 00002477 4 3|missing prototype for abort() 520|7 4 00002477 7 1|Feature test macros: -D_POSIX_C_SOURCE=199506 -D_POSIX_SOURCE 520|7 4 00002477 7 2|Compiler or run-time messages or results: 520|7 4 00002477 7 3|missing prototype for abort() 220|7 4 1 16:44:45|FAIL 200|7 5 16:44:45|TP Start 520|7 5 00002477 4 1|Feature test macros: -D_POSIX_C_SOURCE=199506 520|7 5 00002477 4 2|Compiler or run-time messages or results: 520|7 5 00002477 4 3|missing prototype for abs() 520|7 5 00002477 7 1|Feature test macros: -D_POSIX_C_SOURCE=199506 -D_POSIX_SOURCE 520|7 5 00002477 7 2|Compiler or run-time messages or results: 520|7 5 00002477 7 3|missing prototype for abs() [snip] ... and later on says: 520|7 11 00002477 4 1|Feature test macros: -D_POSIX_C_SOURCE=199506 520|7 11 00002477 4 2|Compiler or run-time messages or results: 520|7 11 00002477 4 3|missing prototype for exit() 520|7 11 00002477 7 1|Feature test macros: -D_POSIX_C_SOURCE=199506 -D_POSIX_SOURCE 520|7 11 00002477 7 2|Compiler or run-time messages or results: 520|7 11 00002477 7 3|missing prototype for exit()
This stuff works for me: alien (gafton):~/src/glibc/proto>cat proto.c #define DPOSIX_C_SOURCE 199506 #include <stdlib.h> alien (gafton):~/src/glibc/proto>gcc -E proto.c -c | grep "abort\|exit\|abs" extern void abort (void) __attribute__ ((__noreturn__)); extern int atexit (void (*__func) (void)) ; extern int __on_exit (void (*__func) (int __status, void * __arg), extern int on_exit (void (*__func) (int __status, void * __arg), extern void exit (int __status) __attribute__ ((__noreturn__)); extern int abs (int __x) __attribute__ ((__const__)); extern long int labs (long int __x) __attribute__ ((__const__));