[PATCH] Rules.mak: MIPS64: Select correct interpreter

Markos Chandras markos.chandras at gmail.com
Thu Jul 4 09:58:57 UTC 2013


On 4 July 2013 10:44, Bernhard Reutner-Fischer <rep.dot.nop at gmail.com> wrote:
> On 1 July 2013 14:15, Markos Chandras <markos.chandras at gmail.com> wrote:
>> From: Markos Chandras <markos.chandras at imgtec.com>
>>
>> gcc (eg 4.7.3) hardcodes the MIPS64 interpreters like this:
>> (see gcc/config/linux.h and gcc/config/mips/linux64.h)
>>
>> o32: UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
>> n32: UCLIBC_DYNAMIC_LINKERN32 "/lib32/ld-uClibc.so.0"
>> n64: UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
>>
>> The existing check for MIPS64 in uClibc is wrong because it does
>> not respect the selected ABI
>>
>> We fix this by explicitely checking the selected ABI instead of the
>> selected MIPS variant.
>>
>> Signed-off-by: Markos Chandras <markos.chandras at imgtec.com>
>> Cc: Anthony G. Basile <blueness at gentoo.org>
>> ---
>>  Rules.mak | 12 ++++++++----
>>  1 file changed, 8 insertions(+), 4 deletions(-)
>>
>> diff --git a/Rules.mak b/Rules.mak
>> index 792b794..87eb5ae 100644
>> --- a/Rules.mak
>> +++ b/Rules.mak
>> @@ -138,13 +138,17 @@ export MAJOR_VERSION MINOR_VERSION SUBLEVEL VERSION ABI_VERSION LC_ALL
>>  LIBC := libc
>>  SHARED_LIBNAME := $(LIBC).so.$(ABI_VERSION)
>>  UBACKTRACE_DSO := libubacktrace.so.$(ABI_VERSION)
>> -ifneq ($(findstring  $(TARGET_ARCH) , hppa64 ia64 mips64 powerpc64 s390x sparc64 x86_64 ),)
>> -UCLIBC_LDSO_NAME := ld64-uClibc
>> -ARCH_NATIVE_BIT := 64
>> -else
>> +
>>  UCLIBC_LDSO_NAME := ld-uClibc
>>  ARCH_NATIVE_BIT := 32
>> +ifneq ($(findstring  $(TARGET_ARCH) , hppa64 ia64 powerpc64 s390x sparc64 x86_64 ),)
>> +UCLIBC_LDSO_NAME := ld64-uClibc
>> +ARCH_NATIVE_BIT := 64
>> +else ifeq ($(CONFIG_MIPS_N64_ABI),y)
>> +UCLIBC_LDSO_NAME := ld64-uClibc
>> +ARCH_NATIVE_BIT := 64
>>  endif
>
> Will that work with make-3.81, which is currently the minimal version
> we require?
> thanks,

Hi Bernhard,

I just tested it on my box with make-3.81 and it builds fine.

--
Regards,
Markos Chandras


More information about the uClibc mailing list