Commit Graph

12 Commits

Author SHA1 Message Date
Jeff Law c40439a219 * som.c (hppa_som_gen_reloc_type): New argument "sym_diff",
nonzero when we're generating relocations for an expression
	using the difference of two symbols.  All callers changed.
	Handle difference of symbols for both R_HPPA and R_COMPLEX
	cases.
	(som_write_fixups): Handle R_COMP1, R_COMP2 and R_CODE_EXPR
	fixups.
1995-07-03 23:27:25 +00:00
Jeff Law 8a2cdc6278 * som.h (som_symbol_type): Add "stringtab_offset" field.
* som.c (som_write_symbol_strings): Use "stringtab_offset"
	rather than destroying the "name" field in the BFD symbol.
	(som_build_and_write_symbol_table): Likewise.
1994-09-14 21:44:35 +00:00
Jeff Law e10639db44 * som.h (som_symbol_type): Delete unwind field.
* som.c (som_write_fixups): For R_ENTRY fixups, get 32bits of
	unwind information from the addend field of the R_ENTRY, get the
	other 32bits from the addend field of the R_EXIT.
	(bfd_som_attach_unwind_info): Delete function and all references.
1994-09-14 02:28:52 +00:00
Jeff Law 39836432f8 * som.h (som_symbol_type): Delete unused a.out-related fields.
* som.c (bfd_section_from_som_symbol): Use bfd_abs_section_ptr
	instead of &bfd_abs_section.
1994-09-14 00:51:33 +00:00
Jeff Law edf7c1e4fe * som.h (R_HPPA_COMPLEX): Define.
* elf32-hppa.h (R_HPPA_COMPLEX): Define.
	(elf32_hppa_reloc_type): Delete R_PARISC_STUB_CALL_17.
1994-07-05 01:19:31 +00:00
Jeff Law 459ae909b9 * bfd-in2.h: Rebuilt.
* elf32-hppa.c: Change .hppa_linker_stubs to .PARISC.stubs,
	likewise for other PA specific sections.
	(hppa_elf_relocate_unwind_table): Delete unused
	function.
	(elf_hppa_howto_table): Completely new table based on 94-02-02
	draft PA ELF spec.  Change relocation tags appropriately
	throughout elf32-hppa.c
	(hppa_elf_gen_reloc_type): Rewrite and simplify based on 94-02-02
	spec.
	(hppa_elf_reloc): Likewise.
	(hppa_look_for_stubs_in_section): Likewise
	(ELF_MACHINE_CODE): Change to EM_PARISC.
	* elf32-hppa.h: Include "elf/hppa.h".  Change relocation tags
	appropriately throughout elf32-hppa.h.
	(elf32_hppa_reloc_type): New table based on 94-02-02 draft PA ELF
	spec.
	(R_HPPA_ABS_CALL, R_HPPA_COMPLEX*, R_HPPA_UNWIND): Delete definitions.
	* elfcode.h (prep_headers): Use EM_PARISC instead of EM_HPPA.
	* reloc.c (bfd_reloc_code_real): Delete unused HPPA relocations.
	* som.h (R_HPPA_ABS_CALL, R_HPPA_COMPLEX): Delete definitions.

	* libhppa.h (hppa_field_adjust): Avoid adding constant_value into
	the final value twice for LR and RR field selectors.
1994-05-16 19:34:13 +00:00
Jeff Law 4359a7ef33 * som.h (struct som_exec_data): New structure to hold exec
info that must be preserved when running objcopy/strip.
	(struct somdata): Add new "exec_data" field and accessor
	macro.  Add some comments on how the various fields are used.
	(som_section_data_struct): Make is_space and is_subspace bitfields.
	Delete unused subspace_index.  All references now use the
	target_index field within the section structure itself.

	* som.c (make_unique_section): Delete unused declaration.
	(som_bfd_copy_private_bfd_data): New function.
	(som_object_setup): Allocate space for and save exec information
	that needs to be copied during objcopy/strip.
	(som_mkobject): Do not allocate space for a file header here.
	It is not used when only reading SOM objects.
	(som_prep_headers): Allocate space for and attach a file header
	to the output bfd.  For executables, use the saved system_id
	value rather than trying to guess the right value.  Do not abort
	wwhen setting file_hdr->entry* for executables.
	(som_begin_writing): For executables, set the exec_entry and
	exec_flags fields.
	(som_copy_private_backend_section_data): Always return a value.
1994-03-19 05:06:54 +00:00
Jeff Law 7b5f6e48f1 * som.h (_PA_RISC_ID): Treat HOST_HPPAOSF just like HOST_HPPABSD. 1994-03-04 04:04:48 +00:00
Jeff Law 4e64845ca5 * som.[ch]: Do not include libhppa.h in som.c, instead include
it in som.h.

        * elf32-hppa.[ch]: Do not include libhppa.h in elf32-hppa.c, instead
        include it in elf32-hppa.h.
1994-03-02 23:04:29 +00:00
Jeff Law 44fd66228a * som.c (hppa_som_gen_reloc_type): Use correct enum type for
field parameter.
        (bfd_som_set_section_attributes): Use unsigned int rather than
        unsigned char to avoid GNU-C extensions.
        (bfd_som_attach_aux_hdr): Return a boolean to indicate success
        or failure rather than aborting on failure.

        * som.h (bfd_som_set_section_attributes): Fix prototype to match
        som.c changes.
        (bfd_som_attach_aux_hdr): Add prototype.
        (hppa_som-gen_reloc_type): Likewise.

        * elf32-hppa.c: Add a couple casts to make HP compiler happy.
        (hppa_look_for_stubs_in_section): Do not return false on failure
        until rest of code is ready to handle it.  Abort for now.
1994-03-02 19:59:03 +00:00
Jeff Law 6863eb4b74 * som.h: Include <lst.h> and <ar.h>. 1994-02-13 22:30:51 +00:00
Jeff Law 176ed088ef * som.h (struct som_symbol): Add new fields to hold additional
information needed to build/write symbol tables and fixup streams.
	(struct som_section_data_struct): Add new fields to hold additional
	information needed to build/write space and subspace headers.
	(som_symbol_data): New accessor macro for SOM symbol information.
	(R_HPPA_*): Basic relocation types to be used by the assembler.
1993-11-12 23:08:13 +00:00