summaryrefslogtreecommitdiff
path: root/binutils-2.24.51.midipix.patch
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2015-06-06 14:04:45 -0400
committermidipix <writeonce@midipix.org>2015-06-06 14:04:45 -0400
commit7ead5aa3032e3cf04f0beb03a8833147db0a2639 (patch)
tree57ddd478ef6368de20f5e334392414df8d63ca0c /binutils-2.24.51.midipix.patch
parent40ec1af0496be0e6129e5eaf72ec8b5d2568a78d (diff)
downloadchainport-7ead5aa3032e3cf04f0beb03a8833147db0a2639.tar.bz2
chainport-7ead5aa3032e3cf04f0beb03a8833147db0a2639.tar.xz
binutils-2.24.51: updated patch.
+ PE shared libraries: fix the logic that allows weak definitions to be exported (cf. commit ddd1583). signed-off by Z. Gilboa; see copying.midipix (9cd0746c) for additional information.
Diffstat (limited to 'binutils-2.24.51.midipix.patch')
-rw-r--r--binutils-2.24.51.midipix.patch21
1 files changed, 19 insertions, 2 deletions
diff --git a/binutils-2.24.51.midipix.patch b/binutils-2.24.51.midipix.patch
index ae202c5..4cf660e 100644
--- a/binutils-2.24.51.midipix.patch
+++ b/binutils-2.24.51.midipix.patch
@@ -371,7 +371,7 @@ diff -ru --new-file a/binutils/winduni.c b/binutils/winduni.c
{ 437, "MS-ANSI" },
{ 737, "MS-GREEK" },
--- a/ld/pe-dll.c 2014-07-03 01:37:48.000000000 -0400
-+++ b/ld/pe-dll.c 2015-06-05 01:41:53.468944737 -0400
++++ b/ld/pe-dll.c 2015-06-06 13:29:26.820285683 -0400
@@ -40,6 +40,7 @@
#include "coff/internal.h"
#include "../bfd/libcoff.h"
@@ -424,7 +424,7 @@ diff -ru --new-file a/binutils/winduni.c b/binutils/winduni.c
+ if (weaksym)
+ {
+ free (p->internal_name);
-+ p->internal_name = strdup (symbols[j]->name);
++ p->internal_name = strdup (weaksym);
+ }
}
+ if (weaksym)
@@ -432,6 +432,23 @@ diff -ru --new-file a/binutils/winduni.c b/binutils/winduni.c
}
}
}
+@@ -910,6 +933,7 @@
+
+ if (blhe
+ && (blhe->type == bfd_link_hash_defined
++ || (blhe->type == bfd_link_hash_defweak)
+ || (blhe->type == bfd_link_hash_common)))
+ {
+ count_exported++;
+@@ -919,7 +943,7 @@
+ /* Only fill in the sections. The actual offsets are computed
+ in fill_exported_offsets() after common symbols are laid
+ out. */
+- if (blhe->type == bfd_link_hash_defined)
++ if ((blhe->type == bfd_link_hash_defined) || (blhe->type == bfd_link_hash_defweak))
+ exported_symbol_sections[i] = blhe->u.def.section;
+ else
+ exported_symbol_sections[i] = blhe->u.c.p->section;
diff -ru --new-file a/bfd/config.bfd b/bfd/config.bfd
--- a/bfd/config.bfd 2014-07-03 01:37:20.000000000 -0400
+++ b/bfd/config.bfd 2015-02-14 11:27:08.199179775 -0500