This is the mail archive of the binutils@sources.redhat.com 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]

Re: "Warning: size of symbol FOO changed from X to Y in OBJ"


On Wed, May 30, 2001 at 06:10:42PM -0700, Ian Lance Taylor wrote:
> amodra@one.net.au writes:
> 
> > On Wed, May 30, 2001 at 10:12:48AM -0700, Ian Lance Taylor wrote:
> > > 
> > > Looking at the code, though, it doesn't seem to be a fatal error.  It
> > > just seems to issue the warning and move on.  What's the test case?
> > 
> > Aye, but ldlang.c:open_input_bfds has set the bfd error handler to
> > record_bfd_errors.  record_bfd_errors stops output file creation on
> > any error.
> 
> Well, I don't know what that's about.  That's completely wrong.  If
> BFD wants to report a fatal error, it should arrange to return false.
> If BFD does not want to report a fatal error, it should not return
> false.  It makes no sense for the linker to try to second guess BFD in
> this regard.
> 
> According to the ChangeLog, H.J. added this:
> 
> 2001-02-26  H.J. Lu  <hjl@gnu.org>
> 
> 	* ldlang.c (open_input_bfds): Set the bfd error handler so
>         that problems can be caught whilst loading symbols.
>         (record_bfd_errors): New function: Report BFD errors and mark
>         the executable output as being invalid.
> 
> Why?

That patch was made after some discussions with Nick for

http://sources.redhat.com/ml/binutils/2001-02/msg00508.html

I guess for some platform, warning during symbol loading may be fatal.


H.J.


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