This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perl 3.0 patch #36 patch #29, continued
[perl5.git] / config.h.SH
CommitLineData
8d063cd8
LW
1case $CONFIG in
2'')
3 if test ! -f config.sh; then
4 ln ../config.sh . || \
5 ln ../../config.sh . || \
6 ln ../../../config.sh . || \
7 (echo "Can't find config.sh."; exit 1)
8 echo "Using config.sh from above..."
9 fi
378cc40b 10 . ./config.sh
8d063cd8
LW
11 ;;
12esac
13echo "Extracting config.h (with variable substitutions)"
13281fa4 14sed <<!GROK!THIS! >config.h -e 's!^#undef!/\*#undef!'
8d063cd8
LW
15/* config.h
16 * This file was produced by running the config.h.SH script, which
17 * gets its values from config.sh, which is generally produced by
18 * running Configure.
19 *
20 * Feel free to modify any of this as the need arises. Note, however,
21 * that running config.h.SH again will wipe out any changes you've made.
22 * For a more permanent change edit config.sh and rerun config.h.SH.
23 */
24
25
26/* EUNICE:
27 * This symbol, if defined, indicates that the program is being compiled
28 * under the EUNICE package under VMS. The program will need to handle
29 * things like files that don't go away the first time you unlink them,
30 * due to version numbering. It will also need to compensate for lack
31 * of a respectable link() command.
32 */
33/* VMS:
34 * This symbol, if defined, indicates that the program is running under
35 * VMS. It is currently only set in conjunction with the EUNICE symbol.
36 */
37#$d_eunice EUNICE /**/
38#$d_eunice VMS /**/
39
a687059c
LW
40/* BIN:
41 * This symbol holds the name of the directory in which the user wants
42 * to put publicly executable images for the package in question. It
43 * is most often a local directory such as /usr/local/bin.
44 */
45#define BIN "$bin" /**/
46
47/* BYTEORDER:
48 * This symbol contains an encoding of the order of bytes in a long.
49 * Usual values (in octal) are 01234, 04321, 02143, 03412...
50 */
0d3e774c 51#define BYTEORDER 0x$byteorder /**/
a687059c 52
378cc40b 53/* CPPSTDIN:
36ce8bec
DFDL
54 * This symbol contains the first part of the string which will invoke
55 * the C preprocessor on the standard input and produce to standard
56 * output. Typical value of "cc -E" or "/lib/cpp".
57 */
58/* CPPMINUS:
59 * This symbol contains the second part of the string which will invoke
60 * the C preprocessor on the standard input and produce to standard
378cc40b 61 * output. This symbol will have the value "-" if CPPSTDIN needs a minus
36ce8bec
DFDL
62 * to specify standard input, otherwise the value is "".
63 */
378cc40b 64#define CPPSTDIN "$cppstdin"
36ce8bec
DFDL
65#define CPPMINUS "$cppminus"
66
a687059c
LW
67/* BCMP:
68 * This symbol, if defined, indicates that the bcmp routine is available
69 * to compare blocks of memory. If undefined, use memcmp. If that's
70 * not available, roll your own.
71 */
72#$d_bcmp BCMP /**/
73
c51b80d1
LW
74/* BCOPY:
75 * This symbol, if defined, indicates that the bcopy routine is available
76 * to copy blocks of memory. Otherwise you should probably use memcpy().
77 */
78#$d_bcopy BCOPY /**/
79
0d3e774c
LW
80/* BZERO:
81 * This symbol, if defined, indicates that the bzero routine is available
82 * to zero blocks of memory. Otherwise you should probably use memcpy().
83 */
84#$d_bzero BZERO /**/
85
b1248f16
LW
86/* CASTNEGFLOAT:
87 * This symbol, if defined, indicates that this C compiler knows how to
88 * cast negative numbers to unsigned longs, ints and shorts.
89 */
90#$d_castneg CASTNEGFLOAT /**/
91
8d063cd8
LW
92/* CHARSPRINTF:
93 * This symbol is defined if this system declares "char *sprintf()" in
94 * stdio.h. The trend seems to be to declare it as "int sprintf()". It
95 * is up to the package author to declare sprintf correctly based on the
96 * symbol.
97 */
98#$d_charsprf CHARSPRINTF /**/
99
87250799
LW
100/* CHSIZE:
101 * This symbol, if defined, indicates that the chsize routine is available
102 * to truncate files. You might need a -lx to get this routine.
103 */
104#$d_chsize CHSIZE /**/
105
2e1b3b7e
KK
106/* CRYPT:
107 * This symbol, if defined, indicates that the crypt routine is available
108 * to encrypt passwords and the like.
109 */
110#$d_crypt CRYPT /**/
111
bf38876a
LW
112/* CSH:
113 * This symbol, if defined, indicates that the C-shell exists.
114 * If defined, contains the full pathname of csh.
115 */
116#$d_csh CSH "$csh" /**/
117
13281fa4
LW
118/* DOSUID:
119 * This symbol, if defined, indicates that the C program should
120 * check the script that it is executing for setuid/setgid bits, and
121 * attempt to emulate setuid/setgid on systems that have disabled
122 * setuid #! scripts because the kernel can't do it securely.
123 * It is up to the package designer to make sure that this emulation
124 * is done securely. Among other things, it should do an fstat on
125 * the script it just opened to make sure it really is a setuid/setgid
126 * script, it should make sure the arguments passed correspond exactly
127 * to the argument on the #! line, and it should not trust any
128 * subprocesses to which it must pass the filename rather than the
129 * file descriptor of the script to be executed.
130 */
131#$d_dosuid DOSUID /**/
132
a687059c
LW
133/* DUP2:
134 * This symbol, if defined, indicates that the dup2 routine is available
135 * to dup file descriptors. Otherwise you should use dup().
136 */
137#$d_dup2 DUP2 /**/
138
378cc40b
LW
139/* FCHMOD:
140 * This symbol, if defined, indicates that the fchmod routine is available
141 * to change mode of opened files. If unavailable, use chmod().
142 */
143#$d_fchmod FCHMOD /**/
144
145/* FCHOWN:
146 * This symbol, if defined, indicates that the fchown routine is available
147 * to change ownership of opened files. If unavailable, use chown().
148 */
149#$d_fchown FCHOWN /**/
150
a687059c
LW
151/* FCNTL:
152 * This symbol, if defined, indicates to the C program that it should
153 * include fcntl.h.
154 */
155#$d_fcntl FCNTL /**/
156
157/* FLOCK:
158 * This symbol, if defined, indicates that the flock() routine is
159 * available to do file locking.
160 */
161#$d_flock FLOCK /**/
162
378cc40b
LW
163/* GETGROUPS:
164 * This symbol, if defined, indicates that the getgroups() routine is
165 * available to get the list of process groups. If unavailable, multiple
166 * groups are probably not supported.
167 */
168#$d_getgrps GETGROUPS /**/
169
a687059c
LW
170/* GETHOSTENT:
171 * This symbol, if defined, indicates that the gethostent() routine is
172 * available to lookup host names in some data base or other.
173 */
174#$d_gethent GETHOSTENT /**/
175
176/* GETPGRP:
177 * This symbol, if defined, indicates that the getpgrp() routine is
178 * available to get the current process group.
179 */
180#$d_getpgrp GETPGRP /**/
181
d8f2e4cc
LW
182/* GETPGRP2:
183 * This symbol, if defined, indicates that the getpgrp2() (as in DG/UX)
184 * routine is available to get the current process group.
185 */
186#$d_getpgrp2 GETPGRP2 /**/
187
a687059c
LW
188/* GETPRIORITY:
189 * This symbol, if defined, indicates that the getpriority() routine is
190 * available to get a process's priority.
191 */
192#$d_getprior GETPRIORITY /**/
193
194/* HTONS:
195 * This symbol, if defined, indicates that the htons routine (and friends)
196 * are available to do network order byte swapping.
197 */
198/* HTONL:
199 * This symbol, if defined, indicates that the htonl routine (and friends)
200 * are available to do network order byte swapping.
201 */
202/* NTOHS:
203 * This symbol, if defined, indicates that the ntohs routine (and friends)
204 * are available to do network order byte swapping.
205 */
206/* NTOHL:
207 * This symbol, if defined, indicates that the ntohl routine (and friends)
208 * are available to do network order byte swapping.
209 */
210#$d_htonl HTONS /**/
211#$d_htonl HTONL /**/
212#$d_htonl NTOHS /**/
213#$d_htonl NTOHL /**/
214
8d063cd8
LW
215/* index:
216 * This preprocessor symbol is defined, along with rindex, if the system
217 * uses the strchr and strrchr routines instead.
218 */
219/* rindex:
220 * This preprocessor symbol is defined, along with index, if the system
221 * uses the strchr and strrchr routines instead.
222 */
223#$d_index index strchr /* cultural */
224#$d_index rindex strrchr /* differences? */
225
a687059c
LW
226/* IOCTL:
227 * This symbol, if defined, indicates that sys/ioctl.h exists and should
228 * be included.
229 */
230#$d_ioctl IOCTL /**/
231
378cc40b
LW
232/* KILLPG:
233 * This symbol, if defined, indicates that the killpg routine is available
234 * to kill process groups. If unavailable, you probably should use kill
235 * with a negative process number.
236 */
237#$d_killpg KILLPG /**/
238
0d3e774c
LW
239/* LSTAT:
240 * This symbol, if defined, indicates that the lstat() routine is
241 * available to do file locking.
242 */
243#$d_lstat LSTAT /**/
244
a687059c
LW
245/* MEMCMP:
246 * This symbol, if defined, indicates that the memcmp routine is available
247 * to compare blocks of memory. If undefined, roll your own.
248 */
249#$d_memcmp MEMCMP /**/
250
378cc40b
LW
251/* MEMCPY:
252 * This symbol, if defined, indicates that the memcpy routine is available
253 * to copy blocks of memory. Otherwise you should probably use bcopy().
254 * If neither is defined, roll your own.
255 */
256#$d_memcpy MEMCPY /**/
257
a687059c
LW
258/* MKDIR:
259 * This symbol, if defined, indicates that the mkdir routine is available
260 * to create directories. Otherwise you should fork off a new process to
261 * exec /bin/mkdir.
262 */
263#$d_mkdir MKDIR /**/
264
265/* NDBM:
266 * This symbol, if defined, indicates that ndbm.h exists and should
267 * be included.
268 */
269#$d_ndbm NDBM /**/
270
271/* ODBM:
272 * This symbol, if defined, indicates that dbm.h exists and should
273 * be included.
274 */
275#$d_odbm ODBM /**/
276
277/* READDIR:
278 * This symbol, if defined, indicates that the readdir routine is available
279 * from the C library to create directories.
280 */
281#$d_readdir READDIR /**/
282
378cc40b
LW
283/* RENAME:
284 * This symbol, if defined, indicates that the rename routine is available
285 * to rename files. Otherwise you should do the unlink(), link(), unlink()
286 * trick.
287 */
288#$d_rename RENAME /**/
289
a687059c
LW
290/* RMDIR:
291 * This symbol, if defined, indicates that the rmdir routine is available
292 * to remove directories. Otherwise you should fork off a new process to
293 * exec /bin/rmdir.
294 */
295#$d_rmdir RMDIR /**/
296
87250799
LW
297/* SELECT:
298 * This symbol, if defined, indicates that the select routine is available
299 * to select active file descriptors.
300 */
301#$d_select SELECT /**/
302
378cc40b
LW
303/* SETEGID:
304 * This symbol, if defined, indicates that the setegid routine is available
305 * to change the effective gid of the current program.
306 */
307#$d_setegid SETEGID /**/
308
309/* SETEUID:
310 * This symbol, if defined, indicates that the seteuid routine is available
311 * to change the effective uid of the current program.
312 */
313#$d_seteuid SETEUID /**/
314
a687059c
LW
315/* SETPGRP:
316 * This symbol, if defined, indicates that the setpgrp() routine is
317 * available to set the current process group.
318 */
319#$d_setpgrp SETPGRP /**/
320
d8f2e4cc
LW
321/* SETPGRP2:
322 * This symbol, if defined, indicates that the setpgrp2() (as in DG/UX)
323 * routine is available to set the current process group.
324 */
325#$d_setpgrp2 SETPGRP2 /**/
326
a687059c
LW
327/* SETPRIORITY:
328 * This symbol, if defined, indicates that the setpriority() routine is
329 * available to set a process's priority.
330 */
331#$d_setprior SETPRIORITY /**/
332
333/* SETREGID:
334 * This symbol, if defined, indicates that the setregid routine is
335 * available to change the real and effective gid of the current program.
336 */
337/* SETRESGID:
338 * This symbol, if defined, indicates that the setresgid routine is
339 * available to change the real, effective and saved gid of the current
340 * program.
341 */
342#$d_setregid SETREGID /**/
343#$d_setresgid SETRESGID /**/
344
345/* SETREUID:
346 * This symbol, if defined, indicates that the setreuid routine is
347 * available to change the real and effective uid of the current program.
348 */
349/* SETRESUID:
350 * This symbol, if defined, indicates that the setresuid routine is
351 * available to change the real, effective and saved uid of the current
352 * program.
353 */
354#$d_setreuid SETREUID /**/
355#$d_setresuid SETRESUID /**/
356
378cc40b
LW
357/* SETRGID:
358 * This symbol, if defined, indicates that the setrgid routine is available
359 * to change the real gid of the current program.
360 */
361#$d_setrgid SETRGID /**/
362
363/* SETRUID:
364 * This symbol, if defined, indicates that the setruid routine is available
365 * to change the real uid of the current program.
366 */
367#$d_setruid SETRUID /**/
368
a687059c
LW
369/* SOCKET:
370 * This symbol, if defined, indicates that the BSD socket interface is
371 * supported.
372 */
373/* SOCKETPAIR:
374 * This symbol, if defined, indicates that the BSD socketpair call is
375 * supported.
376 */
377/* OLDSOCKET:
378 * This symbol, if defined, indicates that the 4.1c BSD socket interface
379 * is supported instead of the 4.2/4.3 BSD socket interface.
380 */
381#$d_socket SOCKET /**/
382
383#$d_sockpair SOCKETPAIR /**/
384
385#$d_oldsock OLDSOCKET /**/
386
c51b80d1
LW
387/* STATBLOCKS:
388 * This symbol is defined if this system has a stat structure declaring
389 * st_blksize and st_blocks.
390 */
391#$d_statblks STATBLOCKS /**/
392
36ce8bec
DFDL
393/* STDSTDIO:
394 * This symbol is defined if this system has a FILE structure declaring
395 * _ptr and _cnt in stdio.h.
396 */
397#$d_stdstdio STDSTDIO /**/
398
8d063cd8
LW
399/* STRUCTCOPY:
400 * This symbol, if defined, indicates that this C compiler knows how
401 * to copy structures. If undefined, you'll need to use a block copy
402 * routine of some sort instead.
403 */
404#$d_strctcpy STRUCTCOPY /**/
405
d8f2e4cc
LW
406/* STRERROR:
407 * This symbol, if defined, indicates that the strerror() routine is
408 * available to translate error numbers to strings.
409 */
410#$d_strerror STRERROR /**/
411
2e1b3b7e
KK
412/* SYMLINK:
413 * This symbol, if defined, indicates that the symlink routine is available
414 * to create symbolic links.
415 */
416#$d_symlink SYMLINK /**/
417
a687059c
LW
418/* SYSCALL:
419 * This symbol, if defined, indicates that the syscall routine is available
420 * to call arbitrary system calls. If undefined, that's tough.
421 */
422#$d_syscall SYSCALL /**/
423
39c3038c
LW
424/* SYSVIPC:
425 * This symbol, if defined, indicates that System V IPC exists.
426 */
427#$d_sysvipc SYSVIPC /**/
428
87250799
LW
429/* TRUNCATE:
430 * This symbol, if defined, indicates that the truncate routine is
431 * available to truncate files.
432 */
433#$d_truncate TRUNCATE /**/
434
a687059c
LW
435/* VARARGS:
436 * This symbol, if defined, indicates to the C program that it should
437 * include varargs.h.
438 */
439#$d_varargs VARARGS /**/
c51b80d1 440
03a14243
LW
441/* VFORK:
442 * This symbol, if defined, indicates that vfork() exists.
8d063cd8 443 */
03a14243 444#$d_vfork VFORK /**/
8d063cd8 445
36ce8bec
DFDL
446/* VOIDSIG:
447 * This symbol is defined if this system declares "void (*signal())()" in
448 * signal.h. The old way was to declare it as "int (*signal())()". It
449 * is up to the package author to declare things correctly based on the
450 * symbol.
451 */
452#$d_voidsig VOIDSIG /**/
453
afd9f252
LW
454/* HASVOLATILE:
455 * This symbol, if defined, indicates that this C compiler knows about
456 * the volatile declaration.
457 */
458#$d_volatile HASVOLATILE /**/
459
a687059c
LW
460/* VPRINTF:
461 * This symbol, if defined, indicates that the vprintf routine is available
462 * to printf with a pointer to an argument list. If unavailable, you
463 * may need to write your own, probably in terms of _doprnt().
464 */
465/* CHARVSPRINTF:
466 * This symbol is defined if this system has vsprintf() returning type
467 * (char*). The trend seems to be to declare it as "int vsprintf()". It
468 * is up to the package author to declare vsprintf correctly based on the
469 * symbol.
470 */
471#$d_vprintf VPRINTF /**/
472#$d_charvspr CHARVSPRINTF /**/
473
bf38876a
LW
474/* WAIT4:
475 * This symbol, if defined, indicates that wait4() exists.
476 */
477#$d_wait4 WAIT4 /**/
478
39c3038c
LW
479/* WAITPID:
480 * This symbol, if defined, indicates that waitpid() exists.
481 */
482#$d_waitpid WAITPID /**/
483
378cc40b
LW
484/* GIDTYPE:
485 * This symbol has a value like gid_t, int, ushort, or whatever type is
486 * used to declare group ids in the kernel.
487 */
488#define GIDTYPE $gidtype /**/
489
a687059c
LW
490/* I_DIRENT:
491 * This symbol, if defined, indicates to the C program that it should
492 * include dirent.h.
493 */
494/* DIRNAMLEN:
495 * This symbol, if defined, indicates to the C program that the length
496 * of directory entry names is provided by a d_namlen field. Otherwise
497 * you need to do strlen() on the d_name field.
498 */
499#$i_dirent I_DIRENT /**/
500#$d_dirnamlen DIRNAMLEN /**/
501
502/* I_FCNTL:
503 * This symbol, if defined, indicates to the C program that it should
504 * include fcntl.h.
505 */
506#$i_fcntl I_FCNTL /**/
507
508/* I_GRP:
509 * This symbol, if defined, indicates to the C program that it should
510 * include grp.h.
511 */
512#$i_grp I_GRP /**/
513
03a14243
LW
514/* I_NETINET_IN:
515 * This symbol, if defined, indicates to the C program that it should
516 * include netinet/in.h.
517 */
518#$i_niin I_NETINET_IN /**/
519
a687059c
LW
520/* I_PWD:
521 * This symbol, if defined, indicates to the C program that it should
522 * include pwd.h.
523 */
39c3038c
LW
524/* PWCOMMENT:
525 * This symbol, if defined, indicates to the C program that struct passwd
526 * contains pw_comment.
527 */
a687059c
LW
528/* PWQUOTA:
529 * This symbol, if defined, indicates to the C program that struct passwd
530 * contains pw_quota.
531 */
532/* PWAGE:
533 * This symbol, if defined, indicates to the C program that struct passwd
534 * contains pw_age.
535 */
03a14243
LW
536/* PWCHANGE:
537 * This symbol, if defined, indicates to the C program that struct passwd
538 * contains pw_change.
539 */
540/* PWCLASS:
541 * This symbol, if defined, indicates to the C program that struct passwd
542 * contains pw_class.
543 */
544/* PWEXPIRE:
545 * This symbol, if defined, indicates to the C program that struct passwd
546 * contains pw_expire.
547 */
a687059c 548#$i_pwd I_PWD /**/
39c3038c 549#$d_pwcomment PWCOMMENT /**/
a687059c
LW
550#$d_pwquota PWQUOTA /**/
551#$d_pwage PWAGE /**/
bf38876a
LW
552#$d_pwchange PWCHANGE /**/
553#$d_pwclass PWCLASS /**/
554#$d_pwexpire PWEXPIRE /**/
a687059c
LW
555
556/* I_SYSDIR:
557 * This symbol, if defined, indicates to the C program that it should
558 * include sys/dir.h.
559 */
560#$i_sysdir I_SYSDIR /**/
561
562/* I_SYSIOCTL:
563 * This symbol, if defined, indicates that sys/ioctl.h exists and should
564 * be included.
565 */
566#$i_sysioctl I_SYSIOCTL /**/
567
d8f2e4cc
LW
568/* I_SYSNDIR:
569 * This symbol, if defined, indicates to the C program that it should
570 * include sys/ndir.h.
571 */
572#$i_sysndir I_SYSNDIR /**/
573
574/* I_TIME:
575 * This symbol is defined if the program should include <time.h>.
576 */
577/* I_SYSTIME:
578 * This symbol is defined if the program should include <sys/time.h>.
579 */
580/* I_SYSTIMEKERNEL:
581 * This symbol is defined if the program should include <sys/time.h>
582 * with KERNEL defined.
583 */
584#$i_time I_TIME /**/
585#$i_systime I_SYSTIME /**/
586#$d_systimekernel SYSTIMEKERNEL /**/
587
588/* I_UTIME:
589 * This symbol, if defined, indicates to the C program that it should
afd9f252 590 * include utime.h.
d8f2e4cc
LW
591 */
592#$i_utime I_UTIME /**/
593
a687059c
LW
594/* I_VARARGS:
595 * This symbol, if defined, indicates to the C program that it should
596 * include varargs.h.
597 */
598#$i_varargs I_VARARGS /**/
599
600/* I_VFORK:
601 * This symbol, if defined, indicates to the C program that it should
602 * include vfork.h.
603 */
604#$i_vfork I_VFORK /**/
605
606/* INTSIZE:
607 * This symbol contains the size of an int, so that the C preprocessor
608 * can make decisions based on it.
609 */
610#define INTSIZE $intsize /**/
611
612/* RANDBITS:
613 * This symbol contains the number of bits of random number the rand()
614 * function produces. Usual values are 15, 16, and 31.
615 */
616#define RANDBITS $randbits /**/
617
87250799
LW
618/* SCRIPTDIR:
619 * This symbol holds the name of the directory in which the user wants
620 * to put publicly executable scripts for the package in question. It
621 * is often a directory that is mounted across diverse architectures.
622 */
623#define SCRIPTDIR "$scriptdir" /**/
624
a687059c
LW
625/* SIG_NAME:
626 * This symbol contains an list of signal names in order.
627 */
628#define SIG_NAME "`echo $sig_name | sed 's/ /","/g'`" /**/
629
36ce8bec
DFDL
630/* STDCHAR:
631 * This symbol is defined to be the type of char used in stdio.h.
632 * It has the values "unsigned char" or "char".
633 */
634#define STDCHAR $stdchar /**/
635
378cc40b
LW
636/* UIDTYPE:
637 * This symbol has a value like uid_t, int, ushort, or whatever type is
638 * used to declare user ids in the kernel.
639 */
640#define UIDTYPE $uidtype /**/
641
8d063cd8
LW
642/* VOIDFLAGS:
643 * This symbol indicates how much support of the void type is given by this
644 * compiler. What various bits mean:
645 *
646 * 1 = supports declaration of void
647 * 2 = supports arrays of pointers to functions returning void
648 * 4 = supports comparisons between pointers to void functions and
649 * addresses of void functions
650 *
651 * The package designer should define VOIDUSED to indicate the requirements
652 * of the package. This can be done either by #defining VOIDUSED before
653 * including config.h, or by defining defvoidused in Myinit.U. If the
a687059c 654 * latter approach is taken, only those flags will be tested. If the
8d063cd8
LW
655 * level of void support necessary is not present, defines void to int.
656 */
657#ifndef VOIDUSED
658#define VOIDUSED $defvoidused
659#endif
660#define VOIDFLAGS $voidflags
661#if (VOIDFLAGS & VOIDUSED) != VOIDUSED
662#$define void int /* is void to be avoided? */
663#$define M_VOID /* Xenix strikes again */
664#endif
665
378cc40b
LW
666/* PRIVLIB:
667 * This symbol contains the name of the private library for this package.
668 * The library is private in the sense that it needn't be in anyone's
a687059c
LW
669 * execution path, but it should be accessible by the world. The program
670 * should be prepared to do ~ expansion.
378cc40b
LW
671 */
672#define PRIVLIB "$privlib" /**/
673
8d063cd8 674!GROK!THIS!