diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2005-06-13 12:05:45 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2005-06-13 12:05:45 +0000 |
commit | b1139d328b27001a77629130dc53cec376c97982 (patch) | |
tree | cb36b5d5e9c94baa99ee388a27ec9588befe92fa /dev-libs/openssl/files | |
parent | Added to ~ppc (diff) | |
download | gentoo-2-b1139d328b27001a77629130dc53cec376c97982.tar.gz gentoo-2-b1139d328b27001a77629130dc53cec376c97982.tar.bz2 gentoo-2-b1139d328b27001a77629130dc53cec376c97982.zip |
Fixed the gentoo.config script to be aware of different OS (in this case, FreeBSD), and added an output to tell which target is selected.
(Portage version: 2.0.51.22-r1)
Diffstat (limited to 'dev-libs/openssl/files')
-rwxr-xr-x | dev-libs/openssl/files/gentoo.config-0.9.7g | 98 |
1 files changed, 54 insertions, 44 deletions
diff --git a/dev-libs/openssl/files/gentoo.config-0.9.7g b/dev-libs/openssl/files/gentoo.config-0.9.7g index abb743551f48..a1c43aad83f8 100755 --- a/dev-libs/openssl/files/gentoo.config-0.9.7g +++ b/dev-libs/openssl/files/gentoo.config-0.9.7g @@ -1,7 +1,7 @@ #!/bin/bash # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/files/gentoo.config-0.9.7g,v 1.2 2005/05/14 17:37:46 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/files/gentoo.config-0.9.7g,v 1.3 2005/06/13 12:05:45 flameeyes Exp $ # Openssl doesn't play along nicely with cross-compiling # like autotools based projects, so let's teach it new tricks. @@ -10,55 +10,65 @@ # we can pass to the 'Configure' script. -system="linux" -#case ${CHOST##*-} -# uclibc*) system="linux" -# gnu*) system="linux" -#esac +case ${CHOST} in + *-uclibc-*) system="linux";; + *-gnu*) system="linux";; + *-freebsd*) system="FreeBSD";; +esac compiler="gcc" if [[ ${CC} == "ccc" ]] ; then compiler=${CC} fi -machine="" -case ${CHOST%%-*} in - alphaev56*) machine=alpha+bwx-${compiler};; - alphaev[67]*) machine=alpha+bwx-${compiler};; - alpha*) - # this pretty hack is because we have to make sure we - # maintain ABI on the system or things like ssh break - currmachine="" - if [[ ${ROOT} == "/" ]] && [[ -e /usr/lib/libcrypto.so ]] ; then - currmachine=$(strings /usr/lib/libcrypto.so | grep ^linux-alpha | sed -e s:linux-::) - fi - machine=${currmachine:-alpha-${compiler}} - - # NOTE: drop this crap next time SSL changes ABI #'s - [[ ${PV:0:5} != "0.9.7" ]] && machine="plzupdatemekthxbye" - ;; - - arm*eb*) machine="elf-arm -DB_ENDIAN";; - arm*) machine="elf-arm -DL_ENDIAN";; -# hppa64*) machine=parisc64;; - hppa*) machine=parisc;; - i[0-5]86*) machine=elf;; - i[6-9]86*) machine=pentium;; - ia64*) machine=ia64;; - m68*) machine=m68k;; - mips*el*) machine=mipsel;; - mips*) machine=mips;; - powerpc64*) machine=ppc64;; - powerpc*) machine=ppc;; - sh64*) machine=elf;; - sh*) machine=elf;; - sparc*v7*) machine=sparcv7;; - sparc64*) machine=sparcv9;; - sparc*) machine=sparcv8;; - s390x*) machine=s390x;; - s390*) machine=s390;; - x86_64*) machine=x86_64;; -esac +if [[ ${system} == "linux" ]]; then + machine="" + case ${CHOST} in + alphaev56*) machine=alpha+bwx-${compiler};; + alphaev[67]*) machine=alpha+bwx-${compiler};; + alpha*) + # this pretty hack is because we have to make sure we + # maintain ABI on the system or things like ssh break + currmachine="" + if [[ ${ROOT} == "/" ]] && [[ -e /usr/lib/libcrypto.so ]] ; then + currmachine=$(strings /usr/lib/libcrypto.so | grep ^linux-alpha | sed -e s:linux-::) + fi + machine=${currmachine:-alpha-${compiler}} + + # NOTE: drop this crap next time SSL changes ABI #'s + [[ ${PV:0:5} != "0.9.7" ]] && machine="plzupdatemekthxbye" + ;; + + arm*eb*) machine="elf-arm -DB_ENDIAN";; + arm*) machine="elf-arm -DL_ENDIAN";; + # hppa64*) machine=parisc64;; + hppa*) machine=parisc;; + i[0-5]86*) machine=elf;; + i[6-9]86*) machine=pentium;; + ia64*) machine=ia64;; + m68*) machine=m68k;; + mips*el*) machine=mipsel;; + mips*) machine=mips;; + powerpc64*) machine=ppc64;; + powerpc*) machine=ppc;; + sh64*) machine=elf;; + sh*) machine=elf;; + sparc*v7*) machine=sparcv7;; + sparc64*) machine=sparcv9;; + sparc*) machine=sparcv8;; + s390x*) machine=s390x;; + s390*) machine=s390;; + x86_64*) machine=x86_64;; + esac +elif [[ "${system}" == "FreeBSD" ]]; then + machine="" + case ${CHOST} in + sparc64*) machine=sparc64;; + ia64*) machine=ia64;; + alpha*) machine=alpha;; + *) machine=elf;; + esac +fi if [ -n "${machine}" ] ; then echo ${system}-${machine} |