config.guess 42 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438
  1. #! /bin/sh
  2. # Attempt to guess a canonical system name.
  3. # Copyright 1992-2015 Free Software Foundation, Inc.
  4. timestamp='2015-07-03'
  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 3 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, see <http://www.gnu.org/licenses/>.
  17. #
  18. # As a special exception to the GNU General Public License, if you
  19. # distribute this file as part of a program that contains a
  20. # configuration script generated by Autoconf, you may include it under
  21. # the same distribution terms that you use for the rest of that
  22. # program. This Exception is an additional permission under section 7
  23. # of the GNU General Public License, version 3 ("GPLv3").
  24. #
  25. # Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
  26. #
  27. # You can get the latest version of this script from:
  28. # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
  29. #
  30. # Please send patches to <config-patches@gnu.org>.
  31. me=`echo "$0" | sed -e 's,.*/,,'`
  32. usage="\
  33. Usage: $0 [OPTION]
  34. Output the configuration name of the system \`$me' is run on.
  35. Operation modes:
  36. -h, --help print this help, then exit
  37. -t, --time-stamp print date of last modification, then exit
  38. -v, --version print version number, then exit
  39. Report bugs and patches to <config-patches@gnu.org>."
  40. version="\
  41. GNU config.guess ($timestamp)
  42. Originally written by Per Bothner.
  43. Copyright 1992-2015 Free Software Foundation, Inc.
  44. This is free software; see the source for copying conditions. There is NO
  45. warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
  46. help="
  47. Try \`$me --help' for more information."
  48. # Parse command line
  49. while test $# -gt 0 ; do
  50. case $1 in
  51. --time-stamp | --time* | -t )
  52. echo "$timestamp" ; exit ;;
  53. --version | -v )
  54. echo "$version" ; exit ;;
  55. --help | --h* | -h )
  56. echo "$usage"; exit ;;
  57. -- ) # Stop option processing
  58. shift; break ;;
  59. - ) # Use stdin as input.
  60. break ;;
  61. -* )
  62. echo "$me: invalid option $1$help" >&2
  63. exit 1 ;;
  64. * )
  65. break ;;
  66. esac
  67. done
  68. if test $# != 0; then
  69. echo "$me: too many arguments$help" >&2
  70. exit 1
  71. fi
  72. trap 'exit 1' 1 2 15
  73. # CC_FOR_BUILD -- compiler used by this script. Note that the use of a
  74. # compiler to aid in system detection is discouraged as it requires
  75. # temporary files to be created and, as you can see below, it is a
  76. # headache to deal with in a portable fashion.
  77. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
  78. # use `HOST_CC' if defined, but it is deprecated.
  79. # Portable tmp directory creation inspired by the Autoconf team.
  80. set_cc_for_build='
  81. trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
  82. trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
  83. : ${TMPDIR=/tmp} ;
  84. { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
  85. { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
  86. { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
  87. { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
  88. dummy=$tmp/dummy ;
  89. tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
  90. case $CC_FOR_BUILD,$HOST_CC,$CC in
  91. ,,) echo "int x;" > $dummy.c ;
  92. for c in cc gcc c89 c99 ; do
  93. if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
  94. CC_FOR_BUILD="$c"; break ;
  95. fi ;
  96. done ;
  97. if test x"$CC_FOR_BUILD" = x ; then
  98. CC_FOR_BUILD=no_compiler_found ;
  99. fi
  100. ;;
  101. ,,*) CC_FOR_BUILD=$CC ;;
  102. ,*,*) CC_FOR_BUILD=$HOST_CC ;;
  103. esac ; set_cc_for_build= ;'
  104. # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
  105. # (ghazi@noc.rutgers.edu 1994-08-24)
  106. if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
  107. PATH=$PATH:/.attbin ; export PATH
  108. fi
  109. UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
  110. UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
  111. UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
  112. UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
  113. case "${UNAME_SYSTEM}" in
  114. Linux|GNU|GNU/*)
  115. # If the system lacks a compiler, then just pick glibc.
  116. # We could probably try harder.
  117. LIBC=gnu
  118. eval $set_cc_for_build
  119. cat <<-EOF > $dummy.c
  120. #include <features.h>
  121. #if defined(__UCLIBC__)
  122. LIBC=uclibc
  123. #elif defined(__dietlibc__)
  124. LIBC=dietlibc
  125. #else
  126. LIBC=gnu
  127. #endif
  128. EOF
  129. eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
  130. ;;
  131. esac
  132. # Note: order is significant - the case branches are not exclusive.
  133. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
  134. *:NetBSD:*:*)
  135. # NetBSD (nbsd) targets should (where applicable) match one or
  136. # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
  137. # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
  138. # switched to ELF, *-*-netbsd* would select the old
  139. # object file format. This provides both forward
  140. # compatibility and a consistent mechanism for selecting the
  141. # object file format.
  142. #
  143. # Note: NetBSD doesn't particularly care about the vendor
  144. # portion of the name. We always set it to "unknown".
  145. sysctl="sysctl -n hw.machine_arch"
  146. UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
  147. /sbin/$sysctl 2>/dev/null || \
  148. /usr/sbin/$sysctl 2>/dev/null || \
  149. echo unknown)`
  150. case "${UNAME_MACHINE_ARCH}" in
  151. armeb) machine=armeb-unknown ;;
  152. arm*) machine=arm-unknown ;;
  153. sh3el) machine=shl-unknown ;;
  154. sh3eb) machine=sh-unknown ;;
  155. sh5el) machine=sh5le-unknown ;;
  156. earmv*)
  157. arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
  158. endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'`
  159. machine=${arch}${endian}-unknown
  160. ;;
  161. *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
  162. esac
  163. # The Operating System including object format, if it has switched
  164. # to ELF recently, or will in the future.
  165. case "${UNAME_MACHINE_ARCH}" in
  166. arm*|earm*|i386|m68k|ns32k|sh3*|sparc|vax)
  167. eval $set_cc_for_build
  168. if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
  169. | grep -q __ELF__
  170. then
  171. # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
  172. # Return netbsd for either. FIX?
  173. os=netbsd
  174. else
  175. os=netbsdelf
  176. fi
  177. ;;
  178. *)
  179. os=netbsd
  180. ;;
  181. esac
  182. # Determine ABI tags.
  183. case "${UNAME_MACHINE_ARCH}" in
  184. earm*)
  185. expr='s/^earmv[0-9]/-eabi/;s/eb$//'
  186. abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"`
  187. ;;
  188. esac
  189. # The OS release
  190. # Debian GNU/NetBSD machines have a different userland, and
  191. # thus, need a distinct triplet. However, they do not need
  192. # kernel version information, so it can be replaced with a
  193. # suitable tag, in the style of linux-gnu.
  194. case "${UNAME_VERSION}" in
  195. Debian*)
  196. release='-gnu'
  197. ;;
  198. *)
  199. release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2`
  200. ;;
  201. esac
  202. # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
  203. # contains redundant information, the shorter form:
  204. # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
  205. echo "${machine}-${os}${release}${abi}"
  206. exit ;;
  207. *:Bitrig:*:*)
  208. UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
  209. echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE}
  210. exit ;;
  211. *:OpenBSD:*:*)
  212. UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
  213. echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
  214. exit ;;
  215. *:ekkoBSD:*:*)
  216. echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
  217. exit ;;
  218. *:SolidBSD:*:*)
  219. echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
  220. exit ;;
  221. macppc:MirBSD:*:*)
  222. echo powerpc-unknown-mirbsd${UNAME_RELEASE}
  223. exit ;;
  224. *:MirBSD:*:*)
  225. echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
  226. exit ;;
  227. alpha:OSF1:*:*)
  228. case $UNAME_RELEASE in
  229. *4.0)
  230. UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
  231. ;;
  232. *5.*)
  233. UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
  234. ;;
  235. esac
  236. # According to Compaq, /usr/sbin/psrinfo has been available on
  237. # OSF/1 and Tru64 systems produced since 1995. I hope that
  238. # covers most systems running today. This code pipes the CPU
  239. # types through head -n 1, so we only detect the type of CPU 0.
  240. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
  241. case "$ALPHA_CPU_TYPE" in
  242. "EV4 (21064)")
  243. UNAME_MACHINE="alpha" ;;
  244. "EV4.5 (21064)")
  245. UNAME_MACHINE="alpha" ;;
  246. "LCA4 (21066/21068)")
  247. UNAME_MACHINE="alpha" ;;
  248. "EV5 (21164)")
  249. UNAME_MACHINE="alphaev5" ;;
  250. "EV5.6 (21164A)")
  251. UNAME_MACHINE="alphaev56" ;;
  252. "EV5.6 (21164PC)")
  253. UNAME_MACHINE="alphapca56" ;;
  254. "EV5.7 (21164PC)")
  255. UNAME_MACHINE="alphapca57" ;;
  256. "EV6 (21264)")
  257. UNAME_MACHINE="alphaev6" ;;
  258. "EV6.7 (21264A)")
  259. UNAME_MACHINE="alphaev67" ;;
  260. "EV6.8CB (21264C)")
  261. UNAME_MACHINE="alphaev68" ;;
  262. "EV6.8AL (21264B)")
  263. UNAME_MACHINE="alphaev68" ;;
  264. "EV6.8CX (21264D)")
  265. UNAME_MACHINE="alphaev68" ;;
  266. "EV6.9A (21264/EV69A)")
  267. UNAME_MACHINE="alphaev69" ;;
  268. "EV7 (21364)")
  269. UNAME_MACHINE="alphaev7" ;;
  270. "EV7.9 (21364A)")
  271. UNAME_MACHINE="alphaev79" ;;
  272. esac
  273. # A Pn.n version is a patched version.
  274. # A Vn.n version is a released version.
  275. # A Tn.n version is a released field test version.
  276. # A Xn.n version is an unreleased experimental baselevel.
  277. # 1.2 uses "1.2" for uname -r.
  278. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
  279. # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
  280. exitcode=$?
  281. trap '' 0
  282. exit $exitcode ;;
  283. Alpha\ *:Windows_NT*:*)
  284. # How do we know it's Interix rather than the generic POSIX subsystem?
  285. # Should we change UNAME_MACHINE based on the output of uname instead
  286. # of the specific Alpha model?
  287. echo alpha-pc-interix
  288. exit ;;
  289. 21064:Windows_NT:50:3)
  290. echo alpha-dec-winnt3.5
  291. exit ;;
  292. Amiga*:UNIX_System_V:4.0:*)
  293. echo m68k-unknown-sysv4
  294. exit ;;
  295. *:[Aa]miga[Oo][Ss]:*:*)
  296. echo ${UNAME_MACHINE}-unknown-amigaos
  297. exit ;;
  298. *:[Mm]orph[Oo][Ss]:*:*)
  299. echo ${UNAME_MACHINE}-unknown-morphos
  300. exit ;;
  301. *:OS/390:*:*)
  302. echo i370-ibm-openedition
  303. exit ;;
  304. *:z/VM:*:*)
  305. echo s390-ibm-zvmoe
  306. exit ;;
  307. *:OS400:*:*)
  308. echo powerpc-ibm-os400
  309. exit ;;
  310. arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
  311. echo arm-acorn-riscix${UNAME_RELEASE}
  312. exit ;;
  313. arm*:riscos:*:*|arm*:RISCOS:*:*)
  314. echo arm-unknown-riscos
  315. exit ;;
  316. SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
  317. echo hppa1.1-hitachi-hiuxmpp
  318. exit ;;
  319. Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
  320. # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
  321. if test "`(/bin/universe) 2>/dev/null`" = att ; then
  322. echo pyramid-pyramid-sysv3
  323. else
  324. echo pyramid-pyramid-bsd
  325. fi
  326. exit ;;
  327. NILE*:*:*:dcosx)
  328. echo pyramid-pyramid-svr4
  329. exit ;;
  330. DRS?6000:unix:4.0:6*)
  331. echo sparc-icl-nx6
  332. exit ;;
  333. DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
  334. case `/usr/bin/uname -p` in
  335. sparc) echo sparc-icl-nx7; exit ;;
  336. esac ;;
  337. s390x:SunOS:*:*)
  338. echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  339. exit ;;
  340. sun4H:SunOS:5.*:*)
  341. echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  342. exit ;;
  343. sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
  344. echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  345. exit ;;
  346. i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
  347. echo i386-pc-auroraux${UNAME_RELEASE}
  348. exit ;;
  349. i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
  350. eval $set_cc_for_build
  351. SUN_ARCH="i386"
  352. # If there is a compiler, see if it is configured for 64-bit objects.
  353. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
  354. # This test works for both compilers.
  355. if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
  356. if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
  357. (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
  358. grep IS_64BIT_ARCH >/dev/null
  359. then
  360. SUN_ARCH="x86_64"
  361. fi
  362. fi
  363. echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  364. exit ;;
  365. sun4*:SunOS:6*:*)
  366. # According to config.sub, this is the proper way to canonicalize
  367. # SunOS6. Hard to guess exactly what SunOS6 will be like, but
  368. # it's likely to be more like Solaris than SunOS4.
  369. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  370. exit ;;
  371. sun4*:SunOS:*:*)
  372. case "`/usr/bin/arch -k`" in
  373. Series*|S4*)
  374. UNAME_RELEASE=`uname -v`
  375. ;;
  376. esac
  377. # Japanese Language versions have a version number like `4.1.3-JL'.
  378. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
  379. exit ;;
  380. sun3*:SunOS:*:*)
  381. echo m68k-sun-sunos${UNAME_RELEASE}
  382. exit ;;
  383. sun*:*:4.2BSD:*)
  384. UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
  385. test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
  386. case "`/bin/arch`" in
  387. sun3)
  388. echo m68k-sun-sunos${UNAME_RELEASE}
  389. ;;
  390. sun4)
  391. echo sparc-sun-sunos${UNAME_RELEASE}
  392. ;;
  393. esac
  394. exit ;;
  395. aushp:SunOS:*:*)
  396. echo sparc-auspex-sunos${UNAME_RELEASE}
  397. exit ;;
  398. # The situation for MiNT is a little confusing. The machine name
  399. # can be virtually everything (everything which is not
  400. # "atarist" or "atariste" at least should have a processor
  401. # > m68000). The system name ranges from "MiNT" over "FreeMiNT"
  402. # to the lowercase version "mint" (or "freemint"). Finally
  403. # the system name "TOS" denotes a system which is actually not
  404. # MiNT. But MiNT is downward compatible to TOS, so this should
  405. # be no problem.
  406. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
  407. echo m68k-atari-mint${UNAME_RELEASE}
  408. exit ;;
  409. atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
  410. echo m68k-atari-mint${UNAME_RELEASE}
  411. exit ;;
  412. *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
  413. echo m68k-atari-mint${UNAME_RELEASE}
  414. exit ;;
  415. milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
  416. echo m68k-milan-mint${UNAME_RELEASE}
  417. exit ;;
  418. hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
  419. echo m68k-hades-mint${UNAME_RELEASE}
  420. exit ;;
  421. *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
  422. echo m68k-unknown-mint${UNAME_RELEASE}
  423. exit ;;
  424. m68k:machten:*:*)
  425. echo m68k-apple-machten${UNAME_RELEASE}
  426. exit ;;
  427. powerpc:machten:*:*)
  428. echo powerpc-apple-machten${UNAME_RELEASE}
  429. exit ;;
  430. RISC*:Mach:*:*)
  431. echo mips-dec-mach_bsd4.3
  432. exit ;;
  433. RISC*:ULTRIX:*:*)
  434. echo mips-dec-ultrix${UNAME_RELEASE}
  435. exit ;;
  436. VAX*:ULTRIX*:*:*)
  437. echo vax-dec-ultrix${UNAME_RELEASE}
  438. exit ;;
  439. 2020:CLIX:*:* | 2430:CLIX:*:*)
  440. echo clipper-intergraph-clix${UNAME_RELEASE}
  441. exit ;;
  442. mips:*:*:UMIPS | mips:*:*:RISCos)
  443. eval $set_cc_for_build
  444. sed 's/^ //' << EOF >$dummy.c
  445. #ifdef __cplusplus
  446. #include <stdio.h> /* for printf() prototype */
  447. int main (int argc, char *argv[]) {
  448. #else
  449. int main (argc, argv) int argc; char *argv[]; {
  450. #endif
  451. #if defined (host_mips) && defined (MIPSEB)
  452. #if defined (SYSTYPE_SYSV)
  453. printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
  454. #endif
  455. #if defined (SYSTYPE_SVR4)
  456. printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
  457. #endif
  458. #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
  459. printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
  460. #endif
  461. #endif
  462. exit (-1);
  463. }
  464. EOF
  465. $CC_FOR_BUILD -o $dummy $dummy.c &&
  466. dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
  467. SYSTEM_NAME=`$dummy $dummyarg` &&
  468. { echo "$SYSTEM_NAME"; exit; }
  469. echo mips-mips-riscos${UNAME_RELEASE}
  470. exit ;;
  471. Motorola:PowerMAX_OS:*:*)
  472. echo powerpc-motorola-powermax
  473. exit ;;
  474. Motorola:*:4.3:PL8-*)
  475. echo powerpc-harris-powermax
  476. exit ;;
  477. Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
  478. echo powerpc-harris-powermax
  479. exit ;;
  480. Night_Hawk:Power_UNIX:*:*)
  481. echo powerpc-harris-powerunix
  482. exit ;;
  483. m88k:CX/UX:7*:*)
  484. echo m88k-harris-cxux7
  485. exit ;;
  486. m88k:*:4*:R4*)
  487. echo m88k-motorola-sysv4
  488. exit ;;
  489. m88k:*:3*:R3*)
  490. echo m88k-motorola-sysv3
  491. exit ;;
  492. AViiON:dgux:*:*)
  493. # DG/UX returns AViiON for all architectures
  494. UNAME_PROCESSOR=`/usr/bin/uname -p`
  495. if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
  496. then
  497. if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
  498. [ ${TARGET_BINARY_INTERFACE}x = x ]
  499. then
  500. echo m88k-dg-dgux${UNAME_RELEASE}
  501. else
  502. echo m88k-dg-dguxbcs${UNAME_RELEASE}
  503. fi
  504. else
  505. echo i586-dg-dgux${UNAME_RELEASE}
  506. fi
  507. exit ;;
  508. M88*:DolphinOS:*:*) # DolphinOS (SVR3)
  509. echo m88k-dolphin-sysv3
  510. exit ;;
  511. M88*:*:R3*:*)
  512. # Delta 88k system running SVR3
  513. echo m88k-motorola-sysv3
  514. exit ;;
  515. XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
  516. echo m88k-tektronix-sysv3
  517. exit ;;
  518. Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
  519. echo m68k-tektronix-bsd
  520. exit ;;
  521. *:IRIX*:*:*)
  522. echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
  523. exit ;;
  524. ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
  525. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
  526. exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
  527. i*86:AIX:*:*)
  528. echo i386-ibm-aix
  529. exit ;;
  530. ia64:AIX:*:*)
  531. if [ -x /usr/bin/oslevel ] ; then
  532. IBM_REV=`/usr/bin/oslevel`
  533. else
  534. IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
  535. fi
  536. echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
  537. exit ;;
  538. *:AIX:2:3)
  539. if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
  540. eval $set_cc_for_build
  541. sed 's/^ //' << EOF >$dummy.c
  542. #include <sys/systemcfg.h>
  543. main()
  544. {
  545. if (!__power_pc())
  546. exit(1);
  547. puts("powerpc-ibm-aix3.2.5");
  548. exit(0);
  549. }
  550. EOF
  551. if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
  552. then
  553. echo "$SYSTEM_NAME"
  554. else
  555. echo rs6000-ibm-aix3.2.5
  556. fi
  557. elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
  558. echo rs6000-ibm-aix3.2.4
  559. else
  560. echo rs6000-ibm-aix3.2
  561. fi
  562. exit ;;
  563. *:AIX:*:[4567])
  564. IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
  565. if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
  566. IBM_ARCH=rs6000
  567. else
  568. IBM_ARCH=powerpc
  569. fi
  570. if [ -x /usr/bin/lslpp ] ; then
  571. IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
  572. awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
  573. else
  574. IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
  575. fi
  576. echo ${IBM_ARCH}-ibm-aix${IBM_REV}
  577. exit ;;
  578. *:AIX:*:*)
  579. echo rs6000-ibm-aix
  580. exit ;;
  581. ibmrt:4.4BSD:*|romp-ibm:BSD:*)
  582. echo romp-ibm-bsd4.4
  583. exit ;;
  584. ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
  585. echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
  586. exit ;; # report: romp-ibm BSD 4.3
  587. *:BOSX:*:*)
  588. echo rs6000-bull-bosx
  589. exit ;;
  590. DPX/2?00:B.O.S.:*:*)
  591. echo m68k-bull-sysv3
  592. exit ;;
  593. 9000/[34]??:4.3bsd:1.*:*)
  594. echo m68k-hp-bsd
  595. exit ;;
  596. hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
  597. echo m68k-hp-bsd4.4
  598. exit ;;
  599. 9000/[34678]??:HP-UX:*:*)
  600. HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
  601. case "${UNAME_MACHINE}" in
  602. 9000/31? ) HP_ARCH=m68000 ;;
  603. 9000/[34]?? ) HP_ARCH=m68k ;;
  604. 9000/[678][0-9][0-9])
  605. if [ -x /usr/bin/getconf ]; then
  606. sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
  607. sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
  608. case "${sc_cpu_version}" in
  609. 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
  610. 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
  611. 532) # CPU_PA_RISC2_0
  612. case "${sc_kernel_bits}" in
  613. 32) HP_ARCH="hppa2.0n" ;;
  614. 64) HP_ARCH="hppa2.0w" ;;
  615. '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
  616. esac ;;
  617. esac
  618. fi
  619. if [ "${HP_ARCH}" = "" ]; then
  620. eval $set_cc_for_build
  621. sed 's/^ //' << EOF >$dummy.c
  622. #define _HPUX_SOURCE
  623. #include <stdlib.h>
  624. #include <unistd.h>
  625. int main ()
  626. {
  627. #if defined(_SC_KERNEL_BITS)
  628. long bits = sysconf(_SC_KERNEL_BITS);
  629. #endif
  630. long cpu = sysconf (_SC_CPU_VERSION);
  631. switch (cpu)
  632. {
  633. case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
  634. case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
  635. case CPU_PA_RISC2_0:
  636. #if defined(_SC_KERNEL_BITS)
  637. switch (bits)
  638. {
  639. case 64: puts ("hppa2.0w"); break;
  640. case 32: puts ("hppa2.0n"); break;
  641. default: puts ("hppa2.0"); break;
  642. } break;
  643. #else /* !defined(_SC_KERNEL_BITS) */
  644. puts ("hppa2.0"); break;
  645. #endif
  646. default: puts ("hppa1.0"); break;
  647. }
  648. exit (0);
  649. }
  650. EOF
  651. (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
  652. test -z "$HP_ARCH" && HP_ARCH=hppa
  653. fi ;;
  654. esac
  655. if [ ${HP_ARCH} = "hppa2.0w" ]
  656. then
  657. eval $set_cc_for_build
  658. # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
  659. # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
  660. # generating 64-bit code. GNU and HP use different nomenclature:
  661. #
  662. # $ CC_FOR_BUILD=cc ./config.guess
  663. # => hppa2.0w-hp-hpux11.23
  664. # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
  665. # => hppa64-hp-hpux11.23
  666. if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
  667. grep -q __LP64__
  668. then
  669. HP_ARCH="hppa2.0w"
  670. else
  671. HP_ARCH="hppa64"
  672. fi
  673. fi
  674. echo ${HP_ARCH}-hp-hpux${HPUX_REV}
  675. exit ;;
  676. ia64:HP-UX:*:*)
  677. HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
  678. echo ia64-hp-hpux${HPUX_REV}
  679. exit ;;
  680. 3050*:HI-UX:*:*)
  681. eval $set_cc_for_build
  682. sed 's/^ //' << EOF >$dummy.c
  683. #include <unistd.h>
  684. int
  685. main ()
  686. {
  687. long cpu = sysconf (_SC_CPU_VERSION);
  688. /* The order matters, because CPU_IS_HP_MC68K erroneously returns
  689. true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct
  690. results, however. */
  691. if (CPU_IS_PA_RISC (cpu))
  692. {
  693. switch (cpu)
  694. {
  695. case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
  696. case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
  697. case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
  698. default: puts ("hppa-hitachi-hiuxwe2"); break;
  699. }
  700. }
  701. else if (CPU_IS_HP_MC68K (cpu))
  702. puts ("m68k-hitachi-hiuxwe2");
  703. else puts ("unknown-hitachi-hiuxwe2");
  704. exit (0);
  705. }
  706. EOF
  707. $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
  708. { echo "$SYSTEM_NAME"; exit; }
  709. echo unknown-hitachi-hiuxwe2
  710. exit ;;
  711. 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
  712. echo hppa1.1-hp-bsd
  713. exit ;;
  714. 9000/8??:4.3bsd:*:*)
  715. echo hppa1.0-hp-bsd
  716. exit ;;
  717. *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
  718. echo hppa1.0-hp-mpeix
  719. exit ;;
  720. hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
  721. echo hppa1.1-hp-osf
  722. exit ;;
  723. hp8??:OSF1:*:*)
  724. echo hppa1.0-hp-osf
  725. exit ;;
  726. i*86:OSF1:*:*)
  727. if [ -x /usr/sbin/sysversion ] ; then
  728. echo ${UNAME_MACHINE}-unknown-osf1mk
  729. else
  730. echo ${UNAME_MACHINE}-unknown-osf1
  731. fi
  732. exit ;;
  733. parisc*:Lites*:*:*)
  734. echo hppa1.1-hp-lites
  735. exit ;;
  736. C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
  737. echo c1-convex-bsd
  738. exit ;;
  739. C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
  740. if getsysinfo -f scalar_acc
  741. then echo c32-convex-bsd
  742. else echo c2-convex-bsd
  743. fi
  744. exit ;;
  745. C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
  746. echo c34-convex-bsd
  747. exit ;;
  748. C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
  749. echo c38-convex-bsd
  750. exit ;;
  751. C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
  752. echo c4-convex-bsd
  753. exit ;;
  754. CRAY*Y-MP:*:*:*)
  755. echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
  756. exit ;;
  757. CRAY*[A-Z]90:*:*:*)
  758. echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
  759. | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
  760. -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
  761. -e 's/\.[^.]*$/.X/'
  762. exit ;;
  763. CRAY*TS:*:*:*)
  764. echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
  765. exit ;;
  766. CRAY*T3E:*:*:*)
  767. echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
  768. exit ;;
  769. CRAY*SV1:*:*:*)
  770. echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
  771. exit ;;
  772. *:UNICOS/mp:*:*)
  773. echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
  774. exit ;;
  775. F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
  776. FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
  777. FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
  778. FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
  779. echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
  780. exit ;;
  781. 5000:UNIX_System_V:4.*:*)
  782. FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
  783. FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
  784. echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
  785. exit ;;
  786. i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
  787. echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
  788. exit ;;
  789. sparc*:BSD/OS:*:*)
  790. echo sparc-unknown-bsdi${UNAME_RELEASE}
  791. exit ;;
  792. *:BSD/OS:*:*)
  793. echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
  794. exit ;;
  795. *:FreeBSD:*:*)
  796. UNAME_PROCESSOR=`/usr/bin/uname -p`
  797. case ${UNAME_PROCESSOR} in
  798. amd64)
  799. echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
  800. *)
  801. echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
  802. esac
  803. exit ;;
  804. i*:CYGWIN*:*)
  805. echo ${UNAME_MACHINE}-pc-cygwin
  806. exit ;;
  807. *:MINGW64*:*)
  808. echo ${UNAME_MACHINE}-pc-mingw64
  809. exit ;;
  810. *:MINGW*:*)
  811. echo ${UNAME_MACHINE}-pc-mingw32
  812. exit ;;
  813. *:MSYS*:*)
  814. echo ${UNAME_MACHINE}-pc-msys
  815. exit ;;
  816. i*:windows32*:*)
  817. # uname -m includes "-pc" on this system.
  818. echo ${UNAME_MACHINE}-mingw32
  819. exit ;;
  820. i*:PW*:*)
  821. echo ${UNAME_MACHINE}-pc-pw32
  822. exit ;;
  823. *:Interix*:*)
  824. case ${UNAME_MACHINE} in
  825. x86)
  826. echo i586-pc-interix${UNAME_RELEASE}
  827. exit ;;
  828. authenticamd | genuineintel | EM64T)
  829. echo x86_64-unknown-interix${UNAME_RELEASE}
  830. exit ;;
  831. IA64)
  832. echo ia64-unknown-interix${UNAME_RELEASE}
  833. exit ;;
  834. esac ;;
  835. [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
  836. echo i${UNAME_MACHINE}-pc-mks
  837. exit ;;
  838. 8664:Windows_NT:*)
  839. echo x86_64-pc-mks
  840. exit ;;
  841. i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
  842. # How do we know it's Interix rather than the generic POSIX subsystem?
  843. # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
  844. # UNAME_MACHINE based on the output of uname instead of i386?
  845. echo i586-pc-interix
  846. exit ;;
  847. i*:UWIN*:*)
  848. echo ${UNAME_MACHINE}-pc-uwin
  849. exit ;;
  850. amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
  851. echo x86_64-unknown-cygwin
  852. exit ;;
  853. p*:CYGWIN*:*)
  854. echo powerpcle-unknown-cygwin
  855. exit ;;
  856. prep*:SunOS:5.*:*)
  857. echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
  858. exit ;;
  859. *:GNU:*:*)
  860. # the GNU system
  861. echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
  862. exit ;;
  863. *:GNU/*:*:*)
  864. # other systems with GNU libc and userland
  865. echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC}
  866. exit ;;
  867. i*86:Minix:*:*)
  868. echo ${UNAME_MACHINE}-pc-minix
  869. exit ;;
  870. aarch64:Linux:*:*)
  871. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  872. exit ;;
  873. aarch64_be:Linux:*:*)
  874. UNAME_MACHINE=aarch64_be
  875. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  876. exit ;;
  877. alpha:Linux:*:*)
  878. case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
  879. EV5) UNAME_MACHINE=alphaev5 ;;
  880. EV56) UNAME_MACHINE=alphaev56 ;;
  881. PCA56) UNAME_MACHINE=alphapca56 ;;
  882. PCA57) UNAME_MACHINE=alphapca56 ;;
  883. EV6) UNAME_MACHINE=alphaev6 ;;
  884. EV67) UNAME_MACHINE=alphaev67 ;;
  885. EV68*) UNAME_MACHINE=alphaev68 ;;
  886. esac
  887. objdump --private-headers /bin/sh | grep -q ld.so.1
  888. if test "$?" = 0 ; then LIBC="gnulibc1" ; fi
  889. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  890. exit ;;
  891. arc:Linux:*:* | arceb:Linux:*:*)
  892. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  893. exit ;;
  894. arm*:Linux:*:*)
  895. eval $set_cc_for_build
  896. if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
  897. | grep -q __ARM_EABI__
  898. then
  899. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  900. else
  901. if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
  902. | grep -q __ARM_PCS_VFP
  903. then
  904. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi
  905. else
  906. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf
  907. fi
  908. fi
  909. exit ;;
  910. avr32*:Linux:*:*)
  911. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  912. exit ;;
  913. cris:Linux:*:*)
  914. echo ${UNAME_MACHINE}-axis-linux-${LIBC}
  915. exit ;;
  916. crisv32:Linux:*:*)
  917. echo ${UNAME_MACHINE}-axis-linux-${LIBC}
  918. exit ;;
  919. e2k:Linux:*:*)
  920. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  921. exit ;;
  922. frv:Linux:*:*)
  923. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  924. exit ;;
  925. hexagon:Linux:*:*)
  926. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  927. exit ;;
  928. i*86:Linux:*:*)
  929. echo ${UNAME_MACHINE}-pc-linux-${LIBC}
  930. exit ;;
  931. ia64:Linux:*:*)
  932. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  933. exit ;;
  934. m32r*:Linux:*:*)
  935. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  936. exit ;;
  937. m68*:Linux:*:*)
  938. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  939. exit ;;
  940. mips:Linux:*:* | mips64:Linux:*:*)
  941. eval $set_cc_for_build
  942. sed 's/^ //' << EOF >$dummy.c
  943. #undef CPU
  944. #undef ${UNAME_MACHINE}
  945. #undef ${UNAME_MACHINE}el
  946. #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
  947. CPU=${UNAME_MACHINE}el
  948. #else
  949. #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
  950. CPU=${UNAME_MACHINE}
  951. #else
  952. CPU=
  953. #endif
  954. #endif
  955. EOF
  956. eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
  957. test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; }
  958. ;;
  959. openrisc*:Linux:*:*)
  960. echo or1k-unknown-linux-${LIBC}
  961. exit ;;
  962. or32:Linux:*:* | or1k*:Linux:*:*)
  963. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  964. exit ;;
  965. padre:Linux:*:*)
  966. echo sparc-unknown-linux-${LIBC}
  967. exit ;;
  968. parisc64:Linux:*:* | hppa64:Linux:*:*)
  969. echo hppa64-unknown-linux-${LIBC}
  970. exit ;;
  971. parisc:Linux:*:* | hppa:Linux:*:*)
  972. # Look for CPU level
  973. case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
  974. PA7*) echo hppa1.1-unknown-linux-${LIBC} ;;
  975. PA8*) echo hppa2.0-unknown-linux-${LIBC} ;;
  976. *) echo hppa-unknown-linux-${LIBC} ;;
  977. esac
  978. exit ;;
  979. ppc64:Linux:*:*)
  980. echo powerpc64-unknown-linux-${LIBC}
  981. exit ;;
  982. ppc:Linux:*:*)
  983. echo powerpc-unknown-linux-${LIBC}
  984. exit ;;
  985. ppc64le:Linux:*:*)
  986. echo powerpc64le-unknown-linux-${LIBC}
  987. exit ;;
  988. ppcle:Linux:*:*)
  989. echo powerpcle-unknown-linux-${LIBC}
  990. exit ;;
  991. s390:Linux:*:* | s390x:Linux:*:*)
  992. echo ${UNAME_MACHINE}-ibm-linux-${LIBC}
  993. exit ;;
  994. sh64*:Linux:*:*)
  995. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  996. exit ;;
  997. sh*:Linux:*:*)
  998. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  999. exit ;;
  1000. sparc:Linux:*:* | sparc64:Linux:*:*)
  1001. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  1002. exit ;;
  1003. tile*:Linux:*:*)
  1004. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  1005. exit ;;
  1006. vax:Linux:*:*)
  1007. echo ${UNAME_MACHINE}-dec-linux-${LIBC}
  1008. exit ;;
  1009. x86_64:Linux:*:*)
  1010. echo ${UNAME_MACHINE}-pc-linux-${LIBC}
  1011. exit ;;
  1012. xtensa*:Linux:*:*)
  1013. echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
  1014. exit ;;
  1015. i*86:DYNIX/ptx:4*:*)
  1016. # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
  1017. # earlier versions are messed up and put the nodename in both
  1018. # sysname and nodename.
  1019. echo i386-sequent-sysv4
  1020. exit ;;
  1021. i*86:UNIX_SV:4.2MP:2.*)
  1022. # Unixware is an offshoot of SVR4, but it has its own version
  1023. # number series starting with 2...
  1024. # I am not positive that other SVR4 systems won't match this,
  1025. # I just have to hope. -- rms.
  1026. # Use sysv4.2uw... so that sysv4* matches it.
  1027. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
  1028. exit ;;
  1029. i*86:OS/2:*:*)
  1030. # If we were able to find `uname', then EMX Unix compatibility
  1031. # is probably installed.
  1032. echo ${UNAME_MACHINE}-pc-os2-emx
  1033. exit ;;
  1034. i*86:XTS-300:*:STOP)
  1035. echo ${UNAME_MACHINE}-unknown-stop
  1036. exit ;;
  1037. i*86:atheos:*:*)
  1038. echo ${UNAME_MACHINE}-unknown-atheos
  1039. exit ;;
  1040. i*86:syllable:*:*)
  1041. echo ${UNAME_MACHINE}-pc-syllable
  1042. exit ;;
  1043. i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
  1044. echo i386-unknown-lynxos${UNAME_RELEASE}
  1045. exit ;;
  1046. i*86:*DOS:*:*)
  1047. echo ${UNAME_MACHINE}-pc-msdosdjgpp
  1048. exit ;;
  1049. i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
  1050. UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
  1051. if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
  1052. echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
  1053. else
  1054. echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
  1055. fi
  1056. exit ;;
  1057. i*86:*:5:[678]*)
  1058. # UnixWare 7.x, OpenUNIX and OpenServer 6.
  1059. case `/bin/uname -X | grep "^Machine"` in
  1060. *486*) UNAME_MACHINE=i486 ;;
  1061. *Pentium) UNAME_MACHINE=i586 ;;
  1062. *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
  1063. esac
  1064. echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
  1065. exit ;;
  1066. i*86:*:3.2:*)
  1067. if test -f /usr/options/cb.name; then
  1068. UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
  1069. echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
  1070. elif /bin/uname -X 2>/dev/null >/dev/null ; then
  1071. UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
  1072. (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
  1073. (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
  1074. && UNAME_MACHINE=i586
  1075. (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
  1076. && UNAME_MACHINE=i686
  1077. (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
  1078. && UNAME_MACHINE=i686
  1079. echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
  1080. else
  1081. echo ${UNAME_MACHINE}-pc-sysv32
  1082. fi
  1083. exit ;;
  1084. pc:*:*:*)
  1085. # Left here for compatibility:
  1086. # uname -m prints for DJGPP always 'pc', but it prints nothing about
  1087. # the processor, so we play safe by assuming i586.
  1088. # Note: whatever this is, it MUST be the same as what config.sub
  1089. # prints for the "djgpp" host, or else GDB configury will decide that
  1090. # this is a cross-build.
  1091. echo i586-pc-msdosdjgpp
  1092. exit ;;
  1093. Intel:Mach:3*:*)
  1094. echo i386-pc-mach3
  1095. exit ;;
  1096. paragon:*:*:*)
  1097. echo i860-intel-osf1
  1098. exit ;;
  1099. i860:*:4.*:*) # i860-SVR4
  1100. if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
  1101. echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
  1102. else # Add other i860-SVR4 vendors below as they are discovered.
  1103. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
  1104. fi
  1105. exit ;;
  1106. mini*:CTIX:SYS*5:*)
  1107. # "miniframe"
  1108. echo m68010-convergent-sysv
  1109. exit ;;
  1110. mc68k:UNIX:SYSTEM5:3.51m)
  1111. echo m68k-convergent-sysv
  1112. exit ;;
  1113. M680?0:D-NIX:5.3:*)
  1114. echo m68k-diab-dnix
  1115. exit ;;
  1116. M68*:*:R3V[5678]*:*)
  1117. test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
  1118. 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
  1119. OS_REL=''
  1120. test -r /etc/.relid \
  1121. && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
  1122. /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
  1123. && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
  1124. /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
  1125. && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
  1126. 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
  1127. /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
  1128. && { echo i486-ncr-sysv4; exit; } ;;
  1129. NCR*:*:4.2:* | MPRAS*:*:4.2:*)
  1130. OS_REL='.3'
  1131. test -r /etc/.relid \
  1132. && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
  1133. /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
  1134. && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
  1135. /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
  1136. && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
  1137. /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
  1138. && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
  1139. m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
  1140. echo m68k-unknown-lynxos${UNAME_RELEASE}
  1141. exit ;;
  1142. mc68030:UNIX_System_V:4.*:*)
  1143. echo m68k-atari-sysv4
  1144. exit ;;
  1145. TSUNAMI:LynxOS:2.*:*)
  1146. echo sparc-unknown-lynxos${UNAME_RELEASE}
  1147. exit ;;
  1148. rs6000:LynxOS:2.*:*)
  1149. echo rs6000-unknown-lynxos${UNAME_RELEASE}
  1150. exit ;;
  1151. PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
  1152. echo powerpc-unknown-lynxos${UNAME_RELEASE}
  1153. exit ;;
  1154. SM[BE]S:UNIX_SV:*:*)
  1155. echo mips-dde-sysv${UNAME_RELEASE}
  1156. exit ;;
  1157. RM*:ReliantUNIX-*:*:*)
  1158. echo mips-sni-sysv4
  1159. exit ;;
  1160. RM*:SINIX-*:*:*)
  1161. echo mips-sni-sysv4
  1162. exit ;;
  1163. *:SINIX-*:*:*)
  1164. if uname -p 2>/dev/null >/dev/null ; then
  1165. UNAME_MACHINE=`(uname -p) 2>/dev/null`
  1166. echo ${UNAME_MACHINE}-sni-sysv4
  1167. else
  1168. echo ns32k-sni-sysv
  1169. fi
  1170. exit ;;
  1171. PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
  1172. # says <Richard.M.Bartel@ccMail.Census.GOV>
  1173. echo i586-unisys-sysv4
  1174. exit ;;
  1175. *:UNIX_System_V:4*:FTX*)
  1176. # From Gerald Hewes <hewes@openmarket.com>.
  1177. # How about differentiating between stratus architectures? -djm
  1178. echo hppa1.1-stratus-sysv4
  1179. exit ;;
  1180. *:*:*:FTX*)
  1181. # From seanf@swdc.stratus.com.
  1182. echo i860-stratus-sysv4
  1183. exit ;;
  1184. i*86:VOS:*:*)
  1185. # From Paul.Green@stratus.com.
  1186. echo ${UNAME_MACHINE}-stratus-vos
  1187. exit ;;
  1188. *:VOS:*:*)
  1189. # From Paul.Green@stratus.com.
  1190. echo hppa1.1-stratus-vos
  1191. exit ;;
  1192. mc68*:A/UX:*:*)
  1193. echo m68k-apple-aux${UNAME_RELEASE}
  1194. exit ;;
  1195. news*:NEWS-OS:6*:*)
  1196. echo mips-sony-newsos6
  1197. exit ;;
  1198. R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
  1199. if [ -d /usr/nec ]; then
  1200. echo mips-nec-sysv${UNAME_RELEASE}
  1201. else
  1202. echo mips-unknown-sysv${UNAME_RELEASE}
  1203. fi
  1204. exit ;;
  1205. BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
  1206. echo powerpc-be-beos
  1207. exit ;;
  1208. BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
  1209. echo powerpc-apple-beos
  1210. exit ;;
  1211. BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
  1212. echo i586-pc-beos
  1213. exit ;;
  1214. BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
  1215. echo i586-pc-haiku
  1216. exit ;;
  1217. x86_64:Haiku:*:*)
  1218. echo x86_64-unknown-haiku
  1219. exit ;;
  1220. SX-4:SUPER-UX:*:*)
  1221. echo sx4-nec-superux${UNAME_RELEASE}
  1222. exit ;;
  1223. SX-5:SUPER-UX:*:*)
  1224. echo sx5-nec-superux${UNAME_RELEASE}
  1225. exit ;;
  1226. SX-6:SUPER-UX:*:*)
  1227. echo sx6-nec-superux${UNAME_RELEASE}
  1228. exit ;;
  1229. SX-7:SUPER-UX:*:*)
  1230. echo sx7-nec-superux${UNAME_RELEASE}
  1231. exit ;;
  1232. SX-8:SUPER-UX:*:*)
  1233. echo sx8-nec-superux${UNAME_RELEASE}
  1234. exit ;;
  1235. SX-8R:SUPER-UX:*:*)
  1236. echo sx8r-nec-superux${UNAME_RELEASE}
  1237. exit ;;
  1238. Power*:Rhapsody:*:*)
  1239. echo powerpc-apple-rhapsody${UNAME_RELEASE}
  1240. exit ;;
  1241. *:Rhapsody:*:*)
  1242. echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
  1243. exit ;;
  1244. *:Darwin:*:*)
  1245. UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
  1246. eval $set_cc_for_build
  1247. if test "$UNAME_PROCESSOR" = unknown ; then
  1248. UNAME_PROCESSOR=powerpc
  1249. fi
  1250. if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then
  1251. if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
  1252. if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
  1253. (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
  1254. grep IS_64BIT_ARCH >/dev/null
  1255. then
  1256. case $UNAME_PROCESSOR in
  1257. i386) UNAME_PROCESSOR=x86_64 ;;
  1258. powerpc) UNAME_PROCESSOR=powerpc64 ;;
  1259. esac
  1260. fi
  1261. fi
  1262. elif test "$UNAME_PROCESSOR" = i386 ; then
  1263. # Avoid executing cc on OS X 10.9, as it ships with a stub
  1264. # that puts up a graphical alert prompting to install
  1265. # developer tools. Any system running Mac OS X 10.7 or
  1266. # later (Darwin 11 and later) is required to have a 64-bit
  1267. # processor. This is not true of the ARM version of Darwin
  1268. # that Apple uses in portable devices.
  1269. UNAME_PROCESSOR=x86_64
  1270. fi
  1271. echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
  1272. exit ;;
  1273. *:procnto*:*:* | *:QNX:[0123456789]*:*)
  1274. UNAME_PROCESSOR=`uname -p`
  1275. if test "$UNAME_PROCESSOR" = "x86"; then
  1276. UNAME_PROCESSOR=i386
  1277. UNAME_MACHINE=pc
  1278. fi
  1279. echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
  1280. exit ;;
  1281. *:QNX:*:4*)
  1282. echo i386-pc-qnx
  1283. exit ;;
  1284. NEO-?:NONSTOP_KERNEL:*:*)
  1285. echo neo-tandem-nsk${UNAME_RELEASE}
  1286. exit ;;
  1287. NSE-*:NONSTOP_KERNEL:*:*)
  1288. echo nse-tandem-nsk${UNAME_RELEASE}
  1289. exit ;;
  1290. NSR-?:NONSTOP_KERNEL:*:*)
  1291. echo nsr-tandem-nsk${UNAME_RELEASE}
  1292. exit ;;
  1293. *:NonStop-UX:*:*)
  1294. echo mips-compaq-nonstopux
  1295. exit ;;
  1296. BS2000:POSIX*:*:*)
  1297. echo bs2000-siemens-sysv
  1298. exit ;;
  1299. DS/*:UNIX_System_V:*:*)
  1300. echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
  1301. exit ;;
  1302. *:Plan9:*:*)
  1303. # "uname -m" is not consistent, so use $cputype instead. 386
  1304. # is converted to i386 for consistency with other x86
  1305. # operating systems.
  1306. if test "$cputype" = "386"; then
  1307. UNAME_MACHINE=i386
  1308. else
  1309. UNAME_MACHINE="$cputype"
  1310. fi
  1311. echo ${UNAME_MACHINE}-unknown-plan9
  1312. exit ;;
  1313. *:TOPS-10:*:*)
  1314. echo pdp10-unknown-tops10
  1315. exit ;;
  1316. *:TENEX:*:*)
  1317. echo pdp10-unknown-tenex
  1318. exit ;;
  1319. KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
  1320. echo pdp10-dec-tops20
  1321. exit ;;
  1322. XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
  1323. echo pdp10-xkl-tops20
  1324. exit ;;
  1325. *:TOPS-20:*:*)
  1326. echo pdp10-unknown-tops20
  1327. exit ;;
  1328. *:ITS:*:*)
  1329. echo pdp10-unknown-its
  1330. exit ;;
  1331. SEI:*:*:SEIUX)
  1332. echo mips-sei-seiux${UNAME_RELEASE}
  1333. exit ;;
  1334. *:DragonFly:*:*)
  1335. echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
  1336. exit ;;
  1337. *:*VMS:*:*)
  1338. UNAME_MACHINE=`(uname -p) 2>/dev/null`
  1339. case "${UNAME_MACHINE}" in
  1340. A*) echo alpha-dec-vms ; exit ;;
  1341. I*) echo ia64-dec-vms ; exit ;;
  1342. V*) echo vax-dec-vms ; exit ;;
  1343. esac ;;
  1344. *:XENIX:*:SysV)
  1345. echo i386-pc-xenix
  1346. exit ;;
  1347. i*86:skyos:*:*)
  1348. echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
  1349. exit ;;
  1350. i*86:rdos:*:*)
  1351. echo ${UNAME_MACHINE}-pc-rdos
  1352. exit ;;
  1353. i*86:AROS:*:*)
  1354. echo ${UNAME_MACHINE}-pc-aros
  1355. exit ;;
  1356. x86_64:VMkernel:*:*)
  1357. echo ${UNAME_MACHINE}-unknown-esx
  1358. exit ;;
  1359. esac
  1360. cat >&2 <<EOF
  1361. $0: unable to guess system type
  1362. This script, last modified $timestamp, has failed to recognize
  1363. the operating system you are using. It is advised that you
  1364. download the most up to date version of the config scripts from
  1365. http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
  1366. and
  1367. http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
  1368. If the version you run ($0) is already up to date, please
  1369. send the following data and any information you think might be
  1370. pertinent to <config-patches@gnu.org> in order to provide the needed
  1371. information to handle your system.
  1372. config.guess timestamp = $timestamp
  1373. uname -m = `(uname -m) 2>/dev/null || echo unknown`
  1374. uname -r = `(uname -r) 2>/dev/null || echo unknown`
  1375. uname -s = `(uname -s) 2>/dev/null || echo unknown`
  1376. uname -v = `(uname -v) 2>/dev/null || echo unknown`
  1377. /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
  1378. /bin/uname -X = `(/bin/uname -X) 2>/dev/null`
  1379. hostinfo = `(hostinfo) 2>/dev/null`
  1380. /bin/universe = `(/bin/universe) 2>/dev/null`
  1381. /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
  1382. /bin/arch = `(/bin/arch) 2>/dev/null`
  1383. /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
  1384. /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
  1385. UNAME_MACHINE = ${UNAME_MACHINE}
  1386. UNAME_RELEASE = ${UNAME_RELEASE}
  1387. UNAME_SYSTEM = ${UNAME_SYSTEM}
  1388. UNAME_VERSION = ${UNAME_VERSION}
  1389. EOF
  1390. exit 1
  1391. # Local variables:
  1392. # eval: (add-hook 'write-file-hooks 'time-stamp)
  1393. # time-stamp-start: "timestamp='"
  1394. # time-stamp-format: "%:y-%02m-%02d"
  1395. # time-stamp-end: "'"
  1396. # End: