Changeset 609 for branches/GNU/src/binutils/bfd/hppabsd-core.c
- Timestamp:
- Aug 16, 2003, 6:59:22 PM (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GNU/src/binutils/bfd/hppabsd-core.c
-
Property cvs2svn:cvs-rev
changed from
1.1to1.1.1.2
r608 r609 1 1 /* BFD back-end for HPPA BSD core files. 2 Copyright 1993, 1994, 1995, 1998, 1999, 2001 2 Copyright 1993, 1994, 1995, 1998, 1999, 2001 3 3 Free Software Foundation, Inc. 4 4 … … 49 49 #include <sys/file.h> 50 50 51 static asection *make_bfd_asection PARAMS ((bfd *, CONST char *, 52 flagword, bfd_size_type, 53 file_ptr, unsigned int)); 54 static asymbol *hppabsd_core_make_empty_symbol PARAMS ((bfd *)); 55 static const bfd_target *hppabsd_core_core_file_p PARAMS ((bfd *)); 56 static char *hppabsd_core_core_file_failing_command PARAMS ((bfd *)); 57 static int hppabsd_core_core_file_failing_signal PARAMS ((bfd *)); 58 static boolean hppabsd_core_core_file_matches_executable_p 51 static asection *make_bfd_asection 52 PARAMS ((bfd *, const char *, flagword, bfd_size_type, file_ptr, 53 unsigned int)); 54 static const bfd_target *hppabsd_core_core_file_p 55 PARAMS ((bfd *)); 56 static char *hppabsd_core_core_file_failing_command 57 PARAMS ((bfd *)); 58 static int hppabsd_core_core_file_failing_signal 59 PARAMS ((bfd *)); 60 static bfd_boolean hppabsd_core_core_file_matches_executable_p 59 61 PARAMS ((bfd *, bfd *)); 60 static void swap_abort PARAMS ((void)); 62 static void swap_abort 63 PARAMS ((void)); 61 64 62 65 /* These are stored in the bfd's tdata. */ … … 81 84 make_bfd_asection (abfd, name, flags, _raw_size, offset, alignment_power) 82 85 bfd *abfd; 83 CONSTchar *name;86 char *name; 84 87 flagword flags; 85 88 bfd_size_type _raw_size; … … 101 104 } 102 105 103 static asymbol *104 hppabsd_core_make_empty_symbol (abfd)105 bfd *abfd;106 {107 asymbol *new = (asymbol *) bfd_zalloc (abfd, sizeof (asymbol));108 if (new)109 new->the_bfd = abfd;110 return new;111 }112 113 106 static const bfd_target * 114 107 hppabsd_core_core_file_p (abfd) … … 122 115 /* Try to read in the u-area. We will need information from this 123 116 to know how to grok the rest of the core structures. */ 124 val = bfd_ read ((void *) &u, 1,sizeof u, abfd);117 val = bfd_ sizeof u, abfd); 125 118 if (val != sizeof u) 126 119 { … … 169 162 170 163 coredata = (struct hppabsd_core_struct *) 171 bfd_zalloc (abfd, sizeof (struct hppabsd_core_struct));164 bfd_zalloc (abfd, sizeof (struct hppabsd_core_struct)); 172 165 if (!coredata) 173 166 return NULL; … … 182 175 NBPG * (USIZE + KSTAKSIZE) 183 176 + clicksz * u.u_dsize, 2); 177 178 184 179 core_stacksec (abfd)->vma = USRSTACK; 185 180 … … 189 184 clicksz * u.u_dsize, 190 185 NBPG * (USIZE + KSTAKSIZE), 2); 186 187 191 188 core_datasec (abfd)->vma = UDATASEG; 192 189 … … 195 192 KSTAKSIZE * NBPG, 196 193 NBPG * USIZE, 2); 194 195 197 196 core_regsec (abfd)->vma = 0; 198 197 … … 200 199 core_signal (abfd) = u.u_code; 201 200 return abfd->xvec; 201 202 203 204 205 206 202 207 } 203 208 … … 218 223 219 224 /* ARGSUSED */ 220 static b oolean225 static boolean 221 226 hppabsd_core_core_file_matches_executable_p (core_bfd, exec_bfd) 222 227 bfd *core_bfd, *exec_bfd; 223 228 { 224 229 /* There's no way to know this... */ 225 return true; 226 } 227 228 229 #define hppabsd_core_get_symtab_upper_bound \ 230 _bfd_nosymbols_get_symtab_upper_bound 231 #define hppabsd_core_get_symtab _bfd_nosymbols_get_symtab 232 #define hppabsd_core_print_symbol _bfd_nosymbols_print_symbol 233 #define hppabsd_core_get_symbol_info _bfd_nosymbols_get_symbol_info 234 #define hppabsd_core_bfd_is_local_label_name \ 235 _bfd_nosymbols_bfd_is_local_label_name 236 #define hppabsd_core_get_lineno _bfd_nosymbols_get_lineno 237 #define hppabsd_core_find_nearest_line _bfd_nosymbols_find_nearest_line 238 #define hppabsd_core_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol 239 #define hppabsd_core_read_minisymbols _bfd_nosymbols_read_minisymbols 240 #define hppabsd_core_minisymbol_to_symbol _bfd_nosymbols_minisymbol_to_symbol 230 return TRUE; 231 } 232 241 233 242 234 /* If somebody calls any byte-swapping routines, shoot them. */ … … 288 280 }, 289 281 290 BFD_JUMP_TABLE_GENERIC (_bfd_generic),291 BFD_JUMP_TABLE_COPY (_bfd_generic),292 BFD_JUMP_TABLE_CORE (hppabsd_core),293 BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),294 BFD_JUMP_TABLE_SYMBOLS (hppabsd_core),295 BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),296 BFD_JUMP_TABLE_WRITE (_bfd_generic),297 BFD_JUMP_TABLE_LINK (_bfd_nolink),298 BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),282 BFD_JUMP_TABLE_GENERIC (_bfd_generic), 283 BFD_JUMP_TABLE_COPY (_bfd_generic), 284 BFD_JUMP_TABLE_CORE (hppabsd_core), 285 BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive), 286 ), 287 BFD_JUMP_TABLE_RELOCS (_bfd_norelocs), 288 BFD_JUMP_TABLE_WRITE (_bfd_generic), 289 BFD_JUMP_TABLE_LINK (_bfd_nolink), 290 BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic), 299 291 300 292 NULL, -
Property cvs2svn:cvs-rev
changed from
Note:
See TracChangeset
for help on using the changeset viewer.
