+2015-06-24 Yao Qi <yao.qi@linaro.org>
+
+ * lib/gdb.exp (supports_get_siginfo_type): New proc.
+ * gdb.base/siginfo-obj.exp: Invoke supports_get_siginfo_type.
+ * gdb.base/siginfo-thread.exp: Likewise.
+
2015-06-22 Yao Qi <yao.qi@linaro.org>
* boards/remote-gdbserver-on-localhost.exp: Add comments.
continue
}
-if { ! [istarget "i?86-*-linux*"]
- && ! [istarget "x86_64-*-linux*"]
- && ! [istarget "arm*-*-linux*"] } {
+if { ![supports_get_siginfo_type] } {
verbose "Skipping siginfo-obj.exp because of lack of support."
return
}
continue
}
-if { ! [istarget "i?86-*-linux*"]
- && ! [istarget "x86_64-*-linux*"]
- && ! [istarget "arm*-*-linux*"] } {
+if { ![supports_get_siginfo_type] } {
verbose "Skipping siginfo-thread.exp because of lack of support."
return
}
return $result
}
+# Return 1 if GDB can get a type for siginfo from the target, otherwise
+# return 0.
+
+proc supports_get_siginfo_type {} {
+ if { [istarget "i?86-*-linux*"]
+ || [istarget "x86_64-*-linux*"]
+ || [istarget "arm*-*-linux*"] } {
+ return 1
+ } else {
+ return 0
+ }
+}
+
# Return 1 if target hardware or OS supports single stepping to signal
# handler, otherwise, return 0.