File gdb-6.6-buildid-locate-rpm-suse.patch of Package gdb

Index: gdb-6.8.50.20090803/gdb/symfile.c
===================================================================
--- gdb-6.8.50.20090803.orig/gdb/symfile.c	2009-08-06 12:20:16.000000000 +0200
+++ gdb-6.8.50.20090803/gdb/symfile.c	2009-08-06 12:20:16.000000000 +0200
@@ -2203,8 +2203,12 @@ debug_print_missing (const char *binary,
 	fprintf_unfiltered (gdb_stdlog,
 			    _("Missing separate debuginfo for %s\n"), binary);
         if (debug != NULL)
-	  fprintf_unfiltered (gdb_stdlog, _("Try: %s %s\n"),
-			      "yum --enablerepo='*-debuginfo' install", debug);
+	  {
+	    const char *p = strrchr (debug, '/');
+	    fprintf_unfiltered (gdb_stdlog, _("Try: %s%.2s%.38s\"\n"),
+				"zypper install -C \"debuginfo(build-id)=",
+				p - 2, p + 1);
+	  }
       }
 }
 

openSUSE Build Service is sponsored by