home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-bin / x11r6.1 / lib / x11 / config / imake.cf < prev    next >
Encoding:
Text File  |  1996-10-17  |  9.5 KB  |  459 lines

  1. XCOMM $XConsortium: Imake.cf /main/22 1995/12/05 16:39:53 mor $
  2. /*
  3.  * To add support for another platform:
  4.  * 
  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).
  9.  *
  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.
  13.  *
  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).
  17.  *
  18.  *     4.  Create a .cf file with the name given by MacroFile.
  19.  */
  20.  
  21. #ifdef ultrix
  22. # define MacroIncludeFile <ultrix.cf>
  23. # define MacroFile ultrix.cf
  24. # ifdef vax
  25. #  undef vax
  26. #  define VaxArchitecture
  27. # endif
  28. # ifdef mips
  29. #  undef mips
  30. #  define MipsArchitecture
  31. # endif
  32. # undef ultrix
  33. # define UltrixArchitecture
  34. #endif /* ultrix */
  35.  
  36. #if defined(vax) && !defined(UltrixArchitecture)
  37. # define MacroIncludeFile <bsd.cf>
  38. # define MacroFile bsd.cf
  39. # undef vax
  40. # define BSDArchitecture
  41. # define VaxArchitecture
  42. #endif /* vax */
  43.  
  44. #ifdef bsdi
  45. # define MacroIncludeFile <bsdi.cf>
  46. # define MacroFile bsdi.cf
  47. # undef bsdi
  48. # define BSD386Architecture
  49. # define i386BsdArchitecture
  50. # define i386Architecture
  51. # undef i386
  52. #endif /* bsdi */
  53.  
  54. #ifdef __NetBSD__
  55. # define MacroIncludeFile <NetBSD.cf>
  56. # define MacroFile NetBSD.cf
  57. # undef __NetBSD__
  58. # define NetBSDArchitecture
  59. # ifdef __i386__
  60. #  define i386BsdArchitecture
  61. #  define i386Architecture
  62. #  undef i386
  63. # endif
  64. # if defined(__sparc__) || defined(sparc)
  65. #  define SparcArchitecture
  66. #  undef sparc
  67. # endif
  68. #endif /* NetBSD */
  69.  
  70. #ifdef __FreeBSD__
  71. # define MacroIncludeFile <FreeBSD.cf>
  72. # define MacroFile FreeBSD.cf
  73. # undef __FreeBSD__
  74. # define FreeBSDArchitecture
  75. # ifdef __i386__
  76. #  define i386BsdArchitecture
  77. #  define i386Architecture
  78. #  undef i386
  79. # endif
  80. #endif /* __FreeBSD__ */
  81.  
  82. #ifdef AMOEBA
  83.  /* Should be before the 'sun' entry because we may be cross-compiling */
  84. # define MacroIncludeFile <Amoeba.cf>
  85. # define MacroFile Amoeba.cf
  86. # if defined(i80386) || defined(__i80386__)
  87. #  undef i80386
  88. #  define i386Architecture
  89. # else
  90. #  if defined(mc68000) || defined(__mc68000__)
  91. #   undef mc68000
  92. #   define Sun3Architecture
  93. #   define SunArchitecture
  94. #  else
  95. #   if defined(sparc) || defined(__sparc__)
  96. #    undef sparc
  97. #    define SparcArchitecture
  98. #    define SunArchitecture
  99. #   endif
  100. #  endif
  101. #  undef sun
  102. # endif
  103. #endif /* AMOEBA */
  104.  
  105. #ifdef sun
  106. # define MacroIncludeFile <sun.cf>
  107. # define MacroFile sun.cf
  108. # ifdef SVR4
  109. #  undef SVR4
  110. #  define SVR4Architecture
  111. # endif
  112. # ifdef sparc
  113. #  undef sparc
  114. # define SparcArchitecture
  115. # endif
  116. # ifdef mc68000
  117. #  undef mc68000
  118. # define Sun3Architecture
  119. # endif
  120. # ifdef i386
  121. #  undef i386
  122. #  define i386Architecture
  123. # endif
  124. # undef sun
  125. # define SunArchitecture
  126. #endif /* sun */
  127.  
  128. #ifdef hpux
  129. # define MacroIncludeFile <hp.cf>
  130. # define MacroFile hp.cf
  131. # undef hpux
  132. # define HPArchitecture
  133. #endif /* hpux */
  134.  
  135. #ifdef sco
  136. # define MacroIncludeFile <sco.cf>
  137. # define MacroFile sco.cf
  138. # undef sco
  139. # undef USL
  140. # undef SYSV
  141. # undef i386
  142. /* # define i386Architecture */
  143. # define SCOArchitecture
  144. #endif /* sco */
  145.  
  146. #ifdef USL
  147. # define MacroIncludeFile <usl.cf>
  148. # define MacroFile usl.cf
  149. # undef USL
  150. # undef SVR4
  151. # undef i386
  152. # define SVR4Architecture
  153. # define i386Architecture
  154. # define USLArchitecture
  155. #endif /* USL */
  156.  
  157. #ifdef NCR
  158. # define MacroIncludeFile <ncr.cf>
  159. # define MacroFile ncr.cf
  160. # undef NCR
  161. # undef SVR4
  162. # undef i386
  163. # define SVR4Architecture
  164. # define i386Architecture
  165. # define NCRArchitecture
  166. #endif /* NCR */
  167.  
  168. #ifdef apollo
  169. # define MacroIncludeFile <apollo.cf>
  170. # define MacroFile apollo.cf
  171. # undef apollo
  172. # define ApolloArchitecture
  173. #endif /* apollo */
  174.  
  175. #ifdef sony
  176. # define MacroIncludeFile <sony.cf>
  177. # define MacroFile sony.cf
  178. # undef sony
  179. # undef sony_news
  180. # define SonyArchitecture
  181. # ifdef mc68020
  182. #  undef mc68020
  183. #  undef mc68030
  184. #  define Mc68020Architecture
  185. # endif
  186. # ifdef mips
  187. #  undef mips
  188. #  define MipsArchitecture
  189. # endif
  190. # ifdef __svr4
  191. #  define SVR4Architecture
  192. # else
  193. #  if !defined(bsd43) || defined(SYSTYPE_SYSV) || defined(_SYSTYPE_SYSV)
  194. #   define SonySysvArchitecture
  195. #  else
  196. #   define SonyBsdArchitecture
  197. #  endif
  198. # endif
  199. #endif /* sony */
  200.  
  201. #ifdef M4310
  202. # define MacroIncludeFile <pegasus.cf>
  203. # define MacroFile pegasus.cf
  204. # undef M4310
  205. # define PegasusArchitecture
  206. #endif /* M4310 */
  207.  
  208. #ifdef M4330
  209. # define MacroIncludeFile <m4330.cf>
  210. # define MacroFile m4330.cf
  211. # undef  M4330
  212. # define M4330Architecture
  213. #endif /* M4330 */
  214.  
  215. #ifdef macII
  216. # define MacroIncludeFile <macII.cf>
  217. # define MacroFile macII.cf
  218. # undef  macII
  219. # define MacIIArchitecture
  220. #endif /* macII */
  221.  
  222. #ifdef _CRAY
  223. # define MacroIncludeFile <cray.cf>
  224. # define MacroFile cray.cf
  225. # undef cray
  226. # undef CRAY
  227. # undef CRAY1
  228. # undef CRAY2
  229. # undef YMP
  230. # define CrayArchitecture
  231. #endif /* _CRAY */
  232.  
  233. #ifdef sgi
  234. # define MacroIncludeFile <sgi.cf>
  235. # define MacroFile sgi.cf
  236. # undef sgi
  237. # define SGIArchitecture
  238. # undef mips
  239. # define MipsArchitecture
  240. # ifdef _SVR4
  241. #  undef _SVR4
  242. #  define SVR4Architecture
  243. # endif
  244. #endif /* sgi */
  245.  
  246. #ifdef stellar
  247. # define MacroIncludeFile <stellar.cf>
  248. # define MacroFile stellar.cf
  249. # undef stellar
  250. # define StellarArchitecture
  251. #endif /* stellar */
  252.  
  253. #if defined(ibm) || defined(_IBMR2) || defined(ibm032) || defined(aix)
  254. # define MacroIncludeFile <ibm.cf>
  255. # define MacroFile ibm.cf
  256. # ifdef ibm
  257. #  undef ibm
  258. # endif
  259. # define IBMArchitecture
  260. # ifdef i386
  261. #  undef i386
  262. #  define PS2Architecture
  263. # endif
  264. # ifdef ibm032
  265. #  undef ibm032
  266. #  define RtArchitecture
  267. # endif
  268. # ifdef aix
  269. #  undef aix
  270. #  define AIXArchitecture
  271. # endif
  272. # ifdef _IBMR2
  273. #  undef _IBMR2
  274. #  define RsArchitecture
  275. # endif
  276. #endif /* ibm */
  277.  
  278. #ifdef luna
  279. # undef luna
  280. # define MacroIncludeFile <luna.cf>
  281. # define MacroFile luna.cf
  282. # define LunaArchitecture
  283. # ifdef mc68000
  284. #  undef mc68000
  285. #  define Mc68000Architecture
  286. # else
  287. #  undef mc88000
  288. #  define Mc88000Architecture
  289. # endif
  290. #endif /* luna */
  291.  
  292. #ifdef Mips
  293. #  define MacroIncludeFile <Mips.cf>
  294. #  define MacroFile Mips.cf
  295. #  undef Mips
  296. #  undef mips
  297. #  if defined(SYSTYPE_BSD43) || defined(BSD) || defined(BSD43)
  298. #    define MipsBsdArchitecture
  299. #  else /* BSD */
  300. #    define MipsSysvArchitecture
  301. #  endif /* BSD */
  302. #endif /* Mips */
  303.  
  304. #ifdef MOTOROLA
  305. # define MacroIncludeFile <moto.cf>
  306. # define MacroFile moto.cf
  307. # undef MOTOROLA    
  308. # ifdef SYSV
  309. #  define MotoR3Architecture
  310. # endif
  311. # ifdef SVR4
  312. #  define MotoR4Architecture
  313. # endif
  314. #endif /* MOTOROLA */
  315.  
  316. #ifdef SVR4
  317. # ifdef i386
  318. #  define i386Architecture
  319. #  undef i386
  320. # endif
  321. # define SVR4Architecture
  322. # define MacroIncludeFile <svr4.cf>
  323. # define MacroFile svr4.cf
  324. # undef SVR4
  325. #endif /* SVR4 */
  326.  
  327. #ifdef SYSV
  328. # ifdef i386
  329. #  define MacroIncludeFile <x386.cf>
  330. #  define MacroFile x386.cf
  331. #  define i386SVR3Architecture
  332. #  undef i386
  333. # endif
  334. #endif /* SYSV */
  335.  
  336. #ifdef SYSV386
  337. # undef i386
  338. # ifdef SVR4
  339. #  define i386Architecture
  340. #  define SVR4Architecture
  341. #  define i386SVR4Architecture
  342. #  define MacroIncludeFile <svr4.cf>
  343. #  define MacroFile svr4.cf
  344. #  undef SVR4
  345. # else
  346. #  define MacroIncludeFile <x386.cf>
  347. #  define MacroFile x386.cf
  348. #  define i386SVR3Architecture
  349. # endif
  350. #endif /* SYSV386 */
  351.  
  352. #ifdef DGUX
  353. # define MacroIncludeFile <DGUX.cf>
  354. # define MacroFile DGUX.cf
  355. # undef DGUX
  356. # define DguxArchitecture
  357. #endif /* DGUX */
  358.  
  359. #ifdef __convex__
  360. # define MacroIncludeFile <convex.cf>
  361. # define MacroFile convex.cf
  362. # ifdef convex
  363. #  undef convex
  364. # endif
  365. # define ConvexArchitecture
  366. #endif /* _convex_ */
  367.  
  368. #ifdef __osf__
  369. # define MacroIncludeFile <osf1.cf>
  370. # define MacroFile osf1.cf
  371. # define OSF1Architecture
  372. # undef __osf__
  373. # ifdef __mips__
  374. #  undef __mips__
  375. #  define MipsArchitecture
  376. # endif
  377. # ifdef __alpha
  378. #  undef __alpha
  379. #  define AlphaArchitecture
  380. # endif
  381. #endif /* __osf__ */
  382.  
  383. #ifdef Oki
  384. # define MacroIncludeFile <Oki.cf>
  385. # define MacroFile Oki.cf
  386. # undef Oki
  387. # define i860SVR4Architecture
  388. # define SVR4Architecture
  389. # undef SVR4
  390. #endif /* Oki */
  391.  
  392. #ifdef WIN32
  393. # define MacroIncludeFile <Win32.cf>
  394. # define MacroFile Win32.cf
  395. # define Win32Architecture
  396. #endif /* WIN32 */
  397.  
  398. #ifdef linux 
  399. # define MacroIncludeFile <linux.cf>
  400. # define MacroFile linux.cf
  401. # undef linux
  402. # define LinuxArchitecture
  403. # define i386Architecture
  404. # undef i386
  405. #endif /* linux */
  406.  
  407. #ifdef __uxp__
  408. # define MacroIncludeFile <fujitsu.cf>
  409. # define MacroFile fujitsu.cf
  410. # undef __uxp__
  411. # ifdef sparc
  412. #  undef sparc
  413. #  define SparcArchitecture
  414. # endif
  415. #endif /* __uxp__ */
  416.  
  417. #ifdef __sxg__
  418. # define MacroIncludeFile <fujitsu.cf>
  419. # define MacroFile fujitsu.cf
  420. # undef __sxg__
  421. # define mc68000Architecture
  422. #endif /* __sxg__ */
  423.  
  424. #if defined(sequent) || defined(_SEQUENT_)
  425. # define MacroIncludeFile <sequent.cf>
  426. # define MacroFile sequent.cf
  427. # ifdef sequent
  428. #  undef sequent
  429. #  define Dynix3Architecture
  430. # endif
  431. # ifdef _SEQUENT_
  432. #  undef _SEQUENT_
  433. #  define DynixPtxArchitecture
  434. # endif
  435. # define SequentArchitecture
  436. #endif
  437.  
  438. #if defined(_nec_ews_svr4) || defined(nec_ews_svr4) || defined(nec_ews_svr2) || defined(SX) || defined(_nec_up) || defined(_nec_ft) || defined(PC_UX)
  439. # ifdef nec
  440. #  undef nec
  441. # endif
  442. # define MacroIncludeFile <nec.cf>
  443. # define MacroFile nec.cf
  444. # define NecArchitecture
  445. #endif
  446.  
  447. #if defined(__amigaos__)
  448. # define MacroIncludeFile <Amiga.cf>
  449. # define MacroFile Amiga.cf
  450. # define mc68000Architecture
  451. #endif
  452.  
  453. #ifndef MacroIncludeFile
  454. XCOMM WARNING:  Imake.cf not configured; guessing at definitions!!!
  455. XCOMM This might mean that BOOTSTRAPCFLAGS was not set when building imake.
  456. #define MacroIncludeFile <generic.cf>
  457. #define MacroFile generic.cf
  458. #endif
  459.