Hint Wanted on Debugging Unexpected Section
Joel Sherrill
joel at rtems.org
Mon Jul 4 18:48:00 UTC 2016
On Mon, Jul 4, 2016 at 1:42 PM, Sebastian Huber <
sebastian.huber at embedded-brains.de> wrote:
>
> ----- Joel Sherrill <joel at rtems.org> schrieb:
> > On Mon, Jul 4, 2016 at 1:07 PM, Sebastian Huber <
> > sebastian.huber at embedded-brains.de> wrote:
> >
> > > Hello Joel,
> > >
> > > please use the linker command files of the qoriq BSPs as a template on
> > > PowerPC.
> > >
> > >
> > psim is using the shared linkcmds. Is something wrong with it?
> >
> > What would be the advantage of the qoriq linker script if both are using
> > the shared pattern?
> >
> > Just curious. I was avoiding the cut and pasted ones like the plague. But
> > if there is a second factor, we all should know it.
>
> Sorry for the noise, the PSIM linkcmds is fine.
>
>
No problem. Just wanted to make sure I wasn't missing something.
> >
> >
> > > You can use the linker map file to figure out which sections a the
> trouble
> > > maker (-Wl,-Map,map.txt).
> > >
> > >
> > Hmm... there were these... any ideas?
> >
> > Thanks.
> >
> > .unexpected_sections
> > 0x00000000 0xa8
> > *(*)
> > .rela.rtemsroset._Sysinit.content.0.0x00030080
> > 0x00000000 0xc
>
> You use probably some GCC flags that no other BSP used up to now. What
> are your LDFLAGS or CFLAGS? Do you use PIC or some dynamic relocations?
> Who generates these .rela.rtemsroset.* sections?
>
>
This BSP is paravirtualized. All of the provided system libraries are
dynamic (except for the video one). We already have this running on
x86 and I was moving it to ppc. So the environment is a bit different.
I didn't see this on x86.
CFLAGS are normal. The LDFLAGS have these added which are
the same as on x86.
LDFLAGS += -Wl,-Ttext-segment=0x04200000
LDFLAGS += -Wl,-call_shared
LDFLAGS += -Wl,-Bshareable
LDFLAGS += -Wl,-shared
LDFLAGS += -Wl,-export-dynamic
LDFLAGS += -Wl,-no-undefined
LDFLAGS += ${DESKHOME}/ppc/lib/libkernel.so
LDFLAGS += -Wl,--whole-archive
LDFLAGS += ${DESKHOME}/ppc/lib/gcc-4.6.1/libvideo.a
LDFLAGS += -Wl,--no-whole-archive
LDFLAGS += -Wl,-Map,map.txt
Since the unexpected sections appear to be rtems specific, any suggestions
on how to track them down? All I can think of is a brutal hack to check
every object.
Thanks.
--joel
Address : Dornierstr. 4, D-82178 Puchheim, Germany
> Phone : +49 89 189 47 41-16
> Fax : +49 89 189 47 41-09
> E-Mail : sebastian.huber at embedded-brains.de
> PGP : Public key available on request.
>
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20160704/1a305dd3/attachment-0002.html>
More information about the devel
mailing list