OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [gdb-5.3/] [gdb/] [ns32knbsd-tdep.c] - Blame information for rev 1773

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1181 sfurman
/* Target-dependent code for NS32000 systems running NetBSD.
2
   Copyright 2002 Free Software Foundation, Inc.
3
   Contributed by Wasabi Systems, Inc.
4
 
5
   This file is part of GDB.
6
 
7
   This program is free software; you can redistribute it and/or modify
8
   it under the terms of the GNU General Public License as published by
9
   the Free Software Foundation; either version 2 of the License, or
10
   (at your option) any later version.
11
 
12
   This program is distributed in the hope that it will be useful,
13
   but WITHOUT ANY WARRANTY; without even the implied warranty of
14
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15
   GNU General Public License for more details.
16
 
17
   You should have received a copy of the GNU General Public License
18
   along with this program; if not, write to the Free Software
19
   Foundation, Inc., 59 Temple Place - Suite 330,
20
   Boston, MA 02111-1307, USA.  */
21
 
22
#include "defs.h"
23
 
24
#include "ns32k-tdep.h"
25
#include "gdb_string.h"
26
 
27
static int
28
ns32knbsd_aout_in_solib_call_trampoline (CORE_ADDR pc, char *name)
29
{
30
  if (strcmp (name, "_DYNAMIC") == 0)
31
    return 1;
32
 
33
  return 0;
34
}
35
 
36
static void
37
ns32knbsd_init_abi_common (struct gdbarch_info info,
38
                           struct gdbarch *gdbarch)
39
{
40
  /* We only support machines with the 32382 FPU.  */
41
  ns32k_gdbarch_init_32382 (gdbarch);
42
}
43
 
44
static void
45
ns32knbsd_init_abi_aout (struct gdbarch_info info,
46
                         struct gdbarch *gdbarch)
47
{
48
  ns32knbsd_init_abi_common (info, gdbarch);
49
 
50
  set_gdbarch_in_solib_call_trampoline (gdbarch,
51
                                     ns32knbsd_aout_in_solib_call_trampoline);
52
}
53
 
54
static enum gdb_osabi
55
ns32knbsd_aout_osabi_sniffer (bfd *abfd)
56
{
57
  if (strcmp (bfd_get_target (abfd), "a.out-ns32k-netbsd") == 0)
58
    return GDB_OSABI_NETBSD_AOUT;
59
 
60
  return GDB_OSABI_UNKNOWN;
61
}
62
 
63
void
64
_initialize_ns32knbsd_tdep (void)
65
{
66
  gdbarch_register_osabi_sniffer (bfd_arch_ns32k, bfd_target_aout_flavour,
67
                                  ns32knbsd_aout_osabi_sniffer);
68
 
69
  gdbarch_register_osabi (bfd_arch_ns32k, GDB_OSABI_NETBSD_AOUT,
70
                          ns32knbsd_init_abi_aout);
71
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.