1 /* 2 * End of configuration stuff for PD ksh. 3 * 4 * RCSid: $Id$ 5 */ 6 7 #if defined(EMACS) || defined(VI) 8 # define EDIT 9 #else 10 # undef EDIT 11 #endif 12 13 /* Editing implies history */ 14 #if defined(EDIT) && !defined(HISTORY) 15 # define HISTORY 16 #endif /* EDIT */ 17 18 /* 19 * if you don't have mmap() you can't use Peter Collinson's history 20 * mechanism. If that is the case, then define EASY_HISTORY 21 */ 22 #if defined(HISTORY) && (!defined(COMPLEX_HISTORY) || !defined(HAVE_MMAP) || !defined(HAVE_FLOCK)) 23 # undef COMPLEX_HISTORY 24 # define EASY_HISTORY /* sjg's trivial history file */ 25 #endif 26 27 /* Can we safely catch sigchld and wait for processes? */ 28 #if (defined(HAVE_WAITPID) || defined(HAVE_WAIT3)) \ 29 && (defined(POSIX_SIGNALS) || defined(BSD42_SIGNALS)) 30 # define JOB_SIGS 31 #endif 32 33 #if !defined(JOB_SIGS) || !(defined(POSIX_PGRP) || defined(BSD_PGRP)) 34 # undef JOBS /* if no JOB_SIGS, no job control support */ 35 #endif 36 37 /* pdksh assumes system calls return EINTR if a signal happened (this so 38 * the signal handler doesn't have to longjmp()). I don't know if this 39 * happens (or can be made to happen) with sigset() et. al. (the bsd41 signal 40 * routines), so, the autoconf stuff checks what they do and defines 41 * SIGNALS_DONT_INTERRUPT if signals don't interrupt read(). 42 * If SIGNALS_DONT_INTERRUPT isn't defined and your compiler chokes on this, 43 * delete the hash in front of the error (and file a bug report). 44 */ 45 #ifdef SIGNALS_DONT_INTERRUPT 46 # error pdksh needs interruptable system calls. 47 #endif /* SIGNALS_DONT_INTERRUPT */ 48 49 #ifdef HAVE_GCC_FUNC_ATTR 50 # define GCC_FUNC_ATTR(x) __attribute__((x)) 51 # define GCC_FUNC_ATTR2(x,y) __attribute__((x,y)) 52 #else 53 # define GCC_FUNC_ATTR(x) 54 # define GCC_FUNC_ATTR2(x,y) 55 #endif /* HAVE_GCC_FUNC_ATTR */ 56