This is the mail archive of the mailing list for the binutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH][gold] Place sections like ".rela.dyn" according to linker scripts.

> I've checked it. The things with these sections are definitely complicated
> if we try to imitate ld's behavior in every single detail. Anyway, my patch
> deals with only one particular case and, as far as I can see, doesn't change
> anything for the sample from PR 20062.

Thanks for the patch. I've changed it a bit -- after thinking about it
for a *long* time (!), experimenting with Gnu ld, and working through
a few other test cases, I've decided that linker-generated sections
should match *only* via the output section name (except for the case
of /DISCARD/). Accordingly, this patch just changes
Output_section_definition::output_section_name() to check the output
section name for a linker-generated section. I think this will also
fix both PR 20062 and PR 20522, as we will no longer try to place into .rela.dyn.

I've attached the patch as committed.


2016-12-12  Igor Kudrin  <>
            Cary Coutant  <>

        PR gold/14676
        * (Output_section_definition::output_section_name):
        For linker-generated sections, compare with output section name.
        * testsuite/ (script_test_13): New test.
        * testsuite/ Regenerate.
        * testsuite/script_test_13.c: New source file.
        * testsuite/ New script.
        * testsuite/script_test_13.t: New linker script.

Attachment: pr14676.patch
Description: Binary data

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]