On Thu, Jul 24, 2008 at 9:57 AM, Haavard Skinnemoen <[EMAIL PROTECTED]> wrote: > Kenneth Johansson <[EMAIL PROTECTED]> wrote: >> you have to >> read the gcc code to understand what the -mrelocatable option really do. > > Plus it's only defined for PowerPC. What do we do on the 11 other > architectures? > > We could build u-boot as a shared library I guess, but that feels a bit > weird... >
I ran a quick experiment with -mrelocate, compiled a module with it and then objdump -D its contents, it seems to do exactly what I wanted - stores addresses of pointers to adjust into the fixit section. I guess the least intrusive alternative would be to compile the ported code with this option, and then add a check to the u-boot function dealing with GOT adjustments to see if the fixit section is nonempty. If so - relocate .fixit in addition to GOT. But as you pointed out, this would work on ppc only (with a 'good' compiler), and still remains to be proven, I will get to it a bit later. cheers, /vb > Haavard > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > U-Boot-Users mailing list > U-Boot-Users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/u-boot-users > ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ U-Boot-Users mailing list U-Boot-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/u-boot-users