ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/config.guess
(Generate patch)

Comparing rxvt-unicode/config.guess (file contents):
Revision 1.1 by ayin, Tue Jan 17 12:19:46 2006 UTC vs.
Revision 1.3 by sf-exg, Sun Jan 31 11:34:28 2010 UTC

1#! /bin/sh 1#! /bin/sh
2# Attempt to guess a canonical system name. 2# Attempt to guess a canonical system name.
3# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 3# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. 4# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
5# Free Software Foundation, Inc.
5 6
6timestamp='2005-08-03' 7timestamp='2009-12-30'
7 8
8# This file is free software; you can redistribute it and/or modify it 9# This file is free software; you can redistribute it and/or modify it
9# under the terms of the GNU General Public License as published by 10# under the terms of the GNU General Public License as published by
10# the Free Software Foundation; either version 2 of the License, or 11# the Free Software Foundation; either version 2 of the License, or
11# (at your option) any later version. 12# (at your option) any later version.
24# distribute this file as part of a program that contains a 25# distribute this file as part of a program that contains a
25# configuration script generated by Autoconf, you may include it under 26# configuration script generated by Autoconf, you may include it under
26# the same distribution terms that you use for the rest of that program. 27# the same distribution terms that you use for the rest of that program.
27 28
28 29
29# Originally written by Per Bothner <per@bothner.com>. 30# Originally written by Per Bothner. Please send patches (context
30# Please send patches to <config-patches@gnu.org>. Submit a context 31# diff format) to <config-patches@gnu.org> and include a ChangeLog
31# diff and a properly formatted ChangeLog entry. 32# entry.
32# 33#
33# This script attempts to guess a canonical system name similar to 34# This script attempts to guess a canonical system name similar to
34# config.sub. If it succeeds, it prints the system name on stdout, and 35# config.sub. If it succeeds, it prints the system name on stdout, and
35# exits with 0. Otherwise, it exits with 1. 36# exits with 0. Otherwise, it exits with 1.
36# 37#
37# The plan is that this can be called by configure scripts if you 38# You can get the latest version of this script from:
38# don't specify an explicit build system type. 39# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
39 40
40me=`echo "$0" | sed -e 's,.*/,,'` 41me=`echo "$0" | sed -e 's,.*/,,'`
41 42
42usage="\ 43usage="\
43Usage: $0 [OPTION] 44Usage: $0 [OPTION]
53 54
54version="\ 55version="\
55GNU config.guess ($timestamp) 56GNU config.guess ($timestamp)
56 57
57Originally written by Per Bothner. 58Originally written by Per Bothner.
58Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 59Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
602001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
59Free Software Foundation, Inc. 61Software Foundation, Inc.
60 62
61This is free software; see the source for copying conditions. There is NO 63This is free software; see the source for copying conditions. There is NO
62warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." 64warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
63 65
64help=" 66help="
104 106
105set_cc_for_build=' 107set_cc_for_build='
106trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; 108trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
107trap "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" 1 2 13 15 ;
108: ${TMPDIR=/tmp} ; 110: ${TMPDIR=/tmp} ;
109 { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || 111 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
110 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || 112 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
111 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || 113 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
112 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; 114 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
113dummy=$tmp/dummy ; 115dummy=$tmp/dummy ;
114tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; 116tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
158 case "${UNAME_MACHINE_ARCH}" in 160 case "${UNAME_MACHINE_ARCH}" in
159 armeb) machine=armeb-unknown ;; 161 armeb) machine=armeb-unknown ;;
160 arm*) machine=arm-unknown ;; 162 arm*) machine=arm-unknown ;;
161 sh3el) machine=shl-unknown ;; 163 sh3el) machine=shl-unknown ;;
162 sh3eb) machine=sh-unknown ;; 164 sh3eb) machine=sh-unknown ;;
165 sh5el) machine=sh5le-unknown ;;
163 *) machine=${UNAME_MACHINE_ARCH}-unknown ;; 166 *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
164 esac 167 esac
165 # The Operating System including object format, if it has switched 168 # The Operating System including object format, if it has switched
166 # to ELF recently, or will in the future. 169 # to ELF recently, or will in the future.
167 case "${UNAME_MACHINE_ARCH}" in 170 case "${UNAME_MACHINE_ARCH}" in
168 arm*|i386|m68k|ns32k|sh3*|sparc|vax) 171 arm*|i386|m68k|ns32k|sh3*|sparc|vax)
169 eval $set_cc_for_build 172 eval $set_cc_for_build
170 if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ 173 if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
171 | grep __ELF__ >/dev/null 174 | grep -q __ELF__
172 then 175 then
173 # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). 176 # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
174 # Return netbsd for either. FIX? 177 # Return netbsd for either. FIX?
175 os=netbsd 178 os=netbsd
176 else 179 else
204 echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} 207 echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
205 exit ;; 208 exit ;;
206 *:ekkoBSD:*:*) 209 *:ekkoBSD:*:*)
207 echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} 210 echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
208 exit ;; 211 exit ;;
212 *:SolidBSD:*:*)
213 echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
214 exit ;;
209 macppc:MirBSD:*:*) 215 macppc:MirBSD:*:*)
210 echo powerppc-unknown-mirbsd${UNAME_RELEASE} 216 echo powerpc-unknown-mirbsd${UNAME_RELEASE}
211 exit ;; 217 exit ;;
212 *:MirBSD:*:*) 218 *:MirBSD:*:*)
213 echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} 219 echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
214 exit ;; 220 exit ;;
215 alpha:OSF1:*:*) 221 alpha:OSF1:*:*)
317 exit ;; 323 exit ;;
318 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) 324 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
319 case `/usr/bin/uname -p` in 325 case `/usr/bin/uname -p` in
320 sparc) echo sparc-icl-nx7; exit ;; 326 sparc) echo sparc-icl-nx7; exit ;;
321 esac ;; 327 esac ;;
328 s390x:SunOS:*:*)
329 echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
330 exit ;;
322 sun4H:SunOS:5.*:*) 331 sun4H:SunOS:5.*:*)
323 echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 332 echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
324 exit ;; 333 exit ;;
325 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) 334 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
326 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 335 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
327 exit ;; 336 exit ;;
328 i86pc:SunOS:5.*:*) 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
329 echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 354 echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
330 exit ;; 355 exit ;;
331 sun4*:SunOS:6*:*) 356 sun4*:SunOS:6*:*)
332 # According to config.sub, this is the proper way to canonicalize 357 # According to config.sub, this is the proper way to canonicalize
333 # SunOS6. Hard to guess exactly what SunOS6 will be like, but 358 # SunOS6. Hard to guess exactly what SunOS6 will be like, but
334 # it's likely to be more like Solaris than SunOS4. 359 # it's likely to be more like Solaris than SunOS4.
525 echo rs6000-ibm-aix3.2.4 550 echo rs6000-ibm-aix3.2.4
526 else 551 else
527 echo rs6000-ibm-aix3.2 552 echo rs6000-ibm-aix3.2
528 fi 553 fi
529 exit ;; 554 exit ;;
530 *:AIX:*:[45]) 555 *:AIX:*:[456])
531 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` 556 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
532 if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then 557 if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
533 IBM_ARCH=rs6000 558 IBM_ARCH=rs6000
534 else 559 else
535 IBM_ARCH=powerpc 560 IBM_ARCH=powerpc
633 # => hppa2.0w-hp-hpux11.23 658 # => hppa2.0w-hp-hpux11.23
634 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess 659 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
635 # => hppa64-hp-hpux11.23 660 # => hppa64-hp-hpux11.23
636 661
637 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | 662 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
638 grep __LP64__ >/dev/null 663 grep -q __LP64__
639 then 664 then
640 HP_ARCH="hppa2.0w" 665 HP_ARCH="hppa2.0w"
641 else 666 else
642 HP_ARCH="hppa64" 667 HP_ARCH="hppa64"
643 fi 668 fi
762 exit ;; 787 exit ;;
763 *:BSD/OS:*:*) 788 *:BSD/OS:*:*)
764 echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} 789 echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
765 exit ;; 790 exit ;;
766 *:FreeBSD:*:*) 791 *:FreeBSD:*:*)
792 case ${UNAME_MACHINE} in
793 pc98)
794 echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
795 amd64)
796 echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
797 *)
767 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` 798 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
799 esac
768 exit ;; 800 exit ;;
769 i*:CYGWIN*:*) 801 i*:CYGWIN*:*)
770 echo ${UNAME_MACHINE}-pc-cygwin 802 echo ${UNAME_MACHINE}-pc-cygwin
771 exit ;; 803 exit ;;
772 i*:MINGW*:*) 804 *:MINGW*:*)
773 echo ${UNAME_MACHINE}-pc-mingw32 805 echo ${UNAME_MACHINE}-pc-mingw32
774 exit ;; 806 exit ;;
775 i*:windows32*:*) 807 i*:windows32*:*)
776 # uname -m includes "-pc" on this system. 808 # uname -m includes "-pc" on this system.
777 echo ${UNAME_MACHINE}-mingw32 809 echo ${UNAME_MACHINE}-mingw32
778 exit ;; 810 exit ;;
779 i*:PW*:*) 811 i*:PW*:*)
780 echo ${UNAME_MACHINE}-pc-pw32 812 echo ${UNAME_MACHINE}-pc-pw32
781 exit ;; 813 exit ;;
782 x86:Interix*:[34]*) 814 *:Interix*:*)
815 case ${UNAME_MACHINE} in
816 x86)
783 echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//' 817 echo i586-pc-interix${UNAME_RELEASE}
784 exit ;; 818 exit ;;
819 authenticamd | genuineintel | EM64T)
820 echo x86_64-unknown-interix${UNAME_RELEASE}
821 exit ;;
822 IA64)
823 echo ia64-unknown-interix${UNAME_RELEASE}
824 exit ;;
825 esac ;;
785 [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) 826 [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
786 echo i${UNAME_MACHINE}-pc-mks 827 echo i${UNAME_MACHINE}-pc-mks
828 exit ;;
829 8664:Windows_NT:*)
830 echo x86_64-pc-mks
787 exit ;; 831 exit ;;
788 i*:Windows_NT*:* | Pentium*:Windows_NT*:*) 832 i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
789 # How do we know it's Interix rather than the generic POSIX subsystem? 833 # How do we know it's Interix rather than the generic POSIX subsystem?
790 # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we 834 # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
791 # UNAME_MACHINE based on the output of uname instead of i386? 835 # UNAME_MACHINE based on the output of uname instead of i386?
811 # other systems with GNU libc and userland 855 # other systems with GNU libc and userland
812 echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu 856 echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
813 exit ;; 857 exit ;;
814 i*86:Minix:*:*) 858 i*86:Minix:*:*)
815 echo ${UNAME_MACHINE}-pc-minix 859 echo ${UNAME_MACHINE}-pc-minix
816 exit ;;
817 arm*:Linux:*:*)
818 echo ${UNAME_MACHINE}-unknown-linux-gnu
819 exit ;;
820 cris:Linux:*:*)
821 echo cris-axis-linux-gnu
822 exit ;;
823 crisv32:Linux:*:*)
824 echo crisv32-axis-linux-gnu
825 exit ;;
826 frv:Linux:*:*)
827 echo frv-unknown-linux-gnu
828 exit ;;
829 ia64:Linux:*:*)
830 echo ${UNAME_MACHINE}-unknown-linux-gnu
831 exit ;;
832 m32r*:Linux:*:*)
833 echo ${UNAME_MACHINE}-unknown-linux-gnu
834 exit ;;
835 m68*:Linux:*:*)
836 echo ${UNAME_MACHINE}-unknown-linux-gnu
837 exit ;;
838 mips:Linux:*:*)
839 eval $set_cc_for_build
840 sed 's/^ //' << EOF >$dummy.c
841 #undef CPU
842 #undef mips
843 #undef mipsel
844 #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
845 CPU=mipsel
846 #else
847 #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
848 CPU=mips
849 #else
850 CPU=
851 #endif
852 #endif
853EOF
854 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
855 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
856 ;;
857 mips64:Linux:*:*)
858 eval $set_cc_for_build
859 sed 's/^ //' << EOF >$dummy.c
860 #undef CPU
861 #undef mips64
862 #undef mips64el
863 #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
864 CPU=mips64el
865 #else
866 #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
867 CPU=mips64
868 #else
869 CPU=
870 #endif
871 #endif
872EOF
873 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
874 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
875 ;;
876 or32:Linux:*:*)
877 echo or32-unknown-linux-gnu
878 exit ;;
879 ppc:Linux:*:*)
880 echo powerpc-unknown-linux-gnu
881 exit ;;
882 ppc64:Linux:*:*)
883 echo powerpc64-unknown-linux-gnu
884 exit ;; 860 exit ;;
885 alpha:Linux:*:*) 861 alpha:Linux:*:*)
886 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in 862 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
887 EV5) UNAME_MACHINE=alphaev5 ;; 863 EV5) UNAME_MACHINE=alphaev5 ;;
888 EV56) UNAME_MACHINE=alphaev56 ;; 864 EV56) UNAME_MACHINE=alphaev56 ;;
890 PCA57) UNAME_MACHINE=alphapca56 ;; 866 PCA57) UNAME_MACHINE=alphapca56 ;;
891 EV6) UNAME_MACHINE=alphaev6 ;; 867 EV6) UNAME_MACHINE=alphaev6 ;;
892 EV67) UNAME_MACHINE=alphaev67 ;; 868 EV67) UNAME_MACHINE=alphaev67 ;;
893 EV68*) UNAME_MACHINE=alphaev68 ;; 869 EV68*) UNAME_MACHINE=alphaev68 ;;
894 esac 870 esac
895 objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null 871 objdump --private-headers /bin/sh | grep -q ld.so.1
896 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi 872 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
897 echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} 873 echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
874 exit ;;
875 arm*:Linux:*:*)
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
884 exit ;;
885 avr32*:Linux:*:*)
886 echo ${UNAME_MACHINE}-unknown-linux-gnu
887 exit ;;
888 cris:Linux:*:*)
889 echo cris-axis-linux-gnu
890 exit ;;
891 crisv32:Linux:*:*)
892 echo crisv32-axis-linux-gnu
893 exit ;;
894 frv:Linux:*:*)
895 echo frv-unknown-linux-gnu
896 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 ;;
908 ia64:Linux:*:*)
909 echo ${UNAME_MACHINE}-unknown-linux-gnu
910 exit ;;
911 m32r*:Linux:*:*)
912 echo ${UNAME_MACHINE}-unknown-linux-gnu
913 exit ;;
914 m68*:Linux:*:*)
915 echo ${UNAME_MACHINE}-unknown-linux-gnu
916 exit ;;
917 mips:Linux:*:* | mips64:Linux:*:*)
918 eval $set_cc_for_build
919 sed 's/^ //' << EOF >$dummy.c
920 #undef CPU
921 #undef ${UNAME_MACHINE}
922 #undef ${UNAME_MACHINE}el
923 #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
924 CPU=${UNAME_MACHINE}el
925 #else
926 #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
927 CPU=${UNAME_MACHINE}
928 #else
929 CPU=
930 #endif
931 #endif
932EOF
933 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
934 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
935 ;;
936 or32:Linux:*:*)
937 echo or32-unknown-linux-gnu
938 exit ;;
939 padre:Linux:*:*)
940 echo sparc-unknown-linux-gnu
941 exit ;;
942 parisc64:Linux:*:* | hppa64:Linux:*:*)
943 echo hppa64-unknown-linux-gnu
898 exit ;; 944 exit ;;
899 parisc:Linux:*:* | hppa:Linux:*:*) 945 parisc:Linux:*:* | hppa:Linux:*:*)
900 # Look for CPU level 946 # Look for CPU level
901 case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in 947 case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
902 PA7*) echo hppa1.1-unknown-linux-gnu ;; 948 PA7*) echo hppa1.1-unknown-linux-gnu ;;
903 PA8*) echo hppa2.0-unknown-linux-gnu ;; 949 PA8*) echo hppa2.0-unknown-linux-gnu ;;
904 *) echo hppa-unknown-linux-gnu ;; 950 *) echo hppa-unknown-linux-gnu ;;
905 esac 951 esac
906 exit ;; 952 exit ;;
907 parisc64:Linux:*:* | hppa64:Linux:*:*) 953 ppc64:Linux:*:*)
908 echo hppa64-unknown-linux-gnu 954 echo powerpc64-unknown-linux-gnu
955 exit ;;
956 ppc:Linux:*:*)
957 echo powerpc-unknown-linux-gnu
909 exit ;; 958 exit ;;
910 s390:Linux:*:* | s390x:Linux:*:*) 959 s390:Linux:*:* | s390x:Linux:*:*)
911 echo ${UNAME_MACHINE}-ibm-linux 960 echo ${UNAME_MACHINE}-ibm-linux
912 exit ;; 961 exit ;;
913 sh64*:Linux:*:*) 962 sh64*:Linux:*:*)
917 echo ${UNAME_MACHINE}-unknown-linux-gnu 966 echo ${UNAME_MACHINE}-unknown-linux-gnu
918 exit ;; 967 exit ;;
919 sparc:Linux:*:* | sparc64:Linux:*:*) 968 sparc:Linux:*:* | sparc64:Linux:*:*)
920 echo ${UNAME_MACHINE}-unknown-linux-gnu 969 echo ${UNAME_MACHINE}-unknown-linux-gnu
921 exit ;; 970 exit ;;
971 vax:Linux:*:*)
972 echo ${UNAME_MACHINE}-dec-linux-gnu
973 exit ;;
922 x86_64:Linux:*:*) 974 x86_64:Linux:*:*)
923 echo x86_64-unknown-linux-gnu 975 echo x86_64-unknown-linux-gnu
924 exit ;; 976 exit ;;
925 i*86:Linux:*:*) 977 xtensa*:Linux:*:*)
926 # The BFD linker knows what the default object file format is, so
927 # first see if it will tell us. cd to the root directory to prevent
928 # problems with other programs or directories called `ld' in the path.
929 # Set LC_ALL=C to ensure ld outputs messages in English.
930 ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
931 | sed -ne '/supported targets:/!d
932 s/[ ][ ]*/ /g
933 s/.*supported targets: *//
934 s/ .*//
935 p'`
936 case "$ld_supported_targets" in
937 elf32-i386)
938 TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
939 ;;
940 a.out-i386-linux)
941 echo "${UNAME_MACHINE}-pc-linux-gnuaout" 978 echo ${UNAME_MACHINE}-unknown-linux-gnu
942 exit ;; 979 exit ;;
943 coff-i386)
944 echo "${UNAME_MACHINE}-pc-linux-gnucoff"
945 exit ;;
946 "")
947 # Either a pre-BFD a.out linker (linux-gnuoldld) or
948 # one that does not give us useful --help.
949 echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
950 exit ;;
951 esac
952 # Determine whether the default compiler is a.out or elf
953 eval $set_cc_for_build
954 sed 's/^ //' << EOF >$dummy.c
955 #include <features.h>
956 #ifdef __ELF__
957 # ifdef __GLIBC__
958 # if __GLIBC__ >= 2
959 LIBC=gnu
960 # else
961 LIBC=gnulibc1
962 # endif
963 # else
964 LIBC=gnulibc1
965 # endif
966 #else
967 #ifdef __INTEL_COMPILER
968 LIBC=gnu
969 #else
970 LIBC=gnuaout
971 #endif
972 #endif
973 #ifdef __dietlibc__
974 LIBC=dietlibc
975 #endif
976EOF
977 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
978 test x"${LIBC}" != x && {
979 echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
980 exit
981 }
982 test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; }
983 ;;
984 i*86:DYNIX/ptx:4*:*) 980 i*86:DYNIX/ptx:4*:*)
985 # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. 981 # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
986 # earlier versions are messed up and put the nodename in both 982 # earlier versions are messed up and put the nodename in both
987 # sysname and nodename. 983 # sysname and nodename.
988 echo i386-sequent-sysv4 984 echo i386-sequent-sysv4
1007 echo ${UNAME_MACHINE}-unknown-atheos 1003 echo ${UNAME_MACHINE}-unknown-atheos
1008 exit ;; 1004 exit ;;
1009 i*86:syllable:*:*) 1005 i*86:syllable:*:*)
1010 echo ${UNAME_MACHINE}-pc-syllable 1006 echo ${UNAME_MACHINE}-pc-syllable
1011 exit ;; 1007 exit ;;
1012 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]*:*)
1013 echo i386-unknown-lynxos${UNAME_RELEASE} 1009 echo i386-unknown-lynxos${UNAME_RELEASE}
1014 exit ;; 1010 exit ;;
1015 i*86:*DOS:*:*) 1011 i*86:*DOS:*:*)
1016 echo ${UNAME_MACHINE}-pc-msdosdjgpp 1012 echo ${UNAME_MACHINE}-pc-msdosdjgpp
1017 exit ;; 1013 exit ;;
1051 fi 1047 fi
1052 exit ;; 1048 exit ;;
1053 pc:*:*:*) 1049 pc:*:*:*)
1054 # Left here for compatibility: 1050 # Left here for compatibility:
1055 # uname -m prints for DJGPP always 'pc', but it prints nothing about 1051 # uname -m prints for DJGPP always 'pc', but it prints nothing about
1056 # the processor, so we play safe by assuming i386. 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.
1057 echo i386-pc-msdosdjgpp 1056 echo i586-pc-msdosdjgpp
1058 exit ;; 1057 exit ;;
1059 Intel:Mach:3*:*) 1058 Intel:Mach:3*:*)
1060 echo i386-pc-mach3 1059 echo i386-pc-mach3
1061 exit ;; 1060 exit ;;
1062 paragon:*:*:*) 1061 paragon:*:*:*)
1090 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ 1089 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1091 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 1090 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
1092 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) 1091 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
1093 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 1092 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1094 && { echo i486-ncr-sysv4; exit; } ;; 1093 && { 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; } ;;
1095 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) 1104 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
1096 echo m68k-unknown-lynxos${UNAME_RELEASE} 1105 echo m68k-unknown-lynxos${UNAME_RELEASE}
1097 exit ;; 1106 exit ;;
1098 mc68030:UNIX_System_V:4.*:*) 1107 mc68030:UNIX_System_V:4.*:*)
1099 echo m68k-atari-sysv4 1108 echo m68k-atari-sysv4
1102 echo sparc-unknown-lynxos${UNAME_RELEASE} 1111 echo sparc-unknown-lynxos${UNAME_RELEASE}
1103 exit ;; 1112 exit ;;
1104 rs6000:LynxOS:2.*:*) 1113 rs6000:LynxOS:2.*:*)
1105 echo rs6000-unknown-lynxos${UNAME_RELEASE} 1114 echo rs6000-unknown-lynxos${UNAME_RELEASE}
1106 exit ;; 1115 exit ;;
1107 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) 1116 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
1108 echo powerpc-unknown-lynxos${UNAME_RELEASE} 1117 echo powerpc-unknown-lynxos${UNAME_RELEASE}
1109 exit ;; 1118 exit ;;
1110 SM[BE]S:UNIX_SV:*:*) 1119 SM[BE]S:UNIX_SV:*:*)
1111 echo mips-dde-sysv${UNAME_RELEASE} 1120 echo mips-dde-sysv${UNAME_RELEASE}
1112 exit ;; 1121 exit ;;
1165 echo powerpc-apple-beos 1174 echo powerpc-apple-beos
1166 exit ;; 1175 exit ;;
1167 BePC:BeOS:*:*) # BeOS running on Intel PC compatible. 1176 BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
1168 echo i586-pc-beos 1177 echo i586-pc-beos
1169 exit ;; 1178 exit ;;
1179 BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
1180 echo i586-pc-haiku
1181 exit ;;
1170 SX-4:SUPER-UX:*:*) 1182 SX-4:SUPER-UX:*:*)
1171 echo sx4-nec-superux${UNAME_RELEASE} 1183 echo sx4-nec-superux${UNAME_RELEASE}
1172 exit ;; 1184 exit ;;
1173 SX-5:SUPER-UX:*:*) 1185 SX-5:SUPER-UX:*:*)
1174 echo sx5-nec-superux${UNAME_RELEASE} 1186 echo sx5-nec-superux${UNAME_RELEASE}
1175 exit ;; 1187 exit ;;
1176 SX-6:SUPER-UX:*:*) 1188 SX-6:SUPER-UX:*:*)
1177 echo sx6-nec-superux${UNAME_RELEASE} 1189 echo sx6-nec-superux${UNAME_RELEASE}
1190 exit ;;
1191 SX-7:SUPER-UX:*:*)
1192 echo sx7-nec-superux${UNAME_RELEASE}
1193 exit ;;
1194 SX-8:SUPER-UX:*:*)
1195 echo sx8-nec-superux${UNAME_RELEASE}
1196 exit ;;
1197 SX-8R:SUPER-UX:*:*)
1198 echo sx8r-nec-superux${UNAME_RELEASE}
1178 exit ;; 1199 exit ;;
1179 Power*:Rhapsody:*:*) 1200 Power*:Rhapsody:*:*)
1180 echo powerpc-apple-rhapsody${UNAME_RELEASE} 1201 echo powerpc-apple-rhapsody${UNAME_RELEASE}
1181 exit ;; 1202 exit ;;
1182 *:Rhapsody:*:*) 1203 *:Rhapsody:*:*)
1183 echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} 1204 echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
1184 exit ;; 1205 exit ;;
1185 *:Darwin:*:*) 1206 *:Darwin:*:*)
1186 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown 1207 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
1187 case $UNAME_PROCESSOR in 1208 case $UNAME_PROCESSOR in
1188 *86) UNAME_PROCESSOR=i686 ;; 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 ;;
1189 unknown) UNAME_PROCESSOR=powerpc ;; 1219 unknown) UNAME_PROCESSOR=powerpc ;;
1190 esac 1220 esac
1191 echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} 1221 echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
1192 exit ;; 1222 exit ;;
1193 *:procnto*:*:* | *:QNX:[0123456789]*:*) 1223 *:procnto*:*:* | *:QNX:[0123456789]*:*)
1261 *:XENIX:*:SysV) 1291 *:XENIX:*:SysV)
1262 echo i386-pc-xenix 1292 echo i386-pc-xenix
1263 exit ;; 1293 exit ;;
1264 i*86:skyos:*:*) 1294 i*86:skyos:*:*)
1265 echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' 1295 echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
1296 exit ;;
1297 i*86:rdos:*:*)
1298 echo ${UNAME_MACHINE}-pc-rdos
1299 exit ;;
1300 i*86:AROS:*:*)
1301 echo ${UNAME_MACHINE}-pc-aros
1266 exit ;; 1302 exit ;;
1267esac 1303esac
1268 1304
1269#echo '(No uname command or uname output not recognized.)' 1>&2 1305#echo '(No uname command or uname output not recognized.)' 1>&2
1270#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 1306#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
1422 1458
1423This script, last modified $timestamp, has failed to recognize 1459This script, last modified $timestamp, has failed to recognize
1424the operating system you are using. It is advised that you 1460the operating system you are using. It is advised that you
1425download the most up to date version of the config scripts from 1461download the most up to date version of the config scripts from
1426 1462
1427 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
1428and 1464and
1429 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
1430 1466
1431If the version you run ($0) is already up to date, please 1467If the version you run ($0) is already up to date, please
1432send the following data and any information you think might be 1468send the following data and any information you think might be
1433pertinent to <config-patches@gnu.org> in order to provide the needed 1469pertinent to <config-patches@gnu.org> in order to provide the needed
1434information to handle your system. 1470information to handle your system.

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines