Subject: Re: HEADS UP! New toolchain to be default on i386, sparc64
To: Paul Goyette <paul@whooppee.com>
From: Simon J. Gerraty <sjg@quick.com.au>
List: tech-toolchain
Date: 08/17/2001 21:35:17
>> TOOLDIR should be a directory that is not mounted noexec (since the
>> toolchain will be running from here), and will hold the *host tools* for a
>> given MACHINE_ARCH -- which means that you will be able to cross-compile
>> shortly, right from the top level.  (It *may* work already; I only haven't
>> tested it, and need to finish the rest of the cross-tools just to make
>> sure.)

>Any suggestions for what to set this to for a multi-architecture
>environment?  Any reason why we couldn't have a default?  Like maybe
>somewhere in the src/tools/obj.${arch} hierarchy?

I find obj-${HOST_TARGET} works well.
Where 

HOST_OS=`uname`
HOST_OSREL=`uname -r`
HOST_OSMAJOR=`IFS=.; set $HOST_OSREL; echo $1`
HOST_MACHINE=`uname -m`
HOST_TARGET=`echo ${HOST_OS}${HOST_OSMAJOR}-${HOST_MACHINE} | tr 'A-Z' 'a-z'`

So you end up with say

obj-netbsd1-sparc64
obj-sunos5-sparc
obj-freebsd2-i386
obj-freebsd4-i386

Of course the OSMAJOR is not enough clue on netbsd to distinquish a.out
from ELF.... 

--sjg