1*b4dd7d09SAndy Fiddaman 2*b4dd7d09SAndy Fiddaman/* : : generated by proto : : */ 3*b4dd7d09SAndy Fiddaman/* : : generated from contrib/ast/src/lib/libast/features/sig.sh by iffe version 2012-07-17 : : */ 4*b4dd7d09SAndy Fiddaman#ifndef _def_sig_ast 5*b4dd7d09SAndy Fiddaman#if !defined(__PROTO__) 6*b4dd7d09SAndy Fiddaman# if defined(__STDC__) || defined(__cplusplus) || defined(_proto) || defined(c_plusplus) 7*b4dd7d09SAndy Fiddaman# if defined(__cplusplus) 8*b4dd7d09SAndy Fiddaman# define __LINKAGE__ "C" 9*b4dd7d09SAndy Fiddaman# else 10*b4dd7d09SAndy Fiddaman# define __LINKAGE__ 11*b4dd7d09SAndy Fiddaman# endif 12*b4dd7d09SAndy Fiddaman# define __STDARG__ 13*b4dd7d09SAndy Fiddaman# define __PROTO__(x) x 14*b4dd7d09SAndy Fiddaman# define __OTORP__(x) 15*b4dd7d09SAndy Fiddaman# define __PARAM__(n,o) n 16*b4dd7d09SAndy Fiddaman# if !defined(__STDC__) && !defined(__cplusplus) 17*b4dd7d09SAndy Fiddaman# if !defined(c_plusplus) 18*b4dd7d09SAndy Fiddaman# define const 19*b4dd7d09SAndy Fiddaman# endif 20*b4dd7d09SAndy Fiddaman# define signed 21*b4dd7d09SAndy Fiddaman# define void int 22*b4dd7d09SAndy Fiddaman# define volatile 23*b4dd7d09SAndy Fiddaman# define __V_ char 24*b4dd7d09SAndy Fiddaman# else 25*b4dd7d09SAndy Fiddaman# define __V_ void 26*b4dd7d09SAndy Fiddaman# endif 27*b4dd7d09SAndy Fiddaman# else 28*b4dd7d09SAndy Fiddaman# define __PROTO__(x) () 29*b4dd7d09SAndy Fiddaman# define __OTORP__(x) x 30*b4dd7d09SAndy Fiddaman# define __PARAM__(n,o) o 31*b4dd7d09SAndy Fiddaman# define __LINKAGE__ 32*b4dd7d09SAndy Fiddaman# define __V_ char 33*b4dd7d09SAndy Fiddaman# define const 34*b4dd7d09SAndy Fiddaman# define signed 35*b4dd7d09SAndy Fiddaman# define void int 36*b4dd7d09SAndy Fiddaman# define volatile 37*b4dd7d09SAndy Fiddaman# endif 38*b4dd7d09SAndy Fiddaman# define __MANGLE__ __LINKAGE__ 39*b4dd7d09SAndy Fiddaman# if defined(__cplusplus) || defined(c_plusplus) 40*b4dd7d09SAndy Fiddaman# define __VARARG__ ... 41*b4dd7d09SAndy Fiddaman# else 42*b4dd7d09SAndy Fiddaman# define __VARARG__ 43*b4dd7d09SAndy Fiddaman# endif 44*b4dd7d09SAndy Fiddaman# if defined(__STDARG__) 45*b4dd7d09SAndy Fiddaman# define __VA_START__(p,a) va_start(p,a) 46*b4dd7d09SAndy Fiddaman# else 47*b4dd7d09SAndy Fiddaman# define __VA_START__(p,a) va_start(p) 48*b4dd7d09SAndy Fiddaman# endif 49*b4dd7d09SAndy Fiddaman# if !defined(__INLINE__) 50*b4dd7d09SAndy Fiddaman# if defined(__cplusplus) 51*b4dd7d09SAndy Fiddaman# define __INLINE__ extern __MANGLE__ inline 52*b4dd7d09SAndy Fiddaman# else 53*b4dd7d09SAndy Fiddaman# if defined(_WIN32) && !defined(__GNUC__) 54*b4dd7d09SAndy Fiddaman# define __INLINE__ __inline 55*b4dd7d09SAndy Fiddaman# endif 56*b4dd7d09SAndy Fiddaman# endif 57*b4dd7d09SAndy Fiddaman# endif 58*b4dd7d09SAndy Fiddaman#endif 59*b4dd7d09SAndy Fiddaman#if !defined(__LINKAGE__) 60*b4dd7d09SAndy Fiddaman#define __LINKAGE__ /* 2004-08-11 transition */ 61*b4dd7d09SAndy Fiddaman#endif 62*b4dd7d09SAndy Fiddaman 63*b4dd7d09SAndy Fiddaman#define _def_sig_ast 1 64*b4dd7d09SAndy Fiddaman#define _sys_types 1 /* #include <sys/types.h> ok */ 65*b4dd7d09SAndy Fiddaman 66*b4dd7d09SAndy Fiddaman#define sig_info _sig_info_ 67*b4dd7d09SAndy Fiddaman 68*b4dd7d09SAndy Fiddaman#if defined(__STDPP__directive) && defined(__STDPP__hide) 69*b4dd7d09SAndy Fiddaman__STDPP__directive pragma pp:hide kill killpg 70*b4dd7d09SAndy Fiddaman#else 71*b4dd7d09SAndy Fiddaman#define kill ______kill 72*b4dd7d09SAndy Fiddaman#define killpg ______killpg 73*b4dd7d09SAndy Fiddaman#endif 74*b4dd7d09SAndy Fiddaman#include <signal.h> 75*b4dd7d09SAndy Fiddaman#if defined(__STDPP__directive) && defined(__STDPP__hide) 76*b4dd7d09SAndy Fiddaman__STDPP__directive pragma pp:nohide kill killpg 77*b4dd7d09SAndy Fiddaman#else 78*b4dd7d09SAndy Fiddaman#undef kill 79*b4dd7d09SAndy Fiddaman#undef killpg 80*b4dd7d09SAndy Fiddaman#endif 81*b4dd7d09SAndy Fiddaman#ifndef sigmask 82*b4dd7d09SAndy Fiddaman#define sigmask(s) (1<<((s)-1)) 83*b4dd7d09SAndy Fiddaman#endif 84*b4dd7d09SAndy Fiddamantypedef void (*Sig_handler_t) __PROTO__((int)); 85*b4dd7d09SAndy Fiddaman 86*b4dd7d09SAndy Fiddaman 87*b4dd7d09SAndy Fiddaman#define Handler_t Sig_handler_t 88*b4dd7d09SAndy Fiddaman 89*b4dd7d09SAndy Fiddaman#define SIG_REG_PENDING (-1) 90*b4dd7d09SAndy Fiddaman#define SIG_REG_POP 0 91*b4dd7d09SAndy Fiddaman#define SIG_REG_EXEC 00001 92*b4dd7d09SAndy Fiddaman#define SIG_REG_PROC 00002 93*b4dd7d09SAndy Fiddaman#define SIG_REG_TERM 00004 94*b4dd7d09SAndy Fiddaman#define SIG_REG_ALL 00777 95*b4dd7d09SAndy Fiddaman#define SIG_REG_SET 01000 96*b4dd7d09SAndy Fiddaman 97*b4dd7d09SAndy Fiddamantypedef struct 98*b4dd7d09SAndy Fiddaman{ 99*b4dd7d09SAndy Fiddaman char** name; 100*b4dd7d09SAndy Fiddaman char** text; 101*b4dd7d09SAndy Fiddaman int sigmax; 102*b4dd7d09SAndy Fiddaman} Sig_info_t; 103*b4dd7d09SAndy Fiddaman 104*b4dd7d09SAndy Fiddamanextern __MANGLE__ int kill __PROTO__((pid_t, int)); 105*b4dd7d09SAndy Fiddamanextern __MANGLE__ int killpg __PROTO__((pid_t, int)); 106*b4dd7d09SAndy Fiddaman 107*b4dd7d09SAndy Fiddaman#if _BLD_ast && defined(__EXPORT__) 108*b4dd7d09SAndy Fiddaman#undef __MANGLE__ 109*b4dd7d09SAndy Fiddaman#define __MANGLE__ __LINKAGE__ __EXPORT__ 110*b4dd7d09SAndy Fiddaman#endif 111*b4dd7d09SAndy Fiddaman#if !_BLD_ast && defined(__IMPORT__) 112*b4dd7d09SAndy Fiddaman#undef __MANGLE__ 113*b4dd7d09SAndy Fiddaman#define __MANGLE__ __LINKAGE__ __IMPORT__ 114*b4dd7d09SAndy Fiddaman#endif 115*b4dd7d09SAndy Fiddaman 116*b4dd7d09SAndy Fiddamanextern __MANGLE__ Sig_info_t sig_info; 117*b4dd7d09SAndy Fiddaman 118*b4dd7d09SAndy Fiddaman#undef __MANGLE__ 119*b4dd7d09SAndy Fiddaman#define __MANGLE__ __LINKAGE__ 120*b4dd7d09SAndy Fiddaman 121*b4dd7d09SAndy Fiddaman#if _lib_sigflag && _npt_sigflag 122*b4dd7d09SAndy Fiddamanextern __MANGLE__ int sigflag __PROTO__((int, int, int)); 123*b4dd7d09SAndy Fiddaman#endif 124*b4dd7d09SAndy Fiddaman 125*b4dd7d09SAndy Fiddaman#if _BLD_ast && defined(__EXPORT__) 126*b4dd7d09SAndy Fiddaman#undef __MANGLE__ 127*b4dd7d09SAndy Fiddaman#define __MANGLE__ __LINKAGE__ __EXPORT__ 128*b4dd7d09SAndy Fiddaman#endif 129*b4dd7d09SAndy Fiddaman 130*b4dd7d09SAndy Fiddaman#if !_lib_sigflag 131*b4dd7d09SAndy Fiddamanextern __MANGLE__ int sigflag __PROTO__((int, int, int)); 132*b4dd7d09SAndy Fiddaman#endif 133*b4dd7d09SAndy Fiddamanextern __MANGLE__ int sigcritical __PROTO__((int)); 134*b4dd7d09SAndy Fiddamanextern __MANGLE__ int sigunblock __PROTO__((int)); 135*b4dd7d09SAndy Fiddaman 136*b4dd7d09SAndy Fiddaman#undef __MANGLE__ 137*b4dd7d09SAndy Fiddaman#define __MANGLE__ __LINKAGE__ 138*b4dd7d09SAndy Fiddaman#endif 139