FreeBSD/arm64 MACHINE/MACHINE_ARCH identification

Warner Losh imp at bsdimp.com
Tue Feb 17 18:09:28 UTC 2015


> On Feb 16, 2015, at 10:33 AM, Ed Maste <emaste at FreeBSD.org> wrote:
> 
> On 12 February 2015 at 11:29, Warner Losh <imp at bsdimp.com> wrote:
>> 
>> Traditionally in Linux, they have been a matched set.
> 
> It looks like it's not so straightforward in the GNU/Linux world
> either. Excerpts from Debian's cputable file:
> 
> # <Debian name> <GNU name>      <config.guess regex>    <Bits>  <Endianness>
> amd64           x86_64          x86_64                  64      little
> arm64           aarch64         aarch64                 64      little
> 
> Debian and .deb derivatives use arm64 for the 64-bit ARM port name,
> and I'm told Fedora and .rpm derivatives use aarch64. But in all cases
> the CPU architecture reported by uname is aarch64.
> 
> Debian uses "amd64" for the 64-bit x86 port name, like us, but uname
> reports x86_64.

For pkg(8), we should use whatever MACHINE_ARCH lists, as that’s what
we do everywhere else. We just got done killing the arbitrarily different names
and I’d like to keep them dead :). We already don’t match the debian conventions
for many of our architectures, so that’s not a huge loss :)

Based on our IRC conversations, I think we violently agree on the following bits:

(1) MACHINE_ARCH (-p) should be aarch64
(2) MACHINE (-m) should match /usr/src/sys/BLAH
(3) we control what BLAH is

It would be most compatible to use aarch64 for BLAH from a shell script
perspective. It would be more in keeping with FreeeBSD’s other architectures
to have it be just “arm”. Having BLAH be arm, however, presents many
interesting logistical issues for the port mostly confined to the kernel,
but with a few tendrils into the build system. Having BLAH be aarch64,
however, would mean we’d have to re-do the -m32 support and add a
second special-case to live along side the amd64 special case we have now.

So, there’s no clear cut answers here, except maybe that “arm64” would
present the most pain of the three sensible choices we have at our
disposal for BLAH (arm, aarch64, arm64).

Warner


More information about the freebsd-arm mailing list