# Return 0 if we should skip tests that require the libstdc++ stap
# probes. This must be invoked while gdb is running, after shared
-# libraries have been loaded.
-
-proc skip_libstdcxx_probe_tests {} {
- global gdb_prompt
+# libraries have been loaded. PROMPT_REGEXP is the expected prompt.
+proc skip_libstdcxx_probe_tests_prompt { prompt_regexp } {
set ok 0
gdb_test_multiple "info probe" "check for stap probe in libstdc++" {
- -re ".*libstdcxx.*catch.*\r\n$gdb_prompt $" {
+ -re ".*libstdcxx.*catch.*\r\n$prompt_regexp" {
set ok 1
}
- -re "\r\n$gdb_prompt $" {
+ -re "\r\n$prompt_regexp" {
}
}
return $ok
}
+# As skip_libstdcxx_probe_tests_prompt, with gdb_prompt.
+
+proc skip_libstdcxx_probe_tests {} {
+ global gdb_prompt
+ return [skip_libstdcxx_probe_tests_prompt "$gdb_prompt $"]
+}
+
# Return 1 if we should skip tests of the "compile" feature.
# This must be invoked after the inferior has been started.