Date:2010-07-20 15:21:00 (13 years 8 months ago)
Author:kaloz
Commit:e9b1c9936ab90ce3b22575985da89775d2c953f9
Message:upgrade the config.* scripts

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22312 3c298f89-4303-0410-b956-a3cf2f4a3e73
Files: scripts/config.guess (23 diffs)
scripts/config.sub (28 diffs)

Change Details

scripts/config.guess
11#! /bin/sh
22# Attempt to guess a canonical system name.
33# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
5# Inc.
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
5# Free Software Foundation, Inc.
66
7timestamp='2007-05-17'
7timestamp='2010-04-03'
88
99# This file is free software; you can redistribute it and/or modify it
1010# under the terms of the GNU General Public License as published by
...... 
2727# the same distribution terms that you use for the rest of that program.
2828
2929
30# Originally written by Per Bothner <per@bothner.com>.
31# Please send patches to <config-patches@gnu.org>. Submit a context
32# diff and a properly formatted ChangeLog entry.
30# Originally written by Per Bothner. Please send patches (context
31# diff format) to <config-patches@gnu.org> and include a ChangeLog
32# entry.
3333#
3434# This script attempts to guess a canonical system name similar to
3535# config.sub. If it succeeds, it prints the system name on stdout, and
3636# exits with 0. Otherwise, it exits with 1.
3737#
38# The plan is that this can be called by configure scripts if you
39# don't specify an explicit build system type.
38# You can get the latest version of this script from:
39# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
4040
4141me=`echo "$0" | sed -e 's,.*/,,'`
4242
...... 
5656GNU config.guess ($timestamp)
5757
5858Originally written by Per Bothner.
59Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
60Free Software Foundation, Inc.
59Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
602001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
61Software Foundation, Inc.
6162
6263This is free software; see the source for copying conditions. There is NO
6364warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
...... 
9192  exit 1
9293fi
9394
94trap 'exit 1' 1 2 15
95trap 'exit 1' HUP INT TERM
9596
9697# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
9798# compiler to aid in system detection is discouraged as it requires
...... 
105106
106107set_cc_for_build='
107108trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
108trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
109trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" HUP INT PIPE TERM ;
109110: ${TMPDIR=/tmp} ;
110111 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
111112 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
...... 
170171        arm*|i386|m68k|ns32k|sh3*|sparc|vax)
171172        eval $set_cc_for_build
172173        if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
173            | grep __ELF__ >/dev/null
174            | grep -q __ELF__
174175        then
175176            # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
176177            # Return netbsd for either. FIX?
...... 
324325    case `/usr/bin/uname -p` in
325326        sparc) echo sparc-icl-nx7; exit ;;
326327    esac ;;
328    s390x:SunOS:*:*)
329    echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
330    exit ;;
327331    sun4H:SunOS:5.*:*)
328332    echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
329333    exit ;;
330334    sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
331335    echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
332336    exit ;;
333    i86pc:SunOS:5.*:* | ix86xen:SunOS:5.*:*)
334    echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
337    i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
338    echo i386-pc-auroraux${UNAME_RELEASE}
339    exit ;;
340    i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
341    eval $set_cc_for_build
342    SUN_ARCH="i386"
343    # If there is a compiler, see if it is configured for 64-bit objects.
344    # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
345    # This test works for both compilers.
346    if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
347        if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
348        (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
349        grep IS_64BIT_ARCH >/dev/null
350        then
351        SUN_ARCH="x86_64"
352        fi
353    fi
354    echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
335355    exit ;;
336356    sun4*:SunOS:6*:*)
337357    # According to config.sub, this is the proper way to canonicalize
...... 
532552        echo rs6000-ibm-aix3.2
533553    fi
534554    exit ;;
535    *:AIX:*:[45])
555    *:AIX:*:[456])
536556    IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
537557    if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
538558        IBM_ARCH=rs6000
...... 
640660        # => hppa64-hp-hpux11.23
641661
642662        if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
643        grep __LP64__ >/dev/null
663        grep -q __LP64__
644664        then
645665        HP_ARCH="hppa2.0w"
646666        else
...... 
791811    i*:PW*:*)
792812    echo ${UNAME_MACHINE}-pc-pw32
793813    exit ;;
794    *:Interix*:[3456]*)
814    *:Interix*:*)
795815        case ${UNAME_MACHINE} in
796        x86)
816        x86)
797817        echo i586-pc-interix${UNAME_RELEASE}
798818        exit ;;
799        EM64T | authenticamd)
819        authenticamd | genuineintel | EM64T)
800820        echo x86_64-unknown-interix${UNAME_RELEASE}
801821        exit ;;
822        IA64)
823        echo ia64-unknown-interix${UNAME_RELEASE}
824        exit ;;
802825    esac ;;
803826    [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
804827    echo i${UNAME_MACHINE}-pc-mks
805828    exit ;;
829    8664:Windows_NT:*)
830    echo x86_64-pc-mks
831    exit ;;
806832    i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
807833    # How do we know it's Interix rather than the generic POSIX subsystem?
808834    # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
...... 
832858    i*86:Minix:*:*)
833859    echo ${UNAME_MACHINE}-pc-minix
834860    exit ;;
861    alpha:Linux:*:*)
862    case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
863      EV5) UNAME_MACHINE=alphaev5 ;;
864      EV56) UNAME_MACHINE=alphaev56 ;;
865      PCA56) UNAME_MACHINE=alphapca56 ;;
866      PCA57) UNAME_MACHINE=alphapca56 ;;
867      EV6) UNAME_MACHINE=alphaev6 ;;
868      EV67) UNAME_MACHINE=alphaev67 ;;
869      EV68*) UNAME_MACHINE=alphaev68 ;;
870        esac
871    objdump --private-headers /bin/sh | grep -q ld.so.1
872    if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
873    echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
874    exit ;;
835875    arm*:Linux:*:*)
836    echo ${UNAME_MACHINE}-unknown-linux-gnu
876    eval $set_cc_for_build
877    if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
878        | grep -q __ARM_EABI__
879    then
880        echo ${UNAME_MACHINE}-unknown-linux-gnu
881    else
882        echo ${UNAME_MACHINE}-unknown-linux-gnueabi
883    fi
837884    exit ;;
838885    avr32*:Linux:*:*)
839886    echo ${UNAME_MACHINE}-unknown-linux-gnu
...... 
847894    frv:Linux:*:*)
848895        echo frv-unknown-linux-gnu
849896    exit ;;
897    i*86:Linux:*:*)
898    LIBC=gnu
899    eval $set_cc_for_build
900    sed 's/^ //' << EOF >$dummy.c
901    #ifdef __dietlibc__
902    LIBC=dietlibc
903    #endif
904EOF
905    eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
906    echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
907    exit ;;
850908    ia64:Linux:*:*)
851909    echo ${UNAME_MACHINE}-unknown-linux-gnu
852910    exit ;;
...... 
856914    m68*:Linux:*:*)
857915    echo ${UNAME_MACHINE}-unknown-linux-gnu
858916    exit ;;
859    mips:Linux:*:*)
917    mips:Linux:*:* | mips64:Linux:*:*)
860918    eval $set_cc_for_build
861919    sed 's/^ //' << EOF >$dummy.c
862920    #undef CPU
863    #undef mips
864    #undef mipsel
921    #undef ${UNAME_MACHINE}
922    #undef ${UNAME_MACHINE}el
865923    #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
866    CPU=mipsel
924    CPU=${UNAME_MACHINE}el
867925    #else
868926    #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
869    CPU=mips
927    CPU=${UNAME_MACHINE}
870928    #else
871929    CPU=
872930    #endif
873931    #endif
874932EOF
875    eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
876        /^CPU/{
877        s: ::g
878        p
879        }'`"
880    test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
881    ;;
882    mips64:Linux:*:*)
883    eval $set_cc_for_build
884    sed 's/^ //' << EOF >$dummy.c
885    #undef CPU
886    #undef mips64
887    #undef mips64el
888    #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
889    CPU=mips64el
890    #else
891    #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
892    CPU=mips64
893    #else
894    CPU=
895    #endif
896    #endif
897EOF
898    eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
899        /^CPU/{
900        s: ::g
901        p
902        }'`"
933    eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
903934    test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
904935    ;;
905936    or32:Linux:*:*)
906937    echo or32-unknown-linux-gnu
907938    exit ;;
908    ppc:Linux:*:*)
909    echo powerpc-unknown-linux-gnu
910    exit ;;
911    ppc64:Linux:*:*)
912    echo powerpc64-unknown-linux-gnu
939    padre:Linux:*:*)
940    echo sparc-unknown-linux-gnu
913941    exit ;;
914    alpha:Linux:*:*)
915    case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
916      EV5) UNAME_MACHINE=alphaev5 ;;
917      EV56) UNAME_MACHINE=alphaev56 ;;
918      PCA56) UNAME_MACHINE=alphapca56 ;;
919      PCA57) UNAME_MACHINE=alphapca56 ;;
920      EV6) UNAME_MACHINE=alphaev6 ;;
921      EV67) UNAME_MACHINE=alphaev67 ;;
922      EV68*) UNAME_MACHINE=alphaev68 ;;
923        esac
924    objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
925    if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
926    echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
942    parisc64:Linux:*:* | hppa64:Linux:*:*)
943    echo hppa64-unknown-linux-gnu
927944    exit ;;
928945    parisc:Linux:*:* | hppa:Linux:*:*)
929946    # Look for CPU level
...... 
933950      *) echo hppa-unknown-linux-gnu ;;
934951    esac
935952    exit ;;
936    parisc64:Linux:*:* | hppa64:Linux:*:*)
937    echo hppa64-unknown-linux-gnu
953    ppc64:Linux:*:*)
954    echo powerpc64-unknown-linux-gnu
955    exit ;;
956    ppc:Linux:*:*)
957    echo powerpc-unknown-linux-gnu
938958    exit ;;
939959    s390:Linux:*:* | s390x:Linux:*:*)
940960    echo ${UNAME_MACHINE}-ibm-linux
...... 
954974    x86_64:Linux:*:*)
955975    echo x86_64-unknown-linux-gnu
956976    exit ;;
957    xtensa:Linux:*:*)
958        echo xtensa-unknown-linux-gnu
977    xtensa*:Linux:*:*)
978        echo ${UNAME_MACHINE}-unknown-linux-gnu
959979    exit ;;
960    i*86:Linux:*:*)
961    # The BFD linker knows what the default object file format is, so
962    # first see if it will tell us. cd to the root directory to prevent
963    # problems with other programs or directories called `ld' in the path.
964    # Set LC_ALL=C to ensure ld outputs messages in English.
965    ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
966             | sed -ne '/supported targets:/!d
967                    s/[ ][ ]*/ /g
968                    s/.*supported targets: *//
969                    s/ .*//
970                    p'`
971        case "$ld_supported_targets" in
972      elf32-i386)
973        TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
974        ;;
975      a.out-i386-linux)
976        echo "${UNAME_MACHINE}-pc-linux-gnuaout"
977        exit ;;
978      coff-i386)
979        echo "${UNAME_MACHINE}-pc-linux-gnucoff"
980        exit ;;
981      "")
982        # Either a pre-BFD a.out linker (linux-gnuoldld) or
983        # one that does not give us useful --help.
984        echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
985        exit ;;
986    esac
987    # Determine whether the default compiler is a.out or elf
988    eval $set_cc_for_build
989    sed 's/^ //' << EOF >$dummy.c
990    #include <features.h>
991    #ifdef __ELF__
992    # ifdef __GLIBC__
993    # if __GLIBC__ >= 2
994    LIBC=gnu
995    # else
996    LIBC=gnulibc1
997    # endif
998    # else
999    LIBC=gnulibc1
1000    # endif
1001    #else
1002    #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)
1003    LIBC=gnu
1004    #else
1005    LIBC=gnuaout
1006    #endif
1007    #endif
1008    #ifdef __dietlibc__
1009    LIBC=dietlibc
1010    #endif
1011EOF
1012    eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
1013        /^LIBC/{
1014        s: ::g
1015        p
1016        }'`"
1017    test x"${LIBC}" != x && {
1018        echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
1019        exit
1020    }
1021    test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; }
1022    ;;
1023980    i*86:DYNIX/ptx:4*:*)
1024981    # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
1025982    # earlier versions are messed up and put the nodename in both
...... 
10481005    i*86:syllable:*:*)
10491006    echo ${UNAME_MACHINE}-pc-syllable
10501007    exit ;;
1051    i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
1008    i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
10521009    echo i386-unknown-lynxos${UNAME_RELEASE}
10531010    exit ;;
10541011    i*86:*DOS:*:*)
...... 
10921049    pc:*:*:*)
10931050    # Left here for compatibility:
10941051        # uname -m prints for DJGPP always 'pc', but it prints nothing about
1095        # the processor, so we play safe by assuming i386.
1096    echo i386-pc-msdosdjgpp
1052        # the processor, so we play safe by assuming i586.
1053    # Note: whatever this is, it MUST be the same as what config.sub
1054    # prints for the "djgpp" host, or else GDB configury will decide that
1055    # this is a cross-build.
1056    echo i586-pc-msdosdjgpp
10971057        exit ;;
10981058    Intel:Mach:3*:*)
10991059    echo i386-pc-mach3
...... 
11311091    3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
11321092        /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
11331093          && { echo i486-ncr-sysv4; exit; } ;;
1094    NCR*:*:4.2:* | MPRAS*:*:4.2:*)
1095    OS_REL='.3'
1096    test -r /etc/.relid \
1097        && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1098    /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1099        && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
1100    /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1101        && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
1102    /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
1103        && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
11341104    m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
11351105    echo m68k-unknown-lynxos${UNAME_RELEASE}
11361106    exit ;;
...... 
11431113    rs6000:LynxOS:2.*:*)
11441114    echo rs6000-unknown-lynxos${UNAME_RELEASE}
11451115    exit ;;
1146    PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
1116    PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
11471117    echo powerpc-unknown-lynxos${UNAME_RELEASE}
11481118    exit ;;
11491119    SM[BE]S:UNIX_SV:*:*)
...... 
12061176    BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
12071177    echo i586-pc-beos
12081178    exit ;;
1179    BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
1180    echo i586-pc-haiku
1181    exit ;;
12091182    SX-4:SUPER-UX:*:*)
12101183    echo sx4-nec-superux${UNAME_RELEASE}
12111184    exit ;;
...... 
12331206    *:Darwin:*:*)
12341207    UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
12351208    case $UNAME_PROCESSOR in
1209        i386)
1210        eval $set_cc_for_build
1211        if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
1212          if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
1213              (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
1214              grep IS_64BIT_ARCH >/dev/null
1215          then
1216              UNAME_PROCESSOR="x86_64"
1217          fi
1218        fi ;;
12361219        unknown) UNAME_PROCESSOR=powerpc ;;
12371220    esac
12381221    echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
...... 
13141297    i*86:rdos:*:*)
13151298    echo ${UNAME_MACHINE}-pc-rdos
13161299    exit ;;
1300    i*86:AROS:*:*)
1301    echo ${UNAME_MACHINE}-pc-aros
1302    exit ;;
13171303esac
13181304
13191305#echo '(No uname command or uname output not recognized.)' 1>&2
...... 
14741460the operating system you are using. It is advised that you
14751461download the most up to date version of the config scripts from
14761462
1477  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess
1463  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
14781464and
1479  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub
1465  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
14801466
14811467If the version you run ($0) is already up to date, please
14821468send the following data and any information you think might be
scripts/config.sub
11#! /bin/sh
22# Configuration validation subroutine script.
33# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
5# Inc.
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
5# Free Software Foundation, Inc.
66
7timestamp='2007-04-29'
7timestamp='2010-05-21'
88
99# This file is (in principle) common to ALL GNU software.
1010# The presence of a machine in this file suggests that SOME GNU software
...... 
3232
3333
3434# Please send patches to <config-patches@gnu.org>. Submit a context
35# diff and a properly formatted ChangeLog entry.
35# diff and a properly formatted GNU ChangeLog entry.
3636#
3737# Configuration subroutine to validate and canonicalize a configuration type.
3838# Supply the specified configuration type as an argument.
3939# If it is invalid, we print an error message on stderr and exit with code 1.
4040# Otherwise, we print the canonical config type on stdout and succeed.
4141
42# You can get the latest version of this script from:
43# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
44
4245# This file is supposed to be the same for all GNU packages
4346# and recognize all the CPU types, system types and aliases
4447# that are meaningful with *any* GNU software.
...... 
7275version="\
7376GNU config.sub ($timestamp)
7477
75Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
76Free Software Foundation, Inc.
78Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
792001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
80Software Foundation, Inc.
7781
7882This is free software; see the source for copying conditions. There is NO
7983warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
...... 
120124# Here we must recognize all the valid KERNEL-OS combinations.
121125maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
122126case $maybe_os in
123  nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
124  uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
127  nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
128  linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
129  knetbsd*-gnu* | netbsd*-gnu* | \
130  kopensolaris*-gnu* | \
125131  storm-chaos* | os2-emx* | rtmk-nova*)
126132    os=-$maybe_os
127133    basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
...... 
148154    -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
149155    -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
150156    -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
151    -apple | -axis | -knuth | -cray)
157    -apple | -axis | -knuth | -cray | -microblaze)
152158        os=
153159        basic_machine=$1
154160        ;;
161        -bluegene*)
162            os=-cnk
163        ;;
155164    -sim | -cisco | -oki | -wec | -winbond)
156165        os=
157166        basic_machine=$1
...... 
249258    | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
250259    | i370 | i860 | i960 | ia64 \
251260    | ip2k | iq2000 \
261    | lm32 \
252262    | m32c | m32r | m32rle | m68000 | m68k | m88k \
253    | maxq | mb | microblaze | mcore | mep \
263    | maxq | mb | microblaze | mcore | mep | metag \
254264    | mips | mipsbe | mipseb | mipsel | mipsle \
255265    | mips16 \
256266    | mips64 | mips64el \
257    | mips64vr | mips64vrel \
267    | mips64octeon | mips64octeonel \
258268    | mips64orion | mips64orionel \
269    | mips64r5900 | mips64r5900el \
270    | mips64vr | mips64vrel \
259271    | mips64vr4100 | mips64vr4100el \
260272    | mips64vr4300 | mips64vr4300el \
261273    | mips64vr5000 | mips64vr5000el \
...... 
268280    | mipsisa64sr71k | mipsisa64sr71kel \
269281    | mipstx39 | mipstx39el \
270282    | mn10200 | mn10300 \
283    | moxie \
271284    | mt \
272285    | msp430 \
273286    | nios | nios2 \
...... 
276289    | pdp10 | pdp11 | pj | pjl \
277290    | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
278291    | pyramid \
292    | rx \
279293    | score \
280    | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
294    | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
281295    | sh64 | sh64le \
282296    | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
283297    | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
284298    | spu | strongarm \
285    | tahoe | thumb | tic4x | tic80 | tron \
286    | v850 | v850e \
299    | tahoe | thumb | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
287300    | ubicom32 \
301    | v850 | v850e \
288302    | we32k \
289303    | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
290    | z8k)
304    | z8k | z80)
291305        basic_machine=$basic_machine-unknown
292306        ;;
293    m6811 | m68hc11 | m6812 | m68hc12)
307    c54x)
308        basic_machine=tic54x-unknown
309        ;;
310    c55x)
311        basic_machine=tic55x-unknown
312        ;;
313    c6x)
314        basic_machine=tic6x-unknown
315        ;;
316    m6811 | m68hc11 | m6812 | m68hc12 | picochip)
294317        # Motorola 68HC11/12.
295318        basic_machine=$basic_machine-unknown
296319        os=-none
...... 
321344    | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
322345    | avr-* | avr32-* \
323346    | bfin-* | bs2000-* \
324    | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
347    | c[123]* | c30-* | [cjt]90-* | c4x-* \
325348    | clipper-* | craynv-* | cydra-* \
326349    | d10v-* | d30v-* | dlx-* \
327350    | elxsi-* \
...... 
330353    | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
331354    | i*86-* | i860-* | i960-* | ia64-* \
332355    | ip2k-* | iq2000-* \
356    | lm32-* \
333357    | m32c-* | m32r-* | m32rle-* \
334358    | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
335    | m88110-* | m88k-* | maxq-* | mcore-* \
359    | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
336360    | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
337361    | mips16-* \
338362    | mips64-* | mips64el-* \
339    | mips64vr-* | mips64vrel-* \
363    | mips64octeon-* | mips64octeonel-* \
340364    | mips64orion-* | mips64orionel-* \
365    | mips64r5900-* | mips64r5900el-* \
366    | mips64vr-* | mips64vrel-* \
341367    | mips64vr4100-* | mips64vr4100el-* \
342368    | mips64vr4300-* | mips64vr4300el-* \
343369    | mips64vr5000-* | mips64vr5000el-* \
...... 
358384    | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
359385    | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
360386    | pyramid-* \
361    | romp-* | rs6000-* \
362    | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
387    | romp-* | rs6000-* | rx-* \
388    | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
363389    | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
364390    | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
365391    | sparclite-* \
366392    | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
367393    | tahoe-* | thumb-* \
368394    | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
395    | tile-* | tilegx-* \
369396    | tron-* \
370    | v850-* | v850e-* | vax-* \
371397    | ubicom32-* \
398    | v850-* | v850e-* | vax-* \
372399    | we32k-* \
373400    | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
374    | xstormy16-* | xtensa-* \
401    | xstormy16-* | xtensa*-* \
375402    | ymp-* \
376    | z8k-*)
403    | z8k-* | z80-*)
404        ;;
405    # Recognize the basic CPU types without company name, with glob match.
406    xtensa*)
407        basic_machine=$basic_machine-unknown
377408        ;;
378409    # Recognize the various machine names and aliases which stand
379410    # for a CPU type and a company and sometimes even an OS.
...... 
437468        basic_machine=m68k-apollo
438469        os=-bsd
439470        ;;
471    aros)
472        basic_machine=i386-pc
473        os=-aros
474        ;;
440475    aux)
441476        basic_machine=m68k-apple
442477        os=-aux
...... 
445480        basic_machine=ns32k-sequent
446481        os=-dynix
447482        ;;
483    blackfin)
484        basic_machine=bfin-unknown
485        os=-linux
486        ;;
487    blackfin-*)
488        basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
489        os=-linux
490        ;;
491    bluegene*)
492        basic_machine=powerpc-ibm
493        os=-cnk
494        ;;
495    c54x-*)
496        basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'`
497        ;;
498    c55x-*)
499        basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'`
500        ;;
501    c6x-*)
502        basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'`
503        ;;
448504    c90)
449505        basic_machine=c90-cray
450506        os=-unicos
451507        ;;
508        cegcc)
509        basic_machine=arm-unknown
510        os=-cegcc
511        ;;
452512    convex-c1)
453513        basic_machine=c1-convex
454514        os=-bsd
...... 
477537        basic_machine=craynv-cray
478538        os=-unicosmp
479539        ;;
480    cr16c)
481        basic_machine=cr16c-unknown
540    cr16)
541        basic_machine=cr16-unknown
482542        os=-elf
483543        ;;
484544    crds | unos)
...... 
516576        basic_machine=m88k-motorola
517577        os=-sysv3
518578        ;;
579    dicos)
580        basic_machine=i686-pc
581        os=-dicos
582        ;;
519583    djgpp)
520584        basic_machine=i586-pc
521585        os=-msdosdjgpp
...... 
670734        basic_machine=m68k-isi
671735        os=-sysv
672736        ;;
737    m68knommu)
738        basic_machine=m68k-unknown
739        os=-linux
740        ;;
741    m68knommu-*)
742        basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
743        os=-linux
744        ;;
673745    m88k-omron*)
674746        basic_machine=m88k-omron
675747        ;;
...... 
681753        basic_machine=ns32k-utek
682754        os=-sysv
683755        ;;
756        microblaze)
757        basic_machine=microblaze-xilinx
758        ;;
684759    mingw32)
685760        basic_machine=i386-pc
686761        os=-mingw32
...... 
815890        basic_machine=i860-intel
816891        os=-osf
817892        ;;
893    parisc)
894        basic_machine=hppa-unknown
895        os=-linux
896        ;;
897    parisc-*)
898        basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
899        os=-linux
900        ;;
818901    pbd)
819902        basic_machine=sparc-tti
820903        ;;
...... 
10111094        basic_machine=t90-cray
10121095        os=-unicos
10131096        ;;
1014    tic54x | c54x*)
1015        basic_machine=tic54x-unknown
1016        os=-coff
1017        ;;
1018    tic55x | c55x*)
1019        basic_machine=tic55x-unknown
1020        os=-coff
1097        # This must be matched before tile*.
1098        tilegx*)
1099        basic_machine=tilegx-unknown
1100        os=-linux-gnu
10211101        ;;
1022    tic6x | c6x*)
1023        basic_machine=tic6x-unknown
1024        os=-coff
1102    tile*)
1103        basic_machine=tile-unknown
1104        os=-linux-gnu
10251105        ;;
10261106    tx39)
10271107        basic_machine=mipstx39-unknown
...... 
10981178        basic_machine=z8k-unknown
10991179        os=-sim
11001180        ;;
1181    z80-*-coff)
1182        basic_machine=z80-unknown
1183        os=-sim
1184        ;;
11011185    none)
11021186        basic_machine=none-none
11031187        os=-none
...... 
11361220    we32k)
11371221        basic_machine=we32k-att
11381222        ;;
1139    sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
1223    sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
11401224        basic_machine=sh-unknown
11411225        ;;
11421226    sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
...... 
11861270        # First match some system type aliases
11871271        # that might get confused with valid system types.
11881272    # -solaris* is a basic system type, with this one exception.
1273        -auroraux)
1274            os=-auroraux
1275        ;;
11891276    -solaris1 | -solaris1.*)
11901277        os=`echo $os | sed -e 's|solaris1|sunos4|'`
11911278        ;;
...... 
12061293    # Each alternative MUST END IN A *, to match a version number.
12071294    # -sysv* is not here because it comes later, after sysvr4.
12081295    -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
1209          | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
1210          | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
1296          | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
1297          | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
1298          | -sym* | -kopensolaris* \
12111299          | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
1212          | -aos* \
1300          | -aos* | -aros* \
12131301          | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
12141302          | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
12151303          | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
...... 
12181306          | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
12191307          | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
12201308          | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
1221          | -chorusos* | -chorusrdb* \
1309          | -chorusos* | -chorusrdb* | -cegcc* \
12221310          | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
1223          | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
1311          | -mingw32* | -linux-gnu* | -linux-android* \
1312          | -linux-newlib* | -linux-uclibc* \
12241313          | -uxpv* | -beos* | -mpeix* | -udk* \
12251314          | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
12261315          | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
...... 
12281317          | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
12291318          | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
12301319          | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
1231          | -skyos* | -haiku* | -rdos* | -toppers* | -drops*)
1320          | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
12321321    # Remember, each alternative MUST END IN *, to match a version number.
12331322        ;;
12341323    -qnx*)
...... 
13581447    -zvmoe)
13591448        os=-zvmoe
13601449        ;;
1450    -dicos*)
1451        os=-dicos
1452        ;;
1453        -nacl*)
1454            ;;
13611455    -none)
13621456        ;;
13631457    *)
...... 
13981492        c4x-* | tic4x-*)
13991493            os=-coff
14001494        ;;
1495    tic54x-*)
1496        os=-coff
1497        ;;
1498    tic55x-*)
1499        os=-coff
1500        ;;
1501    tic6x-*)
1502        os=-coff
1503        ;;
14011504    # This must come before the *-dec entry.
14021505    pdp10-*)
14031506        os=-tops20
...... 
15551658            -sunos*)
15561659                vendor=sun
15571660                ;;
1558            -aix*)
1661            -cnk*|-aix*)
15591662                vendor=ibm
15601663                ;;
15611664            -beos*)

Archive Download the corresponding diff file



interactive