toolchain/external: fix building the wrapper on MIPS
authorYann E. MORIN <yann.morin.1998@free.fr>
Wed, 26 Nov 2014 18:09:10 +0000 (19:09 +0100)
committerPeter Korsgaard <peter@korsgaard.com>
Thu, 27 Nov 2014 21:47:08 +0000 (22:47 +0100)
commit3e0440407aa276983439ee1bdf82903d679fb5a7
tree4669640ef8bcf04d3a11570da74172d9f9534fb8
parent30362526a081c7dcbb568e3d543fc83b8a294b56
toolchain/external: fix building the wrapper on MIPS

Some crazy folks use MIPS machines as build machines. ;-)

On MIPS, the only acceptable hash-style is 'sysv', because the MIPS ABI
defines that the GOT ordering to be the same as the symbols ordering,
while GNU hash requires symbols to be sorted by their hash.

Looking at binutils' code, it seems that only MIPS suffers from that
limitation.

Currently, we force the toolchain wrapper to be linked with both hash
styles, which breaks on MIPS.

So, fix that by singling out MIPS, and use sysv in that case, and both
otherwise.

Reported-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Reviewed-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Tested-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
toolchain/toolchain-external/toolchain-external.mk