Blame SOURCES/binutils-2.23.52.0.1-addr2line-dynsymtab.patch

83c6f5
--- a/bfd/opncls.c	2013-03-14 11:25:30.338306122 +0000
83c6f5
+++ b/bfd/opncls.c	2013-03-14 12:20:21.686397360 +0000
83c6f5
@@ -1297,6 +1297,8 @@
83c6f5
       bfd_malloc (strlen (debug_file_directory) + 1
83c6f5
                   + (canon_dirlen > dirlen ? canon_dirlen : dirlen)
83c6f5
                   + strlen (".debug/")
83c6f5
+#define FEDORA_LIB_DEBUG_DIR "/usr/lib/debug"
83c6f5
+		  + strlen (FEDORA_LIB_DEBUG_DIR) + strlen ("usr/")
83c6f5
                   + strlen (base)
83c6f5
                   + 1);
83c6f5
   if (debugfile == NULL)
83c6f5
@@ -1332,6 +1334,26 @@
83c6f5
   if (check_func (debugfile, crc32))
83c6f5
     goto found;
83c6f5
 
83c6f5
+  /* Then try in the global debug dir for Fedora libraries.  */
83c6f5
+  sprintf (debugfile, "%s%s%s", FEDORA_LIB_DEBUG_DIR, dir, base);
83c6f5
+  if (separate_debug_file_exists (debugfile, crc32))
83c6f5
+    {
83c6f5
+      free (base);
83c6f5
+      free (dir);
83c6f5
+      free (canon_dir);
83c6f5
+      return debugfile;
83c6f5
+    }
83c6f5
+
83c6f5
+  /* Then try in the usr subdirectory of the global debug dir for Fedora libraries.  */
83c6f5
+  sprintf (debugfile, "%s/usr%s%s", FEDORA_LIB_DEBUG_DIR, dir, base);
83c6f5
+  if (separate_debug_file_exists (debugfile, crc32))
83c6f5
+    {
83c6f5
+      free (base);
83c6f5
+      free (dir);
83c6f5
+      free (canon_dir);
83c6f5
+      return debugfile;
83c6f5
+    }
83c6f5
+  
83c6f5
   /* Then try in the global debugfile directory.  */
83c6f5
   strcpy (debugfile, debug_file_directory);
83c6f5
   dirlen = strlen (debug_file_directory) - 1;