1 XCOMM $TOG: Imake.cf /main/30 1998/04/28 13:55:25 barstow $
3 * To add support for another platform:
5 * 1. Identify a machine-specific cpp symbol. If your preprocessor
6 * does not have any built in, you will need to add the symbol to the
7 * cpp_argv table in config/imake/imakemdep.h and rebuild imake with
8 * the BOOTSTRAPCFLAGS variable set (see the macII for an example).
10 * 2. Add all machine-specific cpp symbols (either defined by you or by
11 * the preprocessor or compiler) to the predefs table in
12 * config/imake/imakemdep.h.
14 * 3. But a new #ifdef block below that defines MacroIncludeFile and
15 * MacroFile for your new platform and then #undefs the machine-
16 * specific preprocessor symbols (to avoid problems with file names).
18 * 4. Create a .cf file with the name given by MacroFile.
22 # define MacroIncludeFile <ultrix.cf>
23 # define MacroFile ultrix.cf
26 # define VaxArchitecture
30 # define MipsArchitecture
33 # define UltrixArchitecture
36 #if defined(vax) && !defined(UltrixArchitecture)
37 # define MacroIncludeFile <bsd.cf>
38 # define MacroFile bsd.cf
40 # define VaxArchitecture
46 # define BSDArchitecture
47 # define OpenBSDArchitecture
48 # define KOpenBSDArchitecture
49 # define MacroIncludeFile <OpenBSD.cf>
50 # define MacroFile OpenBSD.cf
52 # define i386BsdArchitecture
53 # define i386Architecture
56 # if defined(__sparc__) || defined(sparc)
57 # if !defined(__arch64__)
58 # define SparcArchitecture
60 # define Sparc64Architecture
65 # if defined(__mips__) || defined(mips)
66 # define MipsArchitecture
68 # define Mips64Architecture
71 # define ArcArchitecture
75 # define SGIArchitecture
79 # define PmaxArchitecture
85 # if defined(__alpha__) || defined(alpha)
86 # define AlphaArchitecture
90 # if defined(__amd64__) || defined(__x86_64__)
91 # define AMD64Architecture
97 # define Arm32Architecture
101 # define ZaurusArchitecture
104 # if defined(__mc68020__) || defined(mc68020)
105 # define Mc68020Architecture
107 # define AmigaArchitecture
111 # define Hp300Architecture
115 # define Mac68kArchitecture
118 # if defined(mvme68k)
119 # define Mvme68kArchitecture
123 # define Sun3Architecture
128 # if defined(__m88k__) || defined(m88k)
129 # define Mc88000Architecture
133 # define PpcArchitecture
140 # define SuperHArchitecture
145 # define VaxArchitecture
148 # ifndef HPArchitecture
149 # define HPArchitecture
152 # endif /* __hppa__ */
155 /* Systems based on kernel of OpenBSD */
156 #if defined(__OpenBSD_kernel__)
157 #define KOpenBSDArchitecture
161 # define MacroIncludeFile <NetBSD.cf>
162 # define MacroFile NetBSD.cf
164 # define BSDArchitecture
165 # define NetBSDArchitecture
167 # define i386BsdArchitecture
168 # define i386Architecture
172 # define AMD64BsdArchitecture
173 # define AMD64Architecture
176 # if defined(__sparc__) || defined(sparc)
177 # define SparcArchitecture
183 # define MacroIncludeFile <FreeBSD.cf>
184 # define MacroFile FreeBSD.cf
186 # define BSDArchitecture
187 # define FreeBSDArchitecture
189 # define i386BsdArchitecture
190 # define i386Architecture
194 # define AMD64BsdArchitecture
195 # define AMD64Architecture
198 #endif /* __FreeBSD__ */
201 /* Should be before the 'sun' entry because we may be cross-compiling */
202 # define MacroIncludeFile <Amoeba.cf>
203 # define MacroFile Amoeba.cf
204 # if defined(i80386) || defined(__i80386__)
206 # define i386Architecture
208 # if defined(mc68000) || defined(__mc68000__)
210 # define Sun3Architecture
211 # define SunArchitecture
213 # if defined(sparc) || defined(__sparc__)
215 # define SparcArchitecture
216 # define SunArchitecture
224 # define MacroIncludeFile <sun.cf>
225 # define MacroFile sun.cf
228 # define SVR4Architecture
232 # define SparcArchitecture
236 # define SparcV9Architecture
240 # define Sun3Architecture
244 # define i386Architecture
246 # if defined(__amd64__) || defined (__x86_64__)
249 # define AMD64Architecture
252 # define SunArchitecture
256 # define MacroIncludeFile <hp.cf>
257 # define MacroFile hp.cf
259 # define HPArchitecture
263 # define MacroIncludeFile <ncr.cf>
264 # define MacroFile ncr.cf
268 # define SVR4Architecture
269 # define i386Architecture
270 # define NCRArchitecture
274 # define MacroIncludeFile <apollo.cf>
275 # define MacroFile apollo.cf
277 # define ApolloArchitecture
281 # define MacroIncludeFile <sony.cf>
282 # define MacroFile sony.cf
285 # define SonyArchitecture
289 # define Mc68020Architecture
293 # define MipsArchitecture
296 # define SVR4Architecture
298 # if !defined(bsd43) || defined(SYSTYPE_SYSV) || defined(_SYSTYPE_SYSV)
299 # define SonySysvArchitecture
301 # define SonyBsdArchitecture
307 # define MacroIncludeFile <pegasus.cf>
308 # define MacroFile pegasus.cf
310 # define PegasusArchitecture
314 # define MacroIncludeFile <m4330.cf>
315 # define MacroFile m4330.cf
317 # define M4330Architecture
321 # define MacroIncludeFile <macII.cf>
322 # define MacroFile macII.cf
324 # define MacIIArchitecture
328 # define MacroIncludeFile <cray.cf>
329 # define MacroFile cray.cf
335 # define CrayArchitecture
339 # define MacroIncludeFile <sgi.cf>
340 # define MacroFile sgi.cf
342 # define SGIArchitecture
344 # define MipsArchitecture
347 # define SVR4Architecture
349 # ifdef _SYSTYPE_SVR4
350 # undef _SYSTYPE_SVR4
351 # define SVR4Architecture
356 # define MacroIncludeFile <stellar.cf>
357 # define MacroFile stellar.cf
359 # define StellarArchitecture
362 #if defined(ibm) || defined(_IBMR2) || defined(ibm032) || defined(aix)
363 # define MacroIncludeFile <ibm.cf>
364 # define MacroFile ibm.cf
368 # define IBMArchitecture
371 # define PS2Architecture
375 # define RtArchitecture
379 # define AIXArchitecture
383 # define RsArchitecture
389 # define MacroIncludeFile <luna.cf>
390 # define MacroFile luna.cf
391 # define LunaArchitecture
394 # define Mc68000Architecture
397 # define Mc88000Architecture
402 # define MacroIncludeFile <Mips.cf>
403 # define MacroFile Mips.cf
406 # if defined(SYSTYPE_BSD43) || defined(BSD) || defined(BSD43)
407 # define MipsBsdArchitecture
409 # define MipsSysvArchitecture
414 # define MacroIncludeFile <moto.cf>
415 # define MacroFile moto.cf
418 # define MotoR3Architecture
421 # define MotoR4Architecture
423 #endif /* MOTOROLA */
427 # define i386Architecture
430 # define SVR4Architecture
431 # define MacroIncludeFile <svr4.cf>
432 # define MacroFile svr4.cf
438 # define MacroIncludeFile <x386.cf>
439 # define MacroFile x386.cf
440 # define i386SVR3Architecture
448 # define i386Architecture
449 # define SVR4Architecture
450 # define i386SVR4Architecture
451 # define MacroIncludeFile <svr4.cf>
452 # define MacroFile svr4.cf
455 # define MacroIncludeFile <x386.cf>
456 # define MacroFile x386.cf
457 # define i386SVR3Architecture
462 # define MacroIncludeFile <DGUX.cf>
463 # define MacroFile DGUX.cf
465 # define DguxArchitecture
469 # define MacroIncludeFile <convex.cf>
470 # define MacroFile convex.cf
474 # define ConvexArchitecture
475 #endif /* _convex_ */
478 # define MacroIncludeFile <osf1.cf>
479 # define MacroFile osf1.cf
480 # define OSF1Architecture
484 # define MipsArchitecture
488 # define AlphaArchitecture
493 # define MacroIncludeFile <Oki.cf>
494 # define MacroFile Oki.cf
496 # define i860SVR4Architecture
497 # define SVR4Architecture
502 # define MacroIncludeFile <Win32.cf>
503 # define MacroFile Win32.cf
504 # define Win32Architecture
508 # define MacroIncludeFile <linux.cf>
509 # define MacroFile linux.cf
511 # define LinuxArchitecture
515 # define i386Architecture
519 # ifndef i386Architecture
520 # define i386Architecture
525 # define AlphaArchitecture
527 # endif /* __alpha */
529 # define PpcArchitecture
533 # ifndef PpcArchitecture
534 # define PpcArchitecture
538 # if defined(__amd64__) || defined (__x86_64__)
541 # define AMD64Architecture
543 # if defined(amd64__) || defined (x86_64__)
546 # ifndef AMD64Architecture
547 # define AMD64Architecture
550 # if defined(__arm__)
552 # define ARMArchitecture
554 # if defined(__sparc__) || defined(sparc)
555 # define SparcArchitecture
560 #if defined(sequent) || defined(_SEQUENT_)
561 # define MacroIncludeFile <sequent.cf>
562 # define MacroFile sequent.cf
565 # define Dynix3Architecture
569 # define DynixPtxArchitecture
571 # define SequentArchitecture
574 #if defined(_nec_ews_svr4) || defined(nec_ews_svr4) || defined(nec_ews_svr2) || defined(SX) || defined(_nec_up) || defined(_nec_ft) || defined(PC_UX)
578 # define MacroIncludeFile <nec.cf>
579 # define MacroFile nec.cf
580 # define NecArchitecture
583 #ifndef MacroIncludeFile
584 XCOMM WARNING: Imake.cf not configured; guessing at definitions!!!
585 XCOMM This might mean that BOOTSTRAPCFLAGS was not set when building imake.
586 #define MacroIncludeFile <generic.cf>
587 #define MacroFile generic.cf