From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by archone.tamu.edu id <45338>; Thu, 13 Feb 1992 23:20:05 -0600 From: Byron Rakitzis To: rc Subject: configuration parameters Message-Id: <92Feb13.232005cst.45338@archone.tamu.edu> Date: Thu, 13 Feb 1992 23:19:54 -0600 rc's configuration has become unweildy. I want to try something cleaner than that ugly makefile. Is the solution shown below satisfactory? (the file that follows replaces the current config.h:) /* * Configuration parameters for rc. Suggested defaults are at the bottom * of this file (you should probably look at those first to see if your * system matches one of them; you can search for the beginning of the * defaults section by looking for the string "#ifndef CUSTOM"). If you * want to override the suggested defaults, define the macro CUSTOM. #define CUSTOM */ /* * (Note that certain default settings redefine this macro) * DEFAULTPATH the default search path that rc uses when it is started * without either a PATH or path environment variable. You must pick * something sensible for your system if you don't like the path shown * below. */ #define DEFAULTPATH "/usr/ucb", "/usr/bin", "/bin", "." /* * Define the macro NODIRENT if your system has but not * . (e.g., NeXT-OS and RISCos) #define NODIRENT */ /* * Define the macro SVSIGS if your system has System V signal semantics, * i.e., if "slow" system calls are interrupted rather than resumed * after returning from an interrupt handler. (If you are not sure what * this means, see the man page for signal(2). In any case, it is probably * safe to leave this macro undefined.) #define SVSIGS */ /* * Define the macro NOCMDARG if you do not have /dev/fd or fifos on your * system. You may also want to define this if you have broken fifos. * For example, if you have a Sun with /tmp mounted as a ramdisk * (type "tmpfs") then you cannot use fifos in /tmp (sigh). #define NOCMDARG */ /* * Define the macro DEVFD if your system supports /dev/fd. #define DEVFD */ /* * Define the macro NOLIMITS if your system does not support Berkeley * limits. #define NOLIMITS */ /* * Define the macro NOSIGCLD if your system uses SIGCLD in the System * V way. (e.g., sgi's Irix) #define NOSIGCLD */ /* * Define the macro READLINE if you want rc to call GNU readline * instead of read(2) on interactive shells. #define READLINE */ /* * Define the macro EDITLINE if you want rc to call Simmule Turner's * readline-like library. (it's about 1/10 the size of GNU, but with * fewer options) Also uncomment the EDITLIB variable in the Makefile. #define EDITLINE */ /* * Define the macro NOEXECVE if your Unix does not interpret #! in the * kernel, and uncomment the EXECVE variable in the Makefile. #define NOEXECVE */ /* * If you want rc to default to some interpreter for files which don't * have a legal #! on the first line, define the macro DEFAULTINTERP. #define DEFAULTINTERP "/bin/sh" */ /* * If your /bin/sh (or another program you care about) rejects * environment variables with special characters in them, rc can put * out ugly variable names using [_0-9a-zA-Z] that encode the real * name; define PROTECT_ENV for this hack. (Known offenders: every * sh I have tried; SunOS (silently discards), NeXT (aborts with * error), SGI (aborts with error), Ultrix (sh seems to work, sh5 * aborts with error)) #define PROTECT_ENV */ /* Beginning of defaults section: */ #ifndef CUSTOM /* * Suggested settings for Sun, NeXT and sgi (machines here at TAMU): */ #ifdef NeXT #define NODIRENT #define PROTECT_ENV #define NOCMDARG #endif #ifdef sgi #define SVSIGS #define NOSIGCLD #define PROTECT_ENV #undef DEFAULTPATH #define DEFAULTPATH "/usr/bsd", "/usr/sbin", "/usr/bin", "/bin", "." #endif #ifdef sun #define PROTECT_ENV #undef DEFAULTPATH #define DEFAULTPATH "/usr/ucb", "/usr/bin", "." #endif /* * Suggested settings for HP300 running 4.3BSD-utah (DWS): */ #if defined(hp300) && !defined(hpux) #define NODIRENT #define NOCMDARG #define DEFAULTINTERP "/bin/sh" #define PROTECT_ENV #endif /* * Suggested settings for Ultrix */ #ifdef ultrix #define PROTECT_ENV #define DEFAULTINTERP "/bin/sh" /* so /bin/true can work */ #endif /* * Suggested settings for RiscOS 4.52 */ #ifdef host_mips #define NODIRENT #define PROTECT_ENV extern int errno; /* not defined in the mips !?!?! */ #endif #endif /* CUSTOM */