Disable relaxation if multiple symbol definitions are encountered - otherwise

the linker could abort with an assertion failure.
This commit is contained in:
Nick Clifton 2000-09-14 01:39:42 +00:00
parent 8681fbcd21
commit 9b14b192bb
2 changed files with 13 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2000-09-13 Nick Clifton <nickc@redhat.com>
* ldmain.c (multiple_definition): Disable relaxation if
multiple symbol definitions are encountered - otherwise the
linker could abort with an assertion failure.
2000-09-10 Nick Clifton <nickc@redhat.com>
* mri.c: Fix formatting.

View File

@ -863,6 +863,13 @@ multiple_definition (info, name, obfd, osec, oval, nbfd, nsec, nval)
nbfd, nsec, nval, name);
if (obfd != (bfd *) NULL)
einfo (_("%D: first defined here\n"), obfd, osec, oval);
if (command_line.relax)
{
einfo (_("%P: Disabling relaxation: it will not work with multiple definitions\n"));
command_line.relax = 0;
}
return true;
}