Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mark Kettenis <kettenis@wins.uva.nl>
To: gdb-patches@sources.redhat.com
Cc: dmj+@andrew.cmu.edu
Subject: [PATCH] Get rid of host <signal.h> in config/tm-linux.h
Date: Wed, 11 Jul 2001 01:19:00 -0000	[thread overview]
Message-ID: <200107110819.f6B8JZv19099@delius.kettenis.local> (raw)

As pointed out by Daniel Jacobowitz in his Linux/MIPS patch, including
the host <signal.h> in the tm.h file makes no sense.  This moves it to
the nm.h file and leaves reasonable defaults for REALTIME_LO and
REALTIME_HI in tm-linux.h.

Daniel, I think this should make it possible for you to include
tm-linux.h instead of copying over the relevant bits in
config/mips/tm-linux.h.

Checked in.

Mark


Index: ChangeLog
from  Mark Kettenis  <kettenis@gnu.org>

	* config/tm-linux.h: Do not include <signal.h>.  Instead provide
	reasonable defaults for REALTIME_LO and REALTIME_HI if they're not
	already defined.
	* config/nm-linux.h: Include <signal.h>.
	[__SIGRTMIN] (REALTIME_LO, REALTIME_HI): Define to __SIGRTMIN and
	(__SIGRTMAX + 1) respectively.

Index: config/tm-linux.h
===================================================================
RCS file: /cvs/src/src/gdb/config/tm-linux.h,v
retrieving revision 1.3
diff -u -p -r1.3 tm-linux.h
--- config/tm-linux.h 2001/03/06 08:21:20 1.3
+++ config/tm-linux.h 2001/07/11 08:06:51
@@ -19,15 +19,12 @@
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-/* Some versions of Linux have real-time signal support in the C library, and
-   some don't.  We have to include this file to find out.  */
-#include <signal.h>
+/* Pick reasonable defaults for the number of real-time signals.  */
 
-#ifdef __SIGRTMIN
-#define REALTIME_LO __SIGRTMIN
-#define REALTIME_HI (__SIGRTMAX + 1)
-#else
+#ifndef REALTIME_LO
 #define REALTIME_LO 32
+#endif
+#ifndef REALTIME_HI
 #define REALTIME_HI 64
 #endif
 
Index: config/nm-linux.h
===================================================================
RCS file: /cvs/src/src/gdb/config/nm-linux.h,v
retrieving revision 1.7
diff -u -p -r1.7 nm-linux.h
--- config/nm-linux.h 2001/05/15 00:03:37 1.7
+++ config/nm-linux.h 2001/07/11 08:06:51
@@ -1,4 +1,4 @@
-/* Native support for GNU/Linux, for GDB, the GNU debugger.
+/* Native support for GNU/Linux.
    Copyright 1999, 2000
    Free Software Foundation, Inc.
 
@@ -54,3 +54,13 @@ extern int linuxthreads_prepare_to_proce
 
 #define GDB_GREGSET_T  elf_gregset_t
 #define GDB_FPREGSET_T elf_fpregset_t
+
+/* Since we're building a native debugger, we can include <signal.h>
+   to find the range of real-time signals.  */
+
+#include <signal.h>
+
+#ifdef __SIGRTMIN
+#define REALTIME_LO	__SIGRTMIN
+#define REALTIME_HI	(__SIGRTMAX + 1)
+#endif


             reply	other threads:[~2001-07-11  1:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-11  1:19 Mark Kettenis [this message]
2001-07-11 14:44 ` Daniel Jacobowitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200107110819.f6B8JZv19099@delius.kettenis.local \
    --to=kettenis@wins.uva.nl \
    --cc=dmj+@andrew.cmu.edu \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox