Nick Clifton
fb52b2f459
Add ability for readelf to parse archives
2003-08-11 09:15:55 +00:00
Alan Modra
d3ba05513b
* objcopy.c: Remove unnecessary prototypes and casts.
...
* objdump.c: Remove unnecessary casts.
* readelf.c: Convert to C90. Remove unnecessary prototypes and casts.
(get_osabi_name): Move so we don't need a forward declaration.
2003-08-05 14:40:54 +00:00
Nick Clifton
96c223ce90
* readelf.c (get_data): Print (unsigned) hex values for size and offset in
...
error messages.
(process_section_headers): If the string table could not be allocated, do
not continue.
2003-07-04 10:42:26 +00:00
Jakub Jelinek
bdf4d63a1d
* readelf.c (dynamic_segment_ia64_val): Print address and newline
...
for sections by default. Comment fix.
2003-07-01 15:54:15 +00:00
Nick Clifton
d93f0186ba
Fix computation of offsets in PT_LOAD sections.
2003-06-26 12:46:17 +00:00
Nick Clifton
2c58cc864d
oops - remove spurious debugging left in previous delta
2003-06-19 10:24:52 +00:00
Nick Clifton
b19aac67f8
When printing DEC_5 values, if the number is bigger than 99999 switch to using
...
hexadecimal notation.
2003-06-19 10:23:39 +00:00
Jakub Jelinek
9ee5e4996f
binutils/
...
* readelf.c (get_segment_type): Handle PT_GNU_STACK.
bfd/
* elf.c (_bfd_elf_print_private_bfd_data): Handle PT_GNU_STACK.
(bfd_section_from_phdr): Likewise.
(map_sections_to_segments): Create PT_GNU_STACK segment header.
(get_program_header_size): Count with PT_GNU_STACK.
* elf-bfd.h (struct elf_obj_tdata): Add stack_flags.
* elflink.h (bfd_elfNN_size_dynamic_sections): Set stack_flags.
include/
* bfdlink.h (struct bfd_link_info): Add execstack and noexecstack.
* elf/common.h (PT_GNU_STACK): Define.
ld/
* ldgram.y (phdr_type): Grok PT_GNU_STACK.
* emultempl/elf32.em (gld${EMULATION_NAME}_handle_option): Add
-z execstack and -z noexecstack.
(gld${EMULATION_NAME}_list_options): Likewise.
* scripttempl/elf.sc: If not -r, discard .note.GNU-stack section.
2003-06-03 22:27:24 +00:00
Richard Henderson
38fafa6d08
* readelf.c (byte_get_signed): New.
...
(get_encoded_value): New.
(display_debug_frames): Use it. Always pre-process opcodes.
2003-05-31 19:29:19 +00:00
Michal Ludvig
636fc38722
2003-05-20 Michal Ludvig <mludvig@suse.cz>
...
* readelf.c (display_debug_frames): Print both registers
for DW_CFA_register.
2003-05-20 14:37:46 +00:00
H.J. Lu
8beeaeb703
2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
...
* readelf.c (dump_relocations): Enlarge the type field in wide
mode by one character.
2003-05-07 14:30:13 +00:00
Richard Henderson
6304463472
* readelf.c (struct Frame_Chunk): Add cfa_exp.
...
(frame_display_row): Just print "exp" for cfa or register
defined by a location expression.
(display_debug_frames): Handle DW_CFA_def_cfa_expression,
DW_CFA_expression, DW_CFA_MIPS_advance_loc8.
2003-05-04 00:20:43 +00:00
Joern Rennecke
ef23021837
bfd:
...
* archures.c (enum bfd_architecture): Amend comment to refer to SuperH.
* cpu-sh.c: Likewise.
* elf32-sh.c: Likewise.
* reloc.c (bfd_reloc_code_real): Likewise.
* elf32-sh64-com.c: Change comment to refer to SuperH.
* elf32-sh64.c: Likewise.
* elf64-sh64.c: Likewise.
* bfd-in2.h (enum bfd_architecture): Regenerate.
binutils:
* readelf.c (get_machine_name) <EM_SH>: Amend return value
to refer to SuperH.
gas:
* config/tc-sh.c: Amend comment to refer to SuperH.
* config/tc-sh.h: Likewise.
(LISTING_HEADER): Amend to refer to SuperH.
* config/tc-sh64.c: Change comment to refer to SuperH.
* config/tc-sh64.h (LISTING_HEADER): Change to refer to SuperH.
* doc/as.texinfo [SH, GENERIC]: Amend / Change to refer to SuperH.
* doc/c-sh.texi: Amend to refer to SuperH.
Add SuperH architecture documentation references.
* doc/c-sh64.texi: Change to refer to SuperH.
include/elf:
* common.h (EM_SH): Amend comment to refer to SuperH.
ld/testsuite:
* ld-sh/sh64/crange3-cmpct.rd (Machine): Change to refer to SuperH.
* ld-sh/sh64/crange3-media.rd (Machine): Likewise.
2003-04-23 21:09:04 +00:00
Nick Clifton
3f7de0e75e
Fix "readelf -wi" test
2003-04-23 17:36:08 +00:00
Nick Clifton
26597c8633
Replace references to Mitsubishi M32R with references to Renesas M32R.
2003-04-22 16:22:26 +00:00
Nick Clifton
c2dcd04ec8
Replace occurrances of 'Hitachi' with 'Renesas'.
2003-04-15 08:51:55 +00:00
Alexandre Oliva
adab8cdcb0
* readelf.c (display_debug_info): Apply RELA relocations on the
...
entire section.
(byte_put_little_endian, byte_put_big_endian): New functions.
(byte_put): New variable.
(get_file_header): Initialize it.
2003-04-09 04:07:56 +00:00
Nick Clifton
88da68203d
Add Xtensa port (omitted from previous delta)
2003-04-01 15:53:47 +00:00
H.J. Lu
566b0d53de
2003-03-31 H.J. Lu <hjl@gnu.org>
...
* readelf.c: Include "libiberty.h".
(dynamic_relocations): New.
(process_relocs): Properly handle dynamic relocation.
(process_dynamic_segment): Fill relocation elements in
dynamic_info.
2003-03-31 19:29:45 +00:00
Nick Clifton
ee42cf8cc5
Add some initial 64-bit DWARF support
2003-03-31 13:06:01 +00:00
Nick Clifton
ecc51f48c5
Add SHT_IA_64_LOPSREG, SHT_IA_64_HIPSREG and SHT_IA_64_PRIORITY_INIT.
...
Add code to display these values in readelf.
2003-02-21 12:17:51 +00:00
Nick Clifton
d3c543fde9
Add 'H' to getlongopts so that "readelf -H" does not display "unknown option"
2003-02-13 09:56:51 +00:00
Nick Clifton
fde78edd7a
Add support for marking ARM ELF binaries as support the Cirrus EP9312 Maverick
...
floating point co-processor.
2003-02-10 10:44:48 +00:00
Richard Sandiford
1a677ea81e
* readelf.c (dump_relocations): Reorder the r_info field for
...
little-endian mips elf64. Move #ifdef BFD64 to cover the new code.
2003-01-28 12:51:07 +00:00
Nick Clifton
8dde85fcdf
(display_debug_loc): Skip address base changes.
2003-01-21 15:41:10 +00:00
Alan Modra
c6f8bb1e76
* readelf.c (get_osabi_name): Handle ELFOSABI_AROS, ELFOSABI_OPENVMS
...
and ELFOSABI_NSK.
2003-01-17 01:34:01 +00:00
Alan Modra
c833c0197b
* readelf.c: Include elf/ppc64.h.
...
(dump_relocations <EM_PPC64>): Use elf_ppc64_reloc_type.
* Makefile.am: Run "make dep-am".
* Makefile.in: Regenerate.
2003-01-16 04:10:23 +00:00
Stan Cox
3b36097dde
* readelf.c (guess_is_rela): Handle EM_IQ2000.
...
(get_machine_name): Likewise.
(dump_relocations): Likewise.
* NEWS: Mention IQ2000 support.
2003-01-04 02:13:46 +00:00
Richard Sandiford
cb44e358cf
* readelf.c (get_machine_flags): Handle E_MIPS_ARCH_32R2.
2003-01-02 21:17:59 +00:00
Nick Clifton
2469cfa284
Add support for msp430.
2002-12-30 19:25:13 +00:00
Andreas Schwab
59f14fc0a3
* readelf.c (main): Reset dump request after each file.
2002-12-23 13:18:02 +00:00
Nick Clifton
84ad6ede87
Add support for displaying extension to DWARF2 used by Unified Parallel C
...
compiler.
2002-12-10 17:48:27 +00:00
Alan Modra
3e8bba361d
* readelf.c (process_program_headers): When setting loadaddr, don't
...
assume segment size is 4k. Use p_align instead.
(loadaddr): Change from int to long.
(dynamic_addr, dynamic_info, version_info): Likewise.
(process_dynamic_segment <syminsz>): Likewise.
(process_dynamic_segment): Adjust print format string.
(rela_addr, rela_size): Delete.
(process_relocs): Formatting.
2002-12-07 12:49:55 +00:00
Alan Modra
b34976b65a
s/boolean/bfd_boolean/ s/true/TRUE/ s/false/FALSE/. Simplify
...
comparisons of bfd_boolean vars with TRUE/FALSE. Formatting.
2002-11-30 08:39:46 +00:00
Jakub Jelinek
c8286bd1e8
* readelf.c Replace occurrences of Elf32_Internal_* and
...
Elf64_Internal_* with Elf_Internal_*.
(slurp_rel_relocs): Change Elf_Internal_Rel to Elf_Internal_Rela.
Zero r_addend fields.
(dump_relocations): Remove relas variable, change Elf_Internal_Rel to
Elf_Internal_Rela.
2002-11-29 00:03:30 +00:00
Nick Clifton
2f62977e68
Handle binaries with corrupt section or segment headers
2002-11-14 14:38:39 +00:00
Nick Clifton
232e7cb82c
Revert part of previous patch: Display unknown symbol types in decimal, not hex.
2002-11-07 08:33:15 +00:00
Nick Clifton
49814ed01f
oops - omitted fix to display unknown symbol type in hex.
2002-11-06 17:02:36 +00:00
Nick Clifton
5cf1065c25
Add hex number to PROCESSOR-specific, OS-specific, and reserved symbol types.
2002-11-06 17:00:57 +00:00
Alan Modra
f1ef08cb01
* readelf.c (byte_get_little_endian): Comment typo fix.
...
(print_symbol): Constify "symbol" arg. Don't pass "symbol" to printf
as the format string.
(dump_relocations): Correct section sym names.
(process_section_headers): Clear symtab_shndx_hdr.
(read_and_display_attr_value): Don't pass indirect string to printf
as the format string.
(display_debug_frames): Indicate when zero terminator found. Decode
DW_EH_PE_pcrel addresses.
2002-11-04 03:18:41 +00:00
Daniel Jacobowitz
09fc3b0230
* readelf.c (display_debug_info): Ignore empty .rela.debug_info
...
sections. Allow relocations against the absolute symbol. Don't
use the value in compunit.cu_abbrev_offset if we found a RELA
relocation.
2002-10-09 13:44:27 +00:00
H.J. Lu
810dfa6e36
2002-09-30 H.J. Lu <hjl@gnu.org>
...
* readelf.c (get_machine_flags): Handle E_MIPS_MACH_4120,
E_MIPS_MACH_5400 and E_MIPS_MACH_5500.
2002-10-01 03:27:56 +00:00
Nick Clifton
065c959b71
Handle DW_OP_GNU_push_tls_address.
...
Synch up with the gcc's dwarf2.h
2002-09-12 10:35:54 +00:00
Nick Clifton
069fe61f90
Remove redundant reference to E_V850EA_ARCH.
2002-08-29 15:43:47 +00:00
Alan Modra
c5b060adc5
* readelf.c (parse_args): Change debug_dump_opt to static.
2002-08-20 23:46:41 +00:00
Nick Clifton
61cd567514
Revert previous delta - it was bogus.
2002-08-17 09:59:34 +00:00
Nick Clifton
86f5577900
Put a newline after display an unknown dynamic type.
2002-08-16 14:41:15 +00:00
Alan Modra
35b1837e46
* readelf.c: Include elf/i370.h.
...
(dump_relocations): Handle EM_S370.
(dynamic_segment_parisc_val): Print \n.
(process_dynamic_segment <DT_BIND_NOW>): Here too.
2002-08-15 12:22:39 +00:00
Jakub Jelinek
2979dc3446
* readelf.c (OPTION_DEBUG_DUMP): Define.
...
(options): Use it.
(usage): Update help.
(parse_args): Handle --debug-dump separately from -w.
* doc/binutils.texi (readelf): Update documentation.
2002-07-30 14:33:40 +00:00
Nick Clifton
1e4cf259d2
Add IP2K support
2002-07-18 11:11:13 +00:00