patches/glibc/ports-2.13/630-mips_shn_undef-hack.patch
changeset 2438 2ba5655f6297
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/patches/glibc/ports-2.13/630-mips_shn_undef-hack.patch	Tue May 03 00:19:56 2011 +0200
     1.3 @@ -0,0 +1,16 @@
     1.4 +diff -durN glibc-2.13.orig/elf/dl-lookup.c glibc-2.13/elf/dl-lookup.c
     1.5 +--- glibc-2.13.orig/elf/dl-lookup.c	2009-03-30 23:14:32.000000000 +0200
     1.6 ++++ glibc-2.13/elf/dl-lookup.c	2009-11-13 00:51:36.000000000 +0100
     1.7 +@@ -301,6 +301,12 @@
     1.8 + 	      /* FALLTHROUGH */
     1.9 + 	    case STB_GLOBAL:
    1.10 +	    success:
    1.11 ++#ifdef __mips__
    1.12 ++	      /* HACK: MIPS marks its lazy evaluation stubs with SHN_UNDEF
    1.13 ++		 symbols, we skip them. */
    1.14 ++	      if (sym->st_shndx == SHN_UNDEF)
    1.15 ++		break;
    1.16 ++#endif
    1.17 + 	      /* Global definition.  Just what we need.  */
    1.18 + 	      result->s = sym;
    1.19 + 	      result->m = (struct link_map *) map;