Commit Graph

5091 Commits

Author SHA1 Message Date
Tristan Gingold bfea910e97 2010-08-03 Tristan Gingold <gingold@adacore.com>
* vms-misc.c (vms_convert_to_var): Make it static.
	(_bfd_vms_convert_to_var_unix_filename): Make it public.
2010-08-03 15:18:51 +00:00
Tristan Gingold 1222b29101 bfd/
2010-08-03  Tristan Gingold  <gingold@adacore.com>

	* makefile.vms (OBJS): Update list.

gas/
Index: gas/ChangeLog
2010-08-03  Tristan Gingold  <gingold@adacore.com>

	* makefile.vms (OBJS): Add Add compress-debug.c.
2010-08-03 14:29:00 +00:00
Tristan Gingold 5621317228 2010-08-03 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (_bfd_vms_slurp_egsd): Do not set SEC_HAS_CONTENTS
	nor SEC_RELOC for empty sections.
2010-08-03 09:26:30 +00:00
Tristan Gingold d833fa0d58 2010-08-03 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (evax_section_flags): Fix flags for absolute
	section.  Remove useless parenthesis.
2010-08-03 09:21:09 +00:00
Tristan Gingold 22b6a042aa 2010-08-03 Tristan Gingold <gingold@adacore.com>
* vms-lib.c (vms_lib_bread_raw): Change type of BUF argument.
	(vms_lib_bread, vms_lib_bopen): Adjust.
2010-08-03 08:49:01 +00:00
Alan Modra 85cfcbfb1a PR 11866
* elf.c (assign_file_positions_for_load_sections): Use p_vaddr to
	calculate off_adjust rather than first section vma.
2010-08-02 10:08:02 +00:00
H.J. Lu b20dd2ce19 Add ATTRIBUTE_UNUSED to info in compute_bucket_count.
2010-07-30  H.J. Lu  <hongjiu.lu@intel.com>

	* elflink.c (compute_bucket_count): Add ATTRIBUTE_UNUSED to info.
2010-07-30 16:29:58 +00:00
Anthony Green e95c64cb3b Add moxie-rtems support 2010-07-30 07:32:18 +00:00
Alan Modra d62b368413 * elf64-ppc.c (ppc64_elf_edit_toc): Always adjust local syms in
.toc section, even when none are used in relocs.
2010-07-29 07:35:58 +00:00
Maciej W. Rozycki 9684f07814 * elfxx-mips.h: Include "elf/mips.h".
(gprel16_reloc_p): New static inline function.
	* elfxx-mips.c (_bfd_mips_elf_check_relocs)
	[R_MIPS16_GOT16, R_MIPS_GOT16, R_MIPS_GOT_HI16, R_MIPS_GOT_LO16]:
	Use got16_reloc_p.
	(_bfd_mips_elf_relocate_section)[bfd_reloc_overflow]: Use
	gprel16_reloc_p.
	* elf32-mips.c (mips_info_to_howto_rel): Likewise.
	* elfn32-mips.c (mips_info_to_howto_rel): Likewise.
2010-07-27 21:18:52 +00:00
Maciej W. Rozycki 2b2c11bd2d Fix up last ChangeLog entry in gas/ and bfd/. 2010-07-27 21:14:49 +00:00
Nick Clifton 1cd986c585 Add support for v850E2 and v850E2V3 2010-07-23 14:52:54 +00:00
Alan Modra 21fd2dbd9c * archive.c (_bfd_archive_bsd44_construct_extended_name_table):
Correct format specifier.
2010-07-22 14:48:54 +00:00
Alan Modra c6a3cf87fb * ecoff.c: Don't include aout/ranlib.h.
(_bfd_ecoff_slurp_armap): Use correct struct for ardata->symdefs.
	(_bfd_ecoff_write_armap): Output ar_date and ar_size using
	_bfd_ar_spacepad.
2010-07-22 14:29:15 +00:00
Alan Modra 4c1534c7a2 * aoutx.h (some_aout_object_p): Don't set EXEC_P for files with
relocs.
2010-07-22 14:07:10 +00:00
Alan Modra f463846733 include/elf/
* internal.h (ELF_TBSS_SPECIAL): New macro, extracted from..
	(ELF_SECTION_SIZE): ..here.
	(ELF_SECTION_IN_SEGMENT_1): Add "strict" arg.
	(ELF_SECTION_IN_SEGMENT_STRICT): New macro.
bfd/
	* elf.c (assign_file_positions_for_load_sections): Check that
	zero size sections are allocated in segments too.
	(assign_file_positions_for_non_load_sections): Warn if zero
	size alloc sections are found here.
	(copy_elf_program_header): Don't drop zero size sections from
	segment map.
	(copy_private_bfd_data): Check for changes in zero size sections.
binutils/
	* readelf.c (process_program_headers): Don't ignore all zero size
	sections.
ld/testsuite/
	* ld-powerpc/tlsexe.r: Update.
	* ld-powerpc/tlsexetoc.r: Update.
	* ld-powerpc/tlsso.r: Update.
	* ld-powerpc/tlstocso.r: Update.
2010-07-20 14:08:32 +00:00
Alan Modra b559959291 * elf.c (_bfd_elf_map_sections_to_segments): Force new segment
for sections with overlapping LMAs.
	(assign_file_positions_for_load_sections): Catch overlap for
	sections that wrap around the address space.  Replace a
	warning that duplicates ld's --check-sections error with a
	warning that lma has been adjusted for overlapping sections.
2010-07-17 03:10:50 +00:00
Cary Coutant 8c2ccebd6b PR ld/11817
* dwarf2.c (read_section): Revert patch for compressed debug sections.
	(find_line): Likewise.
	(read_and_uncompress_section): Remove.
2010-07-14 22:18:07 +00:00
H.J. Lu a7b16ceb92 Don't allocate .got.plt section if there are no GOT nor PLT entries.
bfd/

2010-07-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/11812
	* elf32-i386.c (elf_i386_size_dynamic_sections): Don't
	 allocate .got.plt section if there are no GOT nor PLT
	 entries.
	 * elf64-x86-64.c (elf64_x86_64_size_dynamic_sections): Likewise.

ld/testsuite/

2010-07-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/11812
	* ld-elf/exclude3b.d: Don't run on ia64-*-*.  Replace .got with
	.dynamic.

	* ld-elf/exclude3d.d: New.
	* ld-i386/nogot1.d: Likewise.
	* ld-i386/nogot1.s: Likewise.
	* ld-x86-64/nogot1.d: Likewise.
	* ld-x86-64/nogot1.s: Likewise.

	* ld-i386/i386.exp: Run nogot1.
	* ld-x86-64/x86-64.exp: Likewise.
2010-07-14 00:30:57 +00:00
H.J. Lu bb1cb422ae Support garbage collection against STT_GNU_IFUNC symbols.
bfd/

2010-07-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/11791
	* elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Support
	garbage collection against STT_GNU_IFUNC symbols.

	* elf32-i386.c (elf_i386_get_local_sym_hash): Don't set
	elf.plt.offset/elf.got.offset to -1.
	(elf_i386_tls_transition): Skip TLS transition for functions.
	(elf_i386_gc_sweep_hook): Support STT_GNU_IFUNC symbols.

	* elf64-x86-64.c (elf64_x86_64_get_local_sym_hash): Don't set
	elf.plt.offset/elf.got.offset to -1.
	(elf64_x86_64_tls_transition): Skip TLS transition for functions.
	(elf64_x86_64_gc_sweep_hook): Support STT_GNU_IFUNC symbols.

ld/testsuite/

2010-07-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/11791
	* ld-ifunc/ifunc-10-i386.d: New.
	* ld-ifunc/ifunc-10-i386.s: Likewise.
	* ld-ifunc/ifunc-10-x86-64.d: Likewise.
	* ld-ifunc/ifunc-10-x86-64.s: Likewise.
	* ld-ifunc/ifunc-11-i386.d: Likewise.
	* ld-ifunc/ifunc-11-i386.s: Likewise.
	* ld-ifunc/ifunc-11-x86-64.d: Likewise.
	* ld-ifunc/ifunc-11-x86-64.s: Likewise.
2010-07-13 16:59:14 +00:00
H.J. Lu 9fff0c3957 Re-indent elf32-i386.c.
2010-07-12  H.J. Lu  <hongjiu.lu@intel.com>

	* elf32-i386.c (elf_i386_check_relocs): Re-indent.
	(elf_i386_relocate_section): Likewise.
2010-07-12 21:13:24 +00:00
H.J. Lu f5296ddc5e Initialize prev_line.
2010-07-06  H.J. Lu  <hongjiu.lu@intel.com>

	* dwarf2.c (add_line_info): Initialize prev_line.
2010-07-06 21:13:57 +00:00
Alan Modra 50248c890f bfd/
* elf32-ppc.c (ppc_elf_relax_section): Insert branch around
	trampolines only for .init and .fini sections.
ld/testsuite/
	* ld-powerpc/relax.s: Add branch back to _start.
	* ld-powerpc/relax.d: Update.
	* ld-powerpc/relaxr.d: Update.
2010-07-06 09:29:47 +00:00
Alan Modra 5b9144488e * elf32-ppc.c: Formatting.
(ppc_elf_finish_dynamic_sections): Don't make plt_entry var static.
2010-07-05 13:34:27 +00:00
Cary Coutant 0acf065b19 bfd/ChangeLog:
* compress.c (bfd_uncompress_section_contents): Add ATTRIBUTE_UNUSED.
	* dwarf2.c (read_and_uncompress_section): New function.
	(read_section): Call it.
	(find_line): Likewise.

binutils/ChangeLog:

	* objdump.c (load_specific_debug_section): Decompress section contents
	before applying relocations.
	* readelf.c (load_specific_debug_section): Update section size after
	decompression.

gas/ChangeLog:

	* Makefile.am: Add compress-debug.c and compress-debug.h.
	* Makefile.in: Regenerate.
	* config.in: Add HAVE_ZLIB_H.
	* configure.in: Check for zlib.h.
	* configure: Regenerate.

	* as.c (parse_args): Add --compress-debug-sections and
	--nocompress-debug-sections.
	* as.h (flag_compress_debug): New variable.
	* compress-debug.c: New file.
	* compress-debug.h: New file.
	* write.c: Include compress-debug.h.
	(compress_frag): New function.
	(compress_debug): New function.
	(write_object_file): Compress debug sections if requested.
2010-07-03 20:52:24 +00:00
Alan Modra 726d3ab069 * elf64-ppc.c (ppc64_elf_edit_toc): Use SYMBOL_CALLS_LOCAL rather
than SYMBOL_REFERENCES_LOCAL.
	(ppc64_elf_relocate_section): Likewise.
2010-07-01 09:48:26 +00:00
Alan Modra bddc25c9ca * elf64-ppc.c (ppc64_elf_edit_toc): Keep toc entries for ifuncs. 2010-07-01 04:12:29 +00:00
Alan Modra 360cfc9c8b remove maxq-coff port 2010-06-29 04:17:34 +00:00
Alan Modra 3f062f4418 * compress.c (bfd_uncompress_section_contents): Use ATTRIBUTE_UNUSED
to silence gcc warning.
2010-06-28 14:41:11 +00:00
Alan Modra 6bee8834bf * elf64-ppc.c (get_tls_mask): Don't segfault on NULL elf_section_data.
(group_sections): Likewise.
2010-06-27 08:37:22 +00:00
Alan Modra c7e2358a88 fix set but unused variable warnings 2010-06-27 04:07:55 +00:00
Tristan Gingold 4ba2ab9fc3 2010-06-25 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (_bfd_vms_write_egsd): Check absolute section with
	its flags.  Create an absolute section if needed.
2010-06-25 15:37:43 +00:00
Tristan Gingold 1b3d1dbfad 2010-06-25 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (_bfd_vms_write_egsd): Set target_index field of
	sections.  Mark .vmsdebug section as SEC_DEBUGGING.  Do not create
	dummy psect anymore.  Adjust.
	(_bfd_vms_write_eeom): Adjust (use target_index instead of index)
	(_bfd_vms_write_etir): Ditto.
	(start_etir_or_etbt_record): Test for SEC_DEBUGGING instead of
	section name.  Adjust.
2010-06-25 15:21:48 +00:00
Tristan Gingold 9714ee4866 2010-06-25 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (alpha_vms_write_exec): Set linktime field.
2010-06-25 14:54:19 +00:00
Alan Modra ba761f19f5 include/elf/
* ppc64.h (R_PPC64_LO_DS_OPT): Define.
bfd/
	* elf64-ppc.c (toc_skip_enum): Define.
	(ppc64_elf_edit_toc): Use two low bits of skip array as markers.
	Optimize largetoc sequences.
	(adjust_toc_syms): Update for skip array change.
	(ppc64_elf_relocate_section): Handle R_PPC64_LO_DS_OPT.
ld/
	* emultempl/ppc64elf.em (prelim_size_sections): New function.
	(ppc_before_allocation): Use it.  Size sections before toc edit too.
2010-06-25 05:20:57 +00:00
Alan Modra 854b41e7c1 * elf64-ppc.c (is_static_defined): New function.
(get_tls_mask, ppc_type_of_stub): Use it here.
	(ppc64_elf_edit_opd): Ensure we only attempt to edit ppc64 input.
	(ppc64_elf_tls_setup): Typo fix.
	(adjust_toc_syms): Correctly handle symbols defined past the end
	of the toc.  Move syms on removed entries to next entry rather
	than to start of toc.
	(ppc64_elf_edit_toc): Likewise.  Ensure we only attempt to
	edit ppc64 input.  Allocate one extra word in skip array.
	Honour info->keep_memory when reading relocs if we can.
	Adjust toc relocs after adjusting symbols.
2010-06-25 03:46:04 +00:00
Nathan Sidwell 61e8a5ea17 * archive64.c (bfd_elf64_archive_write_armap): Fix buffer overrun
when scaning map.
2010-06-23 10:21:16 +00:00
Tristan Gingold 24df9a516a 2010-06-17 Tristan Gingold <gingold@adacore.com>
* Makefile.am (BFD32_BACKENDS_CFILES): Move vms-alpha.c to ...
	(BFD64_BACKENDS_CFILES): ... here.
	(BFD32_BACKENDS): Move vms-alpha.lo to ...
	(BFD64_BACKENDS): ... here.
	* Makefile.in: Regenerate.
2010-06-17 08:19:14 +00:00
Joseph Myers 59e6276b64 bfd:
* elf-bfd.h (LEAST_KNOWN_OBJ_ATTRIBUTE): Decrease to 2.
	* elf32-tic6x.c (elf32_tic6x_obj_attrs_arg_type,
	elf32_tic6x_merge_arch_attributes, elf32_tic6x_merge_attributes,
	elf32_tic6x_merge_private_bfd_data): New.
	(bfd_elf32_bfd_merge_private_bfd_data,
	elf_backend_obj_attrs_arg_type, elf_backend_obj_attrs_section,
	elf_backend_obj_attrs_section_type, elf_backend_obj_attrs_vendor):
	Define.
	* elf32-tic6x.h (elf32_tic6x_merge_arch_attributes): Declare.

binutils:
	* readelf.c (display_tic6x_attribute, process_tic6x_specific):
	New.
	(process_arch_specific): Call process_tic6x_specific for
	EM_TI_C6000.

gas:
	* config/tc-tic6x.c: Include elf/tic6x.h.
	(tic6x_arch_attribute, tic6x_seen_insns): New.
	(tic6x_arch_table, tic6x_arches): Add attribute values.
	(tic6x_use_arch): Handle attribute settings.
	(tic6x_attributes_set_explicitly, s_tic6x_c6xabi_attribute,
	tic6x_attribute_table, tic6x_attributes,
	tic6x_convert_symbolic_attribute): New.
	(md_pseudo_table): Add c6xabi_attribute.
	(md_assemble): Set tic6x_seen_insns and tic6x_arch_attribute.
	(tic6x_set_attribute_int, tic6x_set_attributes): New.
	(tic6x_end): Call tic6x_set_attributes.
	* config/tc-tic6x.h (CONVERT_SYMBOLIC_ATTRIBUTE): Define.
	(tic6x_convert_symbolic_attribute): Declare.

gas/testsuite:
	* gas/elf/elf.exp: Set target_machine for tic6x-*-*.
	* gas/elf/section2.e-tic6x, gas/tic6x/attr-arch-directive-1.d,
	gas/tic6x/attr-arch-directive-1.s,
	gas/tic6x/attr-arch-directive-2.d,
	gas/tic6x/attr-arch-directive-2.s,
	gas/tic6x/attr-arch-directive-3.d,
	gas/tic6x/attr-arch-directive-3.s,
	gas/tic6x/attr-arch-directive-4.d,
	gas/tic6x/attr-arch-directive-4.s,
	gas/tic6x/attr-arch-directive-5.d,
	gas/tic6x/attr-arch-directive-5.s,
	gas/tic6x/attr-arch-opts-c62x.d, gas/tic6x/attr-arch-opts-c64x+.d,
	gas/tic6x/attr-arch-opts-c64x.d, gas/tic6x/attr-arch-opts-c674x.d,
	gas/tic6x/attr-arch-opts-c67x+.d, gas/tic6x/attr-arch-opts-c67x.d,
	gas/tic6x/attr-arch-opts-none-1.d,
	gas/tic6x/attr-arch-opts-none-2.d,
	gas/tic6x/attr-arch-opts-override-1.d,
	gas/tic6x/attr-arch-opts-override-2.d, gas/tic6x/empty.s: New.

include/elf:
	* tic6x-attrs.h: New.
	* tic6x.h: Include elf/tic6x-attrs.h for attribute table.
	(C6XABI_Tag_CPU_arch_none, C6XABI_Tag_CPU_arch_C62X,
	C6XABI_Tag_CPU_arch_C67X, C6XABI_Tag_CPU_arch_C67XP,
	C6XABI_Tag_CPU_arch_C64X, C6XABI_Tag_CPU_arch_C64XP,
	C6XABI_Tag_CPU_arch_C674X): Define.

ld:
	* emulparams/elf32_tic6x_le.sh (ATTRS_SECTIONS): Define.

ld/testsuite:
	* ld-elf/orphan3.d: Allow section names starting '_'.
	* ld-tic6x/attr-arch-c62x-c62x.d, ld-tic6x/attr-arch-c62x-c64x+.d,
	ld-tic6x/attr-arch-c62x-c64x.d, ld-tic6x/attr-arch-c62x-c674x.d,
	ld-tic6x/attr-arch-c62x-c67x+.d, ld-tic6x/attr-arch-c62x-c67x.d,
	ld-tic6x/attr-arch-c62x.s, ld-tic6x/attr-arch-c64x+-c62x.d,
	ld-tic6x/attr-arch-c64x+-c64x+.d, ld-tic6x/attr-arch-c64x+-c64x.d,
	ld-tic6x/attr-arch-c64x+-c674x.d,
	ld-tic6x/attr-arch-c64x+-c67x+.d, ld-tic6x/attr-arch-c64x+-c67x.d,
	ld-tic6x/attr-arch-c64x+.s, ld-tic6x/attr-arch-c64x-c62x.d,
	ld-tic6x/attr-arch-c64x-c64x+.d, ld-tic6x/attr-arch-c64x-c64x.d,
	ld-tic6x/attr-arch-c64x-c674x.d, ld-tic6x/attr-arch-c64x-c67x+.d,
	ld-tic6x/attr-arch-c64x-c67x.d, ld-tic6x/attr-arch-c64x.s,
	ld-tic6x/attr-arch-c674x-c62x.d, ld-tic6x/attr-arch-c674x-c64x+.d,
	ld-tic6x/attr-arch-c674x-c64x.d, ld-tic6x/attr-arch-c674x-c674x.d,
	ld-tic6x/attr-arch-c674x-c67x+.d, ld-tic6x/attr-arch-c674x-c67x.d,
	ld-tic6x/attr-arch-c674x.s, ld-tic6x/attr-arch-c67x+-c62x.d,
	ld-tic6x/attr-arch-c67x+-c64x+.d, ld-tic6x/attr-arch-c67x+-c64x.d,
	ld-tic6x/attr-arch-c67x+-c674x.d,
	ld-tic6x/attr-arch-c67x+-c67x+.d, ld-tic6x/attr-arch-c67x+-c67x.d,
	ld-tic6x/attr-arch-c67x+.s, ld-tic6x/attr-arch-c67x-c62x.d,
	ld-tic6x/attr-arch-c67x-c64x+.d, ld-tic6x/attr-arch-c67x-c64x.d,
	ld-tic6x/attr-arch-c67x-c674x.d, ld-tic6x/attr-arch-c67x-c67x+.d,
	ld-tic6x/attr-arch-c67x-c67x.d, ld-tic6x/attr-arch-c67x.s: New.
2010-06-16 00:36:04 +00:00
Joseph Myers 3de4a297ec * elf-bfd.h (LEAST_KNOWN_OBJ_ATTRIBUTE): Define.
(struct elf_backend_data): Update comment on obj_attrs_order.
	* elf-attrs.c (vendor_obj_attr_size, vendor_set_obj_attr_contents,
	_bfd_elf_copy_obj_attributes): Use LEAST_KNOWN_OBJ_ATTRIBUTE
	instead of hardcoded 4.
	* elf32-arm.c (elf32_arm_obj_attrs_order): Use
	LEAST_KNOWN_OBJ_ATTRIBUTE and LEAST_KNOWN_OBJ_ATTRIBUTE + 1
	instead of hardcoded 4 and 5.
	(elf32_arm_merge_eabi_attributes): Use LEAST_KNOWN_OBJ_ATTRIBUTE
	instead of hardcoded 4.
2010-06-15 23:10:10 +00:00
Kevin Buettner 84477db9a3 * elf32-h8300.c (elf_symbol_leading_char): Define. 2010-06-14 18:43:46 +00:00
Jan Kratochvil dddb0e800c bfd/
* vms-alpha.c (_bfd_vms_write_egsd): Make sname const.
2010-06-11 21:12:11 +00:00
Tristan Gingold f654f403d3 2010-06-11 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (_bfd_vms_slurp_egsd): Always set vma of absolute
	sections to 0.
2010-06-11 15:30:38 +00:00
Tristan Gingold ff150b92be 2010-06-11 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (evax_bfd_print_etir): Handle ETIR__C_STO_GBL_LW.
2010-06-11 15:21:15 +00:00
Tristan Gingold 81bb31c0d9 2010-06-11 Tristan Gingold <gingold@adacore.com>
* vms-misc.c (_bfd_vms_output_counted): Make VALUE argument const.
	Adjust cast.
	(_bfd_vms_output_dump): Make DATA argument const, adjust cast.
	* vms.h (_bfd_vms_output_counted, _bfd_vms_output_dump): Adjust.
	* vms-alpha.c (evax_section_flags): Make it const.
	(vms_secflag_by_name): Remove unused ABFD argument.
	Make SECTION_FLAGS and NAME arguments const. Clarify comment.
	(vms_esecflag_by_name): Make SECTION_FLAGS and NAME arguments const.
	(_bfd_vms_slurp_egsd): Adjust call to vms_secflag_by_name.
	(_bfd_vms_write_egsd): Remove useless cast.
2010-06-11 15:13:32 +00:00
Tristan Gingold cb3aabc79c 2010-06-10 Tristan Gingold <gingold@adacore.com>
* config.bfd: Remove #if/#endif so that som can be compiled on any
	host.
	* targets.c (_bfd_target_vector): Remove #if/#endif so that som
	can be used on any host.
2010-06-10 09:02:23 +00:00
Tristan Gingold e1f000f69c bfd/
2010-06-10  Tristan Gingold  <gingold@adacore.com>

	* som.c: Can now be compiled on any host.
	Include bfd headers instead of system one.
	(som_compute_checksum): Parameter is now a pointer to a
	som_external_header structure.  Adjust.
	(struct section_to_type): Field section is now const.
	(R_DLT_REL, R_AUX_UNWIND, R_SEC_STMT): Removed conditional
	definition.
	(R_LONG_PCREL_MODE, R_N0SEL, R_N1SEL, R_LINETAB): Ditto.
	(R_LINETAB_ESC, R_LTP_OVERRIDE, R_COMMENT): Ditto.
	(som_swap_clock_in, som_swap_clock_out): New functions.
	(som_swap_header_in, som_swap_header_out): Likewise.
	(som_swap_space_dictionary_in): Likewise.
	(som_swap_space_dictionary_out): Likewise.
	(som_swap_subspace_dictionary_in): Likewise.
	(som_swap_subspace_dictionary_record_out): Likewise.
	(som_swap_aux_id_in, som_swap_aux_id_out): Likewise.
	(som_swap_string_auxhdr_out): Likewise.
	(som_swap_compilation_unit_out): Likewise.
	(som_swap_exec_auxhdr_in): Likewise.
	(som_swap_exec_auxhdr_out): Likewise.
	(som_swap_lst_header_in): Likewise.
	(som_object_setup): Adjust parameter type using bfd types.
	(setup_sections): Likewise.  Ditto for object file types.
	Use intermediate variables for external representation and use the
	swap functions to convert.
	(som_object_p): Ditto.  Remove #ifdef/#endif on always defined
	macros.
	(som_prep_headers): Likewise.
	(som_write_symbol_strings): Likewise.
	(som_begin_writing): Likewise.
	(som_finish_writing): Likewise.
	(som_build_and_write_symbol_table): Likewise.
	(bfd_section_from_som_symbol): Likewise.
	(som_slurp_symbol_table): Likewise.
	(som_bfd_print_private_bfd_data): Likewise.
	(bfd_som_attach_aux_hdr): Likewise.  Clear the padding.
	(bfd_som_attach_compilation_unit): Likewise.
	(som_bfd_count_ar_symbols): Likewise.
	(som_bfd_fill_in_ar_symbols): Likewise.
	(som_slurp_armap): Likewise.
	(som_bfd_ar_write_symbol_stuff): Likewise.
	(som_write_armap): Likewise.  Use _bfd_ar_spacepad instead of
	sprintf to write header fields.
	* som.h: Include bfd headers instead of system one.
	(FILE_HDR_SIZE, AUX_HDR_SIZE): Removed.
	(struct somdata): Use bfd structures instead of system ones.
	(struct som_section_data_struct): Likewise.
	(struct som_subspace_dictionary_record): Removed (now in
	include/som/internal.h)

gas/
2010-06-10  Tristan Gingold  <gingold@adacore.com>

	* config/obj-som.h: Includes som/reloc.h
2010-06-10 08:51:46 +00:00
Tristan Gingold 318cadba83 2010-06-10 Tristan Gingold <gingold@adacore.com>
* targets.c (bfd_target_list): Remove hp/ux compiler work-around
	as bfd requires an ANSI-C compiler.
2010-06-10 08:16:11 +00:00
Tristan Gingold f0b3dbfc47 2010-06-09 Tristan Gingold <gingold@adacore.com>
* bfdio.c (bfd_bread): Fix the code to prevent reading past the
	end of archive members.
2010-06-09 13:28:31 +00:00
Tristan Gingold 7da73d69b0 2010-06-08 Tristan Gingold <gingold@adacore.com>
* som.c (som_bfd_free_cached_info): Do not free relocations as
	they were allocated with bfd_zalloc.
2010-06-08 15:43:38 +00:00