1 /* Native-dependent definitions for NetBSD. 2 Copyright 1994, 1996 Free Software Foundation, Inc. 3 4 This file is part of GDB. 5 6 This program is free software; you can redistribute it and/or modify 7 it under the terms of the GNU General Public License as published by 8 the Free Software Foundation; either version 2 of the License, or 9 (at your option) any later version. 10 11 This program is distributed in the hope that it will be useful, 12 but WITHOUT ANY WARRANTY; without even the implied warranty of 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 GNU General Public License for more details. 15 16 You should have received a copy of the GNU General Public License 17 along with this program; if not, write to the Free Software 18 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ 19 20 /* "Support" the NetBSD-specific "-k" option. */ 21 #define ADDITIONAL_OPTIONS {"k", no_argument, 0, 'k'}, 22 #define ADDITIONAL_OPTION_CASES case 'k': \ 23 fprintf_unfiltered (gdb_stderr, \ 24 "-k: obsolete option. For kernel debugging, start gdb\n" \ 25 "with just the kernel name as an argument (no core file)\n" \ 26 "and then use the gdb command `target kcore COREFILE'.\n"); \ 27 exit (1); 28 /* End of "-k" stuff. */ 29 30 #define ATTACH_DETACH 31 32 /* Use this instead of KERNEL_U_ADDR (See gdb/infptrace.c) */ 33 #define FETCH_INFERIOR_REGISTERS 34 35 /* This enables functions needed by kcore-nbsd.c */ 36 #define FETCH_KCORE_REGISTERS 37 38 #define PTRACE_ARG3_TYPE char* 39 40 #include "solib.h" /* Support for shared libraries. */ 41 42 #ifndef SVR4_SHARED_LIBS 43 /* The NetBSD link.h structure definitions have different names 44 than the SunOS version, but the structures are very similar, 45 so we can use solib.c by defining the SunOS names. */ 46 #define link_object sod 47 #define lo_name sod_name 48 #define lo_library sod_library 49 #define lo_unused sod_reserved 50 #define lo_major sod_major 51 #define lo_minor sod_minor 52 #define lo_next sod_next 53 54 #define link_map so_map 55 #define lm_addr som_addr 56 #define lm_name som_path 57 #define lm_next som_next 58 #define lm_lop som_sod 59 #define lm_lob som_sodbase 60 #define lm_rwt som_write 61 #define lm_ld som_dynamic 62 #define lm_lpd som_spd 63 64 #define link_dynamic_2 section_dispatch_table 65 #define ld_loaded sdt_loaded 66 #define ld_need sdt_sods 67 #define ld_rules sdt_rules 68 #define ld_got sdt_got 69 #define ld_plt sdt_plt 70 #define ld_rel sdt_rel 71 #define ld_hash sdt_hash 72 #define ld_stab sdt_nzlist 73 #define ld_stab_hash sdt_filler2 74 #define ld_buckets sdt_buckets 75 #define ld_symbols sdt_strings 76 #define ld_symb_size sdt_str_sz 77 #define ld_text sdt_text_sz 78 #define ld_plt_sz sdt_plt_sz 79 80 #define rtc_symb rt_symbol 81 #define rtc_sp rt_sp 82 #define rtc_next rt_next 83 84 #define ld_debug so_debug 85 #define ldd_version dd_version 86 #define ldd_in_debugger dd_in_debugger 87 #define ldd_sym_loaded dd_sym_loaded 88 #define ldd_bp_addr dd_bpt_addr 89 #define ldd_bp_inst dd_bpt_shadow 90 #define ldd_cp dd_cc 91 92 #define link_dynamic _dynamic 93 #define ld_version d_version 94 #define ldd d_debug 95 #define ld_un d_un 96 #define ld_2 d_sdt 97 98 #endif /* SVR4_SHARED_LIBS */ 99