Blame SOURCES/gdb-core-open-vdso-warning.patch

e1d87d
http://sourceware.org/ml/gdb-patches/2009-10/msg00142.html
e1d87d
Subject: [patch] Fix GNU/Linux core open: Can't read pathname for load map:  Input/output error.
e1d87d
e1d87d
[ New patch variant.  ]
e1d87d
e1d87d
commit 7d760051ffb8a23cdc51342d4e6243fbc462f73f
e1d87d
Author: Ulrich Weigand <uweigand@de.ibm.com>
e1d87d
Date:   Wed Sep 25 11:52:50 2013 +0000
e1d87d
e1d87d
Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/solib-symbol.exp
e1d87d
===================================================================
e1d87d
--- gdb-7.6.50.20130731-cvs.orig/gdb/testsuite/gdb.base/solib-symbol.exp	2013-08-02 16:27:28.833259471 +0200
e1d87d
+++ gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/solib-symbol.exp	2013-08-02 16:28:22.549330973 +0200
e1d87d
@@ -29,6 +29,7 @@ set testfile "solib-symbol-main"
e1d87d
 set srcfile ${srcdir}/${subdir}/${testfile}.c
e1d87d
 set binfile [standard_output_file ${testfile}]
e1d87d
 set bin_flags [list debug shlib=${binfile_lib}]
e1d87d
+set executable ${testfile}
e1d87d
 
e1d87d
 if [get_compiler_info] {
e1d87d
     return -1
e1d87d
@@ -72,8 +73,26 @@ gdb_test "br foo2" \
e1d87d
 	 "Breakpoint.*: foo2. .2 locations..*" \
e1d87d
 	 "foo2 in mdlib"
e1d87d
 
e1d87d
-gdb_exit
e1d87d
+# Test GDB warns for shared libraris which have not been found.
e1d87d
 
e1d87d
-return 0
e1d87d
+gdb_test "info sharedlibrary" "/${libname}.*"
e1d87d
 
e1d87d
+clean_restart ${executable}
e1d87d
+gdb_breakpoint "main"
e1d87d
+gdb_run_cmd
e1d87d
+set test "no warning for missing libraries"
e1d87d
+gdb_test_multiple "" $test {
e1d87d
+    -re "warning: Could not load shared library symbols for \[0-9\]+ libraries,.*\r\n$gdb_prompt $" {
e1d87d
+	fail $test
e1d87d
+    }
e1d87d
+    -re "Breakpoint \[0-9\]+, main .*\r\n$gdb_prompt $" {
e1d87d
+	pass $test
e1d87d
+    }
e1d87d
+}
e1d87d
 
e1d87d
+clean_restart ${executable}
e1d87d
+gdb_test_no_output "set solib-absolute-prefix /doESnotEXIST"
e1d87d
+gdb_breakpoint "main"
e1d87d
+gdb_run_cmd
e1d87d
+gdb_test "" "warning: Could not load shared library symbols for \[0-9\]+ libraries,.*\r\nBreakpoint \[0-9\]+, main .*" \
e1d87d
+	 "warning for missing libraries"