From 3db8634669090686d790b61700a84c25eed74e04 Mon Sep 17 00:00:00 2001 From: Andrew Hsieh Date: Tue, 23 Oct 2012 19:06:03 +0800 Subject: Fix ld gc-sections Used to be local NDK patch at $NDK/build/tools/toolchain-patches/ binutils/0001-Fix-ld-gc-sections.patch Change-Id: I3946edae82c315904f919f4c2f5f94b10a31aa37 --- binutils-2.21/bfd/elflink.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/binutils-2.21/bfd/elflink.c b/binutils-2.21/bfd/elflink.c index 51dae66..753bb9c 100644 --- a/binutils-2.21/bfd/elflink.c +++ b/binutils-2.21/bfd/elflink.c @@ -11575,6 +11575,9 @@ struct elf_gc_sweep_symbol_info static bfd_boolean elf_gc_sweep_symbol (struct elf_link_hash_entry *h, void *data) { + if (h->root.type == bfd_link_hash_warning) + h = (struct elf_link_hash_entry *) h->root.u.i.link; + if (!h->mark && (((h->root.type == bfd_link_hash_defined || h->root.type == bfd_link_hash_defweak) -- cgit v1.1