aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2000-09-14 01:39:42 +0000
committerNick Clifton <nickc@redhat.com>2000-09-14 01:39:42 +0000
commit9b14b192bba894ebaa57346c116d8feda54829de (patch)
tree37008c8dac2e19f48a1c603284c06725c6bf3394 /ld
parent8681fbcd219a0efe0de390ccffc49b102ee902b9 (diff)
downloadgdb-9b14b192bba894ebaa57346c116d8feda54829de.zip
gdb-9b14b192bba894ebaa57346c116d8feda54829de.tar.gz
gdb-9b14b192bba894ebaa57346c116d8feda54829de.tar.bz2
Disable relaxation if multiple symbol definitions are encountered - otherwise
the linker could abort with an assertion failure.
Diffstat (limited to 'ld')
-rw-r--r--ld/ChangeLog6
-rw-r--r--ld/ldmain.c7
2 files changed, 13 insertions, 0 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 9a093c9..bf42f8f 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -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.
diff --git a/ld/ldmain.c b/ld/ldmain.c
index 45710be..fea1244 100644
--- a/ld/ldmain.c
+++ b/ld/ldmain.c
@@ -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;
}