Subject: IMPORTANT: MACHINE_ARCH WRONG ON MIPS PLATFORMS
To: None <tech-toolchain@NetBSD.ORG>
From: Todd Vierling <tv@pobox.com>
List: current-users
Date: 07/23/1998 12:44:51
[Moving to tech-toolchain - RESPOND THERE - but blind carbon copying the
developers, the lists from the original post, and the original posters.]

On Thu, 23 Jul 1998, Izumi Tsutsui wrote:

: "mips-sony-netbsd*" is big endian, but "mips-dec-netbsd*"
: (and also pica/arc?) should be defined as little endian.
: 
: I think /usr/src/gnu/usr.bin/binutils/Makefile.inc should be support
: bi-endian arch.

No.

I looked into the mips header files and saw a ghastly WRONG thing in there:
both little-endian and big-endian mips systems have "mips" for MACHINE_ARCH.

${MACHINE_ARCH} defines a set of binary formats that are uniform across that
${MACHINE_ARCH}.  For example, all m68k bins are the same format, so they
all have the same ${MACHINE_ARCH} - m68k.

Using "mips" for both big-endian and little-endian sets MUST be changed,
regardless of the effects.  Leaving it as-is will break a lot more than just
config.bfd - it breaks the entire concept of ${MACHINE_ARCH}-global binary
sets (not to mention the concept of binary pkgs).

Now, the question is how to do it:  make a new "mipsle," perhaps?

(Binary pkg/GNU people: it's rather trivial to set MACHINE_GNU_ARCH fr each
platform type as necessary.  Thank my mods for the arm32 guys.  :)

-- 
-- Todd Vierling (Personal tv@pobox.com; Bus. todd_vierling@xn.xerox.com)