crosstool-ng/packages/glibc/2.14.1/0032-mips_shn_undef-hack.patch

20 lines
496 B
Diff
Raw Normal View History

---
elf/dl-lookup.c | 6 ++++++
1 file changed, 6 insertions(+)
--- a/elf/dl-lookup.c
+++ b/elf/dl-lookup.c
@@ -300,6 +300,12 @@
/* FALLTHROUGH */
case STB_GLOBAL:
success:
+#ifdef __mips__
+ /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
+ symbols, we skip them. */
+ if (sym->st_shndx == SHN_UNDEF)
+ break;
+#endif
/* Global definition. Just what we need. */
result->s = sym;
result->m = (struct link_map *) map;