This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
This is my patch patch.1m for perl5.001.
[perl5.git] / config_h.SH
CommitLineData
8d063cd8
LW
1case $CONFIG in
2'')
2304df62
AD
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\(.*\)/'` ;;
8d063cd8
LW
16esac
17echo "Extracting config.h (with variable substitutions)"
2304df62
AD
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
8d063cd8
LW
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,
1aef975c
AD
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.
2304df62 27 *
1aef975c 28 * \$Id: Config_h.U,v 3.0.1.3 1995/01/30 14:25:39 ram Exp $
8d063cd8
LW
29 */
30
2304df62
AD
31/* Configuration time: $cf_time
32 * Configured by: $cf_by
33 * Target system: $myuname
34 */
8d063cd8 35
2304df62
AD
36#ifndef _config_h_
37#define _config_h_
38
a0d0e21e
LW
39/* MEM_ALIGNBYTES:
40 * This symbol contains the number of bytes required to align a
41 * double. Usual values are 2, 4 and 8.
42 */
43#define MEM_ALIGNBYTES $alignbytes /**/
44
40000a8c
AD
45/* ARCHLIB_EXP:
46 * This symbol contains the ~name expanded version of ARCHLIB, to be used
47 * in programs that are not prepared to deal with ~ expansion at run-time.
48 */
49#$d_archlib ARCHLIB_EXP "$archlibexp" /**/
50
2304df62
AD
51/* BIN:
52 * This symbol holds the path of the bin directory where the package will
53 * be installed. Program must be prepared to deal with ~name substitution.
a687059c 54 */
2304df62 55#define BIN "$bin" /**/
a687059c 56
2304df62
AD
57/* BYTEORDER:
58 * This symbol hold the hexadecimal constant defined in byteorder,
59 * i.e. 0x1234 or 0x4321, etc...
a687059c 60 */
2304df62 61#define BYTEORDER 0x$byteorder /* large digits for MSB */
a687059c 62
ecfc5424
AD
63/* CAT2:
64 * This macro catenates 2 tokens together.
65 */
66/* STRINGIFY:
67 * This macro surrounds its token with double quotes.
68 */
69#if $cpp_stuff == 1
70#define CAT2(a,b)a/**/b
71#define CAT3(a,b,c)a/**/b/**/c
72#define CAT4(a,b,c,d)a/**/b/**/c/**/d
73#define CAT5(a,b,c,d,e)a/**/b/**/c/**/d/**/e
74#define STRINGIFY(a)"a"
75 /* If you can get stringification with catify, tell me how! */
76#endif
77#if $cpp_stuff == 42
78#define CAT2(a,b)a ## b
79#define CAT3(a,b,c)a ## b ## c
80#define CAT4(a,b,c,d)a ## b ## c ## d
81#define CAT5(a,b,c,d,e)a ## b ## c ## d ## e
82#define StGiFy(a)# a
83#define STRINGIFY(a)StGiFy(a)
84#define SCAT2(a,b)StGiFy(a) StGiFy(b)
85#define SCAT3(a,b,c)StGiFy(a) StGiFy(b) StGiFy(c)
86#define SCAT4(a,b,c,d)StGiFy(a) StGiFy(b) StGiFy(c) StGiFy(d)
87#define SCAT5(a,b,c,d,e)StGiFy(a) StGiFy(b) StGiFy(c) StGiFy(d) StGiFy(e)
88#endif
89#ifndef CAT2
90#include "Bletch: How does this C preprocessor catenate tokens?"
91#endif
92
2304df62 93/* CPPSTDIN:
36ce8bec
DFDL
94 * This symbol contains the first part of the string which will invoke
95 * the C preprocessor on the standard input and produce to standard
2304df62
AD
96 * output. Typical value of "cc -E" or "/lib/cpp", but it can also
97 * call a wrapper. See CPPRUN.
36ce8bec 98 */
2304df62 99/* CPPMINUS:
36ce8bec
DFDL
100 * This symbol contains the second part of the string which will invoke
101 * the C preprocessor on the standard input and produce to standard
378cc40b 102 * output. This symbol will have the value "-" if CPPSTDIN needs a minus
36ce8bec
DFDL
103 * to specify standard input, otherwise the value is "".
104 */
378cc40b 105#define CPPSTDIN "$cppstdin"
36ce8bec
DFDL
106#define CPPMINUS "$cppminus"
107
a0d0e21e
LW
108/* HAS_ALARM:
109 * This symbol, if defined, indicates that the alarm routine is
110 * available.
111 */
112#$d_alarm HAS_ALARM /**/
113
ecfc5424
AD
114/* HASATTRIBUTE:
115 * This symbol indicates the C compiler can check for function attributes,
116 * such as printf formats. This is normally only supported by GNU cc.
117 */
118#$d_attribut HASATTRIBUTE /**/
119#ifndef HASATTRIBUTE
120#define __attribute__(_arg_)
121#endif
122
2304df62
AD
123/* HAS_BCMP:
124 * This symbol is defined if the bcmp() routine is available to
125 * compare blocks of memory.
a687059c 126 */
2304df62 127#$d_bcmp HAS_BCMP /**/
a687059c 128
2304df62
AD
129/* HAS_BCOPY:
130 * This symbol is defined if the bcopy() routine is available to
131 * copy blocks of memory.
c51b80d1 132 */
2304df62 133#$d_bcopy HAS_BCOPY /**/
c51b80d1 134
2304df62
AD
135/* HAS_BZERO:
136 * This symbol is defined if the bzero() routine is available to
137 * set a memory block to 0.
0d3e774c 138 */
2304df62 139#$d_bzero HAS_BZERO /**/
0d3e774c 140
a0d0e21e
LW
141/* CASTI32:
142 * This symbol is defined if the C compiler can cast negative
143 * or large floating point numbers to 32-bit ints.
144 */
145#$d_casti32 CASTI32 /**/
146
2304df62
AD
147/* CASTNEGFLOAT:
148 * This symbol is defined if the C compiler can cast negative
149 * numbers to unsigned longs, ints and shorts.
b1248f16 150 */
2304df62 151/* CASTFLAGS:
7e1cf235
LW
152 * This symbol contains flags that say what difficulties the compiler
153 * has casting odd floating values to unsigned long:
2304df62 154 * 0 = ok
7e1cf235
LW
155 * 1 = couldn't cast < 0
156 * 2 = couldn't cast >= 0x80000000
232e078e 157 * 4 = couldn't cast in argument expression list
7e1cf235 158 */
2304df62
AD
159#$d_castneg CASTNEGFLOAT /**/
160#define CASTFLAGS $castflags /**/
ed6116ce 161
a0d0e21e
LW
162/* HAS_CHOWN:
163 * This symbol, if defined, indicates that the chown routine is
164 * available.
165 */
166#$d_chown HAS_CHOWN /**/
167
168/* HAS_CHROOT:
169 * This symbol, if defined, indicates that the chroot routine is
170 * available.
171 */
172#$d_chroot HAS_CHROOT /**/
173
2304df62 174/* HAS_CHSIZE:
87250799
LW
175 * This symbol, if defined, indicates that the chsize routine is available
176 * to truncate files. You might need a -lx to get this routine.
177 */
fe14fcc3 178#$d_chsize HAS_CHSIZE /**/
87250799 179
ecfc5424
AD
180/* VOID_CLOSEDIR:
181 * This symbol, if defined, indicates that the closedir() routine
182 * does not return a value.
183 */
184#$d_void_closedir VOID_CLOSEDIR /**/
185
2304df62
AD
186/* HASCONST:
187 * This symbol, if defined, indicates that this C compiler knows about
188 * the const type. There is no need to actually test for that symbol
189 * within your programs. The mere use of the "const" keyword will
190 * trigger the necessary tests.
191 */
192#$d_const HASCONST /**/
193#ifndef HASCONST
194#define const
195#endif
196
197/* HAS_CRYPT:
2e1b3b7e
KK
198 * This symbol, if defined, indicates that the crypt routine is available
199 * to encrypt passwords and the like.
200 */
2304df62 201#$d_crypt HAS_CRYPT /**/
2e1b3b7e 202
a0d0e21e
LW
203/* HAS_CUSERID:
204 * This symbol, if defined, indicates that the cuserid routine is
205 * available to get character login names.
13281fa4 206 */
a0d0e21e
LW
207#$d_cuserid HAS_CUSERID /**/
208
209/* HAS_DBL_DIG:
210 * This symbol, if defined, indicates that this system's <float.h>
211 * or <limits.h> defines the symbol DBL_DIG, which is the number
212 * of significant digits in a double precision number. If this
213 * symbol is not defined, a guess of 15 is usually pretty good.
214 */
215#$d_dbl_dig HAS_DBL_DIG /* */
216
217/* HAS_DIFFTIME:
218 * This symbol, if defined, indicates that the difftime routine is
219 * available.
220 */
221#$d_difftime HAS_DIFFTIME /**/
13281fa4 222
ecfc5424
AD
223/* HAS_DLERROR:
224 * This symbol, if defined, indicates that the dlerror routine is
225 * available to return a string describing the last error that
226 * occurred from a call to dlopen(), dlclose() or dlsym().
227 */
228#$d_dlerror HAS_DLERROR /**/
229
230/* SETUID_SCRIPTS_ARE_SECURE_NOW:
231 * This symbol, if defined, indicates that the bug that prevents
232 * setuid scripts from being secure is not present in this kernel.
233 */
234/* DOSUID:
235 * This symbol, if defined, indicates that the C program should
236 * check the script that it is executing for setuid/setgid bits, and
237 * attempt to emulate setuid/setgid on systems that have disabled
238 * setuid #! scripts because the kernel can't do it securely.
239 * It is up to the package designer to make sure that this emulation
240 * is done securely. Among other things, it should do an fstat on
241 * the script it just opened to make sure it really is a setuid/setgid
242 * script, it should make sure the arguments passed correspond exactly
243 * to the argument on the #! line, and it should not trust any
244 * subprocesses to which it must pass the filename rather than the
245 * file descriptor of the script to be executed.
246 */
247#$d_suidsafe SETUID_SCRIPTS_ARE_SECURE_NOW /**/
248#$d_dosuid DOSUID /**/
249
2304df62
AD
250/* HAS_DUP2:
251 * This symbol, if defined, indicates that the dup2 routine is
252 * available to duplicate file descriptors.
a687059c 253 */
2304df62 254#$d_dup2 HAS_DUP2 /**/
a687059c 255
2304df62 256/* HAS_FCHMOD:
378cc40b
LW
257 * This symbol, if defined, indicates that the fchmod routine is available
258 * to change mode of opened files. If unavailable, use chmod().
259 */
2304df62 260#$d_fchmod HAS_FCHMOD /**/
378cc40b 261
2304df62 262/* HAS_FCHOWN:
378cc40b
LW
263 * This symbol, if defined, indicates that the fchown routine is available
264 * to change ownership of opened files. If unavailable, use chown().
265 */
2304df62 266#$d_fchown HAS_FCHOWN /**/
378cc40b 267
2304df62 268/* HAS_FCNTL:
fe14fcc3
LW
269 * This symbol, if defined, indicates to the C program that
270 * the fcntl() function exists.
a687059c 271 */
2304df62 272#$d_fcntl HAS_FCNTL /**/
a687059c 273
a0d0e21e
LW
274/* HAS_FGETPOS:
275 * This symbol, if defined, indicates that the fgetpos routine is
276 * available to get the file position indicator, similar to ftell().
277 */
278#$d_fgetpos HAS_FGETPOS /**/
279
2304df62 280/* FLEXFILENAMES:
7e1cf235
LW
281 * This symbol, if defined, indicates that the system supports filenames
282 * longer than 14 characters.
283 */
284#$d_flexfnam FLEXFILENAMES /**/
285
2304df62
AD
286/* HAS_FLOCK:
287 * This symbol, if defined, indicates that the flock routine is
a687059c
LW
288 * available to do file locking.
289 */
2304df62 290#$d_flock HAS_FLOCK /**/
a687059c 291
a0d0e21e
LW
292/* HAS_FORK:
293 * This symbol, if defined, indicates that the fork routine is
294 * available.
295 */
296#$d_fork HAS_FORK /**/
297
298/* HAS_FSETPOS:
299 * This symbol, if defined, indicates that the fsetpos routine is
300 * available to set the file position indicator, similar to fseek().
301 */
302#$d_fsetpos HAS_FSETPOS /**/
303
ecfc5424
AD
304/* Gconvert:
305 * This preprocessor macro is defined to convert a floating point
306 * number to a string without a trailing decimal point. This
307 * emulates the behavior of sprintf("%g"), but is sometimes much more
308 * efficient. If gconvert() is not available, but gcvt() drops the
309 * trailing decimal point, then gcvt() is used. If all else fails,
310 * a macro using sprintf("%g") is used. Arguments for the Gconvert
311 * macro are: value, number of digits, whether trailing zeros should
312 * be retained, and the output buffer.
16d20bd9
AD
313 * Possible values are:
314 * d_Gconvert='gconvert((x),(n),(t),(b))'
315 * d_Gconvert='gcvt((x),(n),(b))'
316 * d_Gconvert='sprintf((b),"%.*g",(n),(x))'
317 * The last two assume trailing zeros should not be kept.
ecfc5424
AD
318 */
319#define Gconvert(x,n,t,b) $d_Gconvert
320
2304df62 321/* HAS_GETGROUPS:
378cc40b
LW
322 * This symbol, if defined, indicates that the getgroups() routine is
323 * available to get the list of process groups. If unavailable, multiple
324 * groups are probably not supported.
325 */
2304df62 326#$d_getgrps HAS_GETGROUPS /**/
378cc40b 327
2304df62
AD
328/* HAS_GETHOSTENT:
329 * This symbol, if defined, indicates that the gethostent routine is
a687059c
LW
330 * available to lookup host names in some data base or other.
331 */
2304df62
AD
332#$d_gethent HAS_GETHOSTENT /**/
333
334/* HAS_UNAME:
335 * This symbol, if defined, indicates that the C program may use the
336 * uname() routine to derive the host name. See also HAS_GETHOSTNAME
337 * and PHOSTNAME.
338 */
339#$d_uname HAS_UNAME /**/
a687059c 340
a0d0e21e
LW
341/* HAS_GETLOGIN:
342 * This symbol, if defined, indicates that the getlogin routine is
343 * available to get the login name.
344 */
345#$d_getlogin HAS_GETLOGIN /**/
346
2304df62
AD
347/* HAS_GETPGRP:
348 * This symbol, if defined, indicates that the getpgrp routine is
a687059c
LW
349 * available to get the current process group.
350 */
2304df62 351#$d_getpgrp HAS_GETPGRP /**/
a687059c 352
2304df62 353/* HAS_GETPGRP2:
d8f2e4cc
LW
354 * This symbol, if defined, indicates that the getpgrp2() (as in DG/UX)
355 * routine is available to get the current process group.
356 */
2304df62 357#$d_getpgrp2 HAS_GETPGRP2 /**/
d8f2e4cc 358
a0d0e21e
LW
359/* HAS_GETPPID:
360 * This symbol, if defined, indicates that the getppid routine is
361 * available to get the parent process ID.
362 */
363#$d_getppid HAS_GETPPID /**/
364
2304df62
AD
365/* HAS_GETPRIORITY:
366 * This symbol, if defined, indicates that the getpriority routine is
a687059c
LW
367 * available to get a process's priority.
368 */
2304df62 369#$d_getprior HAS_GETPRIORITY /**/
a687059c 370
a0d0e21e
LW
371/* HAS_HTONL:
372 * This symbol, if defined, indicates that the htonl() routine (and
373 * friends htons() ntohl() ntohs()) are available to do network
374 * order byte swapping.
375 */
376/* HAS_HTONS:
377 * This symbol, if defined, indicates that the htons() routine (and
378 * friends htonl() ntohl() ntohs()) are available to do network
379 * order byte swapping.
380 */
381/* HAS_NTOHL:
382 * This symbol, if defined, indicates that the ntohl() routine (and
383 * friends htonl() htons() ntohs()) are available to do network
384 * order byte swapping.
385 */
386/* HAS_NTOHS:
387 * This symbol, if defined, indicates that the ntohs() routine (and
388 * friends htonl() htons() ntohl()) are available to do network
389 * order byte swapping.
390 */
391#$d_htonl HAS_HTONL /**/
392#$d_htonl HAS_HTONS /**/
393#$d_htonl HAS_NTOHL /**/
394#$d_htonl HAS_NTOHS /**/
395
ecfc5424
AD
396/* HAS_ISASCII:
397 * This manifest constant lets the C program know that isascii
398 * is available.
399 */
400#$d_isascii HAS_ISASCII /**/
401
2304df62 402/* HAS_KILLPG:
378cc40b
LW
403 * This symbol, if defined, indicates that the killpg routine is available
404 * to kill process groups. If unavailable, you probably should use kill
405 * with a negative process number.
406 */
2304df62 407#$d_killpg HAS_KILLPG /**/
378cc40b 408
2304df62
AD
409/* HAS_LINK:
410 * This symbol, if defined, indicates that the link routine is
411 * available to create hard links.
0d3e774c 412 */
2304df62 413#$d_link HAS_LINK /**/
0d3e774c 414
ecfc5424
AD
415/* HAS_LOCALECONV:
416 * This symbol, if defined, indicates that the localeconv routine is
417 * available for numeric and monetary formatting conventions.
418 */
419#$d_locconv HAS_LOCALECONV /**/
420
a0d0e21e
LW
421/* HAS_LOCKF:
422 * This symbol, if defined, indicates that the lockf routine is
423 * available to do file locking.
424 */
425#$d_lockf HAS_LOCKF /**/
426
2304df62
AD
427/* HAS_LSTAT:
428 * This symbol, if defined, indicates that the lstat routine is
429 * available to do file stats on symbolic links.
a687059c 430 */
2304df62 431#$d_lstat HAS_LSTAT /**/
a687059c 432
a0d0e21e
LW
433/* HAS_MBLEN:
434 * This symbol, if defined, indicates that the mblen routine is available
435 * to find the number of bytes in a multibye character.
436 */
437#$d_mblen HAS_MBLEN /**/
438
439/* HAS_MBSTOWCS:
440 * This symbol, if defined, indicates that the mbstowcs routine is
441 * available to covert a multibyte string into a wide character string.
442 */
443#$d_mbstowcs HAS_MBSTOWCS /**/
444
445/* HAS_MBTOWC:
446 * This symbol, if defined, indicates that the mbtowc routine is available
447 * to covert a multibyte to a wide character.
448 */
449#$d_mbtowc HAS_MBTOWC /**/
450
2304df62
AD
451/* HAS_MEMCMP:
452 * This symbol, if defined, indicates that the memcmp routine is available
453 * to compare blocks of memory.
378cc40b 454 */
2304df62
AD
455#$d_memcmp HAS_MEMCMP /**/
456
457/* HAS_MEMCPY:
9f971974 458 * This symbol, if defined, indicates that the memcpy routine is available
2304df62 459 * to copy blocks of memory.
9f971974 460 */
2304df62 461#$d_memcpy HAS_MEMCPY /**/
9f971974 462
2304df62 463/* HAS_MEMMOVE:
9f971974 464 * This symbol, if defined, indicates that the memmove routine is available
2304df62
AD
465 * to copy potentially overlapping blocks of memory. This should be used
466 * only when HAS_SAFE_BCOPY is not defined. If neither is there, roll your
467 * own version.
9f971974 468 */
2304df62 469#$d_memmove HAS_MEMMOVE /**/
9f971974 470
2304df62 471/* HAS_MEMSET:
9f971974 472 * This symbol, if defined, indicates that the memset routine is available
2304df62 473 * to set blocks of memory.
9f971974 474 */
2304df62 475#$d_memset HAS_MEMSET /**/
378cc40b 476
2304df62 477/* HAS_MKDIR:
a687059c
LW
478 * This symbol, if defined, indicates that the mkdir routine is available
479 * to create directories. Otherwise you should fork off a new process to
480 * exec /bin/mkdir.
481 */
2304df62 482#$d_mkdir HAS_MKDIR /**/
fe14fcc3 483
ecfc5424
AD
484/* HAS_MKFIFO:
485 * This symbol, if defined, indicates that the mkfifo routine is
486 * available to create FIFOs. Otherwise, mknod should be able to
487 * do it for you. However, if mkfifo is there, mknod might require
488 * super-user privileges which mkfifo will not.
489 */
490#$d_mkfifo HAS_MKFIFO /**/
491
a0d0e21e
LW
492/* HAS_MKTIME:
493 * This symbol, if defined, indicates that the mktime routine is
494 * available.
495 */
496#$d_mktime HAS_MKTIME /**/
497
2304df62 498/* HAS_MSG:
fe14fcc3 499 * This symbol, if defined, indicates that the entire msg*(2) library is
2304df62 500 * supported (IPC mechanism based on message queues).
fe14fcc3 501 */
2304df62 502#$d_msg HAS_MSG /**/
fe14fcc3 503
a0d0e21e
LW
504/* HAS_NICE:
505 * This symbol, if defined, indicates that the nice routine is
506 * available.
fe14fcc3 507 */
a0d0e21e 508#$d_nice HAS_NICE /**/
a687059c 509
a0d0e21e
LW
510/* HAS_OPEN3:
511 * This manifest constant lets the C program know that the three
512 * argument form of open(2) is available.
fe14fcc3 513 */
a0d0e21e 514#$d_open3 HAS_OPEN3 /**/
fe14fcc3 515
ecfc5424
AD
516/* HAS_PATHCONF:
517 * This symbol, if defined, indicates that pathconf() is available
518 * to determine file-system related limits and options associated
519 * with a given filename.
520 */
521/* HAS_FPATHCONF:
522 * This symbol, if defined, indicates that pathconf() is available
523 * to determine file-system related limits and options associated
524 * with a given open file descriptor.
525 */
526#$d_pathconf HAS_PATHCONF /**/
527#$d_fpathconf HAS_FPATHCONF /**/
528
a0d0e21e
LW
529/* HAS_PAUSE:
530 * This symbol, if defined, indicates that the pause routine is
531 * available to suspend a process until a signal is received.
a687059c 532 */
a0d0e21e 533#$d_pause HAS_PAUSE /**/
a687059c 534
a0d0e21e
LW
535/* HAS_PIPE:
536 * This symbol, if defined, indicates that the pipe routine is
537 * available to create an inter-process channel.
fe14fcc3 538 */
a0d0e21e
LW
539#$d_pipe HAS_PIPE /**/
540
541/* HAS_READDIR:
542 * This symbol, if defined, indicates that the readdir routine is
543 * available to read directory entries. You may have to include
544 * <dirent.h>. See I_DIRENT.
545 */
546#$d_readdir HAS_READDIR /**/
547
548/* HAS_SEEKDIR:
549 * This symbol, if defined, indicates that the seekdir routine is
550 * available. You may have to include <dirent.h>. See I_DIRENT.
551 */
552#$d_seekdir HAS_SEEKDIR /**/
553
554/* HAS_TELLDIR:
555 * This symbol, if defined, indicates that the telldir routine is
556 * available. You may have to include <dirent.h>. See I_DIRENT.
557 */
558#$d_telldir HAS_TELLDIR /**/
559
560/* HAS_REWINDDIR:
561 * This symbol, if defined, indicates that the rewinddir routine is
562 * available. You may have to include <dirent.h>. See I_DIRENT.
563 */
564#$d_rewinddir HAS_REWINDDIR /**/
565
566/* HAS_READLINK:
567 * This symbol, if defined, indicates that the readlink routine is
568 * available to read the value of a symbolic link.
569 */
570#$d_readlink HAS_READLINK /**/
fe14fcc3 571
2304df62 572/* HAS_RENAME:
378cc40b
LW
573 * This symbol, if defined, indicates that the rename routine is available
574 * to rename files. Otherwise you should do the unlink(), link(), unlink()
575 * trick.
576 */
2304df62 577#$d_rename HAS_RENAME /**/
378cc40b 578
2304df62
AD
579/* HAS_RMDIR:
580 * This symbol, if defined, indicates that the rmdir routine is
581 * available to remove directories. Otherwise you should fork off a
582 * new process to exec /bin/rmdir.
9f971974 583 */
2304df62 584#$d_rmdir HAS_RMDIR /**/
9f971974 585
ecfc5424
AD
586/* HAS_SAFE_BCOPY:
587 * This symbol, if defined, indicates that the bcopy routine is available
588 * to copy potentially overlapping memory blocks. Otherwise you should
589 * probably use memmove() or memcpy(). If neither is defined, roll your
590 * own version.
591 */
592#$d_safebcpy HAS_SAFE_BCOPY /**/
593
594/* HAS_SAFE_MEMCPY:
595 * This symbol, if defined, indicates that the memcpy routine is available
596 * to copy potentially overlapping memory blocks. Otherwise you should
597 * probably use memmove() or memcpy(). If neither is defined, roll your
598 * own version.
599 */
600#$d_safemcpy HAS_SAFE_MEMCPY /**/
601
2304df62
AD
602/* HAS_SELECT:
603 * This symbol, if defined, indicates that the select routine is
604 * available to select active file descriptors. If the timeout field
605 * is used, <sys/time.h> may need to be included.
fe14fcc3 606 */
2304df62 607#$d_select HAS_SELECT /**/
a687059c 608
2304df62 609/* HAS_SEM:
fe14fcc3
LW
610 * This symbol, if defined, indicates that the entire sem*(2) library is
611 * supported.
612 */
2304df62 613#$d_sem HAS_SEM /**/
fe14fcc3 614
2304df62 615/* HAS_SETEGID:
378cc40b
LW
616 * This symbol, if defined, indicates that the setegid routine is available
617 * to change the effective gid of the current program.
618 */
2304df62 619#$d_setegid HAS_SETEGID /**/
378cc40b 620
2304df62 621/* HAS_SETEUID:
378cc40b
LW
622 * This symbol, if defined, indicates that the seteuid routine is available
623 * to change the effective uid of the current program.
624 */
2304df62
AD
625#$d_seteuid HAS_SETEUID /**/
626
a0d0e21e
LW
627/* HAS_SETLINEBUF:
628 * This symbol, if defined, indicates that the setlinebuf routine is
629 * available to change stderr or stdout from block-buffered or unbuffered
630 * to a line-buffered mode.
631 */
632#$d_setlinebuf HAS_SETLINEBUF /**/
633
634/* HAS_SETLOCALE:
635 * This symbol, if defined, indicates that the setlocale routine is
636 * available to handle locale-specific ctype implementations.
637 */
638#$d_setlocale HAS_SETLOCALE /**/
639
2304df62
AD
640/* HAS_SETPGID:
641 * This symbol, if defined, indicates that the setpgid routine is
642 * available to set process group ID.
643 */
644#$d_setpgid HAS_SETPGID /**/
378cc40b 645
ecfc5424
AD
646/* HAS_SETPGRP:
647 * This symbol, if defined, indicates that the setpgrp routine is
648 * available to set the current process group.
649 */
650/* USE_BSDPGRP:
651 * This symbol, if defined, indicates that the BSD notion of process
652 * group is to be used. For instance, you have to say setpgrp(pid, pgrp)
653 * instead of the USG setpgrp().
654 */
655#$d_setpgrp HAS_SETPGRP /**/
656#$d_bsdpgrp USE_BSDPGRP /**/
657
2304df62 658/* HAS_SETPGRP2:
d8f2e4cc
LW
659 * This symbol, if defined, indicates that the setpgrp2() (as in DG/UX)
660 * routine is available to set the current process group.
661 */
2304df62 662#$d_setpgrp2 HAS_SETPGRP2 /**/
d8f2e4cc 663
2304df62
AD
664/* HAS_SETPRIORITY:
665 * This symbol, if defined, indicates that the setpriority routine is
a687059c
LW
666 * available to set a process's priority.
667 */
2304df62 668#$d_setprior HAS_SETPRIORITY /**/
a687059c 669
2304df62 670/* HAS_SETREGID:
a687059c 671 * This symbol, if defined, indicates that the setregid routine is
2304df62
AD
672 * available to change the real and effective gid of the current
673 * process.
a687059c 674 */
2304df62 675/* HAS_SETRESGID:
a687059c
LW
676 * This symbol, if defined, indicates that the setresgid routine is
677 * available to change the real, effective and saved gid of the current
2304df62 678 * process.
a687059c 679 */
2304df62
AD
680#$d_setregid HAS_SETREGID /**/
681#$d_setresgid HAS_SETRESGID /**/
a687059c 682
2304df62 683/* HAS_SETREUID:
a687059c 684 * This symbol, if defined, indicates that the setreuid routine is
2304df62
AD
685 * available to change the real and effective uid of the current
686 * process.
a687059c 687 */
2304df62 688/* HAS_SETRESUID:
a687059c
LW
689 * This symbol, if defined, indicates that the setresuid routine is
690 * available to change the real, effective and saved uid of the current
2304df62 691 * process.
a687059c 692 */
2304df62
AD
693#$d_setreuid HAS_SETREUID /**/
694#$d_setresuid HAS_SETRESUID /**/
a687059c 695
2304df62 696/* HAS_SETRGID:
378cc40b
LW
697 * This symbol, if defined, indicates that the setrgid routine is available
698 * to change the real gid of the current program.
699 */
2304df62 700#$d_setrgid HAS_SETRGID /**/
378cc40b 701
2304df62 702/* HAS_SETRUID:
378cc40b
LW
703 * This symbol, if defined, indicates that the setruid routine is available
704 * to change the real uid of the current program.
705 */
2304df62
AD
706#$d_setruid HAS_SETRUID /**/
707
708/* HAS_SETSID:
709 * This symbol, if defined, indicates that the setsid routine is
710 * available to set the process group ID.
711 */
712#$d_setsid HAS_SETSID /**/
fe14fcc3 713
2304df62 714/* HAS_SHM:
fe14fcc3
LW
715 * This symbol, if defined, indicates that the entire shm*(2) library is
716 * supported.
717 */
2304df62 718#$d_shm HAS_SHM /**/
fe14fcc3 719
a0d0e21e
LW
720/* Shmat_t:
721 * This symbol holds the return type of the shmat() system call.
722 * Usually set to 'void *' or 'char *'.
fe14fcc3 723 */
a0d0e21e
LW
724/* HAS_SHMAT_PROTOTYPE:
725 * This symbol, if defined, indicates that the sys/shm.h includes
726 * a prototype for shmat(). Otherwise, it is up to the program to
727 * guess one. Shmat_t shmat _((int, Shmat_t, int)) is a good guess,
728 * but not always right so it should be emitted by the program only
729 * when HAS_SHMAT_PROTOTYPE is not defined to avoid conflicting defs.
fe14fcc3 730 */
a0d0e21e
LW
731#define Shmat_t $shmattype /**/
732#$d_shmatprototype HAS_SHMAT_PROTOTYPE /**/
fe14fcc3 733
2304df62 734/* HAS_SOCKET:
a687059c
LW
735 * This symbol, if defined, indicates that the BSD socket interface is
736 * supported.
737 */
2304df62
AD
738/* HAS_SOCKETPAIR:
739 * This symbol, if defined, indicates that the BSD socketpair() call is
a687059c
LW
740 * supported.
741 */
2304df62
AD
742#$d_socket HAS_SOCKET /**/
743#$d_sockpair HAS_SOCKETPAIR /**/
a687059c 744
2304df62 745/* USE_STAT_BLOCKS:
c51b80d1
LW
746 * This symbol is defined if this system has a stat structure declaring
747 * st_blksize and st_blocks.
748 */
2304df62 749#$d_statblks USE_STAT_BLOCKS /**/
c51b80d1 750
16d20bd9
AD
751/* USE_STDIO_PTR:
752 * This symbol is defined if the _ptr and _cnt fields (or similar)
753 * of the stdio FILE structure can be used to access the stdio buffer
754 * for a file handle. If this is defined, then the FILE_ptr(fp)
755 * and FILE_cnt(fp) macros will also be defined and should be used
756 * to access these fields.
757 */
758/* USE_STDIO_BASE:
759 * This symbol is defined if the _base field (or similar) of the
760 * stdio FILE structure can be used to access the stdio buffer for
761 * a file handle. If this is defined, then the FILE_base(fp) macro
762 * will also be defined and should be used to access this field.
763 * Also, the FILE_bufsiz(fp) macro will be defined and should be used
764 * to determine the number of bytes in the buffer. USE_STDIO_BASE
765 * will never be defined unless USE_STDIO_PTR is.
766 */
767#$d_stdstdio USE_STDIO_PTR /**/
768#$d_stdiobase USE_STDIO_BASE /**/
769
770/* FILE_ptr:
771 * This macro is used to access the _ptr field (or equivalent) of the
772 * FILE structure pointed to by its argument. This macro will always be
773 * defined if USE_STDIO_PTR is defined.
774 */
c2960299
AD
775/* STDIO_PTR_LVALUE:
776 * This symbol is defined if the FILE_ptr macro can be used as an
777 * lvalue.
778 */
16d20bd9
AD
779/* FILE_cnt:
780 * This macro is used to access the _cnt field (or equivalent) of the
781 * FILE structure pointed to by its argument. This macro will always be
782 * defined if USE_STDIO_PTR is defined.
783 */
c2960299
AD
784/* STDIO_CNT_LVALUE:
785 * This symbol is defined if the FILE_cnt macro can be used as an
786 * lvalue.
787 */
16d20bd9
AD
788#ifdef USE_STDIO_PTR
789#define FILE_ptr(fp) $stdio_ptr
4aa0a1f7 790#$d_stdio_ptr_lval STDIO_PTR_LVALUE /**/
16d20bd9 791#define FILE_cnt(fp) $stdio_cnt
4aa0a1f7 792#$d_stdio_cnt_lval STDIO_CNT_LVALUE /**/
16d20bd9
AD
793#endif
794
795/* FILE_base:
796 * This macro is used to access the _base field (or equivalent) of the
797 * FILE structure pointed to by its argument. This macro will always be
798 * defined if USE_STDIO_BASE is defined.
799 */
800/* FILE_bufsiz:
801 * This macro is used to determine the number of bytes in the I/O
802 * buffer pointed to by _base field (or equivalent) of the FILE
803 * structure pointed to its argument. This macro will always be defined
804 * if USE_STDIO_BASE is defined.
36ce8bec 805 */
16d20bd9
AD
806#ifdef USE_STDIO_BASE
807#define FILE_base(fp) $stdio_base
808#define FILE_bufsiz(fp) $stdio_bufsiz
809#endif
36ce8bec 810
a0d0e21e
LW
811/* HAS_STRCHR:
812 * This symbol is defined to indicate that the strchr()/strrchr()
813 * functions are available for string searching. If not, try the
814 * index()/rindex() pair.
815 */
816/* HAS_INDEX:
817 * This symbol is defined to indicate that the index()/rindex()
818 * functions are available for string searching.
819 */
820#$d_strchr HAS_STRCHR /**/
821#$d_index HAS_INDEX /**/
822
823/* HAS_STRCOLL:
824 * This symbol, if defined, indicates that the strcoll routine is
825 * available to compare strings using collating information.
826 */
827#$d_strcoll HAS_STRCOLL /**/
828
2304df62 829/* USE_STRUCT_COPY:
8d063cd8
LW
830 * This symbol, if defined, indicates that this C compiler knows how
831 * to copy structures. If undefined, you'll need to use a block copy
832 * routine of some sort instead.
833 */
2304df62 834#$d_strctcpy USE_STRUCT_COPY /**/
8d063cd8 835
a0d0e21e
LW
836/* HAS_STRERROR:
837 * This symbol, if defined, indicates that the strerror routine is
838 * available to translate error numbers to strings. See the writeup
839 * of Strerror() in this file before you try to define your own.
840 */
841/* HAS_SYS_ERRLIST:
842 * This symbol, if defined, indicates that the sys_errlist array is
843 * available to translate error numbers to strings. The extern int
844 * sys_nerr gives the size of that table.
845 */
846/* Strerror:
847 * This preprocessor symbol is defined as a macro if strerror() is
848 * not available to translate error numbers to strings but sys_errlist[]
849 * array is there.
850 */
851#$d_strerror HAS_STRERROR /**/
852#$d_syserrlst HAS_SYS_ERRLIST /**/
853#define Strerror(e) $d_strerrm
854
855/* HAS_STRXFRM:
856 * This symbol, if defined, indicates that the strxfrm() routine is
857 * available to transform strings.
858 */
859#$d_strxfrm HAS_STRXFRM /**/
860
2304df62 861/* HAS_SYMLINK:
2e1b3b7e
KK
862 * This symbol, if defined, indicates that the symlink routine is available
863 * to create symbolic links.
864 */
2304df62 865#$d_symlink HAS_SYMLINK /**/
2e1b3b7e 866
2304df62
AD
867/* HAS_SYSCALL:
868 * This symbol, if defined, indicates that the syscall routine is
869 * available to call arbitrary system calls. If undefined, that's tough.
a687059c 870 */
2304df62 871#$d_syscall HAS_SYSCALL /**/
e5d73d77 872
ecfc5424
AD
873/* HAS_SYSCONF:
874 * This symbol, if defined, indicates that sysconf() is available
875 * to determine system related limits and options.
876 */
877#$d_sysconf HAS_SYSCONF /**/
878
2304df62
AD
879/* HAS_SYSTEM:
880 * This symbol, if defined, indicates that the system routine is
881 * available to issue a shell command.
9f971974 882 */
2304df62 883#$d_system HAS_SYSTEM /**/
9f971974 884
a0d0e21e
LW
885/* HAS_TCGETPGRP:
886 * This symbol, if defined, indicates that the tcgetpgrp routine is
887 * available to get foreground process group ID.
85e6fe83 888 */
a0d0e21e
LW
889#$d_tcgetpgrp HAS_TCGETPGRP /**/
890
891/* HAS_TCSETPGRP:
892 * This symbol, if defined, indicates that the tcsetpgrp routine is
893 * available to set foreground process group ID.
894 */
895#$d_tcsetpgrp HAS_TCSETPGRP /**/
85e6fe83 896
ecfc5424
AD
897/* Time_t:
898 * This symbol holds the type returned by time(). It can be long,
899 * or time_t on BSD sites (in which case <sys/types.h> should be
900 * included).
901 */
902#define Time_t $timetype /* Time type */
903
2304df62
AD
904/* HAS_TIMES:
905 * This symbol, if defined, indicates that the times() routine exists.
906 * Note that this became obsolete on some systems (SUNOS), which now
907 * use getrusage(). It may be necessary to include <sys/times.h>.
908 */
909#$d_times HAS_TIMES /**/
910
911/* HAS_TRUNCATE:
87250799
LW
912 * This symbol, if defined, indicates that the truncate routine is
913 * available to truncate files.
914 */
2304df62 915#$d_truncate HAS_TRUNCATE /**/
87250799 916
a0d0e21e
LW
917/* HAS_TZNAME:
918 * This symbol, if defined, indicates that the tzname[] array is
919 * available to access timezone names.
920 */
921#$d_tzname HAS_TZNAME /**/
922
923/* HAS_UMASK:
924 * This symbol, if defined, indicates that the umask routine is
925 * available to set and get the value of the file creation mask.
926 */
927#$d_umask HAS_UMASK /**/
928
929/* HAS_VFORK:
930 * This symbol, if defined, indicates that vfork() exists.
2304df62 931 */
a0d0e21e 932#$d_vfork HAS_VFORK /**/
2304df62 933
ecfc5424
AD
934/* Signal_t:
935 * This symbol's value is either "void" or "int", corresponding to the
936 * appropriate return type of a signal handler. Thus, you can declare
937 * a signal handler using "Signal_t (*handler)()", and define the
938 * handler using "Signal_t handler(sig)".
939 */
ecfc5424 940#define Signal_t $signal_t /* Signal handler's return type */
36ce8bec 941
2304df62 942/* HASVOLATILE:
afd9f252
LW
943 * This symbol, if defined, indicates that this C compiler knows about
944 * the volatile declaration.
945 */
946#$d_volatile HASVOLATILE /**/
2304df62
AD
947#ifndef HASVOLATILE
948#define volatile
949#endif
afd9f252 950
2304df62 951/* HAS_VPRINTF:
a687059c
LW
952 * This symbol, if defined, indicates that the vprintf routine is available
953 * to printf with a pointer to an argument list. If unavailable, you
954 * may need to write your own, probably in terms of _doprnt().
955 */
2304df62 956/* USE_CHAR_VSPRINTF:
a687059c
LW
957 * This symbol is defined if this system has vsprintf() returning type
958 * (char*). The trend seems to be to declare it as "int vsprintf()". It
959 * is up to the package author to declare vsprintf correctly based on the
960 * symbol.
961 */
2304df62
AD
962#$d_vprintf HAS_VPRINTF /**/
963#$d_charvspr USE_CHAR_VSPRINTF /**/
a687059c 964
2304df62 965/* HAS_WAIT4:
bf38876a
LW
966 * This symbol, if defined, indicates that wait4() exists.
967 */
2304df62 968#$d_wait4 HAS_WAIT4 /**/
bf38876a 969
2304df62
AD
970/* HAS_WAITPID:
971 * This symbol, if defined, indicates that the waitpid routine is
972 * available to wait for child process.
39c3038c 973 */
2304df62 974#$d_waitpid HAS_WAITPID /**/
39c3038c 975
a0d0e21e
LW
976/* HAS_WCSTOMBS:
977 * This symbol, if defined, indicates that the wcstombs routine is
978 * available to convert wide character strings to multibyte strings.
979 */
980#$d_wcstombs HAS_WCSTOMBS /**/
981
982/* HAS_WCTOMB:
983 * This symbol, if defined, indicates that the wctomb routine is available
984 * to covert a wide character to a multibyte.
985 */
986#$d_wctomb HAS_WCTOMB /**/
987
988/* Fpos_t:
989 * This symbol holds the type used to declare file positions in libc.
990 * It can be fpos_t, long, uint, etc... It may be necessary to include
991 * <sys/types.h> to get any typedef'ed information.
992 */
993#define Fpos_t $fpostype /* File position type */
994
995/* Gid_t:
996 * This symbol holds the return type of getgid() and the type of
997 * argument to setrgid() and related functions. Typically,
998 * it is the type of group ids in the kernel. It can be int, ushort,
999 * uid_t, etc... It may be necessary to include <sys/types.h> to get
1000 * any typedef'ed information.
378cc40b 1001 */
a0d0e21e 1002#define Gid_t $gidtype /* Type for getgid(), etc... */
378cc40b 1003
ecfc5424
AD
1004/* Groups_t:
1005 * This symbol holds the type used for the second argument to
1006 * getgroups(). Usually, this is the same of gidtype, but
1007 * sometimes it isn't. It can be int, ushort, uid_t, etc...
1008 * It may be necessary to include <sys/types.h> to get any
1009 * typedef'ed information. This is only required if you have
1010 * getgroups().
1011 */
1012#ifdef HAS_GETGROUPS
1013#define Groups_t $groupstype /* Type for 2nd arg to getgroups() */
1014#endif
1015
232e078e
AD
1016/* DB_Prefix_t:
1017 * This symbol contains the type of the prefix structure element
1018 * in the <db.h> header file. In older versions of DB, it was
1019 * int, while in newer ones it is u_int32_t.
1020 */
1021/* DB_Hash_t:
1022 * This symbol contains the type of the prefix structure element
1023 * in the <db.h> header file. In older versions of DB, it was
1024 * int, while in newer ones it is size_t.
1025 */
1026#define DB_Hash_t $db_hashtype /**/
1027#define DB_Prefix_t $db_prefixtype /**/
1028
2304df62
AD
1029/* I_DIRENT:
1030 * This symbol, if defined, indicates to the C program that it should
1031 * include <dirent.h>. Using this symbol also triggers the definition
1032 * of the Direntry_t define which ends up being 'struct dirent' or
1033 * 'struct direct' depending on the availability of <dirent.h>.
1c3d792e 1034 */
2304df62
AD
1035/* DIRNAMLEN:
1036 * This symbol, if defined, indicates to the C program that the length
1037 * of directory entry names is provided by a d_namlen field. Otherwise
1038 * you need to do strlen() on the d_name field.
1039 */
a0d0e21e
LW
1040/* Direntry_t:
1041 * This symbol is set to 'struct direct' or 'struct dirent' depending on
1042 * whether dirent is available or not. You should use this pseudo type to
1043 * portably declare your directory entries.
1044 */
2304df62
AD
1045#$i_dirent I_DIRENT /**/
1046#$d_dirnamlen DIRNAMLEN /**/
a0d0e21e
LW
1047#define Direntry_t $direntrytype
1048
1049/* I_DLFCN:
1050 * This symbol, if defined, indicates that <dlfcn.h> exists and should
1051 * be included.
1052 */
1053#$i_dlfcn I_DLFCN /**/
1c3d792e 1054
2304df62 1055/* I_FCNTL:
fe14fcc3 1056 * This manifest constant tells the C program to include <fcntl.h>.
a687059c 1057 */
2304df62 1058#$i_fcntl I_FCNTL /**/
a687059c 1059
a0d0e21e
LW
1060/* I_FLOAT:
1061 * This symbol, if defined, indicates to the C program that it should
1062 * include <float.h> to get definition of symbols like DBL_MAX or
1063 * DBL_MIN, i.e. machine dependent floating point values.
a687059c 1064 */
a0d0e21e 1065#$i_float I_FLOAT /**/
a687059c 1066
2304df62 1067/* I_GRP:
a687059c 1068 * This symbol, if defined, indicates to the C program that it should
2304df62 1069 * include <grp.h>.
a687059c 1070 */
2304df62 1071#$i_grp I_GRP /**/
a687059c 1072
a0d0e21e
LW
1073/* I_LIMITS:
1074 * This symbol, if defined, indicates to the C program that it should
1075 * include <limits.h> to get definition of symbols like WORD_BIT or
1076 * LONG_MAX, i.e. machine dependant limitations.
1077 */
1078#$i_limits I_LIMITS /**/
1079
1080/* I_MATH:
1081 * This symbol, if defined, indicates to the C program that it should
1082 * include <math.h>.
1083 */
1084#$i_math I_MATH /**/
1085
1086/* I_MEMORY:
1087 * This symbol, if defined, indicates to the C program that it should
1088 * include <memory.h>.
1089 */
1090#$i_memory I_MEMORY /**/
1091
232e078e 1092/* I_NDBM:
16d20bd9 1093 * This symbol, if defined, indicates that <ndbm.h> exists and should
232e078e
AD
1094 * be included.
1095 */
1096#$i_ndbm I_NDBM /**/
1097
ecfc5424
AD
1098/* I_NET_ERRNO:
1099 * This symbol, if defined, indicates that <net/errno.h> exists and
1100 * should be included.
2304df62 1101 */
ecfc5424 1102#$i_neterrno I_NET_ERRNO /**/
2304df62
AD
1103
1104/* I_NETINET_IN:
03a14243 1105 * This symbol, if defined, indicates to the C program that it should
2304df62 1106 * include <netinet/in.h>. Otherwise, you may try <sys/in.h>.
03a14243 1107 */
2304df62 1108#$i_niin I_NETINET_IN /**/
03a14243 1109
a0d0e21e
LW
1110/* I_PWD:
1111 * This symbol, if defined, indicates to the C program that it should
1112 * include <pwd.h>.
a687059c 1113 */
a0d0e21e
LW
1114/* PWQUOTA:
1115 * This symbol, if defined, indicates to the C program that struct passwd
1116 * contains pw_quota.
1117 */
1118/* PWAGE:
1119 * This symbol, if defined, indicates to the C program that struct passwd
1120 * contains pw_age.
1121 */
1122/* PWCHANGE:
1123 * This symbol, if defined, indicates to the C program that struct passwd
1124 * contains pw_change.
1125 */
1126/* PWCLASS:
1127 * This symbol, if defined, indicates to the C program that struct passwd
1128 * contains pw_class.
1129 */
1130/* PWEXPIRE:
1131 * This symbol, if defined, indicates to the C program that struct passwd
1132 * contains pw_expire.
1133 */
1134/* PWCOMMENT:
1135 * This symbol, if defined, indicates to the C program that struct passwd
1136 * contains pw_comment.
1137 */
1138#$i_pwd I_PWD /**/
1139#$d_pwquota PWQUOTA /**/
1140#$d_pwage PWAGE /**/
1141#$d_pwchange PWCHANGE /**/
1142#$d_pwclass PWCLASS /**/
1143#$d_pwexpire PWEXPIRE /**/
1144#$d_pwcomment PWCOMMENT /**/
a687059c 1145
2304df62
AD
1146/* I_STDDEF:
1147 * This symbol, if defined, indicates that <stddef.h> exists and should
a687059c
LW
1148 * be included.
1149 */
2304df62 1150#$i_stddef I_STDDEF /**/
a687059c 1151
a0d0e21e
LW
1152/* I_STDLIB:
1153 * This symbol, if defined, indicates that <stdlib.h> exists and should
1154 * be included.
1155 */
1156#$i_stdlib I_STDLIB /**/
1157
1158/* I_STRING:
85e6fe83
LW
1159 * This symbol, if defined, indicates to the C program that it should
1160 * include <string.h> (USG systems) instead of <strings.h> (BSD systems).
1161 */
1162#$i_string I_STRING /**/
1163
2304df62
AD
1164/* I_SYS_DIR:
1165 * This symbol, if defined, indicates to the C program that it should
1166 * include <sys/dir.h>.
d8f2e4cc 1167 */
2304df62
AD
1168#$i_sysdir I_SYS_DIR /**/
1169
1170/* I_SYS_FILE:
1171 * This symbol, if defined, indicates to the C program that it should
1172 * include <sys/file.h> to get definition of R_OK and friends.
d8f2e4cc 1173 */
2304df62
AD
1174#$i_sysfile I_SYS_FILE /**/
1175
1176/* I_SYS_IOCTL:
1177 * This symbol, if defined, indicates that <sys/ioctl.h> exists and should
1178 * be included. Otherwise, include <sgtty.h> or <termio.h>.
d8f2e4cc 1179 */
2304df62
AD
1180#$i_sysioctl I_SYS_IOCTL /**/
1181
1182/* I_SYS_NDIR:
1183 * This symbol, if defined, indicates to the C program that it should
1184 * include <sys/ndir.h>.
1185 */
1186#$i_sysndir I_SYS_NDIR /**/
1187
a0d0e21e
LW
1188/* I_SYS_PARAM:
1189 * This symbol, if defined, indicates to the C program that it should
1190 * include <sys/param.h>.
1191 */
1192#$i_sysparam I_SYS_PARAM /**/
1193
2304df62
AD
1194/* I_SYS_SELECT:
1195 * This symbol, if defined, indicates to the C program that it should
1196 * include <sys/select.h> in order to get definition of struct timeval.
1197 */
1198#$i_sysselct I_SYS_SELECT /**/
1199
a0d0e21e
LW
1200/* I_SYS_TIMES:
1201 * This symbol, if defined, indicates to the C program that it should
1202 * include <sys/times.h>.
1203 */
1204#$i_systimes I_SYS_TIMES /**/
1205
fed7345c
AD
1206/* I_SYS_TYPES:
1207 * This symbol, if defined, indicates to the C program that it should
1208 * include <sys/types.h>.
1209 */
1210#$i_systypes I_SYS_TYPES /**/
1211
a0d0e21e
LW
1212/* I_TERMIO:
1213 * This symbol, if defined, indicates that the program should include
1214 * <termio.h> rather than <sgtty.h>. There are also differences in
1215 * the ioctl() calls that depend on the value of this symbol.
1216 */
1217/* I_TERMIOS:
1218 * This symbol, if defined, indicates that the program should include
1219 * the POSIX termios.h rather than sgtty.h or termio.h.
1220 * There are also differences in the ioctl() calls that depend on the
1221 * value of this symbol.
1222 */
1223/* I_SGTTY:
1224 * This symbol, if defined, indicates that the program should include
1225 * <sgtty.h> rather than <termio.h>. There are also differences in
1226 * the ioctl() calls that depend on the value of this symbol.
1227 */
1228#$i_termio I_TERMIO /**/
1229#$i_termios I_TERMIOS /**/
1230#$i_sgtty I_SGTTY /**/
1231
2304df62
AD
1232/* I_TIME:
1233 * This symbol, if defined, indicates to the C program that it should
1234 * include <time.h>.
1235 */
1236/* I_SYS_TIME:
1237 * This symbol, if defined, indicates to the C program that it should
1238 * include <sys/time.h>.
fe14fcc3 1239 */
85e6fe83
LW
1240/* I_SYS_TIME_KERNEL:
1241 * This symbol, if defined, indicates to the C program that it should
1242 * include <sys/time.h> with KERNEL defined.
1243 */
2304df62
AD
1244#$i_time I_TIME /**/
1245#$i_systime I_SYS_TIME /**/
85e6fe83
LW
1246#$i_systimek I_SYS_TIME_KERNEL /**/
1247
1248/* I_UNISTD:
1249 * This symbol, if defined, indicates to the C program that it should
1250 * include <unistd.h>.
1251 */
1252#$i_unistd I_UNISTD /**/
d8f2e4cc 1253
2304df62 1254/* I_UTIME:
d8f2e4cc 1255 * This symbol, if defined, indicates to the C program that it should
2304df62 1256 * include <utime.h>.
d8f2e4cc 1257 */
2304df62 1258#$i_utime I_UTIME /**/
d8f2e4cc 1259
a0d0e21e
LW
1260/* I_STDARG:
1261 * This symbol, if defined, indicates that <stdarg.h> exists and should
1262 * be included.
1263 */
2304df62 1264/* I_VARARGS:
a687059c 1265 * This symbol, if defined, indicates to the C program that it should
2304df62 1266 * include <varargs.h>.
a687059c 1267 */
a0d0e21e
LW
1268#$i_stdarg I_STDARG /**/
1269#$i_varargs I_VARARGS /**/
1270
1271/* I_VFORK:
1272 * This symbol, if defined, indicates to the C program that it should
1273 * include vfork.h.
1274 */
1275#$i_vfork I_VFORK /**/
a687059c 1276
2304df62 1277/* INTSIZE:
a687059c
LW
1278 * This symbol contains the size of an int, so that the C preprocessor
1279 * can make decisions based on it.
1280 */
1281#define INTSIZE $intsize /**/
1282
85e6fe83
LW
1283/* Off_t:
1284 * This symbol holds the type used to declare offsets in the kernel.
1285 * It can be int, long, off_t, etc... It may be necessary to include
1286 * <sys/types.h> to get any typedef'ed information.
1287 */
1288#define Off_t $lseektype /* <offset> type */
1289
ecfc5424
AD
1290/* Mode_t:
1291 * This symbol holds the type used to declare file modes
1292 * for systems calls. It is usually mode_t, but may be
1293 * int or unsigned short. It may be necessary to include <sys/types.h>
1294 * to get any typedef'ed information.
1295 */
1296#define Mode_t $modetype /* file mode parameter for system calls */
1297
fed7345c
AD
1298/* PRIVLIB_EXP:
1299 * This symbol contains the ~name expanded version of PRIVLIB, to be used
1300 * in programs that are not prepared to deal with ~ expansion at run-time.
fe14fcc3 1301 */
fed7345c 1302#define PRIVLIB_EXP "$privlibexp" /**/
2304df62 1303
a0d0e21e
LW
1304/* CAN_PROTOTYPE:
1305 * If defined, this macro indicates that the C compiler can handle
1306 * function prototypes.
85e6fe83 1307 */
a0d0e21e
LW
1308/* _:
1309 * This macro is used to declare function parameters for folks who want
1310 * to make declarations with prototypes using a different style than
1311 * the above macros. Use double parentheses. For example:
1312 *
1313 * int main _((int argc, char *argv[]));
1314 */
1315#$prototype CAN_PROTOTYPE /**/
1316#ifdef CAN_PROTOTYPE
1317#define _(args) args
1318#else
1319#define _(args) ()
1320#endif
85e6fe83 1321
2304df62
AD
1322/* RANDBITS:
1323 * This symbol contains the number of bits of random number the rand()
1324 * function produces. Usual values are 15, 16, and 31.
fe14fcc3 1325 */
2304df62
AD
1326#define RANDBITS $randbits /**/
1327
1328/* SCRIPTDIR:
1329 * This symbol holds the name of the directory in which the user wants
1330 * to put publicly executable scripts for the package in question. It
1331 * is often a directory that is mounted across diverse architectures.
1332 * Programs must be prepared to deal with ~name expansion.
fe14fcc3 1333 */
2304df62
AD
1334#define SCRIPTDIR "$scriptdir" /**/
1335
a0d0e21e
LW
1336/* Select_fd_set_t:
1337 * This symbol holds the type used for the 2nd, 3rd, and 4th
1338 * arguments to select. Usually, this is 'fd_set *', if HAS_FD_SET
1339 * is defined, and 'int *' otherwise. This is only useful if you
1340 * have select(), of course.
1341 */
1342#define Select_fd_set_t $selecttype /**/
1343
1344/* SIG_NAME:
1345 * This symbol contains a list of signal names in order. This is intended
1346 * to be used as a static array initialization, like this:
1347 * char *sig_name[] = { SIG_NAME };
1348 * The signals in the list are separated with commas, and each signal
1349 * is surrounded by double quotes. There is no leading SIG in the signal
1350 * name, i.e. SIGQUIT is known as "QUIT".
1351 */
1352#define SIG_NAME "`echo $sig_name | sed 's/ /","/g'`" /**/
1353
1354/* Size_t:
1355 * This symbol holds the type used to declare length parameters
1356 * for string functions. It is usually size_t, but may be
1357 * unsigned long, int, etc. It may be necessary to include
1358 * <sys/types.h> to get any typedef'ed information.
1359 */
1360#define Size_t $sizetype /* length paramater for string functions */
1361
ecfc5424
AD
1362/* SSize_t:
1363 * This symbol holds the type used by functions that return
1364 * a count of bytes or an error condition. It must be a signed type.
1365 * It is usually ssize_t, but may be long or int, etc.
1366 * It may be necessary to include <sys/types.h> or <unistd.h>
1367 * to get any typedef'ed information.
1368 * We will pick a type such that sizeof(SSize_t) == sizeof(Size_t).
1369 */
1370#define SSize_t $ssizetype /* signed count of bytes */
1371
2304df62
AD
1372/* STDCHAR:
1373 * This symbol is defined to be the type of char used in stdio.h.
1374 * It has the values "unsigned char" or "char".
fe14fcc3 1375 */
2304df62
AD
1376#define STDCHAR $stdchar /**/
1377
1378/* Uid_t:
1379 * This symbol holds the type used to declare user ids in the kernel.
1380 * It can be int, ushort, uid_t, etc... It may be necessary to include
1381 * <sys/types.h> to get any typedef'ed information.
fe14fcc3 1382 */
2304df62 1383#define Uid_t $uidtype /* UID type */
fe14fcc3 1384
a0d0e21e
LW
1385/* VOIDFLAGS:
1386 * This symbol indicates how much support of the void type is given by this
1387 * compiler. What various bits mean:
1388 *
1389 * 1 = supports declaration of void
1390 * 2 = supports arrays of pointers to functions returning void
1391 * 4 = supports comparisons between pointers to void functions and
1392 * addresses of void functions
1393 * 8 = suports declaration of generic void pointers
1394 *
1395 * The package designer should define VOIDUSED to indicate the requirements
1396 * of the package. This can be done either by #defining VOIDUSED before
1397 * including config.h, or by defining defvoidused in Myinit.U. If the
1398 * latter approach is taken, only those flags will be tested. If the
1399 * level of void support necessary is not present, defines void to int.
1400 */
1401#ifndef VOIDUSED
1402#define VOIDUSED $defvoidused
1403#endif
1404#define VOIDFLAGS $voidflags
1405#if (VOIDFLAGS & VOIDUSED) != VOIDUSED
1406#define void int /* is void to be avoided? */
1407#define M_VOID /* Xenix strikes again */
1408#endif
1409
85e6fe83
LW
1410/* VMS:
1411 * This symbol, if defined, indicates that the program is running under
1412 * VMS. It is currently only set in conjunction with the EUNICE symbol.
1413 */
85e6fe83
LW
1414#$d_eunice VMS /**/
1415
a0d0e21e
LW
1416/* LOC_SED:
1417 * This symbol holds the complete pathname to the sed program.
85e6fe83 1418 */
1aef975c
AD
1419#define LOC_SED "$full_sed" /**/
1420
1421/* CSH:
1422 * This symbol, if defined, indicates that the C-shell exists.
1423 * If defined, contains the full pathname of csh.
1424 */
1425#$d_csh CSH "$full_csh" /**/
85e6fe83 1426
a0d0e21e
LW
1427/* DLSYM_NEEDS_UNDERSCORE:
1428 * This symbol, if defined, indicates that we need to prepend an
1429 * underscore to the symbol name before calling dlsym(). This only
1430 * makes sense if you *have* dlsym, which we will presume is the
1431 * case if you're using dl_dlopen.xs.
85e6fe83 1432 */
a0d0e21e
LW
1433#$d_dlsymun DLSYM_NEEDS_UNDERSCORE /* */
1434
2304df62
AD
1435/* USE_DYNAMIC_LOADING:
1436 * This symbol, if defined, indicates that dynamic loading of
1437 * some sort is available.
a687059c 1438 */
2304df62 1439#$usedl USE_DYNAMIC_LOADING /**/
a687059c 1440
1aef975c
AD
1441/* I_SYS_STAT:
1442 * This symbol, if defined, indicates to the C program that it should
1443 * include <sys/stat.h>.
1444 */
1445#$i_sysstat I_SYS_STAT /**/
1446
94b6baf5
AD
1447/* Free_t:
1448 * This variable contains the return type of free(). It is usually
1449 * void, but occasionally int.
1450 */
2304df62
AD
1451/* Malloc_t:
1452 * This symbol is the type of pointer returned by malloc and realloc.
36ce8bec 1453 */
2304df62 1454#define Malloc_t $malloctype /**/
94b6baf5 1455#define Free_t $freetype /**/
36ce8bec 1456
85e6fe83
LW
1457/* MYMALLOC:
1458 * This symbol, if defined, indicates that we're using our own malloc.
1459 */
1460#$d_mymalloc MYMALLOC /**/
1461
16d20bd9
AD
1462/* SITELIB_EXP:
1463 * This symbol contains the ~name expanded version of SITELIB, to be used
1464 * in programs that are not prepared to deal with ~ expansion at run-time.
1465 */
1466#$d_sitelib SITELIB_EXP "$sitelibexp" /**/
1467
fe14fcc3 1468#endif
8d063cd8 1469!GROK!THIS!