This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: ld i386 differences 2.10.2 / 2.12
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: binutils at sources dot redhat dot com
- Date: Mon, 8 Apr 2002 10:31:12 +0930
- Subject: Re: ld i386 differences 2.10.2 / 2.12
- References: <20020326065120.GB18838@bubble.sa.bigpond.net.au> <20020326114708.83760.qmail@web11808.mail.yahoo.com> <20020326121526.GE18838@bubble.sa.bigpond.net.au>
On Tue, Mar 26, 2002 at 10:45:26PM +1030, Alan Modra wrote:
> On Tue, Mar 26, 2002 at 12:47:08PM +0100, Etienne Lorrain wrote:
> > /home/etienne/projet/toolchain/bin/ld: warning: no memory region specified
> > for section `.ld-2.12.bug_please_ignore_warning'
> >
> > Note that it is a strange warning for a "NOLOAD" section.
>
> Indeed. :-)
* ldlang.c (lang_size_sections_1): Don't complain about
SEC_NEVER_LOAD sections having no memory region specified.
Index: ld/ldlang.c
===================================================================
RCS file: /cvs/src/src/ld/ldlang.c,v
retrieving revision 1.79
diff -u -p -r1.79 ldlang.c
--- ld/ldlang.c 20 Mar 2002 07:49:53 -0000 1.79
+++ ld/ldlang.c 8 Apr 2002 00:21:07 -0000
@@ -2930,6 +2930,8 @@ lang_size_sections_1 (s, output_section_
defined, issue a warning. */
if ((bfd_get_section_flags (output_bfd, os->bfd_section)
& (SEC_ALLOC | SEC_LOAD)) != 0
+ && (bfd_get_section_flags (output_bfd, os->bfd_section)
+ & SEC_NEVER_LOAD) == 0
&& ! link_info.relocateable
&& strcmp (os->region->name, "*default*") == 0
&& lang_memory_region_list != NULL
--
Alan Modra
IBM OzLabs - Linux Technology Centre