root/releases/1.6/0p2/config_h.SH

Revision 44, 10.5 KB (checked in by pennmush, 3 years ago)

PennMUSH 1.6.0p0 Archival

Line 
1case $CONFIG in
2'')
3    if test -f config.sh; then TOP=.;
4    elif test -f ../config.sh; then TOP=..;
5    elif test -f ../../config.sh; then TOP=../..;
6    elif test -f ../../../config.sh; then TOP=../../..;
7    elif test -f ../../../../config.sh; then TOP=../../../..;
8    else
9        echo "Can't find config.sh."; exit 1
10    fi
11    . $TOP/config.sh
12    ;;
13esac
14case "$0" in
15*/*) cd `expr X$0 : 'X\(.*\)/'` ;;
16esac
17echo "Extracting config.h (with variable substitutions)"
18sed <<!GROK!THIS! >config.h -e 's!^#undef!/\*#define!' -e 's!^#un-def!#undef!'
19/*
20 * This file was produced by running the config_h.SH script, which
21 * gets its values from config.sh, which is generally produced by
22 * running Configure.
23 *
24 * Feel free to modify any of this as the need arises.  Note, however,
25 * that running config_h.SH again will wipe out any changes you've made.
26 * For a more permanent change edit config.sh and rerun config_h.SH.
27 *
28 * \$Id: Config_h.U,v 3.0.1.3 1995/01/30 14:25:39 ram Exp $
29 */
30
31/* Configuration time: $cf_time
32 * Configured by: $cf_by
33 * Target system: $myuname
34 */
35
36#ifndef _config_h_
37#define _config_h_
38
39/* getdtablesize:
40 *  This catches use of the getdtablesize() subroutine, and remaps it
41 *  to either ulimit(4,0) or NOFILE, if getdtablesize() isn't available.
42 */
43#$d_gettblsz getdtablesize() $tablesize /**/
44
45/* HAS_BCOPY:
46 *  This symbol is defined if the bcopy() routine is available to
47 *  copy blocks of memory.
48 */
49#$d_bcopy HAS_BCOPY /**/
50
51/* HAS_BZERO:
52 *  This symbol is defined if the bzero() routine is available to
53 *  set a memory block to 0.
54 */
55#$d_bzero HAS_BZERO /**/
56
57/* HASCONST:
58 *  This symbol, if defined, indicates that this C compiler knows about
59 *  the const type. There is no need to actually test for that symbol
60 *  within your programs. The mere use of the "const" keyword will
61 *  trigger the necessary tests.
62 */
63#$d_const HASCONST  /**/
64#ifndef HASCONST
65#define const
66#endif
67
68/* HAS_MEMSET:
69 *  This symbol, if defined, indicates that the memset routine is available
70 *  to set blocks of memory.
71 */
72#$d_memset HAS_MEMSET   /**/
73
74/* HAS_GETRUSAGE:
75 *  This symbol, if defined, indicates that the getrusage() routine is
76 *  available to get process statistics with a sub-second accuracy.
77 *  Inclusion of <sys/resource.h> and <sys/time.h> may be necessary.
78 */
79#$d_rusage HAS_GETRUSAGE        /**/
80
81/* HAS_SIGACTION:
82 *  This symbol, if defined, indicates that Vr4's sigaction() routine
83 *  is available.
84 */
85#$d_sigaction HAS_SIGACTION /**/
86
87/* HAS_STRCASECMP:
88 *  This symbol, if defined, indicates that the strcasecmp() routine is
89 *  available for case-insensitive string compares.
90 */
91#$d_strccmp HAS_STRCASECMP  /**/
92
93/* HAS_STRDUP:
94 *  This symbol, if defined, indicates that the strdup routine is
95 *  available to duplicate strings in memory. Otherwise, roll up
96 *  your own...
97 */
98#$d_strdup HAS_STRDUP       /**/
99
100/* HAS_SYSCONF:
101 *  This symbol, if defined, indicates that sysconf() is available
102 *  to determine system related limits and options.
103 */
104#$d_sysconf HAS_SYSCONF /**/
105
106/* UNION_WAIT:
107 *  This symbol if defined indicates to the C program that the argument
108 *  for the wait() system call should be declared as 'union wait status'
109 *  instead of 'int status'. You probably need to include <sys/wait.h>
110 *  in the former case (see I_SYSWAIT).
111 */
112#$d_uwait UNION_WAIT        /**/
113
114/* VOIDSIG:
115 *  This symbol is defined if this system declares "void (*signal(...))()" in
116 *  signal.h.  The old way was to declare it as "int (*signal(...))()".  It
117 *  is up to the package author to declare things correctly based on the
118 *  symbol.
119 */
120/* Signal_t:
121 *  This symbol's value is either "void" or "int", corresponding to the
122 *  appropriate return type of a signal handler.  Thus, you can declare
123 *  a signal handler using "Signal_t (*handler)()", and define the
124 *  handler using "Signal_t handler(sig)".
125 */
126#$d_voidsig VOIDSIG     /**/
127#define Signal_t $signal_t  /* Signal handler's return type */
128
129/* HASVOLATILE:
130 *  This symbol, if defined, indicates that this C compiler knows about
131 *  the volatile declaration.
132 */
133#$d_volatile    HASVOLATILE /**/
134#ifndef HASVOLATILE
135#define volatile
136#endif
137
138/* HAS_WAITPID:
139 *  This symbol, if defined, indicates that the waitpid routine is
140 *  available to wait for child process.
141 */
142#$d_waitpid HAS_WAITPID /**/
143
144/* I_LIMITS:
145 *  This symbol, if defined, indicates to the C program that it should
146 *  include <limits.h> to get definition of symbols like WORD_BIT or
147 *  LONG_MAX, i.e. machine dependant limitations.
148 */
149#$i_limits I_LIMITS     /**/
150
151/* I_MEMORY:
152 *  This symbol, if defined, indicates to the C program that it should
153 *  include <memory.h>.
154 */
155#$i_memory I_MEMORY     /**/
156
157/* I_STDLIB:
158 *  This symbol, if defined, indicates that <stdlib.h> exists and should
159 *  be included.
160 */
161#$i_stdlib I_STDLIB     /**/
162
163/* I_STRING:
164 *  This symbol, if defined, indicates to the C program that it should
165 *  include <string.h> (USG systems) instead of <strings.h> (BSD systems).
166 */
167#$i_string I_STRING     /**/
168
169/* I_SYS_RESOURCE:
170 *  This symbol, if defined, indicates to the C program that it should
171 *  include <sys/resource.h>.
172 */
173#$i_sysresrc I_SYS_RESOURCE     /**/
174
175/* I_SYS_SELECT:
176 *  This symbol, if defined, indicates to the C program that it should
177 *  include <sys/select.h> in order to get definition of struct timeval.
178 */
179#$i_sysselct I_SYS_SELECT   /**/
180
181/* I_SYS_TYPES:
182 *  This symbol, if defined, indicates to the C program that it should
183 *  include <sys/types.h>.
184 */
185#$i_systypes    I_SYS_TYPES     /**/
186
187/* I_SYS_WAIT:
188 *  This symbol, if defined, indicates to the C program that it should
189 *  include <sys/wait.h>.
190 */
191#$i_syswait I_SYS_WAIT  /**/
192
193/* I_SYS_TIME:
194 *  This symbol, if defined, indicates to the C program that it should
195 *  include <sys/time.h>.
196 */
197#$i_systime I_SYS_TIME      /**/
198
199/* I_UNISTD:
200 *  This symbol, if defined, indicates to the C program that it should
201 *  include <unistd.h>.
202 */
203#$i_unistd I_UNISTD     /**/
204
205/* I_STDARG:
206 *  This symbol, if defined, indicates that <stdarg.h> exists and should
207 *  be included.
208 */
209#$i_stdarg I_STDARG     /**/
210
211/* Malloc_t:
212 *  This symbol is the type of pointer returned by malloc and realloc.
213 */
214#define Malloc_t $malloctype            /**/
215
216/* CAN_PROTOTYPE:
217 *  If defined, this macro indicates that the C compiler can handle
218 *  function prototypes.
219 */
220/* _:
221 *  This macro is used to declare function parameters for folks who want
222 *  to make declarations with prototypes using a different style than
223 *  the above macros.  Use double parentheses.  For example:
224 *
225 *      int main _((int argc, char *argv[]));
226 */
227#$prototype CAN_PROTOTYPE   /**/
228#ifdef CAN_PROTOTYPE
229#define _(args) args
230#else
231#define _(args) ()
232#endif
233
234/* Size_t:
235 *  This symbol holds the type used to declare length parameters
236 *  for string functions.  It is usually size_t, but may be
237 *  unsigned long, int, etc.  It may be necessary to include
238 *  <sys/types.h> to get any typedef'ed information.
239 */
240#define Size_t $sizetype     /* length paramater for string functions */
241
242/* VOIDFLAGS:
243 *  This symbol indicates how much support of the void type is given by this
244 *  compiler.  What various bits mean:
245 *
246 *      1 = supports declaration of void
247 *      2 = supports arrays of pointers to functions returning void
248 *      4 = supports comparisons between pointers to void functions and
249 *          addresses of void functions
250 *      8 = suports declaration of generic void pointers
251 *
252 *  The package designer should define VOIDUSED to indicate the requirements
253 *  of the package.  This can be done either by #defining VOIDUSED before
254 *  including config.h, or by defining defvoidused in Myinit.U.  If the
255 *  latter approach is taken, only those flags will be tested.  If the
256 *  level of void support necessary is not present, defines void to int.
257 */
258#ifndef VOIDUSED
259#define VOIDUSED $defvoidused
260#endif
261#define VOIDFLAGS $voidflags
262#if (VOIDFLAGS & VOIDUSED) != VOIDUSED
263#define void int        /* is void to be avoided? */
264#define M_VOID          /* Xenix strikes again */
265#endif
266
267/* HAS_CRYPT:
268 *  This symbol, if defined, indicates that the crypt routine is available
269 *  to encrypt passwords and the like.
270 */
271#$d_crypt HAS_CRYPT     /**/
272
273/* HAS_IEEE_MATH:
274 *  Defined if the machine supports IEEE math - that is, can safely
275 *  return NaN or Inf rather than crash on bad math.
276 */
277#$d_ieee HAS_IEEE_MATH /**/
278
279/* SIGNALS_KEPT:
280 *  This symbol is defined if signal handlers needn't be reinstated after
281 *  receipt of a signal.
282 */
283#$d_keepsig SIGNALS_KEPT    /**/
284
285/* HAS_MEMCPY:
286 *  This symbol, if defined, indicates that the memcpy routine is available
287 *  to copy blocks of memory. If not, it will be mapped to bcopy
288 *  in confmagic.h
289 */
290#$d_memcpy HAS_MEMCPY   /**/
291
292/* CAN_NEWSTYLE:
293 *  Defined if new-style functions definitions are allowable.
294 *  If they are, we can avoid some warnings that you get if
295 *  you declare char arguments in a prototype and use old-style
296 *  function definitions, which implicitly promote them to ints.
297 */
298#$d_newstyle CAN_NEWSTYLE /**/
299
300/* HAS_RANDOM:
301 *  Have we got random(), our first choice for number generation.
302 */
303/* HAS_LRAND48:
304 *  Have we got lrand48(), our second choice.
305 */
306/* HAS_RAND:
307 *  Have we got rand(), our last choice.
308 */
309#$d_random HAS_RANDOM   /**/
310#$d_lrand48 HAS_LRAND48 /**/
311#$d_rand HAS_RAND   /**/
312
313/* HAS_GETRLIMIT:
314 *  This symbol, if defined, indicates that the getrlimit() routine is
315 *  available to get resource limits. Probably means setrlimit too.
316 *  Inclusion of <sys/resource.h> and <sys/time.h> may be necessary.
317 */
318#$d_rlimit HAS_GETRLIMIT        /**/
319
320/* HAS_STRCHR:
321 *  This symbol is defined to indicate that the strchr()/strrchr()
322 *  functions are available for string searching. If not, try the
323 *  index()/rindex() pair.
324 */
325/* HAS_INDEX:
326 *  This symbol is defined to indicate that the index()/rindex()
327 *  functions are available for string searching.
328 */
329#$d_strchr HAS_STRCHR   /**/
330#$d_index HAS_INDEX /**/
331
332/* HAS_TIMELOCAL:
333 *  This symbol, if defined, indicates that the timelocal() routine is
334 *  available.
335 */
336#$d_timelocal HAS_TIMELOCAL     /**/
337
338/* HAS_SAFE_TOUPPER:
339 *  Defined if toupper() can operate safely on any ascii character.
340 *  Some systems only allow toupper() on lower-case ascii chars.
341 */
342#$d_toupper HAS_SAFE_TOUPPER /**/
343
344/* UPTIME_PATH:
345 *  This symbol gives the full path to the uptime(1) program if
346 *  it exists on the system. If not, this symbol is undefined.
347 */
348/* HAS_UPTIME:
349 *  This symbol is defined if uptime(1) is available.
350 */
351#$d_uptime HAS_UPTIME   /**/
352#define UPTIME_PATH "$uptime"
353
354/* Free_t:
355 *  This symbol is the type returned by free.
356 */
357/* INT_FREE:
358 *  This symbol is defined if free(3) should return an int instead
359 *  of void (like Sun's cc).
360 */
361#define Free_t $freetype        /**/
362#$d_intfree INT_FREE            /**/
363
364/* I_SYS_VLIMIT:
365 *  This symbol, if defined, indicates to the C program that it should
366 *  include <sys/vlimit.h>.
367 */
368#$i_sysvlimit I_SYS_VLIMIT      /**/
369
370#endif
371!GROK!THIS!
Note: See TracBrowser for help on using the browser.