X-Git-Url: https://git.openssl.org/?p=openssl.git;a=blobdiff_plain;f=config;h=2e02ae36918c185c4e4817f6904b166ad3f5ed14;hp=fb24a5dea3aa780c4125e200083def29cd2d693b;hb=3c82e437bb3af822ea13cd5a24bab0745c556246;hpb=a87c159f19e998bba660ceba9d01c5fc58bfa60b diff --git a/config b/config index fb24a5dea3..2e02ae3691 100755 --- a/config +++ b/config @@ -1,25 +1,15 @@ #!/bin/sh +# Copyright 1998-2016 The OpenSSL Project Authors. All Rights Reserved. # +# Licensed under the OpenSSL license (the "License"). You may not use +# this file except in compliance with the License. You can obtain a copy +# in the file LICENSE in the source distribution or at +# https://www.openssl.org/source/license.html + # OpenSSL config: determine the operating system and run ./Configure +# Derived from minarch and GuessOS from Apache. # -# "config -h" for usage information. -# -# this is a merge of minarch and GuessOS from the Apache Group. -# Originally written by Tim Hudson . - -# Original Apache Group comments on GuessOS - -# Simple OS/Platform guesser. Similar to config.guess but -# much, much smaller. Since it was developed for use with -# Apache, it follows under Apache's regular licensing -# with one specific addition: Any changes or additions -# to this script should be Emailed to the Apache -# group (apache@apache.org) in general and to -# Jim Jagielski (jim@jaguNET.com) in specific. -# -# Be as similar to the output of config.guess/config.sub -# as possible. - +# Do "config -h" for usage information. SUFFIX="" TEST="false" EXE="" @@ -134,10 +124,6 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in esac ;; - IRIX:5.*) - echo "mips2-sgi-irix"; exit 0 - ;; - IRIX:6.*) echo "mips3-sgi-irix"; exit 0 ;; @@ -202,6 +188,10 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in echo "${MACHINE}-whatever-freebsd"; exit 0 ;; + Haiku:*) + echo "${MACHINE}-whatever-haiku"; exit 0 + ;; + NetBSD:*:*:*386*) echo "`(/usr/sbin/sysctl -n hw.model || /sbin/sysctl -n hw.model) | sed 's,.*\(.\)86-class.*,i\186,'`-whatever-netbsd"; exit 0 ;; @@ -261,6 +251,9 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in Power*) echo "ppc-apple-darwin${VERSION}" ;; + x86_64) + echo "x86_64-apple-darwin${VERSION}" + ;; *) echo "i686-apple-darwin${VERSION}" ;; @@ -457,14 +450,6 @@ case "$GUESSOS" in uClinux*) OUT=uClinux-dist ;; - mips2-sgi-irix) - CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'` - CPU=${CPU:-0} - if [ $CPU -ge 4000 ]; then - options="$options -mips2" - fi - OUT="irix-$CC" - ;; mips3-sgi-irix) #CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'` #CPU=${CPU:-0} @@ -511,7 +496,7 @@ case "$GUESSOS" in ISA64=`(sysctl -n hw.optional.x86_64) 2>/dev/null` if [ "$ISA64" = "1" -a -z "$KERNEL_BITS" ]; then echo "WARNING! If you wish to build 64-bit library, then you have to" - echo " invoke '$THERE/Configure darwin64-x86_64-cc $options' *manually*." + echo " invoke 'KERNEL_BITS=64 $THERE/config $options'." if [ "$TEST" = "false" -a -t 1 ]; then echo " You have about 5 seconds to press Ctrl-C to abort." # The stty technique used elsewhere doesn't work on @@ -524,6 +509,22 @@ case "$GUESSOS" in else OUT="darwin-i386-cc" fi ;; + x86_64-apple-darwin*) + if [ -z "$KERNEL_BITS" ]; then + echo "WARNING! If you wish to build 32-bit library, then you have to" + echo " invoke 'KERNEL_BITS=32 $THERE/config $options'." + if [ "$TEST" = "false" -a -t 1 ]; then + echo " You have about 5 seconds to press Ctrl-C to abort." + # The stty technique used elsewhere doesn't work on + # MacOS. At least, right now on this Mac. + sleep 5 + fi + fi + if [ "$KERNEL_BITS" = "32" ]; then + OUT="darwin-i386-cc" + else + OUT="darwin64-x86_64-cc" + fi ;; armv6+7-*-iphoneos) options="$options -arch%20armv6 -arch%20armv7" OUT="iphoneos-cross" ;; @@ -724,6 +725,8 @@ case "$GUESSOS" in *ELF*) OUT="BSD-x86-elf" ;; *) OUT="BSD-x86"; options="$options no-sse2" ;; esac ;; + x86_64-*-haiku) OUT="haiku-x86_64" ;; + *-*-haiku) OUT="haiku-x86" ;; *-*-*bsd*) OUT="BSD-generic32" ;; *-*-osf) OUT="osf1-alpha-cc" ;; @@ -767,8 +770,13 @@ case "$GUESSOS" in (trap "stty `stty -g`; exit 0" 2 0; stty -icanon min 0 time 50; read waste) <&1 fi fi + # PA-RISC 2.0 is no longer supported as separate 32-bit + # target. This is compensated for by run-time detection + # in most critical assembly modules and taking advantage + # of 2.0 architecture in PA-RISC 1.1 build. + OUT="hpux-parisc1_1-${CC}" elif [ $CPU_VERSION -ge 528 ]; then # PA-RISC 1.1+ CPU - OUT="hpux-parisc-${CC}" + OUT="hpux-parisc1_1-${CC}" elif [ $CPU_VERSION -ge 523 ]; then # PA-RISC 1.0 CPU OUT="hpux-parisc-${CC}" else # Motorola(?) CPU