summaryrefslogtreecommitdiff
path: root/libc/signal
diff options
context:
space:
mode:
Diffstat (limited to 'libc/signal')
-rw-r--r--libc/signal/Makefile.in5
-rw-r--r--libc/signal/signal.c13
2 files changed, 9 insertions, 9 deletions
diff --git a/libc/signal/Makefile.in b/libc/signal/Makefile.in
index e930d7ef6..8e904535a 100644
--- a/libc/signal/Makefile.in
+++ b/libc/signal/Makefile.in
@@ -7,7 +7,7 @@
CSRC := allocrtsig.c killpg.c raise.c sigaction.c sigaddset.c sigandset.c \
sigblock.c sigdelset.c sigempty.c sigfillset.c siggetmask.c \
- sigintr.c sigisempty.c sigismem.c sigjmp.c signal.c \
+ sigisempty.c sigismem.c sigjmp.c signal.c \
sigorset.c sigpause.c sigsetmask.c sigsetops.c sigwait.c
ifeq ($(UCLIBC_HAS_OBSOLETE_BSD_SIGNAL),y)
CSRC += sighold.c sigignore.c sigrelse.c sigset.c
@@ -15,6 +15,9 @@ endif
ifeq ($(UCLIBC_HAS_OBSOLETE_SYSV_SIGNAL),y)
CSRC += sysv_signal.c
endif
+ifeq ($(UCLIBC_SUSV4_LEGACY),y)
+CSRC += sigintr.c
+endif
ifneq ($(strip $(ARCH_OBJS)),)
CSRC := $(filter-out $(notdir $(ARCH_OBJS:.o=.c)),$(CSRC))
diff --git a/libc/signal/signal.c b/libc/signal/signal.c
index f3dfa33fc..644617c15 100644
--- a/libc/signal/signal.c
+++ b/libc/signal/signal.c
@@ -22,15 +22,12 @@
#include <signal.h>
#include <string.h> /* For the real memset prototype. */
-/* libc_hidden_proto(sigaction) */
-
sigset_t _sigintr attribute_hidden; /* Set by siginterrupt. */
/* Set the handler for the signal SIG to HANDLER,
returning the old handler, or SIG_ERR on error. */
-extern __typeof(bsd_signal) __bsd_signal;
-attribute_hidden __sighandler_t
-__bsd_signal (int sig, __sighandler_t handler)
+__sighandler_t
+signal (int sig, __sighandler_t handler)
{
struct sigaction act, oact;
@@ -51,7 +48,7 @@ __bsd_signal (int sig, __sighandler_t handler)
return oact.sa_handler;
}
-strong_alias(__bsd_signal,bsd_signal)
-/* libc_hidden_proto(signal) */
-strong_alias(__bsd_signal,signal)
libc_hidden_def(signal)
+#ifdef __UCLIBC_SUSV3_LEGACY__
+strong_alias(signal,bsd_signal)
+#endif