libc-5.4.44 w/ 2.1.90 headers still break SIGRTMAX (include/asm*/signal.h broken)

David Dyck (dcd@tc.fluke.com)
Sat, 21 Mar 1998 12:42:49 -0800


Earlier postings to linux-kernel have not fixed the signal.h file yet,
but perhaps this is because most linux-kernel users are using glibc2.
The problem doesn't show up if using glibc2, as glibc2 bring in its own
copy of the signals declarations that the user programs would see. On
linux that file can be found in the glibc2 configuration as:
sysdeps/unix/sysv/linux/signum.h

libc 5.4.44, as listed in the Changes file causes the
kernel include/asm*/signal.h file to be drawn into the
user program when the #include <signal.h>

This breaks the program listed at the end of this posting.

Who's responsible for include/asm*/signal.h?

If we want POSIX signals handling, perhaps we could
at least define SIGRTMAX based on a constant
that we know (perhaps SIGRTMIN+31)?

Or add
#ifdef __KERNEL__
or
#ifdef NOT_IMPLEMENTED_CORRECTLY_YET

around the declarations of SIGRTMIN and SIGRTMAX.

jd:dcd$ cat -n rtmax.c
1 #include <signal.h>
2
3 #include <stdio.h>
4 int main() {
5 printf("SIGRTMIN=%d\n", SIGRTMIN);
6 printf("SIGRTMAX=%d\n", SIGRTMAX);
7 }

jd:dcd$ gcc -O2 rtmax.c
rtmax.c: In function `main':
rtmax.c:6: `_NSIG' undeclared (first use this function)
rtmax.c:6: (Each undeclared identifier is reported only once
rtmax.c:6: for each function it appears in.)

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu