On 26/09/2012 16.54, Waldemar Brodkorb wrote: > Hi, > Hello,
> when building a buildroot based system for the target qemu-mips64-malta I get > following output > generated: > wbx@neon:~/adk/buildroot $ ./output/host/usr/bin/mips64-linux-readelf -a > output/target/bin/busybox |grep interpreter > > [Requesting program interpreter: /lib/ld64-uClibc.so.0] > wbx@neon:~/adk/buildroot $ ls -la output/target/lib/ld-uClibc* > > -rwxr-xr-x 1 wbx admin 32280 Sep 26 15:51 > output/target/lib/ld-uClibc-0.9.33.2.so > lrwxr-xr-x 1 wbx admin 21 Sep 26 14:25 output/target/lib/ld-uClibc.so.0 > -> ld-uClibc-0.9.33.2.so > > The problem is this line in Rules.mak: > 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 > endif > > TARGET_ARCH can not be set to mips64 via make menuconfig or any .config. > How is it supposed to work? > it's not working indeed. > Would be the use of TARGET_SUBARCH a solution? I don't think so, as it's not a SUBARCH, even if I'm not expert of the MIPS platform. We could add a Config.mips64 to make it selectable as a mips64 arch, but this will have hge impact on the current mips specific code that is generic for the different ABI and implement internally a check wrt to the ABI. Anyway, looking at Config.mips, I can see that is possible to configure it as a 64bit (by setting the Target ABI to CONFIG_MIPS_N64_ABI), but I don't know exactly the implications (the only use I can see is to pass -mips64 to the compiler, that should generate MIPS64 ABI compatible code only). > Something like that: > diff -Nur uClibc-0.9.33.2.orig/Rules.mak uClibc-0.9.33.2/Rules.mak > --- uClibc-0.9.33.2.orig/Rules.mak 2012-05-15 09:20:09.000000000 +0200 > +++ uClibc-0.9.33.2/Rules.mak 2012-09-21 19:28:45.000000000 +0200 > @@ -118,7 +118,7 @@ > 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 ),) > +ifneq ($(findstring $(TARGET_SUBARCH) , hppa64 ia64 mips64 powerpc64 s390x > sparc64 x86_64 ),) this will have an overall impact on all others. I think we should do an exception for mips. > UCLIBC_LDSO_NAME := ld64-uClibc > ARCH_NATIVE_BIT := 64 > else > diff -Nur uClibc-0.9.33.2.orig/extra/Configs/Config.in > uClibc-0.9.33.2/extra/Configs/Config.in > --- uClibc-0.9.33.2.orig/extra/Configs/Config.in 2012-05-15 > 09:20:09.000000000 +0200 > +++ uClibc-0.9.33.2/extra/Configs/Config.in 2012-09-21 19:29:11.000000000 > +0200 > @@ -235,6 +235,7 @@ > default "i486" if CONFIG_486 > default "i586" if CONFIG_586 || CONFIG_586MMX > default "i686" if TARGET_ARCH = "i386" > + default "mips64" if CONFIG_MIPS_ISA_MIPS64 this looks fine > default "" > > source "extra/Configs/Config.in.arch" > > Any feedback is appreciated. > > thanks in advance > Waldemar > I'll try to post a patch. Carmelo > _______________________________________________ > uClibc mailing list > [email protected] > http://lists.busybox.net/mailman/listinfo/uclibc > > _______________________________________________ uClibc mailing list [email protected] http://lists.busybox.net/mailman/listinfo/uclibc
