gst-plugins-nuvdemux/config.sub
author rosfran
Wed Oct 25 00:26:33 2006 +0100 (2006-10-25)
branchtrunk
changeset 51 3e490ac963ce
permissions -rwxr-xr-x
[svn r52] Added reference to the GSTINTERFACES_LIBS (gst_x_overlay* functions).
melunko@47
     1
#! /bin/sh
melunko@47
     2
# Configuration validation subroutine script.
melunko@47
     3
#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
melunko@47
     4
#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
melunko@47
     5
melunko@47
     6
timestamp='2005-07-08'
melunko@47
     7
melunko@47
     8
# This file is (in principle) common to ALL GNU software.
melunko@47
     9
# The presence of a machine in this file suggests that SOME GNU software
melunko@47
    10
# can handle that machine.  It does not imply ALL GNU software can.
melunko@47
    11
#
melunko@47
    12
# This file is free software; you can redistribute it and/or modify
melunko@47
    13
# it under the terms of the GNU General Public License as published by
melunko@47
    14
# the Free Software Foundation; either version 2 of the License, or
melunko@47
    15
# (at your option) any later version.
melunko@47
    16
#
melunko@47
    17
# This program is distributed in the hope that it will be useful,
melunko@47
    18
# but WITHOUT ANY WARRANTY; without even the implied warranty of
melunko@47
    19
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
melunko@47
    20
# GNU General Public License for more details.
melunko@47
    21
#
melunko@47
    22
# You should have received a copy of the GNU General Public License
melunko@47
    23
# along with this program; if not, write to the Free Software
melunko@47
    24
# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
melunko@47
    25
# 02110-1301, USA.
melunko@47
    26
#
melunko@47
    27
# As a special exception to the GNU General Public License, if you
melunko@47
    28
# distribute this file as part of a program that contains a
melunko@47
    29
# configuration script generated by Autoconf, you may include it under
melunko@47
    30
# the same distribution terms that you use for the rest of that program.
melunko@47
    31
melunko@47
    32
melunko@47
    33
# Please send patches to <config-patches@gnu.org>.  Submit a context
melunko@47
    34
# diff and a properly formatted ChangeLog entry.
melunko@47
    35
#
melunko@47
    36
# Configuration subroutine to validate and canonicalize a configuration type.
melunko@47
    37
# Supply the specified configuration type as an argument.
melunko@47
    38
# If it is invalid, we print an error message on stderr and exit with code 1.
melunko@47
    39
# Otherwise, we print the canonical config type on stdout and succeed.
melunko@47
    40
melunko@47
    41
# This file is supposed to be the same for all GNU packages
melunko@47
    42
# and recognize all the CPU types, system types and aliases
melunko@47
    43
# that are meaningful with *any* GNU software.
melunko@47
    44
# Each package is responsible for reporting which valid configurations
melunko@47
    45
# it does not support.  The user should be able to distinguish
melunko@47
    46
# a failure to support a valid configuration from a meaningless
melunko@47
    47
# configuration.
melunko@47
    48
melunko@47
    49
# The goal of this file is to map all the various variations of a given
melunko@47
    50
# machine specification into a single specification in the form:
melunko@47
    51
#	CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
melunko@47
    52
# or in some cases, the newer four-part form:
melunko@47
    53
#	CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
melunko@47
    54
# It is wrong to echo any other type of specification.
melunko@47
    55
melunko@47
    56
me=`echo "$0" | sed -e 's,.*/,,'`
melunko@47
    57
melunko@47
    58
usage="\
melunko@47
    59
Usage: $0 [OPTION] CPU-MFR-OPSYS
melunko@47
    60
       $0 [OPTION] ALIAS
melunko@47
    61
melunko@47
    62
Canonicalize a configuration name.
melunko@47
    63
melunko@47
    64
Operation modes:
melunko@47
    65
  -h, --help         print this help, then exit
melunko@47
    66
  -t, --time-stamp   print date of last modification, then exit
melunko@47
    67
  -v, --version      print version number, then exit
melunko@47
    68
melunko@47
    69
Report bugs and patches to <config-patches@gnu.org>."
melunko@47
    70
melunko@47
    71
version="\
melunko@47
    72
GNU config.sub ($timestamp)
melunko@47
    73
melunko@47
    74
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
melunko@47
    75
Free Software Foundation, Inc.
melunko@47
    76
melunko@47
    77
This is free software; see the source for copying conditions.  There is NO
melunko@47
    78
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
melunko@47
    79
melunko@47
    80
help="
melunko@47
    81
Try \`$me --help' for more information."
melunko@47
    82
melunko@47
    83
# Parse command line
melunko@47
    84
while test $# -gt 0 ; do
melunko@47
    85
  case $1 in
melunko@47
    86
    --time-stamp | --time* | -t )
melunko@47
    87
       echo "$timestamp" ; exit ;;
melunko@47
    88
    --version | -v )
melunko@47
    89
       echo "$version" ; exit ;;
melunko@47
    90
    --help | --h* | -h )
melunko@47
    91
       echo "$usage"; exit ;;
melunko@47
    92
    -- )     # Stop option processing
melunko@47
    93
       shift; break ;;
melunko@47
    94
    - )	# Use stdin as input.
melunko@47
    95
       break ;;
melunko@47
    96
    -* )
melunko@47
    97
       echo "$me: invalid option $1$help"
melunko@47
    98
       exit 1 ;;
melunko@47
    99
melunko@47
   100
    *local*)
melunko@47
   101
       # First pass through any local machine types.
melunko@47
   102
       echo $1
melunko@47
   103
       exit ;;
melunko@47
   104
melunko@47
   105
    * )
melunko@47
   106
       break ;;
melunko@47
   107
  esac
melunko@47
   108
done
melunko@47
   109
melunko@47
   110
case $# in
melunko@47
   111
 0) echo "$me: missing argument$help" >&2
melunko@47
   112
    exit 1;;
melunko@47
   113
 1) ;;
melunko@47
   114
 *) echo "$me: too many arguments$help" >&2
melunko@47
   115
    exit 1;;
melunko@47
   116
esac
melunko@47
   117
melunko@47
   118
# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
melunko@47
   119
# Here we must recognize all the valid KERNEL-OS combinations.
melunko@47
   120
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
melunko@47
   121
case $maybe_os in
melunko@47
   122
  nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
melunko@47
   123
  kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
melunko@47
   124
    os=-$maybe_os
melunko@47
   125
    basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
melunko@47
   126
    ;;
melunko@47
   127
  *)
melunko@47
   128
    basic_machine=`echo $1 | sed 's/-[^-]*$//'`
melunko@47
   129
    if [ $basic_machine != $1 ]
melunko@47
   130
    then os=`echo $1 | sed 's/.*-/-/'`
melunko@47
   131
    else os=; fi
melunko@47
   132
    ;;
melunko@47
   133
esac
melunko@47
   134
melunko@47
   135
### Let's recognize common machines as not being operating systems so
melunko@47
   136
### that things like config.sub decstation-3100 work.  We also
melunko@47
   137
### recognize some manufacturers as not being operating systems, so we
melunko@47
   138
### can provide default operating systems below.
melunko@47
   139
case $os in
melunko@47
   140
	-sun*os*)
melunko@47
   141
		# Prevent following clause from handling this invalid input.
melunko@47
   142
		;;
melunko@47
   143
	-dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
melunko@47
   144
	-att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
melunko@47
   145
	-unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
melunko@47
   146
	-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
melunko@47
   147
	-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
melunko@47
   148
	-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
melunko@47
   149
	-apple | -axis | -knuth | -cray)
melunko@47
   150
		os=
melunko@47
   151
		basic_machine=$1
melunko@47
   152
		;;
melunko@47
   153
	-sim | -cisco | -oki | -wec | -winbond)
melunko@47
   154
		os=
melunko@47
   155
		basic_machine=$1
melunko@47
   156
		;;
melunko@47
   157
	-scout)
melunko@47
   158
		;;
melunko@47
   159
	-wrs)
melunko@47
   160
		os=-vxworks
melunko@47
   161
		basic_machine=$1
melunko@47
   162
		;;
melunko@47
   163
	-chorusos*)
melunko@47
   164
		os=-chorusos
melunko@47
   165
		basic_machine=$1
melunko@47
   166
		;;
melunko@47
   167
 	-chorusrdb)
melunko@47
   168
 		os=-chorusrdb
melunko@47
   169
		basic_machine=$1
melunko@47
   170
 		;;
melunko@47
   171
	-hiux*)
melunko@47
   172
		os=-hiuxwe2
melunko@47
   173
		;;
melunko@47
   174
	-sco5)
melunko@47
   175
		os=-sco3.2v5
melunko@47
   176
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   177
		;;
melunko@47
   178
	-sco4)
melunko@47
   179
		os=-sco3.2v4
melunko@47
   180
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   181
		;;
melunko@47
   182
	-sco3.2.[4-9]*)
melunko@47
   183
		os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
melunko@47
   184
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   185
		;;
melunko@47
   186
	-sco3.2v[4-9]*)
melunko@47
   187
		# Don't forget version if it is 3.2v4 or newer.
melunko@47
   188
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   189
		;;
melunko@47
   190
	-sco*)
melunko@47
   191
		os=-sco3.2v2
melunko@47
   192
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   193
		;;
melunko@47
   194
	-udk*)
melunko@47
   195
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   196
		;;
melunko@47
   197
	-isc)
melunko@47
   198
		os=-isc2.2
melunko@47
   199
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   200
		;;
melunko@47
   201
	-clix*)
melunko@47
   202
		basic_machine=clipper-intergraph
melunko@47
   203
		;;
melunko@47
   204
	-isc*)
melunko@47
   205
		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
melunko@47
   206
		;;
melunko@47
   207
	-lynx*)
melunko@47
   208
		os=-lynxos
melunko@47
   209
		;;
melunko@47
   210
	-ptx*)
melunko@47
   211
		basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
melunko@47
   212
		;;
melunko@47
   213
	-windowsnt*)
melunko@47
   214
		os=`echo $os | sed -e 's/windowsnt/winnt/'`
melunko@47
   215
		;;
melunko@47
   216
	-psos*)
melunko@47
   217
		os=-psos
melunko@47
   218
		;;
melunko@47
   219
	-mint | -mint[0-9]*)
melunko@47
   220
		basic_machine=m68k-atari
melunko@47
   221
		os=-mint
melunko@47
   222
		;;
melunko@47
   223
esac
melunko@47
   224
melunko@47
   225
# Decode aliases for certain CPU-COMPANY combinations.
melunko@47
   226
case $basic_machine in
melunko@47
   227
	# Recognize the basic CPU types without company name.
melunko@47
   228
	# Some are omitted here because they have special meanings below.
melunko@47
   229
	1750a | 580 \
melunko@47
   230
	| a29k \
melunko@47
   231
	| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
melunko@47
   232
	| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
melunko@47
   233
	| am33_2.0 \
melunko@47
   234
	| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
melunko@47
   235
	| bfin \
melunko@47
   236
	| c4x | clipper \
melunko@47
   237
	| d10v | d30v | dlx | dsp16xx \
melunko@47
   238
	| fr30 | frv \
melunko@47
   239
	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
melunko@47
   240
	| i370 | i860 | i960 | ia64 \
melunko@47
   241
	| ip2k | iq2000 \
melunko@47
   242
	| m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \
melunko@47
   243
	| mips | mipsbe | mipseb | mipsel | mipsle \
melunko@47
   244
	| mips16 \
melunko@47
   245
	| mips64 | mips64el \
melunko@47
   246
	| mips64vr | mips64vrel \
melunko@47
   247
	| mips64orion | mips64orionel \
melunko@47
   248
	| mips64vr4100 | mips64vr4100el \
melunko@47
   249
	| mips64vr4300 | mips64vr4300el \
melunko@47
   250
	| mips64vr5000 | mips64vr5000el \
melunko@47
   251
	| mips64vr5900 | mips64vr5900el \
melunko@47
   252
	| mipsisa32 | mipsisa32el \
melunko@47
   253
	| mipsisa32r2 | mipsisa32r2el \
melunko@47
   254
	| mipsisa64 | mipsisa64el \
melunko@47
   255
	| mipsisa64r2 | mipsisa64r2el \
melunko@47
   256
	| mipsisa64sb1 | mipsisa64sb1el \
melunko@47
   257
	| mipsisa64sr71k | mipsisa64sr71kel \
melunko@47
   258
	| mipstx39 | mipstx39el \
melunko@47
   259
	| mn10200 | mn10300 \
melunko@47
   260
	| ms1 \
melunko@47
   261
	| msp430 \
melunko@47
   262
	| ns16k | ns32k \
melunko@47
   263
	| or32 \
melunko@47
   264
	| pdp10 | pdp11 | pj | pjl \
melunko@47
   265
	| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
melunko@47
   266
	| pyramid \
melunko@47
   267
	| sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
melunko@47
   268
	| sh64 | sh64le \
melunko@47
   269
	| sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \
melunko@47
   270
	| sparcv8 | sparcv9 | sparcv9b \
melunko@47
   271
	| strongarm \
melunko@47
   272
	| tahoe | thumb | tic4x | tic80 | tron \
melunko@47
   273
	| v850 | v850e \
melunko@47
   274
	| we32k \
melunko@47
   275
	| x86 | xscale | xscalee[bl] | xstormy16 | xtensa \
melunko@47
   276
	| z8k)
melunko@47
   277
		basic_machine=$basic_machine-unknown
melunko@47
   278
		;;
melunko@47
   279
	m32c)
melunko@47
   280
		basic_machine=$basic_machine-unknown
melunko@47
   281
		;;
melunko@47
   282
	m6811 | m68hc11 | m6812 | m68hc12)
melunko@47
   283
		# Motorola 68HC11/12.
melunko@47
   284
		basic_machine=$basic_machine-unknown
melunko@47
   285
		os=-none
melunko@47
   286
		;;
melunko@47
   287
	m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
melunko@47
   288
		;;
melunko@47
   289
melunko@47
   290
	# We use `pc' rather than `unknown'
melunko@47
   291
	# because (1) that's what they normally are, and
melunko@47
   292
	# (2) the word "unknown" tends to confuse beginning users.
melunko@47
   293
	i*86 | x86_64)
melunko@47
   294
	  basic_machine=$basic_machine-pc
melunko@47
   295
	  ;;
melunko@47
   296
	# Object if more than one company name word.
melunko@47
   297
	*-*-*)
melunko@47
   298
		echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
melunko@47
   299
		exit 1
melunko@47
   300
		;;
melunko@47
   301
	# Recognize the basic CPU types with company name.
melunko@47
   302
	580-* \
melunko@47
   303
	| a29k-* \
melunko@47
   304
	| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
melunko@47
   305
	| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
melunko@47
   306
	| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
melunko@47
   307
	| arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
melunko@47
   308
	| avr-* \
melunko@47
   309
	| bfin-* | bs2000-* \
melunko@47
   310
	| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
melunko@47
   311
	| clipper-* | craynv-* | cydra-* \
melunko@47
   312
	| d10v-* | d30v-* | dlx-* \
melunko@47
   313
	| elxsi-* \
melunko@47
   314
	| f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
melunko@47
   315
	| h8300-* | h8500-* \
melunko@47
   316
	| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
melunko@47
   317
	| i*86-* | i860-* | i960-* | ia64-* \
melunko@47
   318
	| ip2k-* | iq2000-* \
melunko@47
   319
	| m32r-* | m32rle-* \
melunko@47
   320
	| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
melunko@47
   321
	| m88110-* | m88k-* | maxq-* | mcore-* \
melunko@47
   322
	| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
melunko@47
   323
	| mips16-* \
melunko@47
   324
	| mips64-* | mips64el-* \
melunko@47
   325
	| mips64vr-* | mips64vrel-* \
melunko@47
   326
	| mips64orion-* | mips64orionel-* \
melunko@47
   327
	| mips64vr4100-* | mips64vr4100el-* \
melunko@47
   328
	| mips64vr4300-* | mips64vr4300el-* \
melunko@47
   329
	| mips64vr5000-* | mips64vr5000el-* \
melunko@47
   330
	| mips64vr5900-* | mips64vr5900el-* \
melunko@47
   331
	| mipsisa32-* | mipsisa32el-* \
melunko@47
   332
	| mipsisa32r2-* | mipsisa32r2el-* \
melunko@47
   333
	| mipsisa64-* | mipsisa64el-* \
melunko@47
   334
	| mipsisa64r2-* | mipsisa64r2el-* \
melunko@47
   335
	| mipsisa64sb1-* | mipsisa64sb1el-* \
melunko@47
   336
	| mipsisa64sr71k-* | mipsisa64sr71kel-* \
melunko@47
   337
	| mipstx39-* | mipstx39el-* \
melunko@47
   338
	| mmix-* \
melunko@47
   339
	| ms1-* \
melunko@47
   340
	| msp430-* \
melunko@47
   341
	| none-* | np1-* | ns16k-* | ns32k-* \
melunko@47
   342
	| orion-* \
melunko@47
   343
	| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
melunko@47
   344
	| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
melunko@47
   345
	| pyramid-* \
melunko@47
   346
	| romp-* | rs6000-* \
melunko@47
   347
	| sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | shbe-* \
melunko@47
   348
	| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
melunko@47
   349
	| sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \
melunko@47
   350
	| sparclite-* \
melunko@47
   351
	| sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
melunko@47
   352
	| tahoe-* | thumb-* \
melunko@47
   353
	| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
melunko@47
   354
	| tron-* \
melunko@47
   355
	| v850-* | v850e-* | vax-* \
melunko@47
   356
	| we32k-* \
melunko@47
   357
	| x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \
melunko@47
   358
	| xstormy16-* | xtensa-* \
melunko@47
   359
	| ymp-* \
melunko@47
   360
	| z8k-*)
melunko@47
   361
		;;
melunko@47
   362
	m32c-*)
melunko@47
   363
		;;
melunko@47
   364
	# Recognize the various machine names and aliases which stand
melunko@47
   365
	# for a CPU type and a company and sometimes even an OS.
melunko@47
   366
	386bsd)
melunko@47
   367
		basic_machine=i386-unknown
melunko@47
   368
		os=-bsd
melunko@47
   369
		;;
melunko@47
   370
	3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
melunko@47
   371
		basic_machine=m68000-att
melunko@47
   372
		;;
melunko@47
   373
	3b*)
melunko@47
   374
		basic_machine=we32k-att
melunko@47
   375
		;;
melunko@47
   376
	a29khif)
melunko@47
   377
		basic_machine=a29k-amd
melunko@47
   378
		os=-udi
melunko@47
   379
		;;
melunko@47
   380
    	abacus)
melunko@47
   381
		basic_machine=abacus-unknown
melunko@47
   382
		;;
melunko@47
   383
	adobe68k)
melunko@47
   384
		basic_machine=m68010-adobe
melunko@47
   385
		os=-scout
melunko@47
   386
		;;
melunko@47
   387
	alliant | fx80)
melunko@47
   388
		basic_machine=fx80-alliant
melunko@47
   389
		;;
melunko@47
   390
	altos | altos3068)
melunko@47
   391
		basic_machine=m68k-altos
melunko@47
   392
		;;
melunko@47
   393
	am29k)
melunko@47
   394
		basic_machine=a29k-none
melunko@47
   395
		os=-bsd
melunko@47
   396
		;;
melunko@47
   397
	amd64)
melunko@47
   398
		basic_machine=x86_64-pc
melunko@47
   399
		;;
melunko@47
   400
	amd64-*)
melunko@47
   401
		basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   402
		;;
melunko@47
   403
	amdahl)
melunko@47
   404
		basic_machine=580-amdahl
melunko@47
   405
		os=-sysv
melunko@47
   406
		;;
melunko@47
   407
	amiga | amiga-*)
melunko@47
   408
		basic_machine=m68k-unknown
melunko@47
   409
		;;
melunko@47
   410
	amigaos | amigados)
melunko@47
   411
		basic_machine=m68k-unknown
melunko@47
   412
		os=-amigaos
melunko@47
   413
		;;
melunko@47
   414
	amigaunix | amix)
melunko@47
   415
		basic_machine=m68k-unknown
melunko@47
   416
		os=-sysv4
melunko@47
   417
		;;
melunko@47
   418
	apollo68)
melunko@47
   419
		basic_machine=m68k-apollo
melunko@47
   420
		os=-sysv
melunko@47
   421
		;;
melunko@47
   422
	apollo68bsd)
melunko@47
   423
		basic_machine=m68k-apollo
melunko@47
   424
		os=-bsd
melunko@47
   425
		;;
melunko@47
   426
	aux)
melunko@47
   427
		basic_machine=m68k-apple
melunko@47
   428
		os=-aux
melunko@47
   429
		;;
melunko@47
   430
	balance)
melunko@47
   431
		basic_machine=ns32k-sequent
melunko@47
   432
		os=-dynix
melunko@47
   433
		;;
melunko@47
   434
	c90)
melunko@47
   435
		basic_machine=c90-cray
melunko@47
   436
		os=-unicos
melunko@47
   437
		;;
melunko@47
   438
	convex-c1)
melunko@47
   439
		basic_machine=c1-convex
melunko@47
   440
		os=-bsd
melunko@47
   441
		;;
melunko@47
   442
	convex-c2)
melunko@47
   443
		basic_machine=c2-convex
melunko@47
   444
		os=-bsd
melunko@47
   445
		;;
melunko@47
   446
	convex-c32)
melunko@47
   447
		basic_machine=c32-convex
melunko@47
   448
		os=-bsd
melunko@47
   449
		;;
melunko@47
   450
	convex-c34)
melunko@47
   451
		basic_machine=c34-convex
melunko@47
   452
		os=-bsd
melunko@47
   453
		;;
melunko@47
   454
	convex-c38)
melunko@47
   455
		basic_machine=c38-convex
melunko@47
   456
		os=-bsd
melunko@47
   457
		;;
melunko@47
   458
	cray | j90)
melunko@47
   459
		basic_machine=j90-cray
melunko@47
   460
		os=-unicos
melunko@47
   461
		;;
melunko@47
   462
	craynv)
melunko@47
   463
		basic_machine=craynv-cray
melunko@47
   464
		os=-unicosmp
melunko@47
   465
		;;
melunko@47
   466
	cr16c)
melunko@47
   467
		basic_machine=cr16c-unknown
melunko@47
   468
		os=-elf
melunko@47
   469
		;;
melunko@47
   470
	crds | unos)
melunko@47
   471
		basic_machine=m68k-crds
melunko@47
   472
		;;
melunko@47
   473
	crisv32 | crisv32-* | etraxfs*)
melunko@47
   474
		basic_machine=crisv32-axis
melunko@47
   475
		;;
melunko@47
   476
	cris | cris-* | etrax*)
melunko@47
   477
		basic_machine=cris-axis
melunko@47
   478
		;;
melunko@47
   479
	crx)
melunko@47
   480
		basic_machine=crx-unknown
melunko@47
   481
		os=-elf
melunko@47
   482
		;;
melunko@47
   483
	da30 | da30-*)
melunko@47
   484
		basic_machine=m68k-da30
melunko@47
   485
		;;
melunko@47
   486
	decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
melunko@47
   487
		basic_machine=mips-dec
melunko@47
   488
		;;
melunko@47
   489
	decsystem10* | dec10*)
melunko@47
   490
		basic_machine=pdp10-dec
melunko@47
   491
		os=-tops10
melunko@47
   492
		;;
melunko@47
   493
	decsystem20* | dec20*)
melunko@47
   494
		basic_machine=pdp10-dec
melunko@47
   495
		os=-tops20
melunko@47
   496
		;;
melunko@47
   497
	delta | 3300 | motorola-3300 | motorola-delta \
melunko@47
   498
	      | 3300-motorola | delta-motorola)
melunko@47
   499
		basic_machine=m68k-motorola
melunko@47
   500
		;;
melunko@47
   501
	delta88)
melunko@47
   502
		basic_machine=m88k-motorola
melunko@47
   503
		os=-sysv3
melunko@47
   504
		;;
melunko@47
   505
	djgpp)
melunko@47
   506
		basic_machine=i586-pc
melunko@47
   507
		os=-msdosdjgpp
melunko@47
   508
		;;
melunko@47
   509
	dpx20 | dpx20-*)
melunko@47
   510
		basic_machine=rs6000-bull
melunko@47
   511
		os=-bosx
melunko@47
   512
		;;
melunko@47
   513
	dpx2* | dpx2*-bull)
melunko@47
   514
		basic_machine=m68k-bull
melunko@47
   515
		os=-sysv3
melunko@47
   516
		;;
melunko@47
   517
	ebmon29k)
melunko@47
   518
		basic_machine=a29k-amd
melunko@47
   519
		os=-ebmon
melunko@47
   520
		;;
melunko@47
   521
	elxsi)
melunko@47
   522
		basic_machine=elxsi-elxsi
melunko@47
   523
		os=-bsd
melunko@47
   524
		;;
melunko@47
   525
	encore | umax | mmax)
melunko@47
   526
		basic_machine=ns32k-encore
melunko@47
   527
		;;
melunko@47
   528
	es1800 | OSE68k | ose68k | ose | OSE)
melunko@47
   529
		basic_machine=m68k-ericsson
melunko@47
   530
		os=-ose
melunko@47
   531
		;;
melunko@47
   532
	fx2800)
melunko@47
   533
		basic_machine=i860-alliant
melunko@47
   534
		;;
melunko@47
   535
	genix)
melunko@47
   536
		basic_machine=ns32k-ns
melunko@47
   537
		;;
melunko@47
   538
	gmicro)
melunko@47
   539
		basic_machine=tron-gmicro
melunko@47
   540
		os=-sysv
melunko@47
   541
		;;
melunko@47
   542
	go32)
melunko@47
   543
		basic_machine=i386-pc
melunko@47
   544
		os=-go32
melunko@47
   545
		;;
melunko@47
   546
	h3050r* | hiux*)
melunko@47
   547
		basic_machine=hppa1.1-hitachi
melunko@47
   548
		os=-hiuxwe2
melunko@47
   549
		;;
melunko@47
   550
	h8300hms)
melunko@47
   551
		basic_machine=h8300-hitachi
melunko@47
   552
		os=-hms
melunko@47
   553
		;;
melunko@47
   554
	h8300xray)
melunko@47
   555
		basic_machine=h8300-hitachi
melunko@47
   556
		os=-xray
melunko@47
   557
		;;
melunko@47
   558
	h8500hms)
melunko@47
   559
		basic_machine=h8500-hitachi
melunko@47
   560
		os=-hms
melunko@47
   561
		;;
melunko@47
   562
	harris)
melunko@47
   563
		basic_machine=m88k-harris
melunko@47
   564
		os=-sysv3
melunko@47
   565
		;;
melunko@47
   566
	hp300-*)
melunko@47
   567
		basic_machine=m68k-hp
melunko@47
   568
		;;
melunko@47
   569
	hp300bsd)
melunko@47
   570
		basic_machine=m68k-hp
melunko@47
   571
		os=-bsd
melunko@47
   572
		;;
melunko@47
   573
	hp300hpux)
melunko@47
   574
		basic_machine=m68k-hp
melunko@47
   575
		os=-hpux
melunko@47
   576
		;;
melunko@47
   577
	hp3k9[0-9][0-9] | hp9[0-9][0-9])
melunko@47
   578
		basic_machine=hppa1.0-hp
melunko@47
   579
		;;
melunko@47
   580
	hp9k2[0-9][0-9] | hp9k31[0-9])
melunko@47
   581
		basic_machine=m68000-hp
melunko@47
   582
		;;
melunko@47
   583
	hp9k3[2-9][0-9])
melunko@47
   584
		basic_machine=m68k-hp
melunko@47
   585
		;;
melunko@47
   586
	hp9k6[0-9][0-9] | hp6[0-9][0-9])
melunko@47
   587
		basic_machine=hppa1.0-hp
melunko@47
   588
		;;
melunko@47
   589
	hp9k7[0-79][0-9] | hp7[0-79][0-9])
melunko@47
   590
		basic_machine=hppa1.1-hp
melunko@47
   591
		;;
melunko@47
   592
	hp9k78[0-9] | hp78[0-9])
melunko@47
   593
		# FIXME: really hppa2.0-hp
melunko@47
   594
		basic_machine=hppa1.1-hp
melunko@47
   595
		;;
melunko@47
   596
	hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
melunko@47
   597
		# FIXME: really hppa2.0-hp
melunko@47
   598
		basic_machine=hppa1.1-hp
melunko@47
   599
		;;
melunko@47
   600
	hp9k8[0-9][13679] | hp8[0-9][13679])
melunko@47
   601
		basic_machine=hppa1.1-hp
melunko@47
   602
		;;
melunko@47
   603
	hp9k8[0-9][0-9] | hp8[0-9][0-9])
melunko@47
   604
		basic_machine=hppa1.0-hp
melunko@47
   605
		;;
melunko@47
   606
	hppa-next)
melunko@47
   607
		os=-nextstep3
melunko@47
   608
		;;
melunko@47
   609
	hppaosf)
melunko@47
   610
		basic_machine=hppa1.1-hp
melunko@47
   611
		os=-osf
melunko@47
   612
		;;
melunko@47
   613
	hppro)
melunko@47
   614
		basic_machine=hppa1.1-hp
melunko@47
   615
		os=-proelf
melunko@47
   616
		;;
melunko@47
   617
	i370-ibm* | ibm*)
melunko@47
   618
		basic_machine=i370-ibm
melunko@47
   619
		;;
melunko@47
   620
# I'm not sure what "Sysv32" means.  Should this be sysv3.2?
melunko@47
   621
	i*86v32)
melunko@47
   622
		basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
melunko@47
   623
		os=-sysv32
melunko@47
   624
		;;
melunko@47
   625
	i*86v4*)
melunko@47
   626
		basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
melunko@47
   627
		os=-sysv4
melunko@47
   628
		;;
melunko@47
   629
	i*86v)
melunko@47
   630
		basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
melunko@47
   631
		os=-sysv
melunko@47
   632
		;;
melunko@47
   633
	i*86sol2)
melunko@47
   634
		basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
melunko@47
   635
		os=-solaris2
melunko@47
   636
		;;
melunko@47
   637
	i386mach)
melunko@47
   638
		basic_machine=i386-mach
melunko@47
   639
		os=-mach
melunko@47
   640
		;;
melunko@47
   641
	i386-vsta | vsta)
melunko@47
   642
		basic_machine=i386-unknown
melunko@47
   643
		os=-vsta
melunko@47
   644
		;;
melunko@47
   645
	iris | iris4d)
melunko@47
   646
		basic_machine=mips-sgi
melunko@47
   647
		case $os in
melunko@47
   648
		    -irix*)
melunko@47
   649
			;;
melunko@47
   650
		    *)
melunko@47
   651
			os=-irix4
melunko@47
   652
			;;
melunko@47
   653
		esac
melunko@47
   654
		;;
melunko@47
   655
	isi68 | isi)
melunko@47
   656
		basic_machine=m68k-isi
melunko@47
   657
		os=-sysv
melunko@47
   658
		;;
melunko@47
   659
	m88k-omron*)
melunko@47
   660
		basic_machine=m88k-omron
melunko@47
   661
		;;
melunko@47
   662
	magnum | m3230)
melunko@47
   663
		basic_machine=mips-mips
melunko@47
   664
		os=-sysv
melunko@47
   665
		;;
melunko@47
   666
	merlin)
melunko@47
   667
		basic_machine=ns32k-utek
melunko@47
   668
		os=-sysv
melunko@47
   669
		;;
melunko@47
   670
	mingw32)
melunko@47
   671
		basic_machine=i386-pc
melunko@47
   672
		os=-mingw32
melunko@47
   673
		;;
melunko@47
   674
	miniframe)
melunko@47
   675
		basic_machine=m68000-convergent
melunko@47
   676
		;;
melunko@47
   677
	*mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*)
melunko@47
   678
		basic_machine=m68k-atari
melunko@47
   679
		os=-mint
melunko@47
   680
		;;
melunko@47
   681
	mips3*-*)
melunko@47
   682
		basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
melunko@47
   683
		;;
melunko@47
   684
	mips3*)
melunko@47
   685
		basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
melunko@47
   686
		;;
melunko@47
   687
	monitor)
melunko@47
   688
		basic_machine=m68k-rom68k
melunko@47
   689
		os=-coff
melunko@47
   690
		;;
melunko@47
   691
	morphos)
melunko@47
   692
		basic_machine=powerpc-unknown
melunko@47
   693
		os=-morphos
melunko@47
   694
		;;
melunko@47
   695
	msdos)
melunko@47
   696
		basic_machine=i386-pc
melunko@47
   697
		os=-msdos
melunko@47
   698
		;;
melunko@47
   699
	mvs)
melunko@47
   700
		basic_machine=i370-ibm
melunko@47
   701
		os=-mvs
melunko@47
   702
		;;
melunko@47
   703
	ncr3000)
melunko@47
   704
		basic_machine=i486-ncr
melunko@47
   705
		os=-sysv4
melunko@47
   706
		;;
melunko@47
   707
	netbsd386)
melunko@47
   708
		basic_machine=i386-unknown
melunko@47
   709
		os=-netbsd
melunko@47
   710
		;;
melunko@47
   711
	netwinder)
melunko@47
   712
		basic_machine=armv4l-rebel
melunko@47
   713
		os=-linux
melunko@47
   714
		;;
melunko@47
   715
	news | news700 | news800 | news900)
melunko@47
   716
		basic_machine=m68k-sony
melunko@47
   717
		os=-newsos
melunko@47
   718
		;;
melunko@47
   719
	news1000)
melunko@47
   720
		basic_machine=m68030-sony
melunko@47
   721
		os=-newsos
melunko@47
   722
		;;
melunko@47
   723
	news-3600 | risc-news)
melunko@47
   724
		basic_machine=mips-sony
melunko@47
   725
		os=-newsos
melunko@47
   726
		;;
melunko@47
   727
	necv70)
melunko@47
   728
		basic_machine=v70-nec
melunko@47
   729
		os=-sysv
melunko@47
   730
		;;
melunko@47
   731
	next | m*-next )
melunko@47
   732
		basic_machine=m68k-next
melunko@47
   733
		case $os in
melunko@47
   734
		    -nextstep* )
melunko@47
   735
			;;
melunko@47
   736
		    -ns2*)
melunko@47
   737
		      os=-nextstep2
melunko@47
   738
			;;
melunko@47
   739
		    *)
melunko@47
   740
		      os=-nextstep3
melunko@47
   741
			;;
melunko@47
   742
		esac
melunko@47
   743
		;;
melunko@47
   744
	nh3000)
melunko@47
   745
		basic_machine=m68k-harris
melunko@47
   746
		os=-cxux
melunko@47
   747
		;;
melunko@47
   748
	nh[45]000)
melunko@47
   749
		basic_machine=m88k-harris
melunko@47
   750
		os=-cxux
melunko@47
   751
		;;
melunko@47
   752
	nindy960)
melunko@47
   753
		basic_machine=i960-intel
melunko@47
   754
		os=-nindy
melunko@47
   755
		;;
melunko@47
   756
	mon960)
melunko@47
   757
		basic_machine=i960-intel
melunko@47
   758
		os=-mon960
melunko@47
   759
		;;
melunko@47
   760
	nonstopux)
melunko@47
   761
		basic_machine=mips-compaq
melunko@47
   762
		os=-nonstopux
melunko@47
   763
		;;
melunko@47
   764
	np1)
melunko@47
   765
		basic_machine=np1-gould
melunko@47
   766
		;;
melunko@47
   767
	nsr-tandem)
melunko@47
   768
		basic_machine=nsr-tandem
melunko@47
   769
		;;
melunko@47
   770
	op50n-* | op60c-*)
melunko@47
   771
		basic_machine=hppa1.1-oki
melunko@47
   772
		os=-proelf
melunko@47
   773
		;;
melunko@47
   774
	openrisc | openrisc-*)
melunko@47
   775
		basic_machine=or32-unknown
melunko@47
   776
		;;
melunko@47
   777
	os400)
melunko@47
   778
		basic_machine=powerpc-ibm
melunko@47
   779
		os=-os400
melunko@47
   780
		;;
melunko@47
   781
	OSE68000 | ose68000)
melunko@47
   782
		basic_machine=m68000-ericsson
melunko@47
   783
		os=-ose
melunko@47
   784
		;;
melunko@47
   785
	os68k)
melunko@47
   786
		basic_machine=m68k-none
melunko@47
   787
		os=-os68k
melunko@47
   788
		;;
melunko@47
   789
	pa-hitachi)
melunko@47
   790
		basic_machine=hppa1.1-hitachi
melunko@47
   791
		os=-hiuxwe2
melunko@47
   792
		;;
melunko@47
   793
	paragon)
melunko@47
   794
		basic_machine=i860-intel
melunko@47
   795
		os=-osf
melunko@47
   796
		;;
melunko@47
   797
	pbd)
melunko@47
   798
		basic_machine=sparc-tti
melunko@47
   799
		;;
melunko@47
   800
	pbb)
melunko@47
   801
		basic_machine=m68k-tti
melunko@47
   802
		;;
melunko@47
   803
	pc532 | pc532-*)
melunko@47
   804
		basic_machine=ns32k-pc532
melunko@47
   805
		;;
melunko@47
   806
	pentium | p5 | k5 | k6 | nexgen | viac3)
melunko@47
   807
		basic_machine=i586-pc
melunko@47
   808
		;;
melunko@47
   809
	pentiumpro | p6 | 6x86 | athlon | athlon_*)
melunko@47
   810
		basic_machine=i686-pc
melunko@47
   811
		;;
melunko@47
   812
	pentiumii | pentium2 | pentiumiii | pentium3)
melunko@47
   813
		basic_machine=i686-pc
melunko@47
   814
		;;
melunko@47
   815
	pentium4)
melunko@47
   816
		basic_machine=i786-pc
melunko@47
   817
		;;
melunko@47
   818
	pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
melunko@47
   819
		basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   820
		;;
melunko@47
   821
	pentiumpro-* | p6-* | 6x86-* | athlon-*)
melunko@47
   822
		basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   823
		;;
melunko@47
   824
	pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
melunko@47
   825
		basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   826
		;;
melunko@47
   827
	pentium4-*)
melunko@47
   828
		basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   829
		;;
melunko@47
   830
	pn)
melunko@47
   831
		basic_machine=pn-gould
melunko@47
   832
		;;
melunko@47
   833
	power)	basic_machine=power-ibm
melunko@47
   834
		;;
melunko@47
   835
	ppc)	basic_machine=powerpc-unknown
melunko@47
   836
		;;
melunko@47
   837
	ppc-*)	basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   838
		;;
melunko@47
   839
	ppcle | powerpclittle | ppc-le | powerpc-little)
melunko@47
   840
		basic_machine=powerpcle-unknown
melunko@47
   841
		;;
melunko@47
   842
	ppcle-* | powerpclittle-*)
melunko@47
   843
		basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   844
		;;
melunko@47
   845
	ppc64)	basic_machine=powerpc64-unknown
melunko@47
   846
		;;
melunko@47
   847
	ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   848
		;;
melunko@47
   849
	ppc64le | powerpc64little | ppc64-le | powerpc64-little)
melunko@47
   850
		basic_machine=powerpc64le-unknown
melunko@47
   851
		;;
melunko@47
   852
	ppc64le-* | powerpc64little-*)
melunko@47
   853
		basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
melunko@47
   854
		;;
melunko@47
   855
	ps2)
melunko@47
   856
		basic_machine=i386-ibm
melunko@47
   857
		;;
melunko@47
   858
	pw32)
melunko@47
   859
		basic_machine=i586-unknown
melunko@47
   860
		os=-pw32
melunko@47
   861
		;;
melunko@47
   862
	rom68k)
melunko@47
   863
		basic_machine=m68k-rom68k
melunko@47
   864
		os=-coff
melunko@47
   865
		;;
melunko@47
   866
	rm[46]00)
melunko@47
   867
		basic_machine=mips-siemens
melunko@47
   868
		;;
melunko@47
   869
	rtpc | rtpc-*)
melunko@47
   870
		basic_machine=romp-ibm
melunko@47
   871
		;;
melunko@47
   872
	s390 | s390-*)
melunko@47
   873
		basic_machine=s390-ibm
melunko@47
   874
		;;
melunko@47
   875
	s390x | s390x-*)
melunko@47
   876
		basic_machine=s390x-ibm
melunko@47
   877
		;;
melunko@47
   878
	sa29200)
melunko@47
   879
		basic_machine=a29k-amd
melunko@47
   880
		os=-udi
melunko@47
   881
		;;
melunko@47
   882
	sb1)
melunko@47
   883
		basic_machine=mipsisa64sb1-unknown
melunko@47
   884
		;;
melunko@47
   885
	sb1el)
melunko@47
   886
		basic_machine=mipsisa64sb1el-unknown
melunko@47
   887
		;;
melunko@47
   888
	sei)
melunko@47
   889
		basic_machine=mips-sei
melunko@47
   890
		os=-seiux
melunko@47
   891
		;;
melunko@47
   892
	sequent)
melunko@47
   893
		basic_machine=i386-sequent
melunko@47
   894
		;;
melunko@47
   895
	sh)
melunko@47
   896
		basic_machine=sh-hitachi
melunko@47
   897
		os=-hms
melunko@47
   898
		;;
melunko@47
   899
	sh64)
melunko@47
   900
		basic_machine=sh64-unknown
melunko@47
   901
		;;
melunko@47
   902
	sparclite-wrs | simso-wrs)
melunko@47
   903
		basic_machine=sparclite-wrs
melunko@47
   904
		os=-vxworks
melunko@47
   905
		;;
melunko@47
   906
	sps7)
melunko@47
   907
		basic_machine=m68k-bull
melunko@47
   908
		os=-sysv2
melunko@47
   909
		;;
melunko@47
   910
	spur)
melunko@47
   911
		basic_machine=spur-unknown
melunko@47
   912
		;;
melunko@47
   913
	st2000)
melunko@47
   914
		basic_machine=m68k-tandem
melunko@47
   915
		;;
melunko@47
   916
	stratus)
melunko@47
   917
		basic_machine=i860-stratus
melunko@47
   918
		os=-sysv4
melunko@47
   919
		;;
melunko@47
   920
	sun2)
melunko@47
   921
		basic_machine=m68000-sun
melunko@47
   922
		;;
melunko@47
   923
	sun2os3)
melunko@47
   924
		basic_machine=m68000-sun
melunko@47
   925
		os=-sunos3
melunko@47
   926
		;;
melunko@47
   927
	sun2os4)
melunko@47
   928
		basic_machine=m68000-sun
melunko@47
   929
		os=-sunos4
melunko@47
   930
		;;
melunko@47
   931
	sun3os3)
melunko@47
   932
		basic_machine=m68k-sun
melunko@47
   933
		os=-sunos3
melunko@47
   934
		;;
melunko@47
   935
	sun3os4)
melunko@47
   936
		basic_machine=m68k-sun
melunko@47
   937
		os=-sunos4
melunko@47
   938
		;;
melunko@47
   939
	sun4os3)
melunko@47
   940
		basic_machine=sparc-sun
melunko@47
   941
		os=-sunos3
melunko@47
   942
		;;
melunko@47
   943
	sun4os4)
melunko@47
   944
		basic_machine=sparc-sun
melunko@47
   945
		os=-sunos4
melunko@47
   946
		;;
melunko@47
   947
	sun4sol2)
melunko@47
   948
		basic_machine=sparc-sun
melunko@47
   949
		os=-solaris2
melunko@47
   950
		;;
melunko@47
   951
	sun3 | sun3-*)
melunko@47
   952
		basic_machine=m68k-sun
melunko@47
   953
		;;
melunko@47
   954
	sun4)
melunko@47
   955
		basic_machine=sparc-sun
melunko@47
   956
		;;
melunko@47
   957
	sun386 | sun386i | roadrunner)
melunko@47
   958
		basic_machine=i386-sun
melunko@47
   959
		;;
melunko@47
   960
	sv1)
melunko@47
   961
		basic_machine=sv1-cray
melunko@47
   962
		os=-unicos
melunko@47
   963
		;;
melunko@47
   964
	symmetry)
melunko@47
   965
		basic_machine=i386-sequent
melunko@47
   966
		os=-dynix
melunko@47
   967
		;;
melunko@47
   968
	t3e)
melunko@47
   969
		basic_machine=alphaev5-cray
melunko@47
   970
		os=-unicos
melunko@47
   971
		;;
melunko@47
   972
	t90)
melunko@47
   973
		basic_machine=t90-cray
melunko@47
   974
		os=-unicos
melunko@47
   975
		;;
melunko@47
   976
	tic54x | c54x*)
melunko@47
   977
		basic_machine=tic54x-unknown
melunko@47
   978
		os=-coff
melunko@47
   979
		;;
melunko@47
   980
	tic55x | c55x*)
melunko@47
   981
		basic_machine=tic55x-unknown
melunko@47
   982
		os=-coff
melunko@47
   983
		;;
melunko@47
   984
	tic6x | c6x*)
melunko@47
   985
		basic_machine=tic6x-unknown
melunko@47
   986
		os=-coff
melunko@47
   987
		;;
melunko@47
   988
	tx39)
melunko@47
   989
		basic_machine=mipstx39-unknown
melunko@47
   990
		;;
melunko@47
   991
	tx39el)
melunko@47
   992
		basic_machine=mipstx39el-unknown
melunko@47
   993
		;;
melunko@47
   994
	toad1)
melunko@47
   995
		basic_machine=pdp10-xkl
melunko@47
   996
		os=-tops20
melunko@47
   997
		;;
melunko@47
   998
	tower | tower-32)
melunko@47
   999
		basic_machine=m68k-ncr
melunko@47
  1000
		;;
melunko@47
  1001
	tpf)
melunko@47
  1002
		basic_machine=s390x-ibm
melunko@47
  1003
		os=-tpf
melunko@47
  1004
		;;
melunko@47
  1005
	udi29k)
melunko@47
  1006
		basic_machine=a29k-amd
melunko@47
  1007
		os=-udi
melunko@47
  1008
		;;
melunko@47
  1009
	ultra3)
melunko@47
  1010
		basic_machine=a29k-nyu
melunko@47
  1011
		os=-sym1
melunko@47
  1012
		;;
melunko@47
  1013
	v810 | necv810)
melunko@47
  1014
		basic_machine=v810-nec
melunko@47
  1015
		os=-none
melunko@47
  1016
		;;
melunko@47
  1017
	vaxv)
melunko@47
  1018
		basic_machine=vax-dec
melunko@47
  1019
		os=-sysv
melunko@47
  1020
		;;
melunko@47
  1021
	vms)
melunko@47
  1022
		basic_machine=vax-dec
melunko@47
  1023
		os=-vms
melunko@47
  1024
		;;
melunko@47
  1025
	vpp*|vx|vx-*)
melunko@47
  1026
		basic_machine=f301-fujitsu
melunko@47
  1027
		;;
melunko@47
  1028
	vxworks960)
melunko@47
  1029
		basic_machine=i960-wrs
melunko@47
  1030
		os=-vxworks
melunko@47
  1031
		;;
melunko@47
  1032
	vxworks68)
melunko@47
  1033
		basic_machine=m68k-wrs
melunko@47
  1034
		os=-vxworks
melunko@47
  1035
		;;
melunko@47
  1036
	vxworks29k)
melunko@47
  1037
		basic_machine=a29k-wrs
melunko@47
  1038
		os=-vxworks
melunko@47
  1039
		;;
melunko@47
  1040
	w65*)
melunko@47
  1041
		basic_machine=w65-wdc
melunko@47
  1042
		os=-none
melunko@47
  1043
		;;
melunko@47
  1044
	w89k-*)
melunko@47
  1045
		basic_machine=hppa1.1-winbond
melunko@47
  1046
		os=-proelf
melunko@47
  1047
		;;
melunko@47
  1048
	xbox)
melunko@47
  1049
		basic_machine=i686-pc
melunko@47
  1050
		os=-mingw32
melunko@47
  1051
		;;
melunko@47
  1052
	xps | xps100)
melunko@47
  1053
		basic_machine=xps100-honeywell
melunko@47
  1054
		;;
melunko@47
  1055
	ymp)
melunko@47
  1056
		basic_machine=ymp-cray
melunko@47
  1057
		os=-unicos
melunko@47
  1058
		;;
melunko@47
  1059
	z8k-*-coff)
melunko@47
  1060
		basic_machine=z8k-unknown
melunko@47
  1061
		os=-sim
melunko@47
  1062
		;;
melunko@47
  1063
	none)
melunko@47
  1064
		basic_machine=none-none
melunko@47
  1065
		os=-none
melunko@47
  1066
		;;
melunko@47
  1067
melunko@47
  1068
# Here we handle the default manufacturer of certain CPU types.  It is in
melunko@47
  1069
# some cases the only manufacturer, in others, it is the most popular.
melunko@47
  1070
	w89k)
melunko@47
  1071
		basic_machine=hppa1.1-winbond
melunko@47
  1072
		;;
melunko@47
  1073
	op50n)
melunko@47
  1074
		basic_machine=hppa1.1-oki
melunko@47
  1075
		;;
melunko@47
  1076
	op60c)
melunko@47
  1077
		basic_machine=hppa1.1-oki
melunko@47
  1078
		;;
melunko@47
  1079
	romp)
melunko@47
  1080
		basic_machine=romp-ibm
melunko@47
  1081
		;;
melunko@47
  1082
	mmix)
melunko@47
  1083
		basic_machine=mmix-knuth
melunko@47
  1084
		;;
melunko@47
  1085
	rs6000)
melunko@47
  1086
		basic_machine=rs6000-ibm
melunko@47
  1087
		;;
melunko@47
  1088
	vax)
melunko@47
  1089
		basic_machine=vax-dec
melunko@47
  1090
		;;
melunko@47
  1091
	pdp10)
melunko@47
  1092
		# there are many clones, so DEC is not a safe bet
melunko@47
  1093
		basic_machine=pdp10-unknown
melunko@47
  1094
		;;
melunko@47
  1095
	pdp11)
melunko@47
  1096
		basic_machine=pdp11-dec
melunko@47
  1097
		;;
melunko@47
  1098
	we32k)
melunko@47
  1099
		basic_machine=we32k-att
melunko@47
  1100
		;;
melunko@47
  1101
	sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
melunko@47
  1102
		basic_machine=sh-unknown
melunko@47
  1103
		;;
melunko@47
  1104
	sparc | sparcv8 | sparcv9 | sparcv9b)
melunko@47
  1105
		basic_machine=sparc-sun
melunko@47
  1106
		;;
melunko@47
  1107
	cydra)
melunko@47
  1108
		basic_machine=cydra-cydrome
melunko@47
  1109
		;;
melunko@47
  1110
	orion)
melunko@47
  1111
		basic_machine=orion-highlevel
melunko@47
  1112
		;;
melunko@47
  1113
	orion105)
melunko@47
  1114
		basic_machine=clipper-highlevel
melunko@47
  1115
		;;
melunko@47
  1116
	mac | mpw | mac-mpw)
melunko@47
  1117
		basic_machine=m68k-apple
melunko@47
  1118
		;;
melunko@47
  1119
	pmac | pmac-mpw)
melunko@47
  1120
		basic_machine=powerpc-apple
melunko@47
  1121
		;;
melunko@47
  1122
	*-unknown)
melunko@47
  1123
		# Make sure to match an already-canonicalized machine name.
melunko@47
  1124
		;;
melunko@47
  1125
	*)
melunko@47
  1126
		echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
melunko@47
  1127
		exit 1
melunko@47
  1128
		;;
melunko@47
  1129
esac
melunko@47
  1130
melunko@47
  1131
# Here we canonicalize certain aliases for manufacturers.
melunko@47
  1132
case $basic_machine in
melunko@47
  1133
	*-digital*)
melunko@47
  1134
		basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
melunko@47
  1135
		;;
melunko@47
  1136
	*-commodore*)
melunko@47
  1137
		basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
melunko@47
  1138
		;;
melunko@47
  1139
	*)
melunko@47
  1140
		;;
melunko@47
  1141
esac
melunko@47
  1142
melunko@47
  1143
# Decode manufacturer-specific aliases for certain operating systems.
melunko@47
  1144
melunko@47
  1145
if [ x"$os" != x"" ]
melunko@47
  1146
then
melunko@47
  1147
case $os in
melunko@47
  1148
        # First match some system type aliases
melunko@47
  1149
        # that might get confused with valid system types.
melunko@47
  1150
	# -solaris* is a basic system type, with this one exception.
melunko@47
  1151
	-solaris1 | -solaris1.*)
melunko@47
  1152
		os=`echo $os | sed -e 's|solaris1|sunos4|'`
melunko@47
  1153
		;;
melunko@47
  1154
	-solaris)
melunko@47
  1155
		os=-solaris2
melunko@47
  1156
		;;
melunko@47
  1157
	-svr4*)
melunko@47
  1158
		os=-sysv4
melunko@47
  1159
		;;
melunko@47
  1160
	-unixware*)
melunko@47
  1161
		os=-sysv4.2uw
melunko@47
  1162
		;;
melunko@47
  1163
	-gnu/linux*)
melunko@47
  1164
		os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
melunko@47
  1165
		;;
melunko@47
  1166
	# First accept the basic system types.
melunko@47
  1167
	# The portable systems comes first.
melunko@47
  1168
	# Each alternative MUST END IN A *, to match a version number.
melunko@47
  1169
	# -sysv* is not here because it comes later, after sysvr4.
melunko@47
  1170
	-gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
melunko@47
  1171
	      | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
melunko@47
  1172
	      | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
melunko@47
  1173
	      | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
melunko@47
  1174
	      | -aos* \
melunko@47
  1175
	      | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
melunko@47
  1176
	      | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
melunko@47
  1177
	      | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
melunko@47
  1178
	      | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
melunko@47
  1179
	      | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
melunko@47
  1180
	      | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
melunko@47
  1181
	      | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
melunko@47
  1182
	      | -chorusos* | -chorusrdb* \
melunko@47
  1183
	      | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
melunko@47
  1184
	      | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
melunko@47
  1185
	      | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
melunko@47
  1186
	      | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
melunko@47
  1187
	      | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
melunko@47
  1188
	      | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
melunko@47
  1189
	      | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
melunko@47
  1190
	      | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
melunko@47
  1191
	      | -skyos* | -haiku*)
melunko@47
  1192
	# Remember, each alternative MUST END IN *, to match a version number.
melunko@47
  1193
		;;
melunko@47
  1194
	-qnx*)
melunko@47
  1195
		case $basic_machine in
melunko@47
  1196
		    x86-* | i*86-*)
melunko@47
  1197
			;;
melunko@47
  1198
		    *)
melunko@47
  1199
			os=-nto$os
melunko@47
  1200
			;;
melunko@47
  1201
		esac
melunko@47
  1202
		;;
melunko@47
  1203
	-nto-qnx*)
melunko@47
  1204
		;;
melunko@47
  1205
	-nto*)
melunko@47
  1206
		os=`echo $os | sed -e 's|nto|nto-qnx|'`
melunko@47
  1207
		;;
melunko@47
  1208
	-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
melunko@47
  1209
	      | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
melunko@47
  1210
	      | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
melunko@47
  1211
		;;
melunko@47
  1212
	-mac*)
melunko@47
  1213
		os=`echo $os | sed -e 's|mac|macos|'`
melunko@47
  1214
		;;
melunko@47
  1215
	-linux-dietlibc)
melunko@47
  1216
		os=-linux-dietlibc
melunko@47
  1217
		;;
melunko@47
  1218
	-linux*)
melunko@47
  1219
		os=`echo $os | sed -e 's|linux|linux-gnu|'`
melunko@47
  1220
		;;
melunko@47
  1221
	-sunos5*)
melunko@47
  1222
		os=`echo $os | sed -e 's|sunos5|solaris2|'`
melunko@47
  1223
		;;
melunko@47
  1224
	-sunos6*)
melunko@47
  1225
		os=`echo $os | sed -e 's|sunos6|solaris3|'`
melunko@47
  1226
		;;
melunko@47
  1227
	-opened*)
melunko@47
  1228
		os=-openedition
melunko@47
  1229
		;;
melunko@47
  1230
        -os400*)
melunko@47
  1231
		os=-os400
melunko@47
  1232
		;;
melunko@47
  1233
	-wince*)
melunko@47
  1234
		os=-wince
melunko@47
  1235
		;;
melunko@47
  1236
	-osfrose*)
melunko@47
  1237
		os=-osfrose
melunko@47
  1238
		;;
melunko@47
  1239
	-osf*)
melunko@47
  1240
		os=-osf
melunko@47
  1241
		;;
melunko@47
  1242
	-utek*)
melunko@47
  1243
		os=-bsd
melunko@47
  1244
		;;
melunko@47
  1245
	-dynix*)
melunko@47
  1246
		os=-bsd
melunko@47
  1247
		;;
melunko@47
  1248
	-acis*)
melunko@47
  1249
		os=-aos
melunko@47
  1250
		;;
melunko@47
  1251
	-atheos*)
melunko@47
  1252
		os=-atheos
melunko@47
  1253
		;;
melunko@47
  1254
	-syllable*)
melunko@47
  1255
		os=-syllable
melunko@47
  1256
		;;
melunko@47
  1257
	-386bsd)
melunko@47
  1258
		os=-bsd
melunko@47
  1259
		;;
melunko@47
  1260
	-ctix* | -uts*)
melunko@47
  1261
		os=-sysv
melunko@47
  1262
		;;
melunko@47
  1263
	-nova*)
melunko@47
  1264
		os=-rtmk-nova
melunko@47
  1265
		;;
melunko@47
  1266
	-ns2 )
melunko@47
  1267
		os=-nextstep2
melunko@47
  1268
		;;
melunko@47
  1269
	-nsk*)
melunko@47
  1270
		os=-nsk
melunko@47
  1271
		;;
melunko@47
  1272
	# Preserve the version number of sinix5.
melunko@47
  1273
	-sinix5.*)
melunko@47
  1274
		os=`echo $os | sed -e 's|sinix|sysv|'`
melunko@47
  1275
		;;
melunko@47
  1276
	-sinix*)
melunko@47
  1277
		os=-sysv4
melunko@47
  1278
		;;
melunko@47
  1279
        -tpf*)
melunko@47
  1280
		os=-tpf
melunko@47
  1281
		;;
melunko@47
  1282
	-triton*)
melunko@47
  1283
		os=-sysv3
melunko@47
  1284
		;;
melunko@47
  1285
	-oss*)
melunko@47
  1286
		os=-sysv3
melunko@47
  1287
		;;
melunko@47
  1288
	-svr4)
melunko@47
  1289
		os=-sysv4
melunko@47
  1290
		;;
melunko@47
  1291
	-svr3)
melunko@47
  1292
		os=-sysv3
melunko@47
  1293
		;;
melunko@47
  1294
	-sysvr4)
melunko@47
  1295
		os=-sysv4
melunko@47
  1296
		;;
melunko@47
  1297
	# This must come after -sysvr4.
melunko@47
  1298
	-sysv*)
melunko@47
  1299
		;;
melunko@47
  1300
	-ose*)
melunko@47
  1301
		os=-ose
melunko@47
  1302
		;;
melunko@47
  1303
	-es1800*)
melunko@47
  1304
		os=-ose
melunko@47
  1305
		;;
melunko@47
  1306
	-xenix)
melunko@47
  1307
		os=-xenix
melunko@47
  1308
		;;
melunko@47
  1309
	-*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
melunko@47
  1310
		os=-mint
melunko@47
  1311
		;;
melunko@47
  1312
	-aros*)
melunko@47
  1313
		os=-aros
melunko@47
  1314
		;;
melunko@47
  1315
	-kaos*)
melunko@47
  1316
		os=-kaos
melunko@47
  1317
		;;
melunko@47
  1318
	-zvmoe)
melunko@47
  1319
		os=-zvmoe
melunko@47
  1320
		;;
melunko@47
  1321
	-none)
melunko@47
  1322
		;;
melunko@47
  1323
	*)
melunko@47
  1324
		# Get rid of the `-' at the beginning of $os.
melunko@47
  1325
		os=`echo $os | sed 's/[^-]*-//'`
melunko@47
  1326
		echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
melunko@47
  1327
		exit 1
melunko@47
  1328
		;;
melunko@47
  1329
esac
melunko@47
  1330
else
melunko@47
  1331
melunko@47
  1332
# Here we handle the default operating systems that come with various machines.
melunko@47
  1333
# The value should be what the vendor currently ships out the door with their
melunko@47
  1334
# machine or put another way, the most popular os provided with the machine.
melunko@47
  1335
melunko@47
  1336
# Note that if you're going to try to match "-MANUFACTURER" here (say,
melunko@47
  1337
# "-sun"), then you have to tell the case statement up towards the top
melunko@47
  1338
# that MANUFACTURER isn't an operating system.  Otherwise, code above
melunko@47
  1339
# will signal an error saying that MANUFACTURER isn't an operating
melunko@47
  1340
# system, and we'll never get to this point.
melunko@47
  1341
melunko@47
  1342
case $basic_machine in
melunko@47
  1343
	*-acorn)
melunko@47
  1344
		os=-riscix1.2
melunko@47
  1345
		;;
melunko@47
  1346
	arm*-rebel)
melunko@47
  1347
		os=-linux
melunko@47
  1348
		;;
melunko@47
  1349
	arm*-semi)
melunko@47
  1350
		os=-aout
melunko@47
  1351
		;;
melunko@47
  1352
    c4x-* | tic4x-*)
melunko@47
  1353
        os=-coff
melunko@47
  1354
        ;;
melunko@47
  1355
	# This must come before the *-dec entry.
melunko@47
  1356
	pdp10-*)
melunko@47
  1357
		os=-tops20
melunko@47
  1358
		;;
melunko@47
  1359
	pdp11-*)
melunko@47
  1360
		os=-none
melunko@47
  1361
		;;
melunko@47
  1362
	*-dec | vax-*)
melunko@47
  1363
		os=-ultrix4.2
melunko@47
  1364
		;;
melunko@47
  1365
	m68*-apollo)
melunko@47
  1366
		os=-domain
melunko@47
  1367
		;;
melunko@47
  1368
	i386-sun)
melunko@47
  1369
		os=-sunos4.0.2
melunko@47
  1370
		;;
melunko@47
  1371
	m68000-sun)
melunko@47
  1372
		os=-sunos3
melunko@47
  1373
		# This also exists in the configure program, but was not the
melunko@47
  1374
		# default.
melunko@47
  1375
		# os=-sunos4
melunko@47
  1376
		;;
melunko@47
  1377
	m68*-cisco)
melunko@47
  1378
		os=-aout
melunko@47
  1379
		;;
melunko@47
  1380
	mips*-cisco)
melunko@47
  1381
		os=-elf
melunko@47
  1382
		;;
melunko@47
  1383
	mips*-*)
melunko@47
  1384
		os=-elf
melunko@47
  1385
		;;
melunko@47
  1386
	or32-*)
melunko@47
  1387
		os=-coff
melunko@47
  1388
		;;
melunko@47
  1389
	*-tti)	# must be before sparc entry or we get the wrong os.
melunko@47
  1390
		os=-sysv3
melunko@47
  1391
		;;
melunko@47
  1392
	sparc-* | *-sun)
melunko@47
  1393
		os=-sunos4.1.1
melunko@47
  1394
		;;
melunko@47
  1395
	*-be)
melunko@47
  1396
		os=-beos
melunko@47
  1397
		;;
melunko@47
  1398
	*-haiku)
melunko@47
  1399
		os=-haiku
melunko@47
  1400
		;;
melunko@47
  1401
	*-ibm)
melunko@47
  1402
		os=-aix
melunko@47
  1403
		;;
melunko@47
  1404
    	*-knuth)
melunko@47
  1405
		os=-mmixware
melunko@47
  1406
		;;
melunko@47
  1407
	*-wec)
melunko@47
  1408
		os=-proelf
melunko@47
  1409
		;;
melunko@47
  1410
	*-winbond)
melunko@47
  1411
		os=-proelf
melunko@47
  1412
		;;
melunko@47
  1413
	*-oki)
melunko@47
  1414
		os=-proelf
melunko@47
  1415
		;;
melunko@47
  1416
	*-hp)
melunko@47
  1417
		os=-hpux
melunko@47
  1418
		;;
melunko@47
  1419
	*-hitachi)
melunko@47
  1420
		os=-hiux
melunko@47
  1421
		;;
melunko@47
  1422
	i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
melunko@47
  1423
		os=-sysv
melunko@47
  1424
		;;
melunko@47
  1425
	*-cbm)
melunko@47
  1426
		os=-amigaos
melunko@47
  1427
		;;
melunko@47
  1428
	*-dg)
melunko@47
  1429
		os=-dgux
melunko@47
  1430
		;;
melunko@47
  1431
	*-dolphin)
melunko@47
  1432
		os=-sysv3
melunko@47
  1433
		;;
melunko@47
  1434
	m68k-ccur)
melunko@47
  1435
		os=-rtu
melunko@47
  1436
		;;
melunko@47
  1437
	m88k-omron*)
melunko@47
  1438
		os=-luna
melunko@47
  1439
		;;
melunko@47
  1440
	*-next )
melunko@47
  1441
		os=-nextstep
melunko@47
  1442
		;;
melunko@47
  1443
	*-sequent)
melunko@47
  1444
		os=-ptx
melunko@47
  1445
		;;
melunko@47
  1446
	*-crds)
melunko@47
  1447
		os=-unos
melunko@47
  1448
		;;
melunko@47
  1449
	*-ns)
melunko@47
  1450
		os=-genix
melunko@47
  1451
		;;
melunko@47
  1452
	i370-*)
melunko@47
  1453
		os=-mvs
melunko@47
  1454
		;;
melunko@47
  1455
	*-next)
melunko@47
  1456
		os=-nextstep3
melunko@47
  1457
		;;
melunko@47
  1458
	*-gould)
melunko@47
  1459
		os=-sysv
melunko@47
  1460
		;;
melunko@47
  1461
	*-highlevel)
melunko@47
  1462
		os=-bsd
melunko@47
  1463
		;;
melunko@47
  1464
	*-encore)
melunko@47
  1465
		os=-bsd
melunko@47
  1466
		;;
melunko@47
  1467
	*-sgi)
melunko@47
  1468
		os=-irix
melunko@47
  1469
		;;
melunko@47
  1470
	*-siemens)
melunko@47
  1471
		os=-sysv4
melunko@47
  1472
		;;
melunko@47
  1473
	*-masscomp)
melunko@47
  1474
		os=-rtu
melunko@47
  1475
		;;
melunko@47
  1476
	f30[01]-fujitsu | f700-fujitsu)
melunko@47
  1477
		os=-uxpv
melunko@47
  1478
		;;
melunko@47
  1479
	*-rom68k)
melunko@47
  1480
		os=-coff
melunko@47
  1481
		;;
melunko@47
  1482
	*-*bug)
melunko@47
  1483
		os=-coff
melunko@47
  1484
		;;
melunko@47
  1485
	*-apple)
melunko@47
  1486
		os=-macos
melunko@47
  1487
		;;
melunko@47
  1488
	*-atari*)
melunko@47
  1489
		os=-mint
melunko@47
  1490
		;;
melunko@47
  1491
	*)
melunko@47
  1492
		os=-none
melunko@47
  1493
		;;
melunko@47
  1494
esac
melunko@47
  1495
fi
melunko@47
  1496
melunko@47
  1497
# Here we handle the case where we know the os, and the CPU type, but not the
melunko@47
  1498
# manufacturer.  We pick the logical manufacturer.
melunko@47
  1499
vendor=unknown
melunko@47
  1500
case $basic_machine in
melunko@47
  1501
	*-unknown)
melunko@47
  1502
		case $os in
melunko@47
  1503
			-riscix*)
melunko@47
  1504
				vendor=acorn
melunko@47
  1505
				;;
melunko@47
  1506
			-sunos*)
melunko@47
  1507
				vendor=sun
melunko@47
  1508
				;;
melunko@47
  1509
			-aix*)
melunko@47
  1510
				vendor=ibm
melunko@47
  1511
				;;
melunko@47
  1512
			-beos*)
melunko@47
  1513
				vendor=be
melunko@47
  1514
				;;
melunko@47
  1515
			-hpux*)
melunko@47
  1516
				vendor=hp
melunko@47
  1517
				;;
melunko@47
  1518
			-mpeix*)
melunko@47
  1519
				vendor=hp
melunko@47
  1520
				;;
melunko@47
  1521
			-hiux*)
melunko@47
  1522
				vendor=hitachi
melunko@47
  1523
				;;
melunko@47
  1524
			-unos*)
melunko@47
  1525
				vendor=crds
melunko@47
  1526
				;;
melunko@47
  1527
			-dgux*)
melunko@47
  1528
				vendor=dg
melunko@47
  1529
				;;
melunko@47
  1530
			-luna*)
melunko@47
  1531
				vendor=omron
melunko@47
  1532
				;;
melunko@47
  1533
			-genix*)
melunko@47
  1534
				vendor=ns
melunko@47
  1535
				;;
melunko@47
  1536
			-mvs* | -opened*)
melunko@47
  1537
				vendor=ibm
melunko@47
  1538
				;;
melunko@47
  1539
			-os400*)
melunko@47
  1540
				vendor=ibm
melunko@47
  1541
				;;
melunko@47
  1542
			-ptx*)
melunko@47
  1543
				vendor=sequent
melunko@47
  1544
				;;
melunko@47
  1545
			-tpf*)
melunko@47
  1546
				vendor=ibm
melunko@47
  1547
				;;
melunko@47
  1548
			-vxsim* | -vxworks* | -windiss*)
melunko@47
  1549
				vendor=wrs
melunko@47
  1550
				;;
melunko@47
  1551
			-aux*)
melunko@47
  1552
				vendor=apple
melunko@47
  1553
				;;
melunko@47
  1554
			-hms*)
melunko@47
  1555
				vendor=hitachi
melunko@47
  1556
				;;
melunko@47
  1557
			-mpw* | -macos*)
melunko@47
  1558
				vendor=apple
melunko@47
  1559
				;;
melunko@47
  1560
			-*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
melunko@47
  1561
				vendor=atari
melunko@47
  1562
				;;
melunko@47
  1563
			-vos*)
melunko@47
  1564
				vendor=stratus
melunko@47
  1565
				;;
melunko@47
  1566
		esac
melunko@47
  1567
		basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
melunko@47
  1568
		;;
melunko@47
  1569
esac
melunko@47
  1570
melunko@47
  1571
echo $basic_machine$os
melunko@47
  1572
exit
melunko@47
  1573
melunko@47
  1574
# Local variables:
melunko@47
  1575
# eval: (add-hook 'write-file-hooks 'time-stamp)
melunko@47
  1576
# time-stamp-start: "timestamp='"
melunko@47
  1577
# time-stamp-format: "%:y-%02m-%02d"
melunko@47
  1578
# time-stamp-end: "'"
melunko@47
  1579
# End: