imakemdep.h revision 0eb10989
1/* $Xorg: imakemdep.h,v 1.6 2001/02/09 02:03:16 xorgcvs Exp $ */
2/* $XdotOrg: xc/config/imake/imakemdep.h,v 1.9 2005/03/02 11:20:29 gisburn Exp $ */
3/*
4
5Copyright (c) 1993, 1994, 1998  The Open Group
6
7Permission to use, copy, modify, distribute, and sell this software and its
8documentation for any purpose is hereby granted without fee, provided that
9the above copyright notice appear in all copies and that both that
10copyright notice and this permission notice appear in supporting
11documentation.
12
13The above copyright notice and this permission notice shall be included in
14all copies or substantial portions of the Software.
15
16THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
19OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
20AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
21CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
23Except as contained in this notice, the name of The Open Group shall not be
24used in advertising or otherwise to promote the sale, use or other dealings
25in this Software without prior written authorization from The Open Group.
26
27*/
28/* $XFree86: xc/config/imake/imakemdep.h,v 3.71 2003/06/12 14:12:26 eich Exp $ */
29
30
31/*
32 * This file contains machine-dependent constants for the imake utility.
33 * When porting imake, read each of the steps below and add in any necessary
34 * definitions.  In general you should *not* edit ccimake.c or imake.c!
35 */
36
37#ifdef __UNIXOS2__
38#define lstat stat
39#endif
40
41#ifdef CCIMAKE
42/*
43 * Step 1:  imake_ccflags
44 *     Define any special flags that will be needed to get imake.c to compile.
45 *     These will be passed to the compile along with the contents of the
46 *     make variable BOOTSTRAPCFLAGS.
47 */
48#if defined(clipper) || defined(__clipper__)
49#define imake_ccflags "-O -DSYSV -DBOOTSTRAPCFLAGS=-DSYSV"
50#endif
51
52#ifdef hpux
53#ifdef hp9000s800
54#define imake_ccflags "-DSYSV"
55#else
56#define imake_ccflags "-Wc,-Nd4000,-Ns3000 -DSYSV"
57#endif
58#endif
59
60#if defined(macII) || defined(_AUX_SOURCE)
61#define imake_ccflags "-DmacII -DSYSV"
62#endif
63
64#ifdef stellar
65#define imake_ccflags "-DSYSV"
66#endif
67
68/*
69 * SCO UnixWare and OpenServer 6 are both System V Release 5 based OSes.
70 * The native C compiler doesn't assert __UNIXWARE__ but gcc does, so
71 * we don't redefine it if we are using gcc (as it sets it to a specific
72 * value). On OpenServer 6, which is a multi-ABI world, if you attempt
73 * to build with -Kosr, then the C compiler will assert __OPENSERVER__
74 * and set it to the value 507.  That indicates an OSR5 compile, and
75 * is handled below.
76 */
77
78#if defined(__UNIXWARE__) || defined(__USLC__) || defined(Oki) || defined(NCR)
79# ifdef imake_ccflags
80#  undef imake_ccflags
81# endif
82# ifdef __UNIXWARE__
83#  ifndef __GNUC__
84#   define imake_ccflags "-Xa -DSVR4 -DSVR5 -D__UNIXWARE__"
85#  else
86#   define imake_ccflags "-Xa -DSVR4 -DSVR5"
87#  endif
88# else
89#  define imake_ccflags "-Xa -DSVR4"
90# endif
91#endif
92
93/* SCO may define __USLC__ so put this after the USL check */
94#if defined(M_UNIX) || defined(_SCO_DS) || defined(__OPENSERVER__)
95# ifdef imake_ccflags
96#  undef imake_ccflags
97# endif
98# define imake_ccflags "-DSYSV -DSCO325 -D__SCO__"
99#endif
100
101#ifdef sony
102#if defined(SYSTYPE_SYSV) || defined(_SYSTYPE_SYSV)
103#define imake_ccflags "-DSVR4"
104#else
105#include <sys/param.h>
106#if NEWSOS < 41
107#define imake_ccflags "-Dbsd43 -DNOSTDHDRS"
108#else
109#if NEWSOS < 42
110#define imake_ccflags "-Dbsd43"
111#endif
112#endif
113#endif
114#endif
115#ifdef _CRAY
116#define imake_ccflags "-DSYSV -DUSG"
117#endif
118
119#if defined(_IBMR2) || defined(aix)
120#define imake_ccflags "-Daix -DSYSV"
121#endif
122
123#ifdef Mips
124#  if defined(SYSTYPE_BSD) || defined(BSD) || defined(BSD43)
125#    define imake_ccflags "-DBSD43"
126#  else
127#    define imake_ccflags "-DSYSV"
128#  endif
129#endif
130
131#ifdef is68k
132#define imake_ccflags "-Dluna -Duniosb"
133#endif
134
135#ifdef SYSV386
136# ifdef SVR4
137#  define imake_ccflags "-Xa -DSVR4"
138# else
139#  define imake_ccflags "-DSYSV"
140# endif
141#endif
142
143#ifdef SVR4
144# ifdef i386
145#  define imake_ccflags "-Xa -DSVR4"
146# endif
147#endif
148
149#ifdef SYSV
150# ifdef i386
151#  define imake_ccflags "-DSYSV"
152# endif
153#endif
154
155#if defined(Lynx) || defined(__Lynx__)
156#define imake_ccflags "-DLynx"
157#endif /* Lynx */
158
159#ifdef __convex__
160#define imake_ccflags "-fn -tm c1"
161#endif
162
163#ifdef apollo
164#define imake_ccflags "-DX_NOT_POSIX"
165#endif
166
167#ifdef WIN32
168#ifdef __GNUC__
169#define imake_ccflags "-D__STDC__"
170#else
171#if _MSC_VER < 1000
172#define imake_ccflags "-nologo -batch -D__STDC__"
173#else
174#define imake_ccflags "-nologo -D__STDC__"
175#endif
176#endif
177#endif
178
179#ifdef __uxp__
180#define imake_ccflags "-DSVR4 -DANSICPP"
181#endif
182
183#ifdef __sxg__
184#define imake_ccflags "-DSYSV -DUSG -DNOSTDHDRS"
185#endif
186
187#ifdef _SEQUENT_
188#define imake_ccflags "-Xa -DSVR4"
189#endif
190
191#if defined(SX) || defined(PC_UX)
192#define imake_ccflags "-DSYSV"
193#endif
194
195#ifdef nec_ews_svr2
196#define imake_ccflags "-DUSG"
197#endif
198
199#if defined(nec_ews_svr4) || defined(_nec_ews_svr4) || defined(_nec_up) || defined(_nec_ft)
200#define imake_ccflags "-DSVR4"
201#endif
202
203#if defined(MACH) && !defined(__GNU__)
204#define imake_ccflags "-DNOSTDHDRS"
205#endif
206
207/* this is for OS/2 under UNIXOS2. This won't work with DOS */
208#if defined(__UNIXOS2__)
209#define imake_ccflags "-DBSD43"
210#endif
211
212#if defined(__QNX__) && !defined(__QNXNTO__)
213#define imake_ccflags "-D__QNX__ -D_i386"
214#endif
215
216#if defined(__QNXNTO__)
217#define imake_ccflags "-D__QNXNTO__"
218#endif
219
220#else /* not CCIMAKE */
221#ifndef MAKEDEPEND
222/*
223 * Step 2:  dup2
224 *     If your OS doesn't have a dup2() system call to duplicate one file
225 *     descriptor onto another, define such a mechanism here (if you don't
226 *     already fall under the existing category(ies).
227 */
228#if defined(SYSV) && !defined(_CRAY) && !defined(Mips) && !defined(_SEQUENT_) && !defined(__SCO__)
229#define	dup2(fd1,fd2)	((fd1 == fd2) ? fd1 : (close(fd2), \
230					       fcntl(fd1, F_DUPFD, fd2)))
231#endif
232
233
234/*
235 * Step 3:  FIXUP_CPP_WHITESPACE
236 *     If your cpp collapses tabs in macro expansions into a single space and
237 *     replaces escaped newlines with a space, define this symbol.  This will
238 *     cause imake to attempt to patch up the generated Makefile by looking
239 *     for lines that have colons in them (this is why the rules file escapes
240 *     all colons).  One way to tell if you need this is to see whether or not
241 *     your Makefiles have no tabs in them and lots of @@ strings.
242 */
243#if defined(sun) || defined(SYSV) || defined(SVR4) || defined(hcx) || defined(WIN32) || defined(__SCO__) || (defined(AMOEBA) && defined(CROSS_COMPILE)) || defined(__QNX__) || defined(__sgi) || defined(__UNIXOS2__) || defined(__UNIXWARE__)
244#define FIXUP_CPP_WHITESPACE
245#endif
246#ifdef WIN32
247#define REMOVE_CPP_LEADSPACE
248#define INLINE_SYNTAX
249#define MAGIC_MAKE_VARS
250#endif
251#ifdef __minix_vmd
252#define FIXUP_CPP_WHITESPACE
253#endif
254
255#if defined(Lynx)
256/* On LynxOS 2.4.0 imake gets built with the old "legacy"
257 * /bin/cc which has a rather pedantic builtin preprocessor.
258 * Using a macro which is not #defined (as in Step 5
259 * below) flags an *error*
260 */
261#define __NetBSD_Version__ 0
262#endif
263
264/*
265 * Step 4:  USE_CC_E, DEFAULT_CC, DEFAULT_CPP
266 *     If you want to use cc -E instead of cpp, define USE_CC_E.
267 *     If use cc -E but want a different compiler, define DEFAULT_CC.
268 *     If the cpp you need is not in /lib/cpp, define DEFAULT_CPP.
269 */
270#if !defined (CROSSCOMPILE) || defined (CROSSCOMPILE_CPP)
271
272#if defined(__APPLE__)
273#define DEFAULT_CPP "/usr/bin/cpp"
274#define DEFAULT_CC "cc"
275#endif
276#if defined(Lynx) || defined(__Lynx__)
277#define DEFAULT_CC "gcc"
278#define USE_CC_E
279#endif
280#ifdef hpux
281#define USE_CC_E
282#endif
283#ifdef WIN32
284#define USE_CC_E
285#ifdef __GNUC__
286#define DEFAULT_CC "gcc"
287#else
288#define DEFAULT_CC "cl"
289#endif
290#endif
291#ifdef apollo
292#define DEFAULT_CPP "/usr/lib/cpp"
293#endif
294#if defined(clipper) || defined(__clipper__)
295#define DEFAULT_CPP "/usr/lib/cpp"
296#endif
297#if defined(_IBMR2) && !defined(DEFAULT_CPP)
298#define DEFAULT_CPP "/usr/ccs/lib/cpp"
299#endif
300#if defined(sun) && (defined(SVR4) || defined(__svr4__) || defined(__SVR4) || defined(__sol__))
301#define DEFAULT_CPP "/usr/ccs/lib/cpp"
302#endif
303#ifdef __bsdi__
304#define DEFAULT_CPP "/usr/bin/cpp"
305#endif
306#ifdef __uxp__
307#define DEFAULT_CPP "/usr/ccs/lib/cpp"
308#endif
309#ifdef __sxg__
310#define DEFAULT_CPP "/usr/lib/cpp"
311#endif
312#ifdef _CRAY
313#define DEFAULT_CPP "/lib/pcpp"
314#endif
315#if defined(__386BSD__)
316#define DEFAULT_CPP "/usr/libexec/cpp"
317#endif
318#if defined(__FreeBSD__)  || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
319#define USE_CC_E
320#endif
321#if defined(__sgi) && defined(__ANSI_CPP__)
322#define USE_CC_E
323#endif
324#if defined(MACH) && !defined(__GNU__)
325#define USE_CC_E
326#endif
327#ifdef __minix_vmd
328#define DEFAULT_CPP "/usr/lib/cpp"
329#endif
330#if defined(__UNIXOS2__)
331/* expects cpp in PATH */
332#define DEFAULT_CPP "cpp"
333#endif
334#ifdef __CYGWIN__
335#define DEFAULT_CC "gcc"
336#define DEFAULT_CPP "/usr/bin/cpp"
337#endif
338#if defined (__QNX__)
339#ifdef __QNXNTO__
340#define DEFAULT_CPP "/usr/bin/cpp"
341#else
342#define DEFAULT_CPP "/usr/X11R6/bin/cpp"
343#endif
344#endif
345#if defined(__GNUC__) && !defined(USE_CC_E)
346#define USE_CC_E
347#ifndef DEFAULT_CC
348#define DEFAULT_CC "gcc"
349#endif
350#endif
351
352#endif /* !defined (CROSSCOMPILE) || defined (CROSSCOMPILE_CPP) */
353/*
354 * Step 5:  cpp_argv
355 *     The following table contains the flags that should be passed
356 *     whenever a Makefile is being generated.  If your preprocessor
357 *     doesn't predefine any unique symbols, choose one and add it to the
358 *     end of this table.  Then, do the following:
359 *
360 *         a.  Use this symbol in Imake.cf when setting MacroFile.
361 *         b.  Put this symbol in the definition of BootstrapCFlags in your
362 *             <platform>.cf file.
363 *         c.  When doing a make World, always add "BOOTSTRAPCFLAGS=-Dsymbol"
364 *             to the end of the command line.
365 *
366 *     Note that you may define more than one symbol (useful for platforms
367 *     that support multiple operating systems).
368 */
369
370#define	ARGUMENTS 50	/* number of arguments in various arrays */
371#if !defined (CROSSCOMPILE) || defined (CROSSCOMPILE_CPP)
372char *cpp_argv[ARGUMENTS] = {
373	"cc",		/* replaced by the actual program to exec */
374	"-I.",		/* add current directory to include path */
375#if !defined(__NetBSD_Version__) || __NetBSD_Version__ < 103080000
376#ifdef unix
377	"-Uunix",	/* remove unix symbol so that filename unix.c okay */
378#endif
379#endif
380#if defined(__386BSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || \
381    defined(__FreeBSD__) || defined(__DragonFly__) || defined(MACH) || \
382    defined(linux) || defined(__GNU__) || defined(__bsdi__) || \
383    defined(__GNUC__) || defined(__GLIBC__)
384# ifdef __i386__
385	"-D__i386__",
386#  if defined(__GNUC__) && (__GNUC__ >= 3)
387	"-m32",
388#  endif
389# endif
390# ifdef __i486__
391	"-D__i486__",
392# endif
393# ifdef __i586__
394	"-D__i586__",
395# endif
396# ifdef __i686__
397	"-D__i686__",
398# endif
399# ifdef __k6__
400	"-D__k6__",
401# endif
402# ifdef __ia64__
403	"-D__ia64__",
404# endif
405# ifdef __amd64__
406	"-D__amd64__",
407# endif
408# ifdef __x86_64__
409	"-D__amd64__",
410# endif
411# ifdef __s390__
412	"-D__s390__",
413# endif
414# ifdef __alpha__
415	"-D__alpha__",
416# endif
417# ifdef __arm__
418	"-D__arm__",
419# endif
420# ifdef __s390x__
421       "-D__s390x__",
422# endif
423# ifdef __sparc__
424	"-D__sparc__",
425# endif
426# ifdef __m68k__
427	"-D__m68k__",
428# endif
429# ifdef __hppa__
430	"-D__hppa__",
431# endif
432# ifdef __sh__
433	"-D__sh__",
434# endif
435# ifdef __sh3__
436	"-D__sh3__",
437# endif
438# ifdef __SH3__
439	"-D__SH3__",
440# endif
441# ifdef __SH4__
442	"-D__SH4__",
443# endif
444# ifdef __SH4NOFPU__
445	"-D__SH4_NOFPU__",
446# endif
447# ifdef __GNUC__
448	"-traditional",
449# endif
450#endif
451#ifdef M4330
452	"-DM4330",	/* Tektronix */
453#endif
454#ifdef M4310
455	"-DM4310",	/* Tektronix */
456#endif
457#if defined(macII) || defined(_AUX_SOURCE)
458	"-DmacII",	/* Apple A/UX */
459#endif
460#if defined(USL) || defined(__UNIXWARE__) || \
461	(defined(__USLC__) && !defined(_SCO_DS))
462	"-D__UNIXWARE__",	/* SCO UnixWare 7 */
463#endif
464#ifdef sony
465	"-Dsony",	/* Sony */
466#if !defined(SYSTYPE_SYSV) && !defined(_SYSTYPE_SYSV) && NEWSOS < 42
467	"-Dbsd43",
468#endif
469#endif
470#ifdef _IBMR2
471	"-D_IBMR2",	/* IBM RS-6000 (we ensured that aix is defined above */
472#ifndef aix
473#define aix		/* allow BOOTSTRAPCFLAGS="-D_IBMR2" */
474#endif
475#endif /* _IBMR2 */
476#ifdef aix
477	"-Daix",	/* AIX instead of AOS */
478#ifndef ibm
479#define ibm		/* allow BOOTSTRAPCFLAGS="-Daix" */
480#endif
481#endif /* aix */
482#ifdef ibm
483	"-Dibm",	/* IBM PS/2 and RT under both AOS and AIX */
484#endif
485#ifdef luna
486	"-Dluna",	/* OMRON luna 68K and 88K */
487#ifdef luna1
488	"-Dluna1",
489#endif
490#ifdef luna88k		/* need not on UniOS-Mach Vers. 1.13 */
491	"-traditional", /* for some older version            */
492#endif			/* instead of "-DXCOMM=\\#"          */
493#ifdef uniosb
494	"-Duniosb",
495#endif
496#ifdef uniosu
497	"-Duniosu",
498#endif
499#endif /* luna */
500#ifdef _CRAY		/* Cray */
501	"-Ucray",
502#endif
503#ifdef Mips
504	"-DMips",	/* Define and use Mips for Mips Co. OS/mach. */
505# if defined(SYSTYPE_BSD) || defined(BSD) || defined(BSD43)
506	"-DBSD43",	/* Mips RISCOS supports two environments */
507# else
508	"-DSYSV",	/* System V environment is the default */
509# endif
510#endif /* Mips */
511#ifdef MOTOROLA
512	"-DMOTOROLA",    /* Motorola Delta Systems */
513# ifdef SYSV
514	"-DSYSV",
515# endif
516# ifdef SVR4
517	"-DSVR4",
518# endif
519#endif /* MOTOROLA */
520#if defined(M_UNIX) || defined(sco) || defined(__SCO__) || \
521	defined(_SCO_DS) || defined(__OPENSERVER__)
522	"-D__SCO__",
523	"-DSYSV",
524#endif
525#ifdef i386
526	"-Di386",
527# ifdef SVR4
528	"-DSVR4",
529# endif
530# ifdef SYSV
531	"-DSYSV",
532#  ifdef ISC
533	"-DISC",
534#   ifdef ISC40
535	"-DISC40",       /* ISC 4.0 */
536#   else
537#    ifdef ISC202
538	"-DISC202",      /* ISC 2.0.2 */
539#    else
540#     ifdef ISC30
541	"-DISC30",       /* ISC 3.0 */
542#     else
543	"-DISC22",       /* ISC 2.2.1 */
544#     endif
545#    endif
546#   endif
547#  endif
548#  if (_SCO_DS - 0 == 1)
549    "-DSCO325",
550#  endif
551#  if (_SCO_DS - 0 > 1)
552    "-DSCO5V6",
553#  endif
554# endif
555# ifdef ESIX
556	"-DESIX",
557# endif
558# ifdef ATT
559	"-DATT",
560# endif
561# ifdef DELL
562	"-DDELL",
563# endif
564#endif
565#ifdef SYSV386           /* System V/386 folks, obsolete */
566	"-Di386",
567# ifdef SVR4
568	"-DSVR4",
569# endif
570# ifdef ISC
571	"-DISC",
572#  ifdef ISC40
573	"-DISC40",       /* ISC 4.0 */
574#  else
575#   ifdef ISC202
576	"-DISC202",      /* ISC 2.0.2 */
577#   else
578#    ifdef ISC30
579	"-DISC30",       /* ISC 3.0 */
580#    else
581	"-DISC22",       /* ISC 2.2.1 */
582#    endif
583#   endif
584#  endif
585# endif
586# if (_SCO_DS - 0 == 1)
587	"-DSCO325",
588# endif
589#  if (_SCO_DS - 0 > 1)
590    "-DSCO5V6",
591#  endif
592# ifdef ESIX
593	"-DESIX",
594# endif
595# ifdef ATT
596	"-DATT",
597# endif
598# ifdef DELL
599	"-DDELL",
600# endif
601#endif
602#ifdef __osf__
603	"-D__osf__",
604# ifdef __mips__
605	"-D__mips__",
606# endif
607# ifdef __alpha
608	"-D__alpha",
609# endif
610# ifdef __amiga__
611	"-D__amiga__",
612# endif
613# ifdef __alpha__
614	"-D__alpha__",
615# endif
616# ifdef __i386__
617	"-D__i386__",
618# endif
619# ifdef __GNUC__
620	"-traditional",
621# endif
622#endif
623#ifdef Oki
624	"-DOki",
625#endif
626#ifdef sun
627#if defined(SVR4) || defined(__svr4__) || defined(__SVR4) || defined(__sol__)
628	"-DSVR4",
629#endif
630# ifdef __sparcv9
631	"-D__sparcv9",
632# endif
633# ifdef __amd64
634	"-D__amd64",
635# endif
636#endif
637#ifdef WIN32
638	"-DWIN32",
639#ifndef __GNUC__
640	"-nologo",
641#if _MSC_VER < 1000
642	"-batch",
643#endif
644#endif
645	"-D__STDC__",
646#endif
647#ifdef NCR
648	"-DNCR",	/* NCR */
649#endif
650#ifdef linux
651        "-Dlinux",
652#endif
653#if defined(__CYGWIN__)
654        "-traditional",
655#endif
656#if defined(Lynx) || defined(__Lynx__)
657        "-traditional",
658#if 0
659        "-DLYNX",		/* do we really need this?? */
660#endif
661	"-DLynx",
662# ifdef ppc
663	"-Dppc",
664# endif
665# ifdef ppc64
666	"-Dppc64",
667# endif
668# if defined(m68k)  || defined(M68k) || defined(m68040)
669	"-Dm68k",
670	"-DM68k",
671# endif
672# ifdef uSPARC1
673	"-Dsparc",
674# endif
675#endif
676#ifdef __uxp__
677	"-D__uxp__",
678#endif
679#ifdef __sxg__
680	"-D__sxg__",
681#endif
682#ifdef nec_ews_svr2
683	"-Dnec_ews_svr2",
684#endif
685#ifdef AMOEBA
686	"-DAMOEBA",
687# ifdef CROSS_COMPILE
688	"-DCROSS_COMPILE",
689#  ifdef CROSS_i80386
690	"-Di80386",
691#  endif
692#  ifdef CROSS_sparc
693	"-Dsparc",
694#  endif
695#  ifdef CROSS_mc68000
696	"-Dmc68000",
697#  endif
698# else
699#  ifdef i80386
700	"-Di80386",
701#  endif
702#  ifdef sparc
703	"-Dsparc",
704#  endif
705#  ifdef mc68000
706	"-Dmc68000",
707#  endif
708# endif
709#endif
710#if defined(__sgi) && defined(__ANSI_CPP__)
711	"-cckr",
712#endif
713#ifdef __minix_vmd
714	"-Dminix",
715#endif
716
717#if defined(__UNIXOS2__)
718	"-traditional",
719	"-Demxos2",
720#endif
721#ifdef MetroLink
722	"-DMetroLink",
723# ifdef SVR4
724	"-DSVR4",
725# endif
726#endif
727#ifdef __powerpc__
728	"-D__powerpc__",
729#endif
730#ifdef __powerpc64__
731	"-D__powerpc64__",
732#endif
733#ifdef PowerMAX_OS
734	"-DPowerMAX_OS",
735#endif
736#if defined (__QNX__) && !defined(__QNXNTO__)
737        "-traditional",
738        "-D__QNX__",
739#endif
740
741#if defined(__QNXNTO__)
742        "-traditional",
743        "-D__QNXNTO__",
744#if defined(i386)
745        "-Di386",
746#endif
747#if defined(__i386__)
748        "-D__i386__",
749#endif
750#if defined(PPC)
751        "-DPPC",
752#endif
753#if defined(MIPS)
754        "-DMIPS",
755#endif
756#endif
757
758#if defined(__APPLE__)
759        "-D__APPLE__",
760        "-D__DARWIN__",
761# ifdef __ppc__
762        "-D__ppc__",
763# endif
764# ifdef __ppc64__
765        "-D__ppc64__",
766# endif
767# ifdef __i386__
768        "-D__i386__",
769# endif
770#endif
771};
772#endif /* CROSSCOMPILE */
773
774
775/*
776 * Step 6: DEFAULT_OS_MAJOR_REV, DEFAULT_OS_MINOR_REV, DEFAULT_OS_TEENY_REV,
777 *	and DEFAULT_OS_NAME.
778 *	If your system provides a way to generate the default major,
779 *	minor, teeny, or system names at runtime add commands below.
780 *	The syntax of the _REV strings is 'f fmt' where 'f' is an argument
781 *	you would give to uname, and "fmt" is a scanf() format string.
782 *	Supported uname arguments are "snrvm", and if you specify multiple
783 *	arguments they will be separated by spaces.  No more than 5 arguments
784 *	may be given.  Unlike uname() order of arguments matters.
785 *
786 *	DEFAULT_OS_MAJOR_REV_FROB, DEFAULT_OS_MINOR_REV_FROB,
787 *	DEFAULT_OS_TEENY_REV_FROB, and DEFAULT_OS_NAME_FROB can be used to
788 *	modify the results of the use of the various strings.
789 */
790#if !defined CROSSCOMPILE || defined CROSSCOMPILE_CPP
791# if defined(aix)
792/* uname -v returns "x" (e.g. "4"), and uname -r returns "y" (e.g. "1") */
793#  define DEFAULT_OS_MAJOR_REV	"v %[0-9]"
794#  define DEFAULT_OS_MINOR_REV	"r %[0-9]"
795/* No information available to generate default OSTeenyVersion value. */
796#  define DEFAULT_OS_NAME	"srvm %[^\n]"
797# elif defined(sun) || defined(sgi) || defined(ultrix) || defined(__uxp__) || defined(sony)
798/* uname -r returns "x.y[.z]", e.g. "5.4" or "4.1.3" */
799#  define DEFAULT_OS_MAJOR_REV	"r %[0-9]"
800#  define DEFAULT_OS_MINOR_REV	"r %*d.%[0-9]"
801#  define DEFAULT_OS_TEENY_REV	"r %*d.%*d.%[0-9]"
802#  define DEFAULT_OS_NAME	"srvm %[^\n]"
803# elif defined(hpux)
804/* uname -r returns "W.x.yz", e.g. "B.10.01" */
805#  define DEFAULT_OS_MAJOR_REV	"r %*[^.].%[0-9]"
806#  define DEFAULT_OS_MINOR_REV	"r %*[^.].%*d.%1s"
807#  define DEFAULT_OS_TEENY_REV	"r %*[^.].%*d.%*c%[0-9]"
808#  define DEFAULT_OS_NAME	"srvm %[^\n]"
809# elif defined(USL) || defined(__USLC__) || defined(__UNIXWARE__) || \
810	defined(__SCO__) || defined(__OPENSERVER__) || defined(_SCO_DS)
811/* uname -v returns "x.yz" or "x.y.z", e.g. "2.02" or "2.1.2". */
812#  define DEFAULT_OS_MAJOR_REV	"v %[0-9]"
813#  define DEFAULT_OS_MINOR_REV	"v %*d.%1s"
814#  define DEFAULT_OS_TEENY_REV	"v %*d.%*c%[.0-9]"
815#  define DEFAULT_OS_NAME	"srvm %[^\n]"
816# elif defined(__APPLE__)
817/* uname -v returns "x.yz" or "x.y.z", e.g. "2.02" or "2.1.2". */
818#  define DEFAULT_OS_MAJOR_REV	"r %[0-9]"
819#  define DEFAULT_OS_MINOR_REV	"r %*d.%[0-9]"
820#  define DEFAULT_OS_TEENY_REV	"r %*d.%*d.%[0-9]" /* this will just get 0 */
821#  define DEFAULT_OS_NAME	"s %[^\n]"
822# elif defined(__osf__)
823/* uname -r returns "Wx.y", e.g. "V3.2" or "T4.0" */
824#  define DEFAULT_OS_MAJOR_REV	"r %*[^0-9]%[0-9]"
825#  define DEFAULT_OS_MINOR_REV	"r %*[^.].%[0-9]"
826#  define DEFAULT_OS_NAME	"srvm %[^\n]"
827# elif defined(__uxp__)
828/* NOTE: "x.y[.z]" above handles UXP/DF.  This is a sample alternative. */
829/* uname -v returns "VxLy Yzzzzz ....", e.g. "V20L10 Y95021 Increment 5 ..." */
830#  define DEFAULT_OS_MAJOR_REV	"v V%[0-9]"
831#  define DEFAULT_OS_MINOR_REV	"v V%*dL%[0-9]"
832#  define DEFAULT_OS_NAME	"srvm %[^\n]"
833# elif defined(linux) || defined(__bsdi__)
834#  define DEFAULT_OS_MAJOR_REV	"r %[0-9]"
835#  define DEFAULT_OS_MINOR_REV	"r %*d.%[0-9]"
836#  define DEFAULT_OS_TEENY_REV	"r %*d.%*d.%[0-9]"
837#  define DEFAULT_OS_NAME	"srm %[^\n]"
838#  if defined(linux) && defined  (CROSSCOMPILE_CPP)
839#   define CROSS_UTS_SYSNAME "Linux"
840#   include <linux/version.h>
841#   define CROSS_UTS_RELEASE UTS_RELEASE
842# endif
843# elif defined(__CYGWIN__)
844#  define DEFAULT_OS_MAJOR_REV	"r %[0-9]"
845#  define DEFAULT_OS_MINOR_REV	"r %*d.%[0-9]"
846#  define DEFAULT_OS_TEENY_REV	"r %*d.%*d.%[0-9]"
847#  define DEFAULT_OS_NAME	"srm %[^\n]"
848#  if defined(__CYGWIN__) && defined  (CROSSCOMPILE_CPP)
849#   define CROSS_UTS_SYSNAME "Cygwin"
850#   include <cygwin/version.h>
851#   define CROSS_UTS_RELEASE "1.3.12"
852#  endif
853# elif defined(__GNU__)
854#  define DEFAULT_OS_MAJOR_REV	"r %[0-9]"
855#  define DEFAULT_OS_MINOR_REV	"r %*d.%[0-9]"
856#  define DEFAULT_OS_NAME	"srm %[^\n]"
857# elif defined(ISC)
858/* ISC all Versions ? */
859/* uname -r returns "x.y", e.g. "3.2" ,uname -v returns "x" e.g. "2" */
860#  define DEFAULT_OS_MAJOR_REV   "r %[0-9]"
861#  define DEFAULT_OS_MINOR_REV   "r %*d.%[0-9]"
862#  define DEFAULT_OS_TEENY_REV   "v %[0-9]"
863/* # define DEFAULT_OS_NAME        "srm %[^\n]" */ /* Not useful on ISC */
864# elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__) || defined(__DragonFly__)
865/* BSD/OS too? */
866/* uname -r returns "x.y[.z]-mumble", e.g. "2.1.5-RELEASE" or "2.2-0801SNAP" */
867#  define DEFAULT_OS_MAJOR_REV   "r %[0-9]"
868#  define DEFAULT_OS_MINOR_REV   "r %*d.%[0-9]"
869#  define DEFAULT_OS_TEENY_REV   "r %*d.%*d.%[0-9]"
870#  define DEFAULT_OS_NAME        "srm %[^\n]"
871#  if defined(__FreeBSD__) || defined(__DragonFly__)
872/* Use an alternate way to find the teeny version for -STABLE, -SNAP versions */
873#   ifndef CROSSCOMPILE_CPP
874#    define DEFAULT_OS_TEENY_REV_FROB(buf, size)			\
875      do {								\
876	if (*buf == 0) {						\
877		int __mib[2];						\
878		size_t __len;						\
879		int __osrel;						\
880									\
881		__mib[0] = CTL_KERN;					\
882		__mib[1] = KERN_OSRELDATE;				\
883		__len = sizeof(__osrel);				\
884		sysctl(__mib, 2, &__osrel, &__len, NULL, 0);		\
885		if (__osrel < 210000) {					\
886			if (__osrel < 199607)				\
887				buf[0] = '0';				\
888			else if (__osrel < 199612)			\
889				buf[0] = '5';				\
890			else if (__osrel == 199612)			\
891				buf[0] = '6';				\
892			else						\
893				buf[0] = '8'; /* guess */		\
894		} else {						\
895			buf[0] = ((__osrel / 1000) % 10) + '0';		\
896		}							\
897		buf[1] = 0;						\
898	}								\
899     } while (0)
900#   endif
901#  else
902   /* OpenBSD - Add DEFAULT_MACHINE_ARCHITECTURE */
903#   define DEFAULT_MACHINE_ARCHITECTURE "m %[^\n]"
904#  endif
905# elif defined(__NetBSD__)
906/*
907 * uname -r returns "x.y([ABCD...]|_mumble)", e.g.:
908 *	1.2	1.2_BETA	1.2A	1.2B
909 *
910 * That means that we have to do something special to turn the
911 * TEENY revision into a form that we can use (i.e., a string of
912 * decimal digits).
913 *
914 * We also frob the name DEFAULT_OS_NAME so that it looks like the
915 * 'standard' NetBSD name for the version, e.g. "NetBSD/i386 1.2B" for
916 * NetBSD 1.2B on an i386.
917 */
918#  define DEFAULT_OS_MAJOR_REV   "r %[0-9]"
919#  define DEFAULT_OS_MINOR_REV   "r %*d.%[0-9]"
920#  define DEFAULT_OS_TEENY_REV   "r %*d.%*d%[A-Z]"
921#  define DEFAULT_OS_TEENY_REV_FROB(buf, size)				\
922    do {								\
923	int	teeny = 0;						\
924	char	*ptr = (buf);						\
925									\
926	while (*ptr >= 'A' && *ptr <= 'Z') /* sanity check */		\
927	    teeny = teeny * 26 + (int)(*ptr++ - 'A');			\
928									\
929	snprintf((buf), (size), "%d", teeny + 1);			\
930    } while (0)
931#  define DEFAULT_OS_NAME        "smr %[^\n]"
932#  define DEFAULT_OS_NAME_FROB(buf, size)				\
933    do {								\
934	char *__sp;							\
935	if ((__sp = strchr((buf), ' ')) != NULL)			\
936		*__sp = '/';						\
937    } while (0)
938# elif defined(__Lynx__) || defined(Lynx)
939/* Lynx 2.4.0 /bin/cc doesn't like #elif */
940#  define DEFAULT_OS_MAJOR_REV   "r %[0-9]"
941#  define DEFAULT_OS_MINOR_REV   "r %*d.%[0-9]"
942#  define DEFAULT_OS_TEENY_REV   "r %*d.%*d.%[0-9]"
943#  define DEFAULT_OS_NAME        "srm %[^\n]"
944# elif defined(_SEQUENT_)
945/* uname -v returns 'Vx.y.z', e.g. 'V4.4.2' */
946#  define DEFAULT_OS_MAJOR_REV	"v V%[0-9]"
947#  define DEFAULT_OS_MINOR_REV	"v V%*d.%[0-9]"
948#  define DEFAULT_OS_TEENY_REV	"v V%*d.%*d.%[0-9]"
949#  define DEFAULT_OS_NAME	"s %[^\n]"
950# endif
951#endif /* !defined CROSSCOMPILE || defined CROSSCOMPILE_CPP */
952
953# if defined (CROSSCOMPILE_CPP)
954#  ifndef CROSS_UTS_SYSNAME
955char *cross_uts_sysname = "";
956#  else
957char *cross_uts_sysname = CROSS_UTS_SYSNAME;
958#  endif
959#  ifndef CROSS_UTS_RELEASE
960char* cross_uts_release = "";
961#  else
962char* cross_uts_release = CROSS_UTS_RELEASE;
963#  endif
964#  ifndef CROSS_UTS_MACHINE
965char *cross_uts_machine = "";
966#  else
967char *cross_uts_machine = CROSS_UTS_MACHINE;
968#  endif
969#  ifndef CROSS_UTS_VERSION
970char * cross_uts_version = "";
971#  else
972char * cross_uts_version = CROSS_UTS_VERSION;
973#  endif
974#  ifdef DEFAULT_OS_NAME
975char *defaultOsName = DEFAULT_OS_NAME;
976#  else
977char *defaultOsName = NULL;
978# endif
979#  ifdef DEFAULT_OS_MAJOR_REV
980char *defaultOsMajorRev = DEFAULT_OS_MAJOR_REV;
981#  else
982char *defaultOsMajorRev = NULL;
983# endif
984#  ifdef DEFAULT_OS_MINOR_REV
985char *defaultOsMinorRev = DEFAULT_OS_MINOR_REV;
986#  else
987char *defaultOsMinorRev = NULL;
988#  endif
989#  ifdef DEFAULT_OS_TEENY_REV
990char *defaultOsTeenyRev = DEFAULT_OS_TEENY_REV;
991#  else
992char *defaultOsTeenyRev = NULL;
993#  endif
994#  ifdef DEFAULT_MACHINE_ARCHITECTURE
995char *defaultMachineArchitecture = DEFAULT_MACHINE_ARCHITECTURE;
996#  else
997char *defaultMachineArchitecture = NULL;
998#  endif
999# ifdef DEFAULT_OS_NAME_FROB
1000void defaultOsNameFrob(char *buf, int size)
1001{DEFAULT_OS_NAME_FROB(buf,size)}
1002# else
1003void (*defaultOsNameFrob)(char *buf, int size) = NULL;
1004# endif
1005# ifdef DEFAULT_OS_MAJOR_REV_FROB
1006void defaultOsMajorRevFrob(char *buf, int size)
1007{DEFAULT_OS_MAJOR_REV_FROB(buf,size)}
1008# else
1009void (*defaultOsMajorRevFrob)(char *buf, int size) = NULL;
1010# endif
1011# ifdef DEFAULT_OS_MINOR_REV_FROB
1012void defaultOsMinorRevFrob(char *buf, int size)
1013{DEFAULT_OS_MINOR_REV_FROB(buf,size)}
1014# else
1015void (*defaultOsMinorRevFrob)(char *buf, int size) = NULL;
1016# endif
1017# ifdef DEFAULT_OS_TEENY_REV_FROB
1018void defaultOsTeenyRevFrob(char *buf, int size)
1019{DEFAULT_OS_TEENY_REV_FROB(buf,size)}
1020# else
1021void (*defaultOsTeenyRevFrob)(char *buf, int size) = NULL;
1022# endif
1023# endif /* CROSSCOMPILE_CPP */
1024
1025#else /* else MAKEDEPEND */
1026#if !defined (CROSSCOMPILE) || defined (CROSSCOMPILE_CPP)
1027/*
1028 * Step 7:  predefs
1029 *     If your compiler and/or preprocessor define any specific symbols, add
1030 *     them to the the following table.  The definition of struct symtab is
1031 *     in util/makedepend/def.h.
1032 */
1033#undef DEF_EVALUATE
1034#undef DEF_STRINGIFY
1035#define DEF_EVALUATE(__x) #__x
1036#define DEF_STRINGIFY(_x) DEF_EVALUATE(_x)
1037struct symtab	predefs[] = {
1038#ifdef apollo
1039	{"apollo", "1"},
1040#endif
1041#if defined(clipper) || defined(__clipper__)
1042	{"clipper", "1"},
1043	{"__clipper__", "1"},
1044	{"clix", "1"},
1045	{"__clix__", "1"},
1046#endif
1047#ifdef ibm032
1048	{"ibm032", "1"},
1049#endif
1050#ifdef ibm
1051	{"ibm", "1"},
1052#endif
1053#ifdef aix
1054	{"aix", "1"},
1055#endif
1056#ifdef sun
1057	{"sun", "1"},
1058#endif
1059#ifdef sun2
1060	{"sun2", "1"},
1061#endif
1062#ifdef sun3
1063	{"sun3", "1"},
1064#endif
1065#ifdef sun4
1066	{"sun4", "1"},
1067#endif
1068#ifdef sparc
1069	{"sparc", "1"},
1070#endif
1071#ifdef __sparc
1072	{"__sparc", "1"},
1073#endif
1074#ifdef __sparcv9
1075	{"__sparcv9", "1"},
1076#endif
1077#ifdef __sparc__
1078	{"__sparc__", "1"},
1079#endif
1080#ifdef __sparcv9__
1081	{"__sparcv9__", "1"},
1082#endif
1083#ifdef hpux
1084	{"hpux", "1"},
1085#endif
1086#ifdef __hpux
1087	{"__hpux", "1"},
1088#endif
1089#ifdef __hp9000s800
1090	{"__hp9000s800", "1"},
1091#endif
1092#ifdef __hp9000s700
1093	{"__hp9000s700", "1"},
1094#endif
1095#ifdef vax
1096	{"vax", "1"},
1097#endif
1098#ifdef VMS
1099	{"VMS", "1"},
1100#endif
1101#ifdef cray
1102	{"cray", "1"},
1103#endif
1104#ifdef CRAY
1105	{"CRAY", "1"},
1106#endif
1107#ifdef _CRAY
1108	{"_CRAY", "1"},
1109#endif
1110#ifdef att
1111	{"att", "1"},
1112#endif
1113#ifdef mips
1114	{"mips", "1"},
1115#endif
1116#ifdef __mips__
1117	{"__mips__", "1"},
1118#endif
1119#ifdef ultrix
1120	{"ultrix", "1"},
1121#endif
1122#ifdef stellar
1123	{"stellar", "1"},
1124#endif
1125#ifdef mc68000
1126	{"mc68000", "1"},
1127#endif
1128#ifdef mc68020
1129	{"mc68020", "1"},
1130#endif
1131#ifdef __GNUC__
1132	{"__GNUC__", DEF_STRINGIFY(__GNUC__)},
1133#endif
1134#ifdef __STRICT_ANSI__
1135	{"__STRICT_ANSI__", "1"},
1136#endif
1137#ifdef __STDC__
1138	{"__STDC__", DEF_STRINGIFY(__STDC__)},
1139#endif
1140#ifdef __HIGHC__
1141	{"__HIGHC__", "1"},
1142#endif
1143#ifdef __OPENSERVER__
1144	{"__OPENSERVER__", DEF_STRINGIFY(__OPENSERVER__)},
1145#endif
1146#ifdef _SCO_DS
1147	{"_SCO_DS", DEF_STRINGIFY(_SCO_DS)},
1148#endif
1149#ifdef _SCO_DS_LL
1150	{"_SCO_DS_LL", DEF_STRINGIFY(_SCO_DS_LL)},
1151#endif
1152#ifdef __SCO_VERSION__
1153	{"__SCO_VERSION__", DEF_STRINGIFY(__SCO_VERSION__)},
1154#endif
1155#ifdef __UNIXWARE__
1156	{"__UNIXWARE__", DEF_STRINGIFY(__UNIXWARE__)},
1157#endif
1158#ifdef __USLC__
1159	{"__USLC__", DEF_STRINGIFY(__USLC__)},
1160#endif
1161#ifdef CMU
1162	{"CMU", "1"},
1163#endif
1164#ifdef luna
1165	{"luna", "1"},
1166#ifdef luna1
1167	{"luna1", "1"},
1168#endif
1169#ifdef luna2
1170	{"luna2", "1"},
1171#endif
1172#ifdef luna88k
1173	{"luna88k", "1"},
1174#endif
1175#ifdef uniosb
1176	{"uniosb", "1"},
1177#endif
1178#ifdef uniosu
1179	{"uniosu", "1"},
1180#endif
1181#endif
1182#ifdef ieeep754
1183	{"ieeep754", "1"},
1184#endif
1185#ifdef is68k
1186	{"is68k", "1"},
1187#endif
1188#ifdef m68k
1189        {"m68k", "1"},
1190#endif
1191#ifdef M68k
1192        {"M68k", "1"},
1193#endif
1194#ifdef __m68k__
1195	{"__m68k__", "1"},
1196#endif
1197#ifdef m88k
1198        {"m88k", "1"},
1199#endif
1200#ifdef __m88k__
1201	{"__m88k__", "1"},
1202#endif
1203#ifdef bsd43
1204	{"bsd43", "1"},
1205#endif
1206#ifdef hcx
1207	{"hcx", "1"},
1208#endif
1209#ifdef sony
1210	{"sony", "1"},
1211#ifdef SYSTYPE_SYSV
1212	{"SYSTYPE_SYSV", "1"},
1213#endif
1214#ifdef _SYSTYPE_SYSV
1215	{"_SYSTYPE_SYSV", "1"},
1216#endif
1217#endif
1218#ifdef __OSF__
1219	{"__OSF__", "1"},
1220#endif
1221#ifdef __osf__
1222	{"__osf__", "1"},
1223#endif
1224#ifdef __amiga__
1225	{"__amiga__", "1"},
1226#endif
1227#ifdef __alpha
1228	{"__alpha", "1"},
1229#endif
1230#ifdef __alpha__
1231	{"__alpha__", "1"},
1232#endif
1233#ifdef __DECC
1234	{"__DECC",  "1"},
1235#endif
1236#ifdef __decc
1237	{"__decc",  "1"},
1238#endif
1239#ifdef __unix__
1240	{"__unix__", "1"},
1241#endif
1242#ifdef __uxp__
1243	{"__uxp__", "1"},
1244#endif
1245#ifdef __sxg__
1246	{"__sxg__", "1"},
1247#endif
1248#ifdef _SEQUENT_
1249	{"_SEQUENT_", "1"},
1250	{"__STDC__", "1"},
1251#endif
1252#ifdef __bsdi__
1253	{"__bsdi__", "1"},
1254#endif
1255#ifdef nec_ews_svr2
1256	{"nec_ews_svr2", "1"},
1257#endif
1258#ifdef nec_ews_svr4
1259	{"nec_ews_svr4", "1"},
1260#endif
1261#ifdef _nec_ews_svr4
1262	{"_nec_ews_svr4", "1"},
1263#endif
1264#ifdef _nec_up
1265	{"_nec_up", "1"},
1266#endif
1267#ifdef SX
1268	{"SX", "1"},
1269#endif
1270#ifdef nec
1271	{"nec", "1"},
1272#endif
1273#ifdef _nec_ft
1274	{"_nec_ft", "1"},
1275#endif
1276#ifdef PC_UX
1277	{"PC_UX", "1"},
1278#endif
1279#ifdef sgi
1280	{"sgi", "1"},
1281#endif
1282#ifdef __sgi
1283	{"__sgi", "1"},
1284#endif
1285#ifdef _MIPS_FPSET
1286	{"_MIPS_FPSET", DEF_STRINGIFY(_MIPS_FPSET)},
1287#endif
1288#ifdef _MIPS_ISA
1289	{"_MIPS_ISA", DEF_STRINGIFY(_MIPS_ISA)},
1290#endif
1291#ifdef _MIPS_SIM
1292	{"_MIPS_SIM", DEF_STRINGIFY(_MIPS_SIM)},
1293#endif
1294#ifdef _MIPS_SZINT
1295	{"_MIPS_SZINT", DEF_STRINGIFY(_MIPS_SZINT)},
1296#endif
1297#ifdef _MIPS_SZLONG
1298	{"_MIPS_SZLONG", DEF_STRINGIFY(_MIPS_SZLONG)},
1299#endif
1300#ifdef _MIPS_SZPTR
1301	{"_MIPS_SZPTR", DEF_STRINGIFY(_MIPS_SZPTR)},
1302#endif
1303#ifdef __DragonFly__
1304	{"__DragonFly__", "1"},
1305#endif
1306#ifdef __FreeBSD__
1307	{"__FreeBSD__", "1"},
1308#endif
1309#ifdef __OpenBSD__
1310	{"__OpenBSD__", "1"},
1311#endif
1312#ifdef __NetBSD__
1313	{"__NetBSD__", "1"},
1314#endif
1315#ifdef __GNU__
1316	{"__GNU__", "1"},
1317#endif
1318#ifdef __ELF__
1319	{"__ELF__", "1"},
1320#endif
1321#ifdef __UNIXOS2__
1322	{"__UNIXOS2__", "1"},
1323#endif
1324#if defined(__QNX__)
1325        {"__QNX__", "1"},
1326#endif
1327#ifdef __QNXNTO__
1328        {"__QNXNTO__", "1"},
1329#endif
1330# ifdef __powerpc__
1331	{"__powerpc__", "1"},
1332# endif
1333# ifdef __powerpc64__
1334	{"__powerpc64__", "1"},
1335# endif
1336# ifdef PowerMAX_OS
1337	{"PowerMAX_OS", "1"},
1338# endif
1339# ifdef ia64
1340	{"ia64", "1"},
1341# endif
1342# ifdef __ia64__
1343	{"__ia64__", "1"},
1344# endif
1345# if defined (amd64) || defined (x86_64)
1346	{"amd64", "1"},
1347	{"x86_64", "1"},
1348# endif
1349# if defined (__amd64__) || defined (__x86_64__)
1350	{"__amd64__", "1"},
1351	{"__x86_64__", "1"},
1352# endif
1353# if defined (__amd64) || defined(__x86_64)
1354	{"__amd64", "1"},
1355	{"__x86_64", "1"},
1356# endif
1357# ifdef __x86
1358	{"__x86", "1"},
1359# endif
1360# ifdef __i386
1361	{"__i386", "1"},
1362# endif
1363# ifdef __i386__
1364	{"__i386__", "1"},
1365# endif
1366# ifdef __i486__
1367	{"__i486__", "1"},
1368# endif
1369# ifdef __i586__
1370	{"__i586__", "1"},
1371# endif
1372# ifdef __i686__
1373	{"__i686__", "1"},
1374# endif
1375# ifdef __k6__
1376	{"__k6__", "1"},
1377# endif
1378# ifdef i386
1379	{"i386", "1"},
1380# endif
1381# ifdef i486
1382	{"i486", "1"},
1383# endif
1384# ifdef i586
1385	{"i586", "1"},
1386# endif
1387# ifdef i686
1388	{ "i686", "1"},
1389# endif
1390# ifdef k6
1391	{"k6", "1"},
1392# endif
1393# ifdef sparc
1394	{"sparc", "1"},
1395# endif
1396# ifdef __sparc__
1397	{"__sparc__", "1"},
1398# endif
1399# ifdef __s390__
1400	{"__s390__", "1"},
1401# endif
1402# ifdef __hppa__
1403	{"__hppa__", "1"},
1404# endif
1405# ifdef __sh__
1406	{"__sh__", "1"},
1407# endif
1408# ifdef __sh3_
1409	{"__sh3__", "1"},
1410# endif
1411# ifdef __SH3__
1412	{"__SH3__", "1"},
1413# endif
1414# ifdef __SH4__
1415	{"__SH4__", "1"},
1416# endif
1417# ifdef __SH4NOFPU__
1418	{"__SH4NOFPU__", "1"},
1419# endif
1420#if defined(__ppc__)
1421        {"__ppc__", "1"},
1422#endif
1423#if defined(__ppc64__)
1424        {"__ppc64__", "1"},
1425#endif
1426#if defined(__BIG_ENDIAN__)
1427      {"__BIG_ENDIAN__", "1"},
1428#endif
1429#if defined(__LITTLE_ENDIAN__)
1430      {"__LITTLE_ENDIAN__", "1"},
1431#endif
1432#if defined (__CHAR_BIT__)
1433	{"__CHAR_BIT__", DEF_STRINGIFY(__CHAR_BIT__)},
1434#endif
1435#if defined (__BUILTIN_VA_STRUCT)
1436	{"__BUILTIN_VA_STRUCT", "1"},
1437#endif
1438#if defined (__BUILTIN_VA_ARG_INCR)
1439	{"__BUILTIN_VA_ARG_INCR", "1"},
1440#endif
1441	/* add any additional symbols before this line */
1442	{NULL, NULL}
1443};
1444#undef DEF_EVALUATE
1445#undef DEF_STRINGIFY
1446#endif /* CROSSCOMPILE */
1447#endif /* MAKEDEPEND */
1448
1449# ifndef MAKEDEPEND
1450#  if  defined (CROSSCOMPILE_CPP)
1451#   ifdef USE_CC_E
1452boolean crosscompile_use_cc_e = TRUE;
1453#    ifdef DEFAULT_CC
1454char* crosscompile_cpp = DEFAULT_CC;
1455#    else
1456char* crosscompile_cpp = "cc";
1457#    endif
1458#   else
1459boolean crosscompile_use_cc_e = FALSE;
1460#    ifdef DEFAULT_CPP
1461char* crosscompile_cpp = DEFAULT_CPP;
1462#    else
1463char* crosscompile_cpp = "cpp";
1464#    endif
1465#   endif
1466#   ifdef FIXUP_CPP_WHITESPACE
1467boolean fixup_whitespace = TRUE;
1468#   else
1469boolean fixup_whitespace = FALSE;
1470#   endif
1471#   ifdef REMOVE_CPP_LEADSPACE
1472boolean remove_cpp_leadspace = TRUE;
1473#   else
1474boolean remove_cpp_leadspace = FALSE;
1475#   endif
1476#   ifdef INLINE_SYNTAX
1477boolean inline_syntax = TRUE;
1478#   else
1479boolean inline_syntax = FALSE;
1480#   endif
1481#   ifdef MAGIC_MAKE_VARS
1482boolean magic_make_vars = TRUE;
1483#   else
1484boolean magic_make_vars = FALSE;
1485#   endif
1486
1487typedef enum {
1488  unknown,
1489  freeBSD,
1490  netBSD,
1491  LinuX,
1492  emx,
1493  win32,
1494  dragonfly
1495} System;
1496
1497#   if defined(linux) || defined(__GLIBC__)
1498System sys = LinuX;
1499#   elif defined __FreeBSD__
1500System sys = freebsd;
1501#   elif defined __NetBSD__
1502System sys = netBSD;
1503#   elif defined __EMX__
1504System sys = emx;
1505#   elif defined WIN32
1506System sys = win32;
1507#   elif defined __DragonFly__
1508System sys = dragonfly;
1509#   else
1510System sys = unknown;
1511#   endif
1512
1513#   if defined __GNUC__
1514int gnu_c = __GNUC__;
1515int gnu_c_minor = __GNUC_MINOR__;
1516#   else
1517int gnu_c = 0;
1518int gnu_c_minor = -1;
1519#   endif
1520#   if defined(linux) || defined(__GLIBC__)
1521#    include <features.h>
1522int glibc_major = __GLIBC__ + 4;
1523int glibc_minor = __GLIBC_MINOR__;
1524#   else
1525int glibc_major = 0;
1526int glibc_minor = -1;
1527#   endif
1528#  endif /* !CROSSCOMPILE || CROSSCOMPILE_CPP */
1529
1530# endif /* MAKEDEPEND */
1531
1532#endif /* CCIMAKE */
1533