[uClibc]ld-uClibc-0.9.19.so on powerpc still buggy?
Simon Rowe
srowe at cambridgebroadband.com
Fri Jun 27 07:30:01 UTC 2003
On Thursday 26 Jun 2003 4:41 pm, Uwe Müller-Wilm wrote:
> I just tried to use the recent powerpc development system, dated 6 March
> (the binary image) and found that the busybox does not start. So I used
> the uClibc-0.9.19 toolchains and build it for my own, unfortunately with
> the same results. When replacing busybox with the bash (or using the
> busybox as a static build) I was able to gdb the corrupt busybox and traced
> down up to the info that the problem is apparently located in the dynamic
> lib loader ld-uClibc-0.9.19.so - to be more concrete in the function
> "_dl_parse_relocation_information" (located in /powerpc/elfinterp.c).
I've had problems there myself, but only on certain executables (snmpd from
net-snmp). While investigating it I added some debug and the problem went
away... My knowledge of PowerPC architecture is negligible so I've added the
following patch, there is some effect of dereferencing reloc_addr which
causes the problem to dissapear. Someone who knows what they're doing might
be able to use the behaviour to help track down the real problem.
diff -Nur uClibc-0.9.16/ldso/ldso/powerpc/elfinterp.c
uClibc-0.9.16-cbl/ldso/ldso/powerpc/elfinterp.c
--- uClibc-0.9.16/ldso/ldso/powerpc/elfinterp.c Wed Nov 6 16:33:29 2002
+++ uClibc-0.9.16-cbl/ldso/ldso/powerpc/elfinterp.c Wed Nov 13 08:50:28 2002
@@ -443,6 +443,9 @@
_dl_dprintf(2, "'%s'\n", strtab + symtab[symtab_index].st_name);
_dl_exit(1);
};
+
+ /* Temp hack for SEGV, dereference reloc_addr */
+ if ((int)*reloc_addr == (int)reloc_addr) _dl_dprintf(2, "SJR reloc_addr :
%x\n",*reloc_addr);
/* instructions were modified */
PPC_DCBST(reloc_addr);
--
Simon Rowe
Cambridge Broadband Ltd
More information about the uClibc
mailing list