Gentoo Archives: gentoo-alt

From: Christopher Friedt <chrisfriedt@×××××.com>
To: gentoo-alt@l.g.o
Subject: [gentoo-alt] portable EPREFIX? ... crossdev toolchains, anyone?
Date: Fri, 27 May 2011 15:43:05
Hi list,

I recently switched to a Mac after over a decade of various machines
running Linux (Gentoo for the most part), and think that the EPREFIX
install is great.

One of the first things I did was hack together a couple of crossdev
toolchains after installing Gentoo-Prefix (it was a bit of a battle,
but it does work).

I thought, "yay! now I can share these binaries and save others their
time", but then I realized there was a big problem.

The EPREFIX suggested on the bootstrap page[1] (at least for Mac) is
completely non-portable, since EPREFIX=${HOME}/Gentoo will change with
every single username. This prevents people like me from sharing
useful things like crossdev toolchains that might not be so easy for
others to put together.

Wouldn't a better solution for the guide be to _strongly_emphasize_ a
common-ish EPREFIX such as '/opt/gentoo' or '/Users/Gentoo' ?

I chose to use EPREFIX=/Users/Gentoo, since that is a fairly open spot
on most Macs, and it likely wouldn't collide with any unix-y paths
that might be used for some other purpose. Incidentally, I'd love to
post my cross-toolchains for anyone to download - can someone from the
gentoo-alt project host them?

Currently, I have

x86_64-apple-darwin10 => i686-pc-linux-gnu
x86_64-apple-darwin10 => armv7a-softfloat-linux-gnueabi

The softfloat toolchain can easily be used to build 'softfp' binaries
(i.e. binaries that use e.g. neon or vfp, but still work with a
softfloat userspace) simply by using e.g. CFLAGS="-march=armv7a
-mfloat-abi=softfp -fpu=neon".

They can be installed with 'emerge -Kav