[Bug 1725] Output section alignment fix

bugzilla-daemon at rtems.org bugzilla-daemon at rtems.org
Thu Dec 9 14:47:50 UTC 2010


https://www.rtems.org/bugzilla/show_bug.cgi?id=1725

Gedare <giddyup44 at yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |giddyup44 at yahoo.com

--- Comment #7 from Gedare <giddyup44 at yahoo.com> 2010-12-09 08:47:48 CST ---
(In reply to comment #6)
<snip>
> 
> The alignment of an output section is derived from the maximum alignment of its
> input sections and thus not known a priori.  The GNU ld without this patch has
> now the following problem.
> 
> Lets look at this SECTIONS part of the linker command file:
> 
>     .jcr : {
>         KEEP (*(.jcr))
>     } > REGION AT > REGION
>     .rodata : {
>         *(.rodata .rodata.* .gnu.linkonce.r.*)
>     } > REGION AT > REGION
> 

Can't you just write:

     .jcr : {
         KEEP (*(.jcr))
     } > REGION AT > REGION
     .rodata : {
         . = ALIGN(8);
         *(.rodata .rodata.* .gnu.linkonce.r.*)
     } > REGION AT > REGION

<snip>

-- 
Configure bugmail: https://www.rtems.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the bugs mailing list