This is the mail archive of the
mailing list for the GCC project.
RE: [GCC Steering Committee] Android sub-port reviewer
Andrew Pinski wrote:
> The point is mips*-*-* is big endian and mipsel*-*-* is little endian.
> And doing adding a target which says mips-linux-android which is
> little-endian is just backwards. Is there anyway to fix the target
> triplet to be mipsel-linux-android including inside the official NDK?
> If not then we have a broken triplet for android.
I agree with what you said.
The simplest fix is that mips-linux-android still generates big-endian code
as the MIPS target triplet design. Don't ever set it to generate little-endian code automatically.
For MIPS GCC Android patches to merge to FSF GCC trunk, we will never change endiannes.
Note that we did use a regular mips-linux-gnu GCC to compile Android systems by using -EL.
The target of "mips-linux-android" is just invented to work with NDK scripts.
And people can freely create "mipsel-linux-*" toolchains to compile Android systems directly,
or create "mips-linux-*" toolchains to compile Android systems with -EL.
The MIPS NDK script patch was just merged to googlesource last night.
I can work on another patch to use -EL options, but to let
"mips-linux-andoird" generate big-endian code. Is this solution ok for you?