aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog10
-rw-r--r--gdb/hpux-thread.c1
-rw-r--r--gdb/inftarg.c2
-rw-r--r--gdb/linux-nat.c5
-rw-r--r--gdb/target.c6
-rw-r--r--gdb/target.h2
-rw-r--r--gdb/win32-nat.c3
-rw-r--r--gdb/wince.c3
-rw-r--r--gdb/windows-nat.c3
9 files changed, 18 insertions, 17 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 78f4963..1e44065 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,13 @@
+2004-09-29 Andrew Cagney <cagney@gnu.org>
+
+ * target.h (child_ops): Declare.
+ * inftarg.c (child_ops): Move from here ...
+ * target.c (child_ops): ... to here.
+ * wince.c (child_ops): Delete extern declaration.
+ * win32-nat.c (child_ops): Delete extern declaration.
+ * linux-nat.c (child_ops): Delete extern declaration.
+ * hpux-thread.c (child_ops): Delete extern declaration.
+
2004-09-28 Mark Kettenis <kettenis@gnu.org>
* configure.tgt: Set default OS/ABI for OpenBSD ELF targets.
diff --git a/gdb/hpux-thread.c b/gdb/hpux-thread.c
index 5664314..ea776ee 100644
--- a/gdb/hpux-thread.c
+++ b/gdb/hpux-thread.c
@@ -45,7 +45,6 @@
#include "gdbcore.h"
extern int child_suppress_run;
-extern struct target_ops child_ops; /* target vector for inftarg.c */
extern void _initialize_hpux_thread (void);
diff --git a/gdb/inftarg.c b/gdb/inftarg.c
index 68efdac..b15b75b 100644
--- a/gdb/inftarg.c
+++ b/gdb/inftarg.c
@@ -89,8 +89,6 @@ static void init_child_ops (void);
extern char **environ;
-struct target_ops child_ops;
-
int child_suppress_run = 0; /* Non-zero if inftarg should pretend not to
be a runnable target. Used by targets
that can sit atop inftarg, such as HPUX
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
index 8ecabda..fa14bb6 100644
--- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c
@@ -83,8 +83,6 @@
static int debug_linux_nat;
-extern struct target_ops child_ops;
-
static int linux_parent_pid;
struct simple_pid_list
@@ -599,9 +597,6 @@ ptid_t trap_ptid;
/* This module's target-specific operations. */
static struct target_ops linux_nat_ops;
-/* The standard child operations. */
-extern struct target_ops child_ops;
-
/* Since we cannot wait (in linux_nat_wait) for the initial process and
any cloned processes with a single call to waitpid, we have to use
the WNOHANG flag and call waitpid in a loop. To optimize
diff --git a/gdb/target.c b/gdb/target.c
index 0e76e71e..ab0f814 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -159,6 +159,12 @@ static int debug_to_thread_alive (ptid_t);
static void debug_to_stop (void);
+/* NOTE: cagney/2004-09-29: Many targets reference this variable in
+ wierd and mysterious ways. Putting the variable here lets those
+ wierd and mysterious ways keep building while they are being
+ converted to the inferior inheritance structure. */
+struct target_ops child_ops;
+
/* Pointer to array of target architecture structures; the size of the
array; the current index into the array; the allocated size of the
array. */
diff --git a/gdb/target.h b/gdb/target.h
index 92becca..4af4799 100644
--- a/gdb/target.h
+++ b/gdb/target.h
@@ -1237,4 +1237,6 @@ extern void push_remote_target (char *name, int from_tty);
/* Blank target vector entries are initialized to target_ignore. */
void target_ignore (void);
+extern struct target_ops child_ops;
+
#endif /* !defined (TARGET_H) */
diff --git a/gdb/win32-nat.c b/gdb/win32-nat.c
index 601f28b..22edb09 100644
--- a/gdb/win32-nat.c
+++ b/gdb/win32-nat.c
@@ -86,9 +86,6 @@ static int debug_registers_used;
#define DEBUG_MEM(x) if (debug_memory) printf_unfiltered x
#define DEBUG_EXCEPT(x) if (debug_exceptions) printf_unfiltered x
-/* Forward declaration */
-extern struct target_ops child_ops;
-
static void child_stop (void);
static int win32_child_thread_alive (ptid_t);
void child_kill_inferior (void);
diff --git a/gdb/wince.c b/gdb/wince.c
index a9dafee..be912d6 100644
--- a/gdb/wince.c
+++ b/gdb/wince.c
@@ -126,9 +126,6 @@ upload_options[3] =
static char *remote_upload = NULL; /* Set by set remoteupload */
static int remote_add_host = 0;
-/* Forward declaration */
-extern struct target_ops child_ops;
-
static int win32_child_thread_alive (ptid_t);
void child_kill_inferior (void);
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c
index 601f28b..22edb09 100644
--- a/gdb/windows-nat.c
+++ b/gdb/windows-nat.c
@@ -86,9 +86,6 @@ static int debug_registers_used;
#define DEBUG_MEM(x) if (debug_memory) printf_unfiltered x
#define DEBUG_EXCEPT(x) if (debug_exceptions) printf_unfiltered x
-/* Forward declaration */
-extern struct target_ops child_ops;
-
static void child_stop (void);
static int win32_child_thread_alive (ptid_t);
void child_kill_inferior (void);