Add the musl dynamic linker names for mips r6. It seems DRIVER_SELF_SPECS sets the default mips isa (MIPS_DEFAULT_ISA_LEVEL_SPEC) on *-mti-linux* or *-mti-elf, but not on gnu linux targets (see config/mips/mti-linux.h vs config/mips/gnu-user.h).
Is that ok? It seems broken, but i didn't try to fix that. If the toolchain is configured with mipsisa32r6-linux-musl the dynlinker name is wrong unless one explicitly passes -mips32r6 to gcc (same for the assembler and linker: they don't get -mips32r6 by default). gcc/ 2016-08-24 Szabolcs Nagy <szabolcs.n...@arm.com> * config/mips/linux.h (MUSL_DYNAMIC_LINKER32): Update. (MUSL_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKERN32): Update.
diff --git a/gcc/config/mips/linux.h b/gcc/config/mips/linux.h index fa253b6..2d79715 100644 --- a/gcc/config/mips/linux.h +++ b/gcc/config/mips/linux.h @@ -38,10 +38,13 @@ along with GCC; see the file COPYING3. If not see "%{mnan=2008:/lib32/ld-uClibc-mipsn8.so.0;:/lib32/ld-uClibc.so.0}" #undef MUSL_DYNAMIC_LINKER32 -#define MUSL_DYNAMIC_LINKER32 "/lib/ld-musl-mips%{EL:el}%{msoft-float:-sf}.so.1" +#define MUSL_DYNAMIC_LINKER32 \ + "/lib/ld-musl-mips%{mips32r6:r6}%{EL:el}%{msoft-float:-sf}.so.1" #undef MUSL_DYNAMIC_LINKER64 -#define MUSL_DYNAMIC_LINKER64 "/lib/ld-musl-mips64%{EL:el}%{msoft-float:-sf}.so.1" -#define MUSL_DYNAMIC_LINKERN32 "/lib/ld-musl-mipsn32%{EL:el}%{msoft-float:-sf}.so.1" +#define MUSL_DYNAMIC_LINKER64 \ + "/lib/ld-musl-mips64%{mips64r6:r6}%{EL:el}%{msoft-float:-sf}.so.1" +#define MUSL_DYNAMIC_LINKERN32 \ + "/lib/ld-musl-mipsn32%{mips64r6:r6}%{EL:el}%{msoft-float:-sf}.so.1" #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32" #define GNU_USER_DYNAMIC_LINKERN32 \