From abbc6945577e04e769a5d62ec3dcff571a091730 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Sun, 7 Nov 2004 21:31:19 +0000 Subject: [PATCH] * m68kbsd-nat.c (m68kbsd_fetch_inferior_registers): Rename from fetch_inferior_registers. Make static. (m68kbsd_store_inferior_registers): Rename from store_inferior_registers. Make static. (_initialize_m68kbsd_nat): Construct and add target vector. * config/m68k/nbsdaout.mh (NATDEPFILES): Remove infptrace.o and inftarg.o. Add inf-ptrace.o. (NAT_FILE): Set to tm-solib.h. (LOADLIBES): New variable. * config/m68k/nbsdelf.mh (NATDEPFILES): Remove infptrace.o and inftarg.o. Add inf-ptrace.o. (NAT_FILE): Delete variable. * config/m68k/obsd.mh (NATDEPFILES): Remove infptrace.o and inftarg.o. Add inf-ptrace.o. (NAT_FILE): Set to tm-solib.h. * config/m68k/nm-nbsdaout.h: Remove file. --- gdb/ChangeLog | 19 +++++++++++++++++++ gdb/config/m68k/nbsdaout.mh | 6 ++++-- gdb/config/m68k/nbsdelf.mh | 3 +-- gdb/config/m68k/nm-nbsdaout.h | 30 ------------------------------ gdb/config/m68k/obsd.mh | 4 ++-- gdb/m68kbsd-nat.c | 15 +++++++++++---- 6 files changed, 37 insertions(+), 40 deletions(-) delete mode 100644 gdb/config/m68k/nm-nbsdaout.h diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 2b171379c83..dedf2759b74 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,22 @@ +2004-11-07 Mark Kettenis + + * m68kbsd-nat.c (m68kbsd_fetch_inferior_registers): Rename from + fetch_inferior_registers. Make static. + (m68kbsd_store_inferior_registers): Rename from + store_inferior_registers. Make static. + (_initialize_m68kbsd_nat): Construct and add target vector. + * config/m68k/nbsdaout.mh (NATDEPFILES): Remove infptrace.o and + inftarg.o. Add inf-ptrace.o. + (NAT_FILE): Set to tm-solib.h. + (LOADLIBES): New variable. + * config/m68k/nbsdelf.mh (NATDEPFILES): Remove infptrace.o and + inftarg.o. Add inf-ptrace.o. + (NAT_FILE): Delete variable. + * config/m68k/obsd.mh (NATDEPFILES): Remove infptrace.o and + inftarg.o. Add inf-ptrace.o. + (NAT_FILE): Set to tm-solib.h. + * config/m68k/nm-nbsdaout.h: Remove file. + 2004-11-07 Daniel Jacobowitz * dwarf2-frame.c (struct dwarf2_frame_ops): Add signal_frame_p. diff --git a/gdb/config/m68k/nbsdaout.mh b/gdb/config/m68k/nbsdaout.mh index 90a43d70b68..910bd88218f 100644 --- a/gdb/config/m68k/nbsdaout.mh +++ b/gdb/config/m68k/nbsdaout.mh @@ -1,4 +1,6 @@ # Host: NetBSD/m68k a.out -NATDEPFILES= m68kbsd-nat.o fork-child.o infptrace.o inftarg.o \ +NATDEPFILES= m68kbsd-nat.o fork-child.o inf-ptrace.o \ solib.o solib-sunos.o -NAT_FILE= nm-nbsdaout.h +NAT_FILE= tm-solib.h + +LOADLIBES= -lkvm \ No newline at end of file diff --git a/gdb/config/m68k/nbsdelf.mh b/gdb/config/m68k/nbsdelf.mh index c58e348be7e..f2d97a14292 100644 --- a/gdb/config/m68k/nbsdelf.mh +++ b/gdb/config/m68k/nbsdelf.mh @@ -1,5 +1,4 @@ # Host: NetBSD/m68k ELF -NATDEPFILES= m68kbsd-nat.o bsd-kvm.o fork-child.o infptrace.o inftarg.o -NAT_FILE= config/nm-nbsd.h +NATDEPFILES= m68kbsd-nat.o bsd-kvm.o fork-child.o inf-ptrace.o LOADLIBES= -lkvm diff --git a/gdb/config/m68k/nm-nbsdaout.h b/gdb/config/m68k/nm-nbsdaout.h deleted file mode 100644 index e7415891657..00000000000 --- a/gdb/config/m68k/nm-nbsdaout.h +++ /dev/null @@ -1,30 +0,0 @@ -/* Native-dependent definitions for NetBSD/m68k a.out. - - Copyright 1996, 2002, 2004 Free Software Foundation, Inc. - - This file is part of GDB. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -#ifndef NM_NBSDAOUT_H -#define NM_NBSDAOUT_H - -#include "config/nm-nbsd.h" - -/* Get generic NetBSD a.out native definitions. */ -#include "config/nm-nbsdaout.h" - -#endif /* nm-nbsdaout.h */ diff --git a/gdb/config/m68k/obsd.mh b/gdb/config/m68k/obsd.mh index 54e4e9d7c2b..fdcd5be4634 100644 --- a/gdb/config/m68k/obsd.mh +++ b/gdb/config/m68k/obsd.mh @@ -1,6 +1,6 @@ # Host: OpenBSD/m68k -NATDEPFILES= m68kbsd-nat.o bsd-kvm.o fork-child.o infptrace.o inftarg.o \ +NATDEPFILES= m68kbsd-nat.o bsd-kvm.o fork-child.o inf-ptrace.o \ solib.o solib-sunos.o -NAT_FILE= nm-nbsdaout.h +NAT_FILE= tm-solib.h LOADLIBES= -lkvm diff --git a/gdb/m68kbsd-nat.c b/gdb/m68kbsd-nat.c index 34e94b4e2f9..dbb569d40d8 100644 --- a/gdb/m68kbsd-nat.c +++ b/gdb/m68kbsd-nat.c @@ -106,8 +106,8 @@ m68kbsd_collect_fpregset (struct regcache *regcache, /* Fetch register REGNUM from the inferior. If REGNUM is -1, do this for all registers (including the floating-point registers). */ -void -fetch_inferior_registers (int regnum) +static void +m68kbsd_fetch_inferior_registers (int regnum) { if (regnum == -1 || m68kbsd_gregset_supplies_p (regnum)) { @@ -135,8 +135,8 @@ fetch_inferior_registers (int regnum) /* Store register REGNUM back into the inferior. If REGNUM is -1, do this for all registers (including the floating-point registers). */ -void -store_inferior_registers (int regnum) +static void +m68kbsd_store_inferior_registers (int regnum) { if (regnum == -1 || m68kbsd_gregset_supplies_p (regnum)) { @@ -223,6 +223,13 @@ void _initialize_m68kbsd_nat (void); void _initialize_m68kbsd_nat (void) { + struct target_ops *t; + + t = inf_ptrace_target (); + t->to_fetch_registers = vaxbsd_fetch_inferior_registers; + t->to_store_registers = vaxbsd_store_inferior_registers; + add_target (t); + /* Support debugging kernel virtual memory images. */ bsd_kvm_add_target (m68kbsd_supply_pcb); } -- 2.30.2