diff options
author | 2009-11-22 22:49:50 -0500 | |
---|---|---|
committer | 2009-11-22 22:52:09 -0500 | |
commit | 671f37d23f13e5f561640c0fa66c3dac5ae1b4af (patch) | |
tree | bae0f1f701a348ceab691180368b4829027da865 /wrappers/emerge-wrapper | |
parent | busybox env: fix small typo (diff) | |
download | crossdev-671f37d23f13e5f561640c0fa66c3dac5ae1b4af.tar.gz crossdev-671f37d23f13e5f561640c0fa66c3dac5ae1b4af.tar.bz2 crossdev-671f37d23f13e5f561640c0fa66c3dac5ae1b4af.zip |
emerge-wrapper: some updates
Signed-off-by: Ned Ludd <solar@gentoo.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'wrappers/emerge-wrapper')
-rwxr-xr-x | wrappers/emerge-wrapper | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/wrappers/emerge-wrapper b/wrappers/emerge-wrapper index 634f2e7..1e3c4f8 100755 --- a/wrappers/emerge-wrapper +++ b/wrappers/emerge-wrapper @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2008 Gentoo Foundation +# Copyright 2008-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ @@ -8,19 +8,31 @@ cross_wrap_etc() { local chost=$1 cp -a __PREFIX__/share/crossdev/etc /usr/$chost/ - + (cd /usr/$chost/etc ; ln -s /etc/make.globals make.globals ) conf=/usr/$chost/etc/make.conf if [[ ${chost:0:1} == "i" ]] && [[ ${chost:3:4} == "86" ]]; then + E_MACHINE=EM_X86 ARCH=x86 fi + if [[ ${chost:3:4} == "x86_64" ]]; then + E_MACHINE=EM_X86_64 + ARCH=amd64 + fi + if [[ ${chost:0:3} == "arm" ]]; then E_MACHINE=EM_ARM ARCH=arm echo 'UCLIBC_CPU_DEFAULT="GENERIC_ARM"' >> ${conf} fi + if [[ ${chost:0:4} == "mips" ]]; then + E_MACHINE=EM_MIPS + ARCH=mips + fi + [[ ${chost/gnu/} != $chost ]] && sed -i -e s/__LIBC__/glibc/g ${conf} + [[ ${chost/uclibc/} != $chost ]] && sed -i -e s/__LIBC__/glibc/g ${conf} [[ $E_MACHINE != "" ]] && sed -i -e s/'#E_MACHINE=__E_MACHINE__'/E_MACHINE=${E_MACHINE}/g ${conf} [[ $ARCH != "" ]] && sed -i -e s/__ARCH__/${ARCH}/g ${conf} sed -i -e s/__CHOST__/${chost}/g -e s/__CBUILD__/${CBUILD}/g ${conf} |