os_dep.c: Use the POSIX signal API in preference to the BSD API.
* os_dep.c: Use the POSIX signal API in preference to the BSD API. Generate a compilation error if neither the POSIX nor BSD APIs can be detected. From-SVN: r154747
This commit is contained in:
parent
7abe582f9d
commit
1f67f80309
@ -1,3 +1,9 @@
|
||||
2009-11-30 Ben Elliston <bje@au.ibm.com>
|
||||
|
||||
* os_dep.c: Use the POSIX signal API in preference to the BSD API.
|
||||
Generate a compilation error if neither the POSIX nor BSD APIs can
|
||||
be detected.
|
||||
|
||||
2009-09-11 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
|
||||
|
||||
* Makefile.am (libgcjgc_la_LINK, gctest_LINK): New.
|
||||
|
@ -501,7 +501,13 @@ void GC_enable_signals(void)
|
||||
&& !defined(MACOS) && !defined(DJGPP) && !defined(DOS4GW) \
|
||||
&& !defined(NOSYS) && !defined(ECOS)
|
||||
|
||||
# if defined(sigmask) && !defined(UTS4) && !defined(HURD)
|
||||
# if defined(SIG_BLOCK)
|
||||
/* Use POSIX/SYSV interface */
|
||||
# define SIGSET_T sigset_t
|
||||
# define SIG_DEL(set, signal) sigdelset(&(set), (signal))
|
||||
# define SIG_FILL(set) sigfillset(&set)
|
||||
# define SIGSETMASK(old, new) sigprocmask(SIG_SETMASK, &(new), &(old))
|
||||
# elif defined(sigmask) && !defined(UTS4) && !defined(HURD)
|
||||
/* Use the traditional BSD interface */
|
||||
# define SIGSET_T int
|
||||
# define SIG_DEL(set, signal) (set) &= ~(sigmask(signal))
|
||||
@ -511,11 +517,7 @@ void GC_enable_signals(void)
|
||||
/* a signal 32. */
|
||||
# define SIGSETMASK(old, new) (old) = sigsetmask(new)
|
||||
# else
|
||||
/* Use POSIX/SYSV interface */
|
||||
# define SIGSET_T sigset_t
|
||||
# define SIG_DEL(set, signal) sigdelset(&(set), (signal))
|
||||
# define SIG_FILL(set) sigfillset(&set)
|
||||
# define SIGSETMASK(old, new) sigprocmask(SIG_SETMASK, &(new), &(old))
|
||||
# error undetectable signal API
|
||||
# endif
|
||||
|
||||
static GC_bool mask_initialized = FALSE;
|
||||
|
Loading…
Reference in New Issue
Block a user