OSDN Git Service

* config/nm-linux.h (struct objfile): Remove forward declaration.
authorMark Kettenis <kettenis@gnu.org>
Sun, 14 Oct 2001 20:59:23 +0000 (20:59 +0000)
committerMark Kettenis <kettenis@gnu.org>
Sun, 14 Oct 2001 20:59:23 +0000 (20:59 +0000)
(linuxthreads_new_objfile): Remove prototype.
(linuxthreads_pid_to_str): Remove prototype.
(PREPARE_TO_PROCEED): Redefine in terms of
lin_lwp_prepare_to_proceed.
(struct target_waitstatus): Forward declaration.
(child_wait): New prototype.
(CHILD_WAIT): Define.
(lin_lwp_attach_lwp, ATTACH_LWP, lin_thread_get_thread_signals,
GET_THREAD_SIGNAL): Moved here from arch-specific files.
* config/alpha/nm-linux.h, config/arm/nm-linux.h,
config/ia64/nm-linux.h, config/mips/nm-linux.h,
config/powerpc/nm-linux.h: Don't include <signal.h>.
(lin_lwp_attach_lwp, ATTACH_LWP, lin_thread_get_thread_signals,
GET_THREAD_SIGNAL): Remove.
* config/i386/nm-linux.h: Likewise.
(struct target_waitstatus, child_wait, CHILD_WAIT): Remove.
* config/m68k/linux.mh, config/sparc/linux.mh (NATDEPFILES):
Remove linux-thread.o.  Add proc-service.o, thread-db.o and
lin-lwp.o.
(LOADLIBES): New variable.

gdb/ChangeLog
gdb/config/alpha/nm-linux.h
gdb/config/arm/nm-linux.h
gdb/config/i386/nm-linux.h
gdb/config/ia64/nm-linux.h
gdb/config/m68k/linux.mh
gdb/config/mips/nm-linux.h
gdb/config/nm-linux.h
gdb/config/powerpc/nm-linux.h
gdb/config/sparc/linux.mh

index a18f0c3..28563c0 100644 (file)
@@ -1,5 +1,27 @@
 2001-10-14  Mark Kettenis  <kettenis@gnu.org>
 
+       * config/nm-linux.h (struct objfile): Remove forward declaration.
+       (linuxthreads_new_objfile): Remove prototype.
+       (linuxthreads_pid_to_str): Remove prototype.
+       (PREPARE_TO_PROCEED): Redefine in terms of
+       lin_lwp_prepare_to_proceed.
+       (struct target_waitstatus): Forward declaration.
+       (child_wait): New prototype.
+       (CHILD_WAIT): Define.
+       (lin_lwp_attach_lwp, ATTACH_LWP, lin_thread_get_thread_signals,
+       GET_THREAD_SIGNAL): Moved here from arch-specific files.
+       * config/alpha/nm-linux.h, config/arm/nm-linux.h,
+       config/ia64/nm-linux.h, config/mips/nm-linux.h,
+       config/powerpc/nm-linux.h: Don't include <signal.h>.
+       (lin_lwp_attach_lwp, ATTACH_LWP, lin_thread_get_thread_signals,
+       GET_THREAD_SIGNAL): Remove.
+       * config/i386/nm-linux.h: Likewise.
+       (struct target_waitstatus, child_wait, CHILD_WAIT): Remove.
+       * config/m68k/linux.mh, config/sparc/linux.mh (NATDEPFILES):
+       Remove linux-thread.o.  Add proc-service.o, thread-db.o and
+       lin-lwp.o.
+       (LOADLIBES): New variable.
+
        * sparc-nat.c (fetch_core_registers): Remove redundant prototype.
 
        * proc-service.c (BUILD_LWP): Redefine in terms of ptid_build.
index 72c6c8b..c86ecc3 100644 (file)
@@ -57,20 +57,4 @@ extern int get_longjmp_target (CORE_ADDR *);
    pointer to the first register.  */
 #define ALPHA_REGSET_BASE(regsetp)  ((long *) (regsetp))
 
-/* FIXME: kettenis/2000-09-03: This should be moved to ../nm-linux.h
-   once we have converted all Linux targets to use the new threads
-   stuff (without the #undef of course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t pid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
 #endif /* NM_LINUX_H */
index ce4e5ff..e2a1795 100644 (file)
@@ -30,20 +30,4 @@ extern int kernel_u_size (void);
 /* Override copies of {fetch,store}_inferior_registers in infptrace.c.  */
 #define FETCH_INFERIOR_REGISTERS
 
-/* FIXME: kettenis/2000-09-03: This should be moved to ../nm-linux.h
-   once we have converted all Linux targets to use the new threads
-   stuff (without the #undef of course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
 #endif /* NM_ARMLINUX_H */
index 089cb1b..8cc69ec 100644 (file)
@@ -63,14 +63,7 @@ extern void i386_linux_dr_reset_addr (int regnum);
 extern unsigned long i386_linux_dr_get_status (void);
 #define I386_DR_LOW_GET_STATUS() \
   i386_linux_dr_get_status ()
-
-/* We define this if link.h is available, because with ELF we use SVR4
-   style shared libraries.  */
-
-#ifdef HAVE_LINK_H
-#define SVR4_SHARED_LIBS
-#include "solib.h"             /* Support for shared libraries.  */
-#endif
+\f
 
 /* Override copies of {fetch,store}_inferior_registers in `infptrace.c'.  */
 #define FETCH_INFERIOR_REGISTERS
@@ -87,25 +80,4 @@ extern int cannot_store_register (int regno);
 /* Override child_resume in `infptrace.c'.  */
 #define CHILD_RESUME
 
-/* Override child_wait in `inftarg.c'.  */
-struct target_waitstatus;
-extern ptid_t child_wait (ptid_t ptid, struct target_waitstatus *ourstatus);
-#define CHILD_WAIT
-
-/* FIXME: kettenis/2000-09-03: This should be moved to ../nm-linux.h
-   once we have converted all Linux targets to use the new threads
-   stuff (without the #undef of course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
-#endif /* nm_linux.h */
+#endif /* nm-linux.h */
index 3d55b36..2c980c0 100644 (file)
@@ -76,20 +76,4 @@ extern int ia64_linux_insert_watchpoint (ptid_t ptid, CORE_ADDR addr,
 extern int ia64_linux_remove_watchpoint (ptid_t ptid, CORE_ADDR addr,
                                          int len);
 
-/* FIXME: kettenis/2000-09-03: This should be moved to ../nm-linux.h
-   once we have converted all Linux targets to use the new threads
-   stuff (without the #undef of course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
 #endif /* #ifndef NM_LINUX_H */
index 510274e..f3d40dd 100644 (file)
@@ -1,10 +1,15 @@
-# Host: Motorola m68k running Linux
+# Host: Motorola m68k running GNU/Linux.
 
 XM_FILE= xm-linux.h
 XDEPFILES=
 
 NAT_FILE= nm-linux.h
 NATDEPFILES= infptrace.o inftarg.o fork-child.o \
-       corelow.o core-aout.o m68klinux-nat.o linux-thread.o
+       corelow.o core-aout.o m68klinux-nat.o \
+       proc-service.o thread-db.o lin-lwp.o
+
+# The dynamically loaded libthread_db needs access to symbols in the
+# gdb executable.
+LOADLIBES = -ldl -rdynamic
 
 GDBSERVER_DEPFILES= low-linux.o
index 27fb1b1..16b241d 100644 (file)
@@ -47,20 +47,4 @@ int mips_linux_cannot_store_register (int regno);
 #define CANNOT_FETCH_REGISTER(regno) mips_linux_cannot_fetch_register (regno)
 #define CANNOT_STORE_REGISTER(regno) mips_linux_cannot_store_register (regno)
 
-/* FIXME: This should be moved to ../nm-linux.h once we have converted all
-   Linux targets to use the new threads stuff (without the #undef of
-   course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
 #endif /* NM_MIPSLINUX_H */
index a152400..59e5acb 100644 (file)
 /* Tell GDB that we can attach and detach other processes.  */
 #define ATTACH_DETACH
 
+/* 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
+
 /* We define this if link.h is available, because with ELF we use SVR4
    style shared libraries.  */
 
 #endif
 \f
 
-/* FIXME: kettenis/2001-07-11: Stuff on this page is obsolete, and
-   only used by the (unmaintained) sparc and m68k ports.  */
-
-/* Support for the glibc LinuxThreads package.  */
-
-struct objfile;
+/* Override child_wait in `inftarg.c'.  */
+struct target_waitstatus;
+extern ptid_t child_wait (ptid_t ptid, struct target_waitstatus *ourstatus);
+#define CHILD_WAIT
 
-/* Hook to look at new objfiles (shared libraries).  */
-extern void linuxthreads_new_objfile (struct objfile *objfile);
+extern int lin_lwp_prepare_to_proceed (void);
+#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
 
-/* Method to print a human-readable thread description.  */
-extern char *linuxthreads_pid_to_str (ptid_t ptid);
+extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
+#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
 
-extern int linuxthreads_prepare_to_proceed (int step);
-#define PREPARE_TO_PROCEED(select_it) linuxthreads_prepare_to_proceed (1)
-\f
+extern void lin_thread_get_thread_signals (sigset_t *mask);
+#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
 
 /* Defined to make stepping-over-breakpoints be thread-atomic.  */
 #define USE_THREAD_STEP_NEEDED 1
+\f
 
 /* Use elf_gregset_t and elf_fpregset_t, rather than
    gregset_t and fpregset_t.  */
 
 #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
index 3835f74..d919d8e 100644 (file)
@@ -33,20 +33,4 @@ extern int kernel_u_size (void);
 #define REGISTER_U_ADDR(addr, blockend, regno) \
         (addr) = ppc_register_u_addr ((blockend),(regno));
 
-/* FIXME: kettenis/2000-09-03: This should be moved to ../nm-linux.h
-   once we have converted all Linux targets to use the new threads
-   stuff (without the #undef of course).  */
-
-extern int lin_lwp_prepare_to_proceed (void);
-#undef PREPARE_TO_PROCEED
-#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
-
-extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
-#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t *mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
 #endif /* #ifndef NM_LINUX_H */
index 937be17..71352b4 100644 (file)
@@ -1,8 +1,15 @@
-# Host: Sparcstation, running Linux
-XDEPFILES=
+# Host: Sparcstation, running GNU/Linux.
+
 XM_FILE= xm-linux.h
+XDEPFILES=
+
 NAT_FILE= nm-linux.h
 NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o sparc-nat.o \
-       linux-thread.o
+       proc-service.o thread-db.o lin-lwp.o
+
+# The dynamically loaded libthread_db needs access to symbols in the
+# gdb executable.
+LOADLIBES = -ldl -rdynamic
+
 HOST_IPC=-DBSD_IPC
 GDBSERVER_DEPFILES= low-sparc.o