I noticed that linkerscript-repsection-va.s was wrong:
For single foo entry:
SECTIONS {.foo : {*(.foo.*)} }
2 output sections were created.
I think that is wrong because:
- It is really confusing and complicates the understanding of the script output. I think nobody expects to see multiple output sections for single entry.
- Imagine that some symbols are to be declared: SECTIONS {.foo : {*(.foo.*)} end = .; } what should be the value of end if we have 2 output sections ? Its just confusing.
- gold and ld do not do that.
- It also adds a problem for refactoring of script I do.
Patch fixes that bu combining the flags of sections if scripted layouting is used.