Revert "gdb: Remove MIPS NSIG patch"
authorKoen Vandeputte <koen.vandeputte@citymesh.com>
Tue, 15 Oct 2024 08:17:02 +0000 (10:17 +0200)
committerKoen Vandeputte <koen.vandeputte@citymesh.com>
Mon, 21 Oct 2024 07:19:01 +0000 (09:19 +0200)
This reverts commit 2758e1b21c35efbc9dbf40348afb4a73d88af207.

package/devel/gdb/patches/001-gdb-pr14523-mips-signal-number.patch [new file with mode: 0644]

diff --git a/package/devel/gdb/patches/001-gdb-pr14523-mips-signal-number.patch b/package/devel/gdb/patches/001-gdb-pr14523-mips-signal-number.patch
new file mode 100644 (file)
index 0000000..dd6cdbd
--- /dev/null
@@ -0,0 +1,16 @@
+See http://sourceware.org/bugzilla/show_bug.cgi?id=14523
+
+--- a/gdbsupport/signals.cc
++++ b/gdbsupport/signals.cc
+@@ -347,6 +347,11 @@ gdb_signal_from_host (int hostsig)
+       else if (64 <= hostsig && hostsig <= 127)
+       return (enum gdb_signal)
+         (hostsig - 64 + (int) GDB_SIGNAL_REALTIME_64);
++      else if (hostsig == 128)
++      /* Some platforms, such as Linux MIPS, have NSIG == 128, in which case
++         signal 128 is the highest realtime signal. There is no constant for
++         that though. */
++      return GDB_SIGNAL_UNKNOWN;
+       else
+       error (_("GDB bug: target.c (gdb_signal_from_host): "
+              "unrecognized real-time signal"));