This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: __NETDEVTAB__ length is zero
> Hi Andrew,
>
> The part of the code you gave is getting compiled. For the commands you suggested
> the output is also as you said. When I link the libraries with an application and see the
> objdump I get same addresses for both of the following
>
> __NETDEVTAB__ and __NETDEVTAB_END__.
>
> Also the command you suggested when ran on an application gave me the following.
> 002fc000 l d .ecos.table.netdev.finish 00000000
> 002fc000 l d .ecos.table.netdev.begin 00000000
> 002fc000 l d .ecos.table.netdev.data 00000000
> 002fc000 g O .ecos.table.netdev.data 00000010 edb7xxx_netdev
So the table entries are in extra.a, but not in the application. This
means its the final link state. Look in your install/lib/target.ld...
The line for data will be something like....
.data ALIGN (0x4) : { __ram_data_start = ABSOLUTE (.); *(.data*) *(.data1) _GOT1_START_ = ABSOLUTE (.); *(.got1) _GOT1_END_ = ABSOLUTE
(.); _GOT2_START_ = ABSOLUTE (.); *(.got2) _GOT2_END_ = ABSOLUTE (.); . = ALIGN (4); KEEP(*( SORT (.ecos.table.*))) ; . = ALIGN (4); __CTOR_LIST__ =
ABSOLUTE (.); KEEP (*(SORT (.ctors*))) __CTOR_END__ = ABSOLUTE (.); __DTOR_LIST__ = ABSOLUTE (.); KEEP (*(SORT (.dtors*))) __DTOR_END__ = ABSOLUTE (.
); *(.dynamic) *(.sdata*) *(.sbss*) . = ALIGN (4); *(.2ram.*) } > ram __rom_data_start = LOADADDR (.data); __ram_data_end = .; PROVIDE (__ram_data_
end = .); _edata = .; PROVIDE (edata = .); PROVIDE (__rom_data_end = LOADADDR (.data) + SIZEOF(.data));
make sure you have
KEEP(*( SORT (.ecos.table.*))) ;
and the other stuff around there looks similar.
Andrew