From 056fffbf1f75b7296492e743c3948471252a6af5 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Thu, 26 Nov 2015 20:03:25 +0000 Subject: Fix "Bad value" error seen when building Mesa 11.0.6 which uses -Bsymbolic. Inspired by https://sourceware.org/ml/binutils/2010-08/msg00333.html, but expressed differently so there are no GPLv3 issues. --- gnu/usr.bin/binutils-2.17/bfd/elfxx-mips.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/usr.bin/binutils-2.17/bfd/elfxx-mips.c b/gnu/usr.bin/binutils-2.17/bfd/elfxx-mips.c index 0d4a623a44d..b28a010a847 100644 --- a/gnu/usr.bin/binutils-2.17/bfd/elfxx-mips.c +++ b/gnu/usr.bin/binutils-2.17/bfd/elfxx-mips.c @@ -4768,7 +4768,7 @@ mips_elf_create_dynamic_relocation (bfd *output_bfd, /* We must now calculate the dynamic symbol table index to use in the relocation. */ if (h != NULL - && (!h->root.def_regular + && (sec == NULL || !h->root.def_regular || (info->shared && !info->symbolic && !h->root.forced_local))) { indx = h->root.dynindx; -- cgit v1.2.3