diff options
author | Taru Karttunen <taruti@taruti.net> | 2011-03-30 15:46:40 +0300 |
---|---|---|
committer | Taru Karttunen <taruti@taruti.net> | 2011-03-30 15:46:40 +0300 |
commit | e5888a1ffdae813d7575f5fb02275c6bb07e5199 (patch) | |
tree | d8d51eac403f07814b9e936eed0c9a79195e2450 /sys/src/ape/cmd/pdksh/conf-end.h |
Import sources from 2011-03-30 iso image
Diffstat (limited to 'sys/src/ape/cmd/pdksh/conf-end.h')
-rwxr-xr-x | sys/src/ape/cmd/pdksh/conf-end.h | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/sys/src/ape/cmd/pdksh/conf-end.h b/sys/src/ape/cmd/pdksh/conf-end.h new file mode 100755 index 000000000..8cd487521 --- /dev/null +++ b/sys/src/ape/cmd/pdksh/conf-end.h @@ -0,0 +1,55 @@ +/* + * End of configuration stuff for PD ksh. + * + * RCSid: $Id$ + */ + +#if defined(EMACS) || defined(VI) +# define EDIT +#else +# undef EDIT +#endif + +/* Editing implies history */ +#if defined(EDIT) && !defined(HISTORY) +# define HISTORY +#endif /* EDIT */ + +/* + * if you don't have mmap() you can't use Peter Collinson's history + * mechanism. If that is the case, then define EASY_HISTORY + */ +#if defined(HISTORY) && (!defined(COMPLEX_HISTORY) || !defined(HAVE_MMAP) || !defined(HAVE_FLOCK)) +# undef COMPLEX_HISTORY +# define EASY_HISTORY /* sjg's trivial history file */ +#endif + +/* Can we safely catch sigchld and wait for processes? */ +#if (defined(HAVE_WAITPID) || defined(HAVE_WAIT3)) \ + && (defined(POSIX_SIGNALS) || defined(BSD42_SIGNALS)) +# define JOB_SIGS +#endif + +#if !defined(JOB_SIGS) || !(defined(POSIX_PGRP) || defined(BSD_PGRP)) +# undef JOBS /* if no JOB_SIGS, no job control support */ +#endif + +/* pdksh assumes system calls return EINTR if a signal happened (this so + * the signal handler doesn't have to longjmp()). I don't know if this + * happens (or can be made to happen) with sigset() et. al. (the bsd41 signal + * routines), so, the autoconf stuff checks what they do and defines + * SIGNALS_DONT_INTERRUPT if signals don't interrupt read(). + * If SIGNALS_DONT_INTERRUPT isn't defined and your compiler chokes on this, + * delete the hash in front of the error (and file a bug report). + */ +#ifdef SIGNALS_DONT_INTERRUPT + # error pdksh needs interruptable system calls. +#endif /* SIGNALS_DONT_INTERRUPT */ + +#ifdef HAVE_GCC_FUNC_ATTR +# define GCC_FUNC_ATTR(x) __attribute__((x)) +# define GCC_FUNC_ATTR2(x,y) __attribute__((x,y)) +#else +# define GCC_FUNC_ATTR(x) +# define GCC_FUNC_ATTR2(x,y) +#endif /* HAVE_GCC_FUNC_ATTR */ |