1#ifndef _SIGNAL_H_ 2#define _SIGNAL_H_ 3 4#include "_ansi.h" 5#include <sys/signal.h> 6 7_BEGIN_STD_C 8 9 /* Indicate that we honor AEABI portability if requested. */ 10#if defined _AEABI_PORTABILITY_LEVEL && _AEABI_PORTABILITY_LEVEL != 0 && !defined _AEABI_PORTABLE 11# define _AEABI_PORTABLE 12#endif 13 14typedef int sig_atomic_t; /* Atomic entity type (ANSI) */ 15#ifndef _POSIX_SOURCE 16typedef _sig_func_ptr sighandler_t; /* glibc naming */ 17#endif /* !_POSIX_SOURCE */ 18 19#ifdef _AEABI_PORTABLE 20void _EXFUN(__aeabi_SIG_DFL, (int)); 21void _EXFUN(__aeabi_SIG_IGN, (int)); 22void _EXFUN(__aeabi_SIG_ERR, (int)); 23 24#define SIG_DFL (__aeabi_SIG_DFL) 25#define SIG_IGN (__aeabi_SIG_IGN) 26#define SIG_ERR (__aeabi_SIG_ERR) 27#else 28#define SIG_DFL ((_sig_func_ptr)0) /* Default action */ 29#define SIG_IGN ((_sig_func_ptr)1) /* Ignore action */ 30#define SIG_ERR ((_sig_func_ptr)-1) /* Error return */ 31#endif 32 33struct _reent; 34 35_sig_func_ptr _EXFUN(_signal_r, (struct _reent *, int, _sig_func_ptr)); 36int _EXFUN(_raise_r, (struct _reent *, int)); 37 38#ifndef _REENT_ONLY 39_sig_func_ptr _EXFUN(signal, (int, _sig_func_ptr)); 40int _EXFUN(raise, (int)); 41#endif 42 43_END_STD_C 44 45#endif /* _SIGNAL_H_ */ 46