]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - bin/csh/host.defs
This commit was generated by cvs2svn to compensate for changes in r93526,
[FreeBSD/FreeBSD.git] / bin / csh / host.defs
1 newcode :
2 /* $Header: /src/pub/tcsh/host.defs,v 1.31 2001/06/10 02:19:11 christos Exp $ */
3 /* $FreeBSD$ */
4 /*
5  * host.defs: Hosttype/Machtype etc.
6  */
7 /*-
8  * Copyright (c) 1980, 1991 The Regents of the University of California.
9  * All rights reserved.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  *    notice, this list of conditions and the following disclaimer.
16  * 2. Redistributions in binary form must reproduce the above copyright
17  *    notice, this list of conditions and the following disclaimer in the
18  *    documentation and/or other materials provided with the distribution.
19  * 3. All advertising materials mentioning features or use of this software
20  *    must display the following acknowledgement:
21  *      This product includes software developed by the University of
22  *      California, Berkeley and its contributors.
23  * 4. Neither the name of the University nor the names of its contributors
24  *    may be used to endorse or promote products derived from this software
25  *    without specific prior written permission.
26  *
27  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
28  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
29  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
31  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
36  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37  * SUCH DAMAGE.
38  */
39 #include "sh.h"
40
41 RCSID("$Id: host.defs,v 1.31 2001/06/10 02:19:11 christos Exp $")
42
43 endcode :
44
45 macro   : M_mipsel : (defined(mips) || defined(__mips)) && (defined(MIPSEL) || defined(__MIPSEL))
46 macro   : M_mipseb : (defined(mips) || defined(__mips)) && (defined(MIPSEB) || defined(__MIPSEB))
47 macro   : M_i386 : (defined(i386) || defined(__i386__))
48 macro   : M_i486 : (defined(i486) || defined(__i486__))
49 macro   : M_i586 : (defined(i586) || defined(__i586__))
50 macro   : M_intel : (defined(M_i386) || defined(M_i486) || defined(M_i586))
51
52 newdef  : defined(ns32000)
53 newcode :
54 static char *
55 isamultimax(flag)
56     int flag;
57 {
58     if (access("/Umax.image", F_OK) == 0)
59         return "multimax";
60     else 
61         return flag ? "mach" : "ns32000";
62 }
63 endcode :
64 enddef  :
65
66
67 newdef  : defined(cray)
68 newcode :
69 /*  
70  * On crays, find the current machine type via the target() syscall
71  * We need ctype.h to convert the name returned to lower case
72  */
73 # include <sys/target.h> 
74 # include <ctype.h>
75 # include <string.h>
76
77 /* From: hpa@hook.eecs.nwu.edu (H. Peter Anvin) */
78 static char *
79 getcray()
80 {
81 # ifdef MC_GET_SYSTEM /* If we have target() */
82     struct target data;
83
84     if (target(MC_GET_SYSTEM, &data) != -1) {
85         static char hosttype_buf[sizeof(data.mc_pmt)+1];
86         char *p = (char *) &(data.mc_pmt);
87         char *q = hosttype_buf;
88         int n;
89
90         /* 
91          * Copy to buffer and convert to lower case 
92          * String may not be null-terminated, so keep a counter
93          */
94         for (n = 0; *p && n < sizeof(data.mc_pmt); n++)
95           *q++ = tolower(p[n]);
96
97         *q = '\0';
98
99         /* replace dashes with underscores if present */
100         while ((q = strchr(hosttype_buf, '-')) != NULL)
101             *q = '_';
102         return hosttype_buf;    /* Return in static buffer */
103     }
104     else
105 # endif /* MC_GET_SYSTEM */
106         return "cray";          /* target() failed */
107 }
108 endcode :
109 enddef  :
110
111
112 newdef  : defined(convex)
113 newcode :
114 /*  
115  * On convex, find the current machine type via the getsysinfo() syscall
116  */
117 #include <sys/sysinfo.h> 
118
119 /* From: fox@convex.com (David DeSimone) */
120 static char *
121 getconvex()
122 {
123     struct system_information  sysinfo;
124     static char  result[8];
125
126     if (getsysinfo(SYSINFO_SIZE, &sysinfo) == -1)
127         return "convex";
128
129     switch(sysinfo.cpu_type) {
130 #ifdef SI_CPUTYPE_C1
131     case SI_CPUTYPE_C1:
132         return "c1";
133 #endif
134
135 #ifdef SI_CPUTYPE_C2
136     case SI_CPUTYPE_C2:
137         return "c2";
138 #endif
139
140 #ifdef SI_CPUTYPE_C2MP
141     case SI_CPUTYPE_C2MP:
142         (void) strcpy(result, "c2X0");
143         result[2] = sysinfo.cpu_count + '0';
144         return result;
145 #endif
146
147 #ifdef SI_CPUTYPE_C34
148     case SI_CPUTYPE_C34:
149         (void) strcpy(result, "c34X0");
150         result[3] = sysinfo.cpu_count + '0';
151         return result;
152 #endif
153
154 #ifdef SI_CPUTYPE_C38
155     case SI_CPUTYPE_C38:
156         (void) strcpy(result, "c38X0");
157         result[3] = sysinfo.cpu_count + '0';
158         return result;
159 #endif
160
161 #ifdef SI_CPUTYPE_C46
162     case SI_CPUTYPE_C46:
163         (void) strcpy(result, "c46X0");
164         result[3] = sysinfo.cpu_count + '0';
165         return result;
166 #endif
167
168     default:
169         return "convex";
170     }
171 }
172 endcode :
173 enddef  :
174
175
176 newcode :
177 void
178 getmachine()
179 {
180      char *hosttype;
181      char *ostype;
182      char *vendor;
183      char *machtype;
184
185 endcode :
186
187
188 newdef  : defined(HOSTTYPE)
189 hosttype:                                               : HOSTTYPE
190 enddef  :
191
192
193 newdef  : defined(__PARAGON__)
194 comment : Intel Paragon running OSF/1
195 vendor  :                                               : "intel"
196 hosttype:                                               : "paragon"
197 ostype  :                                               : "osf1"
198 machtype: defined(M_i386)                               : "i386"
199 enddef  :
200
201
202 newdef  : defined(AMIX)
203 comment : Amiga running Amix 2.02
204 vendor  :                                               : "commodore"
205 hosttype:                                               : "amiga"
206 ostype  :                                               : "Amix"
207 machtype:                                               : "m68k"
208 enddef  :
209
210
211 newdef  : defined(accel)
212 comment : celerity Accel
213 vendor  :                                               : "celerity"
214 hosttype:                                               : "celerityACCEL"
215 ostype  :                                               : "unix"
216 machtype:                                               : "accel"
217 enddef  :
218
219
220 newdef  : defined(_VMS_POSIX)
221 comment : digital vax or alpha running vms posix
222 vendor  :                                               : "dec"
223 hosttype:                                               : "VMS-POSIX"
224 ostype  :                                               : "vms"
225 machtype: defined(__alpha)                              : "alpha"
226 machtype: defined(__vax) || defined(vax)                : "vax"
227 machtype: defined(__vax__)                              : "vax"
228 enddef  :
229
230
231 newdef  : defined(__hp_osf)
232 comment : Hewlett Packard running OSF/1
233 vendor  :                                               : "hp"
234 hosttype: defined(__pa_risc)                            : "hp9000s700-osf1"
235 hosttype:                                               : "hp-osf1"
236 ostype  :                                               : "osf1"
237 machtype: defined(__pa_risc)                            : "pa_risc"
238 enddef  :
239
240
241 newdef  : defined(hp9000)
242 comment : Hewlett Packard running MORE/bsd 
243 vendor  :                                               : "hp"
244 hosttype: defined(hp300)                                : "hp300"
245 hosttype: defined(hp800)                                : "hp800"
246 hosttype:                                               : "hp9000"
247 ostype  : defined(BSD4_4)                               : "bsd44"
248 ostype  :                                               : "mtXinu"
249 machtype: defined(hp300)                                : "m68k"
250 machtype: defined(hp800)                                : "pa_risc"
251 enddef  :
252
253
254 newdef  : defined(hpux) || defined(__hpux)
255 comment : Hewlett Packard running HP/UX
256 vendor  :                                               : "hp"
257 hosttype: defined(__hp9000s700)                         : "hp9000s700"
258 hosttype: defined(__hp9000s800) || defined(hp9000s800)  : "hp9000s800"
259 hosttype: defined(hp9000s500)                           : "hp9000s500"
260 hosttype: defined(__hp9000s300) || defined(hp9000s300)  : "hp9000s300"
261 hosttype:                                               : "hp"
262 ostype  :                                               : "hpux"
263 machtype: defined(__hp9000s700)                         : "pa_risc"
264 machtype: defined(__hp9000s800) || defined(hp9000s800)  : "pa_risc"
265 machtype: defined(hp9000s500)                           : "m68k"
266 machtype: defined(__hp9000s300) || defined(hp9000s300)  : "m68k"
267 enddef  :
268
269
270 newdef  : defined(apollo)
271 comment : Hewlett Packard apollo running Domain/OS
272 vendor  :                                               : "hp"
273 hosttype:                                               : "apollo"
274 ostype  :                                               : "DomainOS"
275 machtype:                                               : "m68k"
276 enddef  :
277
278
279 newdef  : defined(sun) || defined(__sun__)
280 comment : Sun Microsystems series 2 workstation (68010 based)
281 comment : Sun Microsystems series 3 workstation (68020 based)
282 comment : Sun Microsystems 386i workstation (386 based)
283 comment : Sun Microsystems series 4 workstation (SPARC based)
284 vendor  :                                               : "sun"
285 hosttype: defined(M_i386) && !defined(__SVR4)           : "sun386i"
286 hosttype: defined(M_i386) && defined(__SVR4)            : "i86pc"
287 hosttype: defined(mc68010) || defined(__mc68010__)      : "sun2"
288 hosttype: defined(mc68020) || defined(__mc68020__)      : "sun3"
289 hosttype: defined(sparc) || defined(__sparc__)          : "sun4"
290 hosttype:                                               : "sun"
291 ostype  : defined(SUNOS3)                               : "sunos3"
292 ostype  : defined(SUNOS4)                               : "sunos4"
293 ostype  : defined(SOLARIS2)                             : "solaris"
294 machtype: defined(mc68010) || defined(__mc68010__)      : "m68k"
295 machtype: defined(mc68020) || defined(__mc68020__)      : "m68k"
296 machtype: defined(sparc) || defined(__sparc__)          : "sparc"
297 machtype: defined(M_i386)                               : "i386"
298 enddef  :
299
300
301 newdef  : defined(pyr)
302 comment : Pyramid Technology
303 vendor  :                                               : "pyramid"
304 hosttype:                                               : "pyramid"
305 machtype:                                               : "pyramid"
306 enddef  :
307
308
309 newdef  : defined(hcx) || defined(_CX_UX)
310 comment : Harris Tahoe running CX/UX
311 vendor  :                                               : "harris"
312 hosttype:                                               : "hcx"
313 ostype  :                                               : "hcx"
314 machtype:                                               : "tahoe"
315 enddef  :
316
317
318 newdef  : defined(tahoe)
319 comment : Harris Tahoe
320 vendor  :                                               : "harris"
321 hosttype:                                               : "tahoe"
322 machtype:                                               : "tahoe"
323 enddef  :
324
325
326 newdef  : defined(ibm032)
327 comment : RT running IBM AOS4.3 or MACH
328 vendor  :                                               : "ibm"
329 hosttype:                                               : "rt"
330 ostype  : defined(MACH)                                 : "mach"
331 ostype  :                                               : "aos"
332 machtype:                                               : "ibm032"
333 enddef  :
334
335
336 newdef  : defined(aiws)
337 comment : RT running IBM aix2.x
338 vendor  :                                               : "ibm"
339 hosttype:                                               : "rtpc"
340 ostype  :                                               : "aix"
341 machtype:                                               : "ibm032"
342 enddef  :
343
344
345 newdef  : defined(_AIX370)
346 comment : IBM/370 running aix
347 vendor  :                                               : "ibm"
348 hosttype:                                               : "aix370"
349 ostype  :                                               : "aix"
350 machtype:                                               : "ibm370"
351 enddef  :
352
353
354 newdef  : defined(_IBMESA)
355 comment : IBM/ESA running aix
356 vendor  :                                               : "ibm"
357 hosttype:                                               : "aixESA"
358 ostype  :                                               : "aix"
359 machtype:                                               : "esa"
360 enddef  :
361
362
363 newdef  : defined(_IBMR2)
364 comment : IBM/RS6000 running aix
365 vendor  :                                               : "ibm"
366 hosttype:                                               : "rs6000"
367 ostype  :                                               : "aix"
368 machtype:                                               : "rs6000"
369 enddef  :
370
371
372 newdef  : defined(_AIXPS2)
373 comment : IBM/PS2 running aix
374 vendor  :                                               : "ibm"
375 hosttype:                                               : "ps2"
376 ostype  :                                               : "aix"
377 machtype:                                               : "i386"
378 enddef  :
379
380
381 newdef  : defined(OREO)
382 comment : Macintosh running AU/X
383 vendor  :                                               : "apple"
384 hosttype:                                               : "mac2"
385 ostype  :                                               : "aux"
386 machtype: defined(mc68020)                              : "m68k"
387 enddef  :
388
389
390 newdef  : defined(u3b20d)
391 comment : AT&T 3B/20 series running SVR2/3 
392 vendor  :                                               : "att"
393 hosttype:                                               : "att3b20"
394 machtype:                                               : "u3b20"
395 enddef  :
396
397
398 newdef  : defined(u3b15)
399 comment : AT&T 3B/15 series running SVR2/3 
400 vendor  :                                               : "att"
401 hosttype:                                               : "att3b15"
402 machtype:                                               : "u3b15"
403 enddef  :
404
405
406 newdef  : defined(u3b5)
407 comment : AT&T 3B/5 series running SVR2/3 
408 vendor  :                                               : "att"
409 hosttype:                                               : "att3b5"
410 machtype:                                               : "u3b5"
411 enddef  :
412
413
414 newdef  : defined(u3b2)
415 comment : AT&T 3B/2 series running SVR2/3 
416 vendor  :                                               : "att"
417 hosttype:                                               : "att3b2"
418 machtype:                                               : "u3b2"
419 enddef  :
420
421
422 newdef  : defined(UNIXPC)
423 comment : AT&T UnixPC att3b1/att7300
424 vendor  :                                               : "att"
425 hosttype:                                               : "unixpc"
426 machtype: defined(u3b1)                                 : "u3b1"
427 machtype: defined(att7300)                              : "att7300"
428 enddef  :
429
430
431 newdef  : defined(_MINIX)
432 comment : Andy Tanenbaum's minix
433 vendor  : defined(M_i386)                               : "intel"
434 hosttype: defined(M_i386)                               : "minix386"
435 hosttype:                                               : "minix"
436 ostype  :                                               : "minix"
437 machtype: defined(M_i386)                               : "i386"
438 enddef  :
439
440
441 newdef  : defined(linux)
442 comment : Linus Torvalds's linux
443 vendor  : defined(M_intel)                              : "intel"
444 hosttype: defined(M_i586)                               : "i586-linux"
445 hosttype: defined(M_i486)                               : "i486-linux"
446 hosttype: defined(M_i386)                               : "i386-linux"
447 ostype  : !defined(PPC)                                 : "linux"
448 ostype  : defined(PPC)                                  : "mklinux"
449 machtype: defined(M_i586)                               : "i586"
450 machtype: defined(M_i486)                               : "i486"
451 machtype: defined(M_i386)                               : "i386"
452 vendor  : defined(__alpha)                              : "dec"
453 vendor  : defined(PPC)                                  : "apple"
454 hosttype: defined(__alpha)                              : "alpha"
455 hosttype: defined(PPC)                                  : "powerpc"
456 machtype: defined(__alpha)                              : "alpha"
457 machtype: defined(PPC)                                  : "powerpc"
458 enddef  :
459
460
461 newdef  : defined(__EMX__)
462 comment : OS/2 EMX [unix emulation under OS/2]
463 vendor  : defined(M_intel)                              : "intel"
464 hosttype: defined(M_i386)                               : "i386-emx"
465 ostype  :                                               : "os2"
466 machtype: defined(M_i386)                               : "i386"
467 enddef  :
468
469
470 newdef  : defined(__NetBSD__) 
471 comment : NetBSD
472 vendor  : defined(arm32)                                : "acorn"
473 vendor  : defined(alpha)                                : "digital"
474 vendor  : defined(amiga)                                : "commodore"
475 vendor  : defined(atari)                                : "atari"
476 vendor  : defined(hp300)                                : "hp"
477 vendor  : defined(M_intel)                              : "intel"
478 vendor  : defined(m68k)                                 : "motorola"
479 vendor  : defined(mac68k)                               : "apple"
480 vendor  : defined(pc532)                                : "national-semi"
481 vendor  : defined(pmax)                                 : "dec"
482 vendor  : defined(mips)                                 : "mips"
483 vendor  : defined(sparc)                                : "sun"
484 vendor  : defined(sun3)                                 : "sun"
485 vendor  : defined(vax)                                  : "digital"
486 hosttype:                                               : "NetBSD"
487 ostype  :                                               : "NetBSD"
488 machtype: defined(arm32)                                : "arm32"
489 machtype: defined(sparc)                                : "sparc"
490 machtype: defined(mc68020)                              : "m68k"
491 machtype: defined(M_i386)                               : "i386"
492 machtype: defined(M_mipsel)                             : "mipsel"
493 machtype: defined(M_mipseb)                             : "mipseb"
494 machtype: defined(mips)                                 : "mips"
495 machtype: defined(pc532)                                : "pc532"
496 machtype: defined(vax)                                  : "vax"
497 machtype: defined(alpha)                                : "alpha"
498 enddef  :
499
500
501 newdef  : defined(__FreeBSD__) 
502 comment : FreeBSD
503 vendor  : defined(__alpha)                              : "digital"
504 vendor  : defined(M_intel)                              : "intel"
505 hosttype:                                               : "FreeBSD"
506 ostype  :                                               : "FreeBSD"
507 machtype: defined(__alpha)                              : "alpha"
508 machtype: defined(M_i386)                               : "i386"
509 enddef  :
510
511
512 newdef  : defined(__386BSD__)
513 comment : Bill Jolitz's 386BSD
514 vendor  : defined(M_intel)                              : "intel"
515 hosttype:                                               : "386BSD"
516 ostype  :                                               : "386BSD"
517 machtype:                                               : "i386"
518 enddef  :
519
520
521 newdef  : defined(bsdi)
522 comment : BSDI's unix
523 vendor  : defined(M_intel)                              : "intel"
524 vendor  : defined(sparc)                                : "sun"
525 vendor  : defined(__powerpc__)                          : "motorola"
526 hosttype: defined(M_intel)                              : "bsd386"
527 hosttype: defined(sparc)                                : "bsd-sparc"
528 hosttype: defined(__powerpc__)                          : "bsd-powerpc"
529 ostype  :                                               : "bsdi"
530 machtype: defined(M_i386)                               : "i386"
531 machtype: defined(sparc)                                : "sparc"
532 machtype: defined(__powerpc__)                          : "powerpc"
533 enddef  :
534
535
536 newdef  : defined(COHERENT)
537 comment : COHERENT's unix
538 vendor  : defined(_I386)                                : "intel"
539 hosttype:                                               : "coh386"
540 hosttype:                                               : "coherent"
541 ostype  :                                               : "coherent"
542 machtype: defined(_I386)                                : "i386"
543 enddef  :
544
545 newdef  : defined(concurrent)
546 comment : Concurrent PowerHawk
547 vendor  :                                               : "concurrent"
548 hosttype:                                               : "powerhawk"
549 ostype  :                                               : "powermax_os"
550 machtype:                                               : "powerhawk"
551 enddef  :
552
553 newdef  : defined(SCO)
554 comment : SCO UNIX System V/386 Release 3.2
555 vendor  :                                               : "sco"
556 hosttype:                                               : "sco386"
557 ostype  :                                               : "sco_unix"
558 machtype:                                               : "i386"
559 enddef  :
560
561 newdef  : defined(M_XENIX) && !defined(M_UNIX)
562 comment : SCO XENIX
563 vendor  :                                               : "sco"
564 hosttype:                                               : "sco_xenix"
565 ostype  :                                               : "sco_xenix"
566 machtype: defined(M_I386)                               : "i386"
567 machtype: defined(M_I286)                               : "i286"
568 enddef  :
569
570
571 newdef  : defined(ISC) || defined(ISC202)
572 comment : Interactive Unix
573 vendor  :                                               : "isc"
574 hosttype:                                               : "isc386"
575 ostype  : defined(POSIX)                                : "POSIX"
576 ostype  :                                               : "SVR3"
577 machtype: defined(M_i386)                               : "i386"
578 enddef  :
579
580
581 newdef  : defined(INTEL)
582 comment : Intel Unix
583 vendor  :                                               : "intel"
584 hosttype:                                               : "intel386"
585 ostype  :                                               : "intel_unix"
586 machtype: defined(M_i386)                               : "i386"
587 enddef  :
588
589
590 newdef  : defined(MACH)
591 comment : cmu's mach
592 vendor  :                                               : "cmu"
593 hosttype: defined(M_i386)                               : "i386-mach"
594 ostype  :                                               : "mach"
595 machtype: defined(M_i386)                               : "i386"
596 enddef  :
597
598
599 newdef  : defined(alliant)
600 comment : Alliants FSX
601 vendor  :                                               : "alliant"
602 hosttype: defined(mc68000)                              : "alliant-fx80"
603 hosttype: defined(i860)                                 : "alliant-fx2800"
604 hosttype:                                               : "alliant"
605 ostype  :                                               : "fsx"
606 machtype: defined(mc68000)                              : "mc68000"
607 machtype: defined(i860)                                 : "i860"
608 enddef  :
609
610
611 newdef  : defined(_FTX)
612 comment : Stratus Computer, Inc FTX2 (i860 based)
613 comment : Stratus Computer, Inc FTX3 (HPPA based)
614 vendor  :                                               : "stratus"
615 hosttype: defined(i860) && defined(_FTX)                : "atlantic"
616 hosttype: defined(__hppa) && defined(_FTX)              : "continuum"
617 ostype  : defined(i860) && defined(_FTX)                : "ftx2"
618 ostype  : defined(__hppa) && defined(_FTX)              : "ftx3"
619 machtype: defined(i860)                                 : "i860"
620 machtype: defined(__hppa)                               : "hppa"
621 enddef  :
622
623
624 newdef  : defined(sequent) || defined(_SEQUENT_)
625 comment : Sequent Balance (32000 based)
626 comment : Sequent Symmetry running DYNIX/ptx (386/486 based)
627 comment : Sequent Symmetry running DYNIX 3 (386/486 based)
628 vendor  :                                               : "sequent"
629 hosttype: defined(M_i386) && defined(sequent)           : "symmetry"
630 hosttype: defined(M_i386)                               : "ptx"
631 hosttype:                                               : "balance"
632 ostype  : defined(M_i386) && !defined(sequent)          : "ptx"
633 ostype  :                                               : "dynix3"
634 machtype: defined(M_i386)                               : "i386"
635 machtype: defined(ns32000)                              : "ns32000"
636 enddef  :
637
638
639 newdef  : defined(ns32000)
640 comment : Encore Computer Corp. Multimax (32000 based)
641 vendor  :                                               : "encore"
642 hosttype: defined(CMUCS)                                : "multimax"
643 hosttype:                                               : isamultimax(0)
644 ostype  : defined(CMUCS)                                : "mach"
645 ostype  :                                               : isamultimax(1)
646 machtype:                                               : "ns32000"
647 enddef  :
648
649
650 newdef  : defined(iconuxv)
651 comment : Icon 88k running Unix
652 vendor  :                                               : "icon"
653 hosttype:                                               : "icon"
654 ostype  :                                               : "iconuxv"
655 machtype: defined(m88k) || defined(__m88k__)            : "m88k"
656 enddef  :
657
658
659 newdef  : defined(_CRAY) && defined(_CRAYCOM)
660 comment : Cray Computer Corp. running CSOS
661 vendor  :                                               : "ccc"
662 hosttype: defined(_CRAY2)                               : "cray"
663 hosttype: defined(_CRAY3)                               : "cray"
664 hosttype: defined(_CRAY4)                               : "cray"
665 ostype  :                                               : "CSOS"
666 machtype: defined(_CRAY2)                               : "cray2"
667 machtype: defined(_CRAY3)                               : "cray3"
668 machtype: defined(_CRAY4)                               : "cray4"
669 enddef  :
670
671
672 newdef  : defined(cray) && !defined(_CRAYMPP)
673 comment : Cray Research Inc. PVP running UNICOS
674 vendor  :                                               : "cri"
675 hosttype:                                               : getcray()
676 ostype  :                                               : "unicos"
677 machtype:                                               : getcray()
678 enddef  :
679
680
681 newdef  : defined(cray) && defined(_CRAYT3D)
682 comment : Cray Research Inc. running UNICOS MAX
683 vendor  :                                               : "cri"
684 hosttype:                                               : getcray()
685 ostype  :                                               : "unicosmax"
686 machtype:                                               : getcray()
687 enddef  :
688
689
690 newdef  : defined(cray) && defined(_CRAYT3E)
691 comment : Cray Research Inc. running UNICOS/mk
692 vendor  :                                               : "cri"
693 hosttype:                                               : getcray()
694 ostype  :                                               : "unicosmk"
695 machtype:                                               : getcray()
696 enddef  :
697
698
699 newdef  : defined(convex)
700 comment : Convex
701 vendor  :                                               : "convex"
702 hosttype:                                               : "convex"
703 ostype  :                                               : "convexos"
704 machtype:                                               : getconvex()
705 enddef  :
706
707
708 newdef  : defined(butterfly)
709 comment : BBN Butterfly 1000
710 vendor  :                                               : "bbn"
711 hosttype:                                               : "butterfly"
712 machtype: defined(mc68020) || defined(__mc68020__)      : "m68k"
713 enddef  :
714
715
716 newdef  : defined(NeXT)
717 comment : NeXTStep
718 vendor  :                                               : "next"
719 hosttype: defined(mc68020) || defined(__mc68020__)      : "next"
720 hosttype: defined(M_i386)  || defined(__i386__)         : "intel-pc"
721 hosttype: defined(hppa)    || defined(__hppa__)         : "hp"
722 hosttype: defined(sparc)   || defined(__sparc__)        : "sun"
723 ostype  :                                               : "nextstep"
724 machtype: defined(mc68020) || defined(__mc68020__)      : "m68k"
725 machtype: defined(M_i386)  || defined(__i386__)         : "i386"
726 machtype: defined(hppa)    || defined(__hppa__)         : "hppa"
727 machtype: defined(sparc)   || defined(__sparc__)        : "sparc"
728 enddef  :
729
730
731 newdef  : defined(__APPLE__)
732 comment : Rhapsody
733 vendor  :                                               : "apple"
734 hosttype: defined(__i386__)                             : "intel-pc"
735 hosttype: defined(__ppc__)                              : "macintosh"
736 ostype  :                                               : "rhapsody"
737 machtype: defined(__i386__)                             : "i386"
738 machtype: defined(__ppc__)                              : "powerpc"
739 enddef  :
740
741
742 newdef  : defined(sony_news)
743 comment : Sony NEWS 800 or 1700 workstation
744 vendor  :                                               : "sony"
745 hosttype: defined(mips)                                 : "news_mips"
746 hosttype: defined(mc68020) || defined(__mc68020__)      : "news_m68k"
747 ostype  :                                               : "News"
748 machtype: defined(mc68020) || defined(__mc68020__)      : "m68k"
749 machtype: defined(M_mipsel)                             : "mipsel"
750 machtype: defined(M_mipseb)                             : "mipseb"
751 enddef  :
752
753
754 newdef  : defined(sgi)
755 comment : Silicon Graphics
756 vendor  :                                               : "sgi"
757 hosttype: defined(M_mipsel)                             : "iris4d"
758 hosttype: defined(M_mipseb)                             : "iris4d"
759 hosttype: defined(mc68000)                              : "iris3d"
760 ostype  :                                               : "irix"
761 machtype: defined(M_mipsel)                             : "mipsel"
762 machtype: defined(M_mipseb)                             : "mipseb"
763 machtype: defined(mc68000)                              : "mc68000"
764 enddef  :
765
766
767 newdef  : defined(ultrix) || defined(__ultrix)
768 comment : Digital's Ultrix 
769 vendor  :                                               : "dec"
770 hosttype: defined(M_mipsel)                             : "decstation"
771 hosttype: defined(M_mipseb)                             : "decmips"
772 hosttype: defined(vax) || defined(__vax)                : "vax"
773 hosttype: defined(__vax__)                              : "vax"
774 ostype  :                                               : "ultrix"
775 machtype: defined(M_mipsel)                             : "mipsel"
776 machtype: defined(M_mipseb)                             : "mipseb"
777 machtype: defined(vax) || defined (__vax)               : "vax"
778 hosttype: defined(__vax__)                              : "vax"
779 enddef  :
780
781
782 newdef  : defined(MIPS)
783 comment : Mips OS
784 vendor  :                                               : "mips"
785 hosttype: defined(M_mipsel)                             : "mips"
786 hosttype: defined(M_mipseb)                             : "mips"
787 ostype  :                                               : "mips"
788 machtype: defined(M_mipsel)                             : "mipsel"
789 machtype: defined(M_mipseb)                             : "mipseb"
790 enddef  :
791
792
793 newdef  : defined(DECOSF1)
794 comment : Digital's alpha running osf1
795 vendor  :                                               : "dec"
796 ostype  :                                               : "osf1"
797 hosttype: defined(__alpha)                              : "alpha"
798 machtype: defined(__alpha)                              : "alpha"
799 enddef  :
800
801
802 newdef  : defined(Lynx)
803 comment : Lynx OS 2.1
804 vendor  :                                               : "Lynx"
805 hosttype: defined(M_mipsel)                             : "lynxos-mips"
806 hosttype: defined(M_mipseb)                             : "lynxos-mips"
807 hosttype: defined(M_i386)                               : "lynxos-i386"
808 hosttype: defined(i860) || defined(__i860__)            : "lynxos-i860"
809 hosttype: defined(m68k)                                 : "lynxos-m68k"
810 hosttype: defined(m88k)                                 : "lynxos-m88k"
811 hosttype: defined(sparc)                                : "lynxos-sparc"
812 hosttype:                                               : "lynxos-unknown"
813 ostype  :                                               : "LynxOS"
814 machtype: defined(M_mipsel)                             : "mipsel"
815 machtype: defined(M_mipseb)                             : "mipseb"
816 machtype: defined(M_i386)                               : "i386"
817 machtype: defined(i860) || defined(__i860__)            : "i860"
818 machtype: defined(m68k)                                 : "m68k"
819 machtype: defined(m88k)                                 : "m88k"
820 machtype: defined(sparc)                                : "sparc"
821 enddef  :
822
823
824 newdef  : defined(masscomp)
825 comment : Masscomp
826 vendor  :                                               : "masscomp"
827 hosttype:                                               : "masscomp"
828 ostype  :                                               : "masscomp"
829 enddef  :
830
831 newdef  : defined(__MACHTEN__)
832 comment : Machintosh
833 vendor  :                                               : "Tenon"
834 hosttype:                                               : "Macintosh"
835 ostype  :                                               : "MachTen"
836 machtype:                                               : "Macintosh"
837 enddef  :
838
839
840
841 newdef  : defined(GOULD_NP1)
842 comment : Gould
843 vendor  :                                               : "gould"
844 hosttype:                                               : "gould_np1"
845 machtype:                                               : "gould"
846 enddef  :
847
848
849 newdef  : defined(MULTIFLOW)
850 comment : Multiflow running 4.3BSD
851 vendor  :                                               : "multiflow"
852 hosttype:                                               : "multiflow"
853 machtype:                                               : "multiflow"
854 ostype  :                                               : "bsd43"
855 enddef  :
856
857
858 newdef  : defined(SXA)
859 comment : PFU/Fujitsu A-xx computer
860 vendor  :                                               : "sxa"
861 hosttype:                                               : "pfa50"
862 ostype  : defined(_BSDX_)                               : "e60-bsdx"
863 ostype  :                                               : "e60"
864 machtype:                                               : "pfa50"
865 enddef  :
866
867
868 newdef  : defined(titan)
869 comment : (St)Ardent Titan
870 vendor  :                                               : "ardent"
871 hosttype:                                               : "titan"
872 enddef  :
873
874
875 newdef  : defined(stellar)
876 comment : Stellar
877 vendor  :                                               : "stellar"
878 hosttype:                                               : "stellar"
879 ostype  :                                               : "stellix"
880 enddef  :
881
882
883 newdef  : defined(atari)
884 comment : Atari TT running SVR4. This machine was never
885 comment : commercially available.
886 vendor  :                                               : "atari"
887 hosttype:                                               : "atari"
888 ostype  :                                               : "asv"
889 enddef  :
890
891
892 newdef  : defined(OPUS)
893 comment : ???
894 vendor  :                                               : "opus"
895 hosttype:                                               : "opus"
896 enddef  :
897
898
899 newdef  : defined(eta10)
900 comment : ETA running SVR3
901 vendor  :                                               : "eta"
902 hosttype:                                               : "eta10"
903 enddef  :
904
905
906 newdef  : defined(hk68)
907 comment : Heurikon HK68 running Uniplus+ 5.0
908 vendor  :                                               : "heurikon"
909 hosttype:                                               : "hk68"
910 ostype  :                                               : "uniplus"
911 enddef  :
912
913
914 newdef  : defined(NDIX)
915 comment : Norsk Data ND 500/5000 running Ndix
916 vendor  :                                               : "norsk"
917 hosttype:                                               : "nd500"
918 ostype  :                                               : "ndix"
919 enddef  :
920
921
922 newdef  : defined(AMIGA)
923 comment : Amiga running AmigaOS+GG
924 vendor  :                                               : "commodore"
925 hosttype:                                               : "amiga"
926 ostype  :                                               : "AmigaOS"
927 machtype:                                               : "m68k"
928 enddef  :
929
930
931 newdef  : defined(uts)
932 comment : Amdahl running uts 2.1
933 vendor  :                                               : "amdahl"
934 hosttype:                                               : "amdahl"
935 ostype  :                                               : "uts"
936 machtype:                                               : "amdahl"
937 enddef  :
938
939
940 newdef  : defined(UTek)
941 comment : Tektronix 4300 running UTek (BSD 4.2 / 68020 based)
942 vendor  :                                               : "tektronix"
943 hosttype:                                               : "tek4300"
944 enddef  :
945
946
947 newdef  : defined(UTekV)
948 comment : Tektronix XD88/10 running UTekV 3.2e (SVR3/88100 based)
949 vendor  :                                               : "tektronix"
950 hosttype:                                               : "tekXD88"
951 enddef  :
952
953
954 newdef  : defined(__DGUX__)
955 comment : Data-General AViiON running DGUX
956 hosttype:                                               : "aviion"
957 ostype  :                                               : "dgux"
958 vendor  :                                               : "dg"
959 machtype: defined(__m88k__)                             : "m88k"
960 machtype: defined(__i386__)                             : "pentium"
961 enddef  :
962
963
964 newdef  : defined(sysV68)
965 comment : Motorola MPC running System V/68 R32V2 (SVR3/68020 based)
966 vendor  :                                               : "motorola"
967 hosttype:                                               : "sysV68"
968 machtype:                                               : "m68k"
969 enddef  :
970
971
972 newdef  : defined(supermax)
973 comment : DDE Supermax running System V/68 R3 (SVR3/68020 based)
974 vendor  :                                               : "supermax"
975 hosttype:                                               : "supermax"
976 machtype:                                               : "m68k"
977 enddef  :
978
979
980 newdef  : defined(sysV88)
981 comment : Motorola MPC running System V/88 R32V2 (SVR3/88100 based)
982 vendor  :                                               : "motorola"
983 hosttype:                                               : "sysV88"
984 machtype:                                               : "m88k"
985 enddef  :
986
987
988 newdef  : defined(__clipper__)
989 comment : Clipper Chipset (Intergraph)
990 vendor  :                                               : "intergraph"
991 hosttype:                                               : "clipper"
992 machtype:                                               : "clipper"
993 enddef  :
994
995
996 newdef  : defined(SNI) || defined(sinix)
997 comment : Siemens Nixdorf Informationssysteme SINIX
998 vendor  :                                               : "sni"
999 hosttype: defined(M_intel)                              : "wx200i"
1000 hosttype: defined(MIPSEB)                               : "rm400"
1001 ostype  : defined(sinix)                                : "sinix"
1002 machtype: defined(M_i586)                               : "i586"
1003 machtype: defined(M_i486)                               : "i486"
1004 machtype: defined(M_i386)                               : "i386"
1005 machtype: defined(M_mipsel)                             : "mipsel"
1006 machtype: defined(M_mipseb)                             : "mipseb"
1007 machtype:                                               : "mips"
1008 enddef  :
1009
1010 newdef  : defined(_OSD_POSIX)
1011 comment : Siemens Nixdorf Informationssysteme BS2000 POSIX (mainframe, EBCDIC)
1012 vendor  :                                               : "sni"
1013 hosttype: defined(M_intel)                              : "bs2000"
1014 ostype  :                                               : "posix"
1015 machtype:                                               : "bs2000"
1016 enddef  :
1017
1018 newdef  : defined(__MVS__)
1019 comment : ibm uss s/390 (mainframe, EBCDIC)
1020 vendor  :                                               : "ibm"
1021 hosttype:                                               : "s390"
1022 ostype  :                                               : "os390"
1023 machtype:                                               : "s390"
1024 enddef  :
1025
1026 newdef  : defined(_SX)
1027 comment : NEC Corporation (SX-4)
1028 vendor  :                                               : "nec"
1029 ostype  :                                               : "superux"
1030 hosttype:                                               : "sx4"
1031 machtype:                                               : "sx4"
1032 enddef  :
1033
1034 newdef  : !defined(SOLARIS2) && (SYSVREL == 4)
1035 comment : Unix System V Release 4.0
1036 vendor  : defined(DELL)                                 : "dell"
1037 hosttype: defined(M_i386)                               : "i386"
1038 ostype  :                                               : "svr4"
1039 machtype: defined(M_i386)                               : "i386"
1040 enddef  :
1041
1042 newdef  : defined(__uxp__) || defined(__uxps__)
1043 comment : FUJITSU DS/90 7000
1044 vendor  :                                               : "fujitsu"
1045 hosttype:                                               : "ds90"
1046 ostype  :                                               : "sysv4"
1047 machtype:                                               : "sparc"
1048 enddef  :
1049
1050 newdef  : defined(_UWIN)
1051 comment : AT&T Research Unix for Windows
1052 vendor  :                                               : "att"
1053 hosttype:                                               : "win32.i386"
1054 machtype:                                               : "i386"
1055 enddef  :
1056
1057
1058 newdef  : defined(mc68000) || defined(__mc68000__) || defined(mc68k32) || defined(m68k) || defined(mc68010) || defined(mc68020)
1059 hosttype:                                               : "m68k"
1060 vendor  : defined(m68k)                                 : "motorola"
1061 machtype:                                               : "m68k"
1062 enddef  :
1063
1064
1065 newdef  : defined(m88k) || defined(__m88k__)
1066 hosttype:                                               : "m88k"
1067 machtype:                                               : "m88k"
1068 enddef  :
1069
1070
1071 newdef  : defined(M_intel)
1072 hosttype: defined(M_i586)                               : "i586"
1073 hosttype: defined(M_i486)                               : "i486"
1074 hosttype: defined(M_i386)                               : "i386"
1075 vendor  :                                               : "intel"
1076 machtype: defined(M_i586)                               : "i586"
1077 machtype: defined(M_i486)                               : "i486"
1078 machtype: defined(M_i386)                               : "i386"
1079 enddef  :
1080
1081
1082 newdef  : defined(sparc) || defined(__sparc__)
1083 hosttype:                                               : "sparc"
1084 machtype:                                               : "sparc"
1085 enddef  :
1086
1087
1088 newdef  : defined(i860) || defined(__i860__)
1089 hosttype:                                               : "i860"
1090 machtype:                                               : "i860"
1091 enddef  :
1092
1093
1094 newdef  : defined(osf1)
1095 ostype  :                                               : "osf1"
1096 enddef  :
1097
1098
1099 newdef  : SYSVREL == 0
1100 ostype  : defined(BSD4_4)                               : "bsd44"
1101 ostype  : defined(BSD)                                  : "bsd"
1102 ostype  : defined(POSIX)                                : "posix"
1103 enddef  :
1104
1105
1106 newdef  : SYSVREL == 1
1107 ostype  :                                               : "svr1"
1108 enddef  :
1109
1110
1111 newdef  : SYSVREL == 2
1112 ostype  :                                               : "svr2"
1113 enddef  :
1114
1115
1116 newdef  : SYSVREL == 3
1117 ostype  :                                               : "svr3"
1118 enddef  :
1119
1120
1121 newdef  : SYSVREL == 4
1122 ostype  :                                               : "svr4"
1123 enddef  :
1124
1125
1126 newcode :
1127 #ifndef _hosttype_
1128     hosttype = "unknown";
1129 #endif
1130 #ifndef _ostype_
1131     ostype = "unknown";
1132 #endif
1133 #ifndef _vendor_
1134     vendor = "unknown";
1135 #endif
1136 #ifndef _machtype_
1137     machtype = "unknown";
1138 #endif
1139     tsetenv(STRHOSTTYPE, str2short(hosttype));
1140     tsetenv(STRVENDOR,   str2short(vendor));
1141     tsetenv(STROSTYPE,   str2short(ostype));
1142     tsetenv(STRMACHTYPE, str2short(machtype));
1143 } /* end setmachine */
1144 endcode :