config.guess
Upload User: yingmei828
Upload Date: 2007-01-01
Package Size: 1646k
Code Size: 29k
Development Platform:

Unix_Linux

  1. #! /bin/sh
  2. # Attempt to guess a canonical system name.
  3. #   Copyright (C) 1992, 93, 94, 95, 96, 97, 1998 Free Software Foundation, Inc.
  4. #
  5. # This file is free software; you can redistribute it and/or modify it
  6. # under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation; either version 2 of the License, or
  8. # (at your option) any later version.
  9. #
  10. # This program is distributed in the hope that it will be useful, but
  11. # WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  13. # General Public License for more details.
  14. #
  15. # You should have received a copy of the GNU General Public License
  16. # along with this program; if not, write to the Free Software
  17. # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  18. #
  19. # As a special exception to the GNU General Public License, if you
  20. # distribute this file as part of a program that contains a
  21. # configuration script generated by Autoconf, you may include it under
  22. # the same distribution terms that you use for the rest of that program.
  23. # Written by Per Bothner <bothner@cygnus.com>.
  24. # The master version of this file is at the FSF in /home/gd/gnu/lib.
  25. # Please send patches to the Autoconf mailing list <autoconf@gnu.org>.
  26. #
  27. # Changed by Bruno Haible, 1 May 1999.
  28. # The master version of this file is in
  29. # ftp://ftp2.cons.org/pub/lisp/clisp/source/.
  30. #
  31. # This script attempts to guess a canonical system name similar to
  32. # config.sub.  If it succeeds, it prints the system name on stdout, and
  33. # exits with 0.  Otherwise, it exits with 1.
  34. #
  35. # The plan is that this can be called by configure scripts if you
  36. # don't specify an explicit system type (host/target name).
  37. #
  38. # Only a few systems have been added to this list; please add others
  39. # (but try to keep the structure clean).
  40. #
  41. # Use $HOST_CC if defined. $CC may point to a cross-compiler
  42. if test x"$CC_FOR_BUILD" = x; then
  43.   if test x"$HOST_CC" != x; then
  44.     CC_FOR_BUILD="$HOST_CC"
  45.   else
  46.     if test x"$CC" != x; then
  47.       CC_FOR_BUILD="$CC"
  48.     else
  49.       CC_FOR_BUILD=cc
  50.     fi
  51.   fi
  52. fi
  53. # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
  54. # (ghazi@noc.rutgers.edu 8/24/94.)
  55. if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
  56. PATH=$PATH:/.attbin ; export PATH
  57. # This is needed to find uname on SunOS 4.0.3.
  58. elif (test -f /usr/5bin/uname) >/dev/null 2>&1 ; then
  59. PATH=$PATH:/usr/5bin
  60. fi
  61. UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
  62. UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
  63. UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
  64. UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
  65. dummy=dummy-$$
  66. trap 'rm -f $dummy.c $dummy.o $dummy; exit 1' 1 2 15
  67. # Note: order is significant - the case branches are not exclusive.
  68. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
  69.     alpha:OSF1:*:*)
  70. if test $UNAME_RELEASE = "V4.0"; then
  71. UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
  72. fi
  73. # A Vn.n version is a released version.
  74. # A Tn.n version is a released field test version.
  75. # A Xn.n version is an unreleased experimental baselevel.
  76. # 1.2 uses "1.2" for uname -r.
  77. cat <<EOF >$dummy.s
  78. .globl main
  79. .ent main
  80. main:
  81. .frame $30,0,$26,0
  82. .prologue 0
  83. .long 0x47e03d80 # implver $0
  84. lda $2,259
  85. .long 0x47e20c21 # amask $2,$1
  86. srl $1,8,$2
  87. sll $2,2,$2
  88. sll $0,3,$0
  89. addl $1,$0,$0
  90. addl $2,$0,$0
  91. ret $31,($26),1
  92. .end main
  93. EOF
  94. $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
  95. if test "$?" = 0 ; then
  96. ./$dummy
  97. case "$?" in
  98. 7)
  99. UNAME_MACHINE="alpha"
  100. ;;
  101. 15)
  102. UNAME_MACHINE="alphaev5"
  103. ;;
  104. 14)
  105. UNAME_MACHINE="alphaev56"
  106. ;;
  107. 10)
  108. UNAME_MACHINE="alphapca56"
  109. ;;
  110. 16)
  111. UNAME_MACHINE="alphaev6"
  112. ;;
  113. esac
  114. fi
  115. rm -f $dummy.s $dummy
  116. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr [[A-Z]] [[a-z]]`
  117. exit 0 ;;
  118.     21064:Windows_NT:50:3)
  119. echo alpha-dec-winnt3.5
  120. exit 0 ;;
  121.     Amiga*:UNIX_System_V:4.0:*)
  122. echo m68k-cbm-sysv4
  123. exit 0;;
  124.     amiga:NetBSD:*:*)
  125.       echo m68k-cbm-netbsd${UNAME_RELEASE}
  126.       exit 0 ;;
  127.     amiga:OpenBSD:*:*)
  128. echo m68k-unknown-openbsd${UNAME_RELEASE}
  129. exit 0 ;;
  130.     *:[Aa]miga[Oo][Ss]:*:*)
  131. echo ${UNAME_MACHINE}-unknown-amigaos
  132. exit 0 ;;
  133.     arc64:OpenBSD:*:*)
  134. echo mips64el-unknown-openbsd${UNAME_RELEASE}
  135. exit 0 ;;
  136.     arc:OpenBSD:*:*)
  137. echo mipsel-unknown-openbsd${UNAME_RELEASE}
  138. exit 0 ;;
  139.     hkmips:OpenBSD:*:*)
  140. echo mips-unknown-openbsd${UNAME_RELEASE}
  141. exit 0 ;;
  142.     pmax:OpenBSD:*:*)
  143. echo mipsel-unknown-openbsd${UNAME_RELEASE}
  144. exit 0 ;;
  145.     sgi:OpenBSD:*:*)
  146. echo mips-unknown-openbsd${UNAME_RELEASE}
  147. exit 0 ;;
  148.     wgrisc:OpenBSD:*:*)
  149. echo mipsel-unknown-openbsd${UNAME_RELEASE}
  150. exit 0 ;;
  151.     arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
  152. echo arm-acorn-riscix${UNAME_RELEASE}
  153. exit 0;;
  154.     arm32:NetBSD:*:*)
  155. echo arm-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/./'`
  156. exit 0 ;;
  157.     SR2?01:HI-UX/MPP:*:*)
  158. echo hppa1.1-hitachi-hiuxmpp
  159. exit 0;;
  160.     Pyramid*:OSx*:*:*|MIS*:OSx*:*:*|MIS*:SMP_DC-OSx*:*:*)
  161. # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
  162. if test "`(/bin/universe) 2>/dev/null`" = att ; then
  163. echo pyramid-pyramid-sysv3
  164. else
  165. echo pyramid-pyramid-bsd
  166. fi
  167. exit 0 ;;
  168.     NILE*:*:*:dcosx)
  169. echo pyramid-pyramid-svr4
  170. exit 0 ;;
  171.     sun4H:SunOS:5.*:*)
  172. echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  173. exit 0 ;;
  174.     sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
  175. echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  176. exit 0 ;;
  177.     i86pc:SunOS:5.*:*)
  178. echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  179. exit 0 ;;
  180.     sun4*:SunOS:6*:*)
  181. # According to config.sub, this is the proper way to canonicalize
  182. # SunOS6.  Hard to guess exactly what SunOS6 will be like, but
  183. # it's likely to be more like Solaris than SunOS4.
  184. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  185. exit 0 ;;
  186.     sun4*:SunOS:*:*)
  187. case "`/usr/bin/arch -k`" in
  188.     Series*|S4*)
  189. UNAME_RELEASE=`uname -v`
  190. ;;
  191. esac
  192. # Japanese Language versions have a version number like `4.1.3-JL'.
  193. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
  194. exit 0 ;;
  195.     sun3*:SunOS:*:*|sun:SunOS:*:*)
  196. echo m68k-sun-sunos${UNAME_RELEASE}
  197. exit 0 ;;
  198.     sun*:*:4.2BSD:*)
  199. UNAME_RELEASE=`(head -1 /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
  200. test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
  201. case "`/bin/arch`" in
  202.     sun3)
  203. echo m68k-sun-sunos${UNAME_RELEASE}
  204. ;;
  205.     sun4)
  206. echo sparc-sun-sunos${UNAME_RELEASE}
  207. ;;
  208. esac
  209. exit 0 ;;
  210.     aushp:SunOS:*:*)
  211. echo sparc-auspex-sunos${UNAME_RELEASE}
  212. exit 0 ;;
  213.     atari*:NetBSD:*:*)
  214. echo m68k-atari-netbsd${UNAME_RELEASE}
  215. exit 0 ;;
  216.     atari*:OpenBSD:*:*)
  217. echo m68k-unknown-openbsd${UNAME_RELEASE}
  218. exit 0 ;;
  219.     # The situation for MiNT is a little confusing.  The machine name
  220.     # can be virtually everything (everything which is not
  221.     # "atarist" or "atariste" at least should have a processor 
  222.     # > m68000).  The system name ranges from "MiNT" over "FreeMiNT"
  223.     # to the lowercase version "mint" (or "freemint").  Finally
  224.     # the system name "TOS" denotes a system which is actually not
  225.     # MiNT.  But MiNT is downward compatible to TOS, so this should
  226.     # be no problem.
  227.     atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
  228. echo m68k-atari-mint${UNAME_RELEASE}
  229. exit 0 ;;
  230.     atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
  231. echo m68k-atari-mint${UNAME_RELEASE}
  232. exit 0 ;;
  233.     *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
  234. echo m68k-atari-mint${UNAME_RELEASE}
  235. exit 0 ;;
  236.     milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
  237. echo m68k-milan-mint${UNAME_RELEASE}
  238. exit 0 ;;
  239.     hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
  240. echo m68k-hades-mint${UNAME_RELEASE}
  241. exit 0 ;;
  242.     *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
  243. echo m68k-unknown-mint${UNAME_RELEASE}
  244. exit 0 ;;
  245.     sun3*:NetBSD:*:*)
  246. echo m68k-sun-netbsd${UNAME_RELEASE}
  247. exit 0 ;;
  248.     sun3*:OpenBSD:*:*)
  249. echo m68k-unknown-openbsd${UNAME_RELEASE}
  250. exit 0 ;;
  251.     mac68k:NetBSD:*:*)
  252. echo m68k-apple-netbsd${UNAME_RELEASE}
  253. exit 0 ;;
  254.     mac68k:OpenBSD:*:*)
  255. echo m68k-unknown-openbsd${UNAME_RELEASE}
  256. exit 0 ;;
  257.     mvme68k:OpenBSD:*:*)
  258. echo m68k-unknown-openbsd${UNAME_RELEASE}
  259. exit 0 ;;
  260.     mvme88k:OpenBSD:*:*)
  261. echo m88k-unknown-openbsd${UNAME_RELEASE}
  262. exit 0 ;;
  263.     powerpc:machten:*:*)
  264. echo powerpc-apple-machten${UNAME_RELEASE}
  265. exit 0 ;;
  266.     macppc:NetBSD:*:*)
  267.         echo powerpc-apple-netbsd${UNAME_RELEASE}
  268.         exit 0 ;;
  269.     RISC*:Mach:*:*)
  270. echo mips-dec-mach_bsd4.3
  271. exit 0 ;;
  272.     RISC*:ULTRIX:*:*)
  273. echo mips-dec-ultrix${UNAME_RELEASE}
  274. exit 0 ;;
  275.     VAX*:ULTRIX*:*:*)
  276. echo vax-dec-ultrix${UNAME_RELEASE}
  277. exit 0 ;;
  278.     2020:CLIX:*:* | 2430:CLIX:*:*)
  279. echo clipper-intergraph-clix${UNAME_RELEASE}
  280. exit 0 ;;
  281.     mips:*:*:UMIPS | mips:*:*:RISCos)
  282. sed 's/^ //' << EOF >$dummy.c
  283. #if defined(__STDC__) || defined(__cplusplus)
  284. int main (int argc, char *argv[])
  285. #else
  286. main(argc, argv)
  287. int argc;
  288. char *argv[];
  289. #endif
  290. {
  291. #if defined (host_mips) && defined (MIPSEB)
  292. #if defined (SYSTYPE_SYSV)
  293.   printf ("mips-mips-riscos%ssysvn", argv[1]); exit (0);
  294. #endif
  295. #if defined (SYSTYPE_SVR4)
  296.   printf ("mips-mips-riscos%ssvr4n", argv[1]); exit (0);
  297. #endif
  298. #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
  299.   printf ("mips-mips-riscos%sbsdn", argv[1]); exit (0);
  300. #endif
  301. #endif
  302.   exit (-1);
  303. }
  304. EOF
  305. $CC_FOR_BUILD $dummy.c -o $dummy 
  306.   && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/([0-9]*).*/1/p'` 
  307.   && rm $dummy.c $dummy && exit 0
  308. rm -f $dummy.c $dummy
  309. echo mips-mips-riscos${UNAME_RELEASE}
  310. exit 0 ;;
  311.     Night_Hawk:Power_UNIX:*:*)
  312. echo powerpc-harris-powerunix
  313. exit 0 ;;
  314.     m88k:CX/UX:7*:*)
  315. echo m88k-harris-cxux7
  316. exit 0 ;;
  317.     m88k:*:4*:R4*)
  318. echo m88k-motorola-sysv4
  319. exit 0 ;;
  320.     m88k:*:3*:R3*)
  321. echo m88k-motorola-sysv3
  322. exit 0 ;;
  323.     AViiON:dgux:*:*)
  324. # DG/UX returns AViiON for all architectures
  325. UNAME_PROCESSOR=`/usr/bin/uname -p`
  326. if [ $UNAME_PROCESSOR = mc88100 -o $UNAME_PROCESSOR = mc88110 ] ; then
  327. if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx 
  328.      -o ${TARGET_BINARY_INTERFACE}x = x ] ; then
  329. echo m88k-dg-dgux${UNAME_RELEASE}
  330. else
  331. echo m88k-dg-dguxbcs${UNAME_RELEASE}
  332. fi
  333. else echo i586-dg-dgux${UNAME_RELEASE}
  334. fi
  335.   exit 0 ;;
  336.     M88*:DolphinOS:*:*) # DolphinOS (SVR3)
  337. echo m88k-dolphin-sysv3
  338. exit 0 ;;
  339.     M88*:*:R3*:*)
  340. # Delta 88k system running SVR3
  341. echo m88k-motorola-sysv3
  342. exit 0 ;;
  343.     XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
  344. echo m88k-tektronix-sysv3
  345. exit 0 ;;
  346.     Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
  347. echo m68k-tektronix-bsd
  348. exit 0 ;;
  349.     *:IRIX*:*:*)
  350. echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
  351. exit 0 ;;
  352.     ????????:AIX?:[12].1:2)   # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
  353. echo romp-ibm-aix      # uname -m gives an 8 hex-code CPU id
  354. exit 0 ;;              # Note that: echo "'`uname -s`'" gives 'AIX '
  355.     i?86:AIX:*:*)
  356. echo i386-ibm-aix
  357. exit 0 ;;
  358.     *:AIX:2:3)
  359. if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
  360. sed 's/^ //' << EOF >$dummy.c
  361. #include <sys/systemcfg.h>
  362. main()
  363. {
  364. if (!__power_pc())
  365. exit(1);
  366. puts("powerpc-ibm-aix3.2.5");
  367. exit(0);
  368. }
  369. EOF
  370. $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm $dummy.c $dummy && exit 0
  371. rm -f $dummy.c $dummy
  372. echo rs6000-ibm-aix3.2.5
  373. elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
  374. echo rs6000-ibm-aix3.2.4
  375. else
  376. echo rs6000-ibm-aix3.2
  377. fi
  378. exit 0 ;;
  379.     *:AIX:*:4)
  380. IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | head -1 | awk '{ print $1 }'`
  381. if /usr/sbin/lsattr -EHl ${IBM_CPU_ID} | grep POWER >/dev/null 2>&1; then
  382. IBM_ARCH=rs6000
  383. else
  384. IBM_ARCH=powerpc
  385. fi
  386. if [ -x /usr/bin/oslevel ] ; then
  387. IBM_REV=`/usr/bin/oslevel`
  388. else
  389. IBM_REV=4.${UNAME_RELEASE}
  390. fi
  391. echo ${IBM_ARCH}-ibm-aix${IBM_REV}
  392. exit 0 ;;
  393.     *:AIX:*:*)
  394. echo rs6000-ibm-aix
  395. exit 0 ;;
  396.     ibmrt:4.4BSD:*|romp-ibm:BSD:*)
  397. echo romp-ibm-bsd4.4
  398. exit 0 ;;
  399.     ibmrt:*BSD:*|romp-ibm:BSD:*)            # covers RT/PC NetBSD and
  400. echo romp-ibm-bsd${UNAME_RELEASE}   # 4.3 with uname added to
  401. exit 0 ;;                           # report: romp-ibm BSD 4.3
  402.     *:BOSX:*:*)
  403. echo rs6000-bull-bosx
  404. exit 0 ;;
  405.     DPX/2?00:B.O.S.:*:*)
  406. echo m68k-bull-sysv3
  407. exit 0 ;;
  408.     9000/[34]??:4.3bsd:1.*:*)
  409. echo m68k-hp-bsd
  410. exit 0 ;;
  411.     hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
  412. echo m68k-hp-bsd4.4
  413. exit 0 ;;
  414.     9000/[34678]??:HP-UX:*:*)
  415. case "${UNAME_MACHINE}" in
  416.     9000/31? )            HP_ARCH=m68000 ;;
  417.     9000/[34]?? )         HP_ARCH=m68k ;;
  418.     9000/6?? | 9000/7?? | 9000/80[024] | 9000/8?[136790] | 9000/892 )
  419.               sed 's/^              //' << EOF >$dummy.c
  420.               #include <stdlib.h>
  421.               #include <unistd.h>
  422.               
  423.               int main ()
  424.               {
  425.               #if defined(_SC_KERNEL_BITS)
  426.                   long bits = sysconf(_SC_KERNEL_BITS);
  427.               #endif
  428.                   long cpu  = sysconf (_SC_CPU_VERSION);
  429.               
  430.                   switch (cpu)
  431.                {
  432.                case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
  433.                case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
  434.                case CPU_PA_RISC2_0:
  435.               #if defined(_SC_KERNEL_BITS)
  436.                    switch (bits)
  437.                {
  438.                case 64: puts ("hppa2.0w"); break;
  439.                case 32: puts ("hppa2.0n"); break;
  440.                default: puts ("hppa2.0"); break;
  441.                } break;
  442.               #else  /* !defined(_SC_KERNEL_BITS) */
  443.                    puts ("hppa2.0"); break;
  444.               #endif
  445.                default: puts ("hppa1.0"); break;
  446.                }
  447.                   exit (0);
  448.               }
  449. EOF
  450. ($CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null ) && HP_ARCH=`./$dummy`
  451. rm -f $dummy.c $dummy
  452. esac
  453. HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
  454. echo ${HP_ARCH}-hp-hpux${HPUX_REV}
  455. exit 0 ;;
  456.     3050*:HI-UX:*:*)
  457. sed 's/^ //' << EOF >$dummy.c
  458. #include <unistd.h>
  459. int
  460. main ()
  461. {
  462.   long cpu = sysconf (_SC_CPU_VERSION);
  463.   /* The order matters, because CPU_IS_HP_MC68K erroneously returns
  464.      true for CPU_PA_RISC1_0.  CPU_IS_PA_RISC returns correct
  465.      results, however.  */
  466.   if (CPU_IS_PA_RISC (cpu))
  467.     {
  468.       switch (cpu)
  469. {
  470.   case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
  471.   case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
  472.   case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
  473.   default: puts ("hppa-hitachi-hiuxwe2"); break;
  474. }
  475.     }
  476.   else if (CPU_IS_HP_MC68K (cpu))
  477.     puts ("m68k-hitachi-hiuxwe2");
  478.   else puts ("unknown-hitachi-hiuxwe2");
  479.   exit (0);
  480. }
  481. EOF
  482. $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm $dummy.c $dummy && exit 0
  483. rm -f $dummy.c $dummy
  484. echo unknown-hitachi-hiuxwe2
  485. exit 0 ;;
  486.     9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
  487. echo hppa1.1-hp-bsd
  488. exit 0 ;;
  489.     9000/8??:4.3bsd:*:*)
  490. echo hppa1.0-hp-bsd
  491. exit 0 ;;
  492.     *9??*:MPE*:*:*)
  493. echo hppa1.0-hp-mpeix
  494. exit 0 ;;
  495.     hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
  496. echo hppa1.1-hp-osf
  497. exit 0 ;;
  498.     hp8??:OSF1:*:*)
  499. echo hppa1.0-hp-osf
  500. exit 0 ;;
  501.     i?86:OSF1:*:*)
  502. if [ -x /usr/sbin/sysversion ] ; then
  503.     echo ${UNAME_MACHINE}-unknown-osf1mk
  504. else
  505.     echo ${UNAME_MACHINE}-unknown-osf1
  506. fi
  507. exit 0 ;;
  508.     parisc*:Lites*:*:*)
  509. echo hppa1.1-hp-lites
  510. exit 0 ;;
  511.     C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
  512. echo c1-convex-bsd
  513. exit 0 ;;
  514.     C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
  515. if getsysinfo -f scalar_acc
  516. then echo c32-convex-bsd
  517. else echo c2-convex-bsd
  518. fi
  519. exit 0 ;;
  520.     C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
  521. echo c34-convex-bsd
  522. exit 0 ;;
  523.     C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
  524. echo c38-convex-bsd
  525. exit 0 ;;
  526.     C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
  527. echo c4-convex-bsd
  528. exit 0 ;;
  529.     CRAY*X-MP:*:*:*)
  530. echo xmp-cray-unicos
  531. exit 0 ;;
  532.     CRAY*Y-MP:*:*:*)
  533. echo ymp-cray-unicos${UNAME_RELEASE}
  534. exit 0 ;;
  535.     CRAY*[A-Z]90:*:*:*)
  536. echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} 
  537. | sed -e 's/CRAY.*([A-Z]90)/1/' 
  538.       -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/
  539. exit 0 ;;
  540.     CRAY*TS:*:*:*)
  541. echo t90-cray-unicos${UNAME_RELEASE}
  542.    exit 0 ;;
  543.     CRAY*T3E:*:*:*)
  544. echo t3e-cray-unicosmk${UNAME_RELEASE}
  545. exit 0 ;;
  546.     CRAY-2:*:*:*)
  547. echo cray2-cray-unicos
  548. exit 0 ;;
  549.     F300:UNIX_System_V:*:*)
  550. FUJITSU_SYS=`uname -p | tr [A-Z] [a-z] | sed -e 's////'`
  551. FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
  552. echo "f300-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
  553. exit 0 ;;
  554.     F301:UNIX_System_V:*:*)
  555. echo f301-fujitsu-uxpv`echo $UNAME_RELEASE | sed 's/ .*//'`
  556. exit 0 ;;
  557.     hp3[0-9][05]:NetBSD:*:*)
  558. echo m68k-hp-netbsd${UNAME_RELEASE}
  559. exit 0 ;;
  560.     hp300:OpenBSD:*:*)
  561. echo m68k-unknown-openbsd${UNAME_RELEASE}
  562. exit 0 ;;
  563.     sparc*:BSD/OS:*:*)
  564. echo sparc-unknown-bsdi${UNAME_RELEASE}
  565. exit 0 ;;
  566.     i?86:BSD/386:*:* | i?86:BSD/OS:*:*)
  567. echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
  568. exit 0 ;;
  569.     *:BSD/OS:*:*)
  570. echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
  571. exit 0 ;;
  572.     *:FreeBSD:*:*)
  573. if test -x /usr/bin/objformat; then
  574.     if test "elf" = "`/usr/bin/objformat`"; then
  575. echo ${UNAME_MACHINE}-unknown-freebsdelf`echo ${UNAME_RELEASE}|sed -e 's/[-_].*//'`
  576. exit 0
  577.     fi
  578. fi
  579. echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
  580. exit 0 ;;
  581.     *:NetBSD:*:*)
  582. echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/./'`
  583. exit 0 ;;
  584.     *:OpenBSD:*:*)
  585. echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/./'`
  586. exit 0 ;;
  587.     i*:CYGWIN*:*)
  588. echo ${UNAME_MACHINE}-pc-cygwin
  589. exit 0 ;;
  590.     i*:MINGW*:*)
  591. echo ${UNAME_MACHINE}-pc-mingw32
  592. exit 0 ;;
  593.     p*:CYGWIN*:*)
  594. echo powerpcle-unknown-cygwin
  595. exit 0 ;;
  596.     prep*:SunOS:5.*:*)
  597. echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  598. exit 0 ;;
  599.     *:GNU:*:*)
  600. echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
  601. exit 0 ;;
  602.     *:Linux:*:*)
  603. # uname on the ARM produces all sorts of strangeness, and we need to
  604. # filter it out.
  605. case "$UNAME_MACHINE" in
  606.   armv*)       UNAME_MACHINE=$UNAME_MACHINE ;;
  607.   arm* | sa110*)       UNAME_MACHINE="arm" ;;
  608. esac
  609. # The BFD linker knows what the default object file format is, so
  610. # first see if it will tell us. cd to the root directory to prevent
  611. # problems with other programs or directories called `ld' in the path.
  612. ld_help_string=`cd /; ld --help 2>&1`
  613. ld_supported_emulations=`echo $ld_help_string 
  614.  | sed -ne '/supported emulations:/!d
  615.     s/[  ][  ]*/ /g
  616.     s/.*supported emulations: *//
  617.     s/ .*//
  618.     p'`
  619. case "$ld_supported_emulations" in
  620.   i?86linux)  echo "${UNAME_MACHINE}-pc-linuxaout"      ; exit 0 ;;
  621.   i?86coff)   echo "${UNAME_MACHINE}-pc-linuxcoff"      ; exit 0 ;;
  622.   sparclinux) echo "${UNAME_MACHINE}-unknown-linuxaout" ; exit 0 ;;
  623.   armlinux)   echo "${UNAME_MACHINE}-unknown-linuxaout" ; exit 0 ;;
  624.   m68klinux)  echo "${UNAME_MACHINE}-unknown-linuxaout" ; exit 0 ;;
  625.   elf32ppc)   echo "powerpc-unknown-linux"              ; exit 0 ;;
  626. esac
  627. if test "${UNAME_MACHINE}" = "alpha" ; then
  628. sed 's/^ //'  <<EOF >$dummy.s
  629. .globl main
  630. .ent main
  631. main:
  632. .frame $30,0,$26,0
  633. .prologue 0
  634. .long 0x47e03d80 # implver $0
  635. lda $2,259
  636. .long 0x47e20c21 # amask $2,$1
  637. srl $1,8,$2
  638. sll $2,2,$2
  639. sll $0,3,$0
  640. addl $1,$0,$0
  641. addl $2,$0,$0
  642. ret $31,($26),1
  643. .end main
  644. EOF
  645. LIBC="libc6"
  646. $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
  647. if test "$?" = 0 ; then
  648. ./$dummy
  649. case "$?" in
  650. 7)
  651. UNAME_MACHINE="alpha"
  652. ;;
  653. 15)
  654. UNAME_MACHINE="alphaev5"
  655. ;;
  656. 14)
  657. UNAME_MACHINE="alphaev56"
  658. ;;
  659. 10)
  660. UNAME_MACHINE="alphapca56"
  661. ;;
  662. 16)
  663. UNAME_MACHINE="alphaev6"
  664. ;;
  665. esac
  666. objdump --private-headers $dummy | 
  667.   grep ld.so.1 > /dev/null
  668. if test "$?" = 0 ; then
  669. LIBC="libc5"
  670. fi
  671. fi
  672. rm -f $dummy.s $dummy
  673. echo ${UNAME_MACHINE}-unknown-linux${LIBC} ; exit 0
  674. elif test "${UNAME_MACHINE}" = "mips" ; then
  675.   cat >$dummy.c <<EOF
  676. #if defined(__STDC__) || defined(__cplusplus)
  677. int main (int argc, char *argv[])
  678. #else
  679. main(argc, argv)
  680.      int argc;
  681.      char *argv[];
  682. #endif
  683. {
  684. #ifdef __MIPSEB__
  685.   printf ("%s-unknown-linuxlibc6n", argv[1]);
  686. #endif
  687. #ifdef __MIPSEL__
  688.   printf ("%sel-unknown-linuxlibc6n", argv[1]);
  689. #endif
  690.   return 0;
  691. }
  692. EOF
  693.   $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm $dummy.c $dummy && exit 0
  694.   rm -f $dummy.c $dummy
  695. else
  696.   # Either a pre-BFD a.out linker (linuxoldld)
  697.   # or one that does not give us useful --help.
  698.   # GCC wants to distinguish between linuxoldld and linuxaout.
  699.   # If ld does not provide *any* "supported emulations:"
  700.   # that means it is gnuoldld.
  701.   echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations:"
  702.   test $? != 0 && echo "${UNAME_MACHINE}-pc-linuxoldld" && exit 0
  703.   case "${UNAME_MACHINE}" in
  704.   i?86)
  705.     VENDOR=pc;
  706.     ;;
  707.   *)
  708.     VENDOR=unknown;
  709.     ;;
  710.   esac
  711.   # Determine whether the default compiler is a.out or elf
  712.   cat >$dummy.c <<EOF
  713. #include <features.h>
  714. #if defined(__STDC__) || defined(__cplusplus)
  715. int main (int argc, char *argv[])
  716. #else
  717. main(argc, argv)
  718.      int argc;
  719.      char *argv[];
  720. #endif
  721. {
  722. #ifdef __ELF__
  723. # ifdef __GLIBC__
  724. #  if __GLIBC__ >= 2
  725.     printf ("%s-${VENDOR}-linuxlibc6n", argv[1]);
  726. #  else
  727.     printf ("%s-${VENDOR}-linuxlibc5n", argv[1]);
  728. #  endif
  729. # else
  730.    printf ("%s-${VENDOR}-linuxlibc5n", argv[1]);
  731. # endif
  732. #else
  733.   printf ("%s-${VENDOR}-linuxaoutn", argv[1]);
  734. #endif
  735.   return 0;
  736. }
  737. EOF
  738.   $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm $dummy.c $dummy && exit 0
  739.   rm -f $dummy.c $dummy
  740. fi ;;
  741. # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.  earlier versions
  742. # are messed up and put the nodename in both sysname and nodename.
  743.     i?86:DYNIX/ptx:4*:*)
  744. echo i386-sequent-sysv4
  745. exit 0 ;;
  746.     i?86:UNIX_SV:4.2MP:2.*)
  747.         # Unixware is an offshoot of SVR4, but it has its own version
  748.         # number series starting with 2...
  749.         # I am not positive that other SVR4 systems won't match this,
  750. # I just have to hope.  -- rms.
  751.         # Use sysv4.2uw... so that sysv4* matches it.
  752. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
  753. exit 0 ;;
  754.     i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*)
  755. if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
  756. echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE}
  757. else
  758. echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE}
  759. fi
  760. exit 0 ;;
  761.     i?86:*:3.2:*)
  762. if test -f /usr/options/cb.name; then
  763. UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
  764. echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
  765. elif /bin/uname -X 2>/dev/null >/dev/null ; then
  766. UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
  767. (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
  768. (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) 
  769. && UNAME_MACHINE=i586
  770. echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
  771. else
  772. echo ${UNAME_MACHINE}-pc-sysv32
  773. fi
  774. exit 0 ;;
  775.     i?86:UnixWare:*:*)
  776. if /bin/uname -X 2>/dev/null >/dev/null ; then
  777.   (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) 
  778.     && UNAME_MACHINE=i586
  779. fi
  780. echo ${UNAME_MACHINE}-unixware-${UNAME_RELEASE}-${UNAME_VERSION}
  781. exit 0 ;;
  782.     pc:*:*:*)
  783.         # uname -m prints for DJGPP always 'pc', but it prints nothing about
  784.         # the processor, so we play safe by assuming i386.
  785. echo i386-pc-msdosdjgpp
  786.         exit 0 ;;
  787.     Intel:Mach:3*:*)
  788. echo i386-pc-mach3
  789. exit 0 ;;
  790.     paragon:*:*:*)
  791. echo i860-intel-osf1
  792. exit 0 ;;
  793.     i860:*:4.*:*) # i860-SVR4
  794. if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
  795.   echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
  796. else # Add other i860-SVR4 vendors below as they are discovered.
  797.   echo i860-unknown-sysv${UNAME_RELEASE}  # Unknown i860-SVR4
  798. fi
  799. exit 0 ;;
  800.     mini*:CTIX:SYS*5:*)
  801. # "miniframe"
  802. echo m68010-convergent-sysv
  803. exit 0 ;;
  804.     M68*:*:R3V[567]*:*)
  805. test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
  806.     3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0)
  807. OS_REL=''
  808. test -r /etc/.relid 
  809. && OS_REL=.`sed -n 's/[^ ]* [^ ]* ([0-9][0-9]).*/1/p' < /etc/.relid`
  810. /bin/uname -p 2>/dev/null | grep 86 >/dev/null 
  811.   && echo i486-ncr-sysv4.3${OS_REL} && exit 0
  812. /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null 
  813.   && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;;
  814.     3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
  815. /bin/uname -p 2>/dev/null | grep 86 >/dev/null 
  816.   && echo i486-ncr-sysv4 && exit 0 ;;
  817.     m68*:LynxOS:2.*:*)
  818. echo m68k-unknown-lynxos${UNAME_RELEASE}
  819. exit 0 ;;
  820.     mc68030:UNIX_System_V:4.*:*)
  821. echo m68k-atari-sysv4
  822. exit 0 ;;
  823.     i?86:LynxOS:2.*:* | i?86:LynxOS:3.[01]*:*)
  824. echo i386-unknown-lynxos${UNAME_RELEASE}
  825. exit 0 ;;
  826.     TSUNAMI:LynxOS:2.*:*)
  827. echo sparc-unknown-lynxos${UNAME_RELEASE}
  828. exit 0 ;;
  829.     rs6000:LynxOS:2.*:* | PowerPC:LynxOS:2.*:*)
  830. echo rs6000-unknown-lynxos${UNAME_RELEASE}
  831. exit 0 ;;
  832.     SM[BE]S:UNIX_SV:*:*)
  833. echo mips-dde-sysv${UNAME_RELEASE}
  834. exit 0 ;;
  835.     RM*:ReliantUNIX-*:*:*)
  836. echo mips-sni-sysv4
  837. exit 0 ;;
  838.     RM*:SINIX-*:*:*)
  839. echo mips-sni-sysv4
  840. exit 0 ;;
  841.     *:SINIX-*:*:*)
  842. if uname -p 2>/dev/null >/dev/null ; then
  843. UNAME_MACHINE=`(uname -p) 2>/dev/null`
  844. echo ${UNAME_MACHINE}-sni-sysv4
  845. else
  846. echo ns32k-sni-sysv
  847. fi
  848. exit 0 ;;
  849.     PENTIUM:CPunix:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
  850.                            # says <Richard.M.Bartel@ccMail.Census.GOV>
  851.         echo i586-unisys-sysv4
  852.         exit 0 ;;
  853.     *:UNIX_System_V:4*:FTX*)
  854. # From Gerald Hewes <hewes@openmarket.com>.
  855. # How about differentiating between stratus architectures? -djm
  856. echo hppa1.1-stratus-sysv4
  857. exit 0 ;;
  858.     *:*:*:FTX*)
  859. # From seanf@swdc.stratus.com.
  860. echo i860-stratus-sysv4
  861. exit 0 ;;
  862.     mc68*:A/UX:*:*)
  863. echo m68k-apple-aux${UNAME_RELEASE}
  864. exit 0 ;;
  865.     news*:NEWS-OS:*:6*)
  866. echo mips-sony-newsos6
  867. exit 0 ;;
  868.     R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R4000:UNIX_SV:*:*)
  869. if [ -d /usr/nec ]; then
  870.         echo mips-nec-sysv${UNAME_RELEASE}
  871. else
  872.         echo mips-unknown-sysv${UNAME_RELEASE}
  873. fi
  874. exit 0 ;;
  875.     BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
  876. echo powerpc-be-beos
  877. exit 0 ;;
  878.     BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
  879. echo powerpc-apple-beos
  880. exit 0 ;;
  881.     BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
  882. echo i586-pc-beos
  883. exit 0 ;;
  884.     SX-4:SUPER-UX:*:*)
  885. echo sx4-nec-superux${UNAME_RELEASE}
  886. exit 0 ;;
  887.     SX-5:SUPER-UX:*:*)
  888. echo sx5-nec-superux${UNAME_RELEASE}
  889. exit 0 ;;
  890.     Power*:Rhapsody:*:*)
  891. echo powerpc-apple-rhapsody${UNAME_RELEASE}
  892. exit 0 ;;
  893.     *:Rhapsody:*:*)
  894. echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
  895. exit 0 ;;
  896. esac
  897. #echo '(No uname command or uname output not recognized.)' 1>&2
  898. #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
  899. cat >$dummy.c <<EOF
  900. #ifdef _SEQUENT_
  901. # include <sys/types.h>
  902. # include <sys/utsname.h>
  903. #endif
  904. main ()
  905. {
  906. #if defined (sony)
  907. #if defined (MIPSEB)
  908.   /* BFD wants "bsd" instead of "newsos".  Perhaps BFD should be changed,
  909.      I don't know....  */
  910.   printf ("mips-sony-bsdn"); exit (0);
  911. #else
  912. #include <sys/param.h>
  913.   printf ("m68k-sony-newsos%sn",
  914. #ifdef NEWSOS4
  915.           "4"
  916. #else
  917.   ""
  918. #endif
  919.          ); exit (0);
  920. #endif
  921. #endif
  922. #if defined (__arm) && defined (__acorn) && defined (__unix)
  923.   printf ("arm-acorn-riscix"); exit (0);
  924. #endif
  925. #if defined (hp300) && !defined (hpux)
  926.   printf ("m68k-hp-bsdn"); exit (0);
  927. #endif
  928. #if defined (NeXT)
  929. #if !defined (__ARCHITECTURE__)
  930. #define __ARCHITECTURE__ "m68k"
  931. #endif
  932.   int version;
  933.   version=`(hostinfo | sed -n 's/.*NeXT Mach ([0-9]*).*/1/p') 2>/dev/null`;
  934.   if (version < 4)
  935.     printf ("%s-next-nextstep%dn", __ARCHITECTURE__, version);
  936.   else
  937.     printf ("%s-next-openstep%dn", __ARCHITECTURE__, version);
  938.   exit (0);
  939. #endif
  940. #if defined (MULTIMAX) || defined (n16)
  941. #if defined (UMAXV)
  942.   printf ("ns32k-encore-sysvn"); exit (0);
  943. #else
  944. #if defined (CMU)
  945.   printf ("ns32k-encore-machn"); exit (0);
  946. #else
  947.   printf ("ns32k-encore-bsdn"); exit (0);
  948. #endif
  949. #endif
  950. #endif
  951. #if defined (__386BSD__)
  952.   printf ("i386-pc-bsdn"); exit (0);
  953. #endif
  954. #if defined (sequent)
  955. #if defined (i386)
  956.   printf ("i386-sequent-dynixn"); exit (0);
  957. #endif
  958. #if defined (ns32000)
  959.   printf ("ns32k-sequent-dynixn"); exit (0);
  960. #endif
  961. #endif
  962. #if defined (_SEQUENT_)
  963.     struct utsname un;
  964.     uname(&un);
  965.     if (strncmp(un.version, "V2", 2) == 0) {
  966. printf ("i386-sequent-ptx2n"); exit (0);
  967.     }
  968.     if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
  969. printf ("i386-sequent-ptx1n"); exit (0);
  970.     }
  971.     printf ("i386-sequent-ptxn"); exit (0);
  972. #endif
  973. #if defined (vax)
  974. #if !defined (ultrix)
  975.   printf ("vax-dec-bsdn"); exit (0);
  976. #else
  977.   printf ("vax-dec-ultrixn"); exit (0);
  978. #endif
  979. #endif
  980. #if defined (alliant) && defined (i860)
  981.   printf ("i860-alliant-bsdn"); exit (0);
  982. #endif
  983.   exit (1);
  984. }
  985. EOF
  986. $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm $dummy.c $dummy && exit 0
  987. rm -f $dummy.c $dummy
  988. # Apollos put the system type in the environment.
  989. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }
  990. # Convex versions that predate uname can use getsysinfo(1)
  991. if [ -x /usr/convex/getsysinfo ]
  992. then
  993.     case `getsysinfo -f cpu_type` in
  994.     c1*)
  995. echo c1-convex-bsd
  996. exit 0 ;;
  997.     c2*)
  998. if getsysinfo -f scalar_acc
  999. then echo c32-convex-bsd
  1000. else echo c2-convex-bsd
  1001. fi
  1002. exit 0 ;;
  1003.     c34*)
  1004. echo c34-convex-bsd
  1005. exit 0 ;;
  1006.     c38*)
  1007. echo c38-convex-bsd
  1008. exit 0 ;;
  1009.     c4*)
  1010. echo c4-convex-bsd
  1011. exit 0 ;;
  1012.     esac
  1013. fi
  1014. #echo '(Unable to guess system type)' 1>&2
  1015. exit 1