diff --git a/components/libc/compilers/common/include/sys/signal.h b/components/libc/compilers/common/include/sys/signal.h index b92276ecb18f4bdef510de6a350bf697ba3e5a27..1a3b9c1beb5717dfa470f832ad9939a5c8ad8fb3 100644 --- a/components/libc/compilers/common/include/sys/signal.h +++ b/components/libc/compilers/common/include/sys/signal.h @@ -139,8 +139,6 @@ int sigaction(int signum, const struct sigaction *act, struct sigaction *oldact) #define SIGRTMAX 31 #define NSIG 32 -#include - #elif defined(__IAR_SYSTEMS_ICC__) #define SIGHUP 1 #define SIGINT 2 @@ -175,8 +173,6 @@ int sigaction(int signum, const struct sigaction *act, struct sigaction *oldact) #define SIGRTMAX 31 #define NSIG 32 -#include - #elif defined(__GNUC__) #define SIGHUP 1 /* hangup */ #define SIGINT 2 /* interrupt */ @@ -213,13 +209,25 @@ int sigaction(int signum, const struct sigaction *act, struct sigaction *oldact) #define SIGUSR1 30 /* user defined signal 1 */ #define SIGUSR2 31 /* user defined signal 2 */ #define NSIG 32 /* signal 0 implied */ +#endif /* __ARMCC_VERSION */ -#if defined(RT_USING_NEWLIBC) +#ifndef RT_USING_MUSLLIBC /* Some applications take advantage of the fact that * and are equivalent in glibc. Allow for that here. */ #include -#endif /* defined(RT_USING_NEWLIBC) */ -#endif /* __ARMCC_VERSION */ +#endif /* RT_USING_MUSLLIBC */ + +#ifndef SIG_ERR +#define SIG_ERR ((void (*)(int))-1) +#endif + +#ifndef SIG_DFL +#define SIG_DFL ((void (*)(int)) 0) +#endif + +#ifndef SIG_IGN +#define SIG_IGN ((void (*)(int)) 1) +#endif #ifdef __cplusplus }