Commit Graph

309 Commits

Author SHA1 Message Date
Ian Lance Taylor 6082cdd566 Forgot to commit ChangeLog. 1993-01-08 21:26:42 +00:00
David D. Zuhn 240f485a41 use bfd_xmalloc instead of malloc 1993-01-06 08:24:08 +00:00
Ken Raeburn 7a938fa53d Temporary hack until Per's solution gets implemented: If --with-minimal-bfd is
specified, set MINIMIZE=1.  (Not the default.)
1993-01-05 14:57:44 +00:00
Steve Chamberlain 27de82c603 * srec.c (srec_write_records): one of my boards wants a CR between
records.
1993-01-04 15:21:21 +00:00
Ian Lance Taylor 7b4eaa0ee6 Wed Dec 30 12:46:30 1992 Ian Lance Taylor (ian@cygnus.com)
* archive.c (do_slurp_coff_armap): set symdef_count correctly
	(it broke a couple of weeks ago).
1992-12-30 20:49:21 +00:00
Ken Raeburn c3efeb9248 fix libbfd.h declaration, by tweaking elf.c comment, so bfd can compile 1992-12-30 02:48:29 +00:00
Ian Lance Taylor cc29d6659b Tue Dec 29 13:54:35 1992 Ian Lance Taylor (ian@cygnus.com)
* coffcode.h (coff_real_object_p): use name I386AIXMAGIC rather
	than I386SVMAGIC.
	(coff_pointerize_aux): don't pointerize a negative tagndx
	(sometimes generated by SCO 3.2v4 cc).

	* bout.c (calljx_callback, callj_callback,
	b_out_get_relocated_section_contents): warn if relocating against
	an undefined symbol.
1992-12-29 21:59:15 +00:00
Stu Grossman edff05870e * hppa.c: Get rid of DEFUN, use more conventional prolog stuff.
Make a bunch more routines be static.
* hppa.c (fill_spaces):  Get rid of this, replace with much better
written setup_sections().
* (setup_sections):  New routine to create BFD sections for each
space and subspace in SOM files.
* (hppa_object_setup):  Use BFD sections created by
setup_sections() to locate GDB symbol table info.
* (make_unique_section):  New routine to create a BFD section.  It
ensures that the given name is unique, and will generate a unique
one if necessary.
* (hppa_object_p):  Become much more paranoid about file header.
* (make_bfd_asection):  Call bfd_make_section to do the dirty
work.  Simplify code somewhat.
* (hppa_core_file_p):  Use proper name for stack section.
* libhppa.h:  Remove millicode_start, millicode_end decls.
1992-12-28 22:57:19 +00:00
Ken Raeburn 5145ac4f24 today's changes 1992-12-28 19:11:56 +00:00
Fred Fish e555d76415 * bfd.c (bfd_get_size): New function that gets an upper bound
on the possible size of any object in a bfd.
	* elf.c (bfd_elf_find_section, elf_get_str_section,
	elf_get_symtab_upper_bound):  Rewrite to avoid NULL pointer
	dereferences.
	* elf.c (elf_big_vec, elf_little_vec):  Document last three
	members initialized to NULL.
1992-12-28 01:51:57 +00:00
David D. Zuhn 75dd6a3e4b * hppa.c: change a 'const' to 'CONST', or else HP C compiler dies 1992-12-25 01:50:27 +00:00
David D. Zuhn 74991624b2 added dvi target 1992-12-24 22:44:50 +00:00
Per Bothner 0e238aa74b * bfd-in.h: New macros bfd_asymbol_bfd and bfd_asymbol_flavour;
perhaps we can later remove the the_bfd field from each symbol.
	* syms.c (struct symbol_cache_entry):  Remove unused field
	app_data.  Add comment noting that the_bfd is almost redundant,
	but not quite.
	* aoutx.h, coff-a29k.c, coff-i386.c, coff-i960.c, coffcode.h:
	Use new macros bfd_asymbol_bfd and bfd_asymbol_flavour.
	* hppa.c (fill_spaces):  Make slightly more rebust.
	* configure.in:  Allow std-host as the "default" host.
1992-12-22 23:40:27 +00:00
Stu Grossman d70d5a2601 * bfd.c: Add struct hppa_core_data to tdata union. 1992-12-22 05:28:27 +00:00
Stu Grossman 205d660d59 * hppa.c: Conditionalize on HOST_HPPAHPUX instead of hp9000s800.
Get rid of HPPA/BSD specific code.  That will go somewhere else
someday.
* (fill_spaces):  Don't spin forever and die if you don't find
$MILLICODE$ subspace.
* (hppa_object_p):  Make sure that we have a real honest-to-cthulu
exec file!
* (hppa_core_file_failing_signal, hppa_core_file_failing_command):
Make these work for HPUX.
* (make_bfd_asection):  New routine to make section creation a
little easier.
* (hppa_core_file_p):  Completely rewrite, leave out bugs.
* libhppa.h:  #include the right system files.  Redefine all of
the structs/macros for hacking core files to use more sensible
HPUX core file structures.
* targets.c (target_vector):  Conditionalize hppa_vec on
HOST_HPPAHPUX, not hp9000s800.
* hosts/hppahpux.h:  #include stdlib.h to get correct decls for
malloc and realloc.  #define HOST_HPPAHPUX.
1992-12-22 01:53:06 +00:00
Ian Lance Taylor 60ac749cab Mon Dec 21 12:40:10 1992 Ian Lance Taylor (ian@cygnus.com)
* Patches from Minh Tran-le <mtranle@paris.intellicorp.com>.
	* configure.in (i386-*-isc*, i386-*-aix*): New targets.
	* configure.host (i386-*-isc*, i386-*-aix*): New hosts.
	* hosts/i386isc.h, config/i386isc.mh: New files for Interactive
	Unix.
	* hosts/i386aix.h, config/i386aix.mh: New files for AIX on PS/2.
	* aix386-core.c: New file for handling core files on AIX on PS/2.
	* targets.c: if AIX386_CORE, use aix386_core_vec.
	* coffcode.h (coff_real_object_p): check for I386SVMAGIC as well
	as I386MAGIC.
1992-12-21 21:17:54 +00:00
Steve Chamberlain 6c1cabd48f * aoutf1.h (sunos4_write_object_contents): set flags to 0, fixing
1927.
1992-12-18 18:38:04 +00:00
John Gilmore d3e667e88d * bfd.c: Use right name for tekhex tdata struct.
* tekhex.c:  Insert leading_char (0) into bfd_target struct.  Style.
* libcoff.h:  Updated to get spacing change from coffcode.h.
* trad-core.c:  leading_char is 0 (no symbols!), not '_'.
1992-12-17 08:42:31 +00:00
Per Bothner 287c221dd2 Various changes to improve archive support. See ChangeLog. 1992-12-16 00:01:59 +00:00
Stu Grossman 76c7e44dde * hppa.c: #include "sysdep.h", not <sysdep.h>.
* libhppa.h:  Make millicode_start and millicode_end be unsigned
int to be same type as CORE_ADDR in GDB.  Why are these here?
1992-12-15 01:12:34 +00:00
Ken Raeburn 07de8e96b3 syms.c (asymbol): Added new field "app_data", for data particular to the
application.  Some of the linker flags ought to get moved to this field
someday.

archures.c (bfd_default_scan): Recognize a few more numbers: 80486, 80960,
and 960.

bfd-in.h, bfd.c, targets.c, coffcode.h, coff-mips.c, other targets: Moved COFF
swap table to backend data.

hosts/i386linux.h: Include unistd.h.
aoutx.h, libaout.h, stab-syms.c: stab names are now in constant storage.
trad-core.c: Fixed some `PARAMS' uses that were missing parentheses.
aoutx.h, archive.c, archures.c, coffcode.h, ctor.c, reloc.c, syms.c: Doc fixes.
1992-12-03 23:03:17 +00:00
Fred Fish b86f998b8a * aoutx.h (some_aout_object_p): Protect arg prototype in
callback_to_real_object_p with PARAMS macro for non-ANSI compilers.
1992-11-29 16:40:09 +00:00
John Gilmore 1f29e30b1f * aout-target.h, aoutf1.h, trad-core.c, coffcode.h, libaout.h:
Eliminate all PROTO calls, replace with PARAMS for readability.

* aoutx.h:  Add type to callback parameter.
* coff-mips.c:  Don't call trad-core.h, not needed.
* trad-core.c:  Incorporate trad-core.h declarations.  Fix comments.
* trad-core.h:  Eliminate, unused.
1992-11-28 13:00:18 +00:00
John Gilmore 1093ee14ae * libbfd-in.h, bfd-in.h: Eliminate all PROTO calls, replace with
PARAMS for readability.
1992-11-28 12:14:14 +00:00
David D. Zuhn 2385eb2f1f pass down prefix and exec_prefix 1992-11-13 01:03:52 +00:00
Steve Chamberlain 1a9904b4cb * coff-z8k.c: checkpoint, more addressing modes handled
* coffcode.h (get_value): don't truncate reloc->addend field, it's
	a long now.
1992-11-12 17:53:58 +00:00
Brendan Kehoe 91ec84ef69 * we32k.mt (TDEFAULTS): Use we32kcoff_vec, not i386coff_vec. 1992-11-12 07:59:59 +00:00
David D. Zuhn 6cabab7823 make cc command lines more consistent 1992-11-10 22:07:02 +00:00
John Gilmore 9ee6289b47 * opncls.c (bfd_fdopenr, bfd_close): Add doc about cacheing
and about when file descriptors are closed.
1992-11-10 07:59:39 +00:00
Ian Lance Taylor 8f718ed3bd Thu Nov 5 15:34:19 1992 Ian Lance Taylor (ian@cygnus.com)
* section.c: New section bit SEC_SHARED_LIBRARY.
	coffcode.h (styp_to_sec_flags): if STYP_NOLOAD && (STYP_TEXT ||
	STYP_DATA), set SEC_SHARED_LIBRARY.  This seems to be correct for
	i386-sysv.
1992-11-06 00:38:59 +00:00
John Gilmore 3662554d78 * target.c (struct bfd_target): Eliminate the SDEF and SDEF_FMT
macros; use PARAMS to declare the function pointers involved.
1992-11-05 13:50:25 +00:00
John Gilmore 990e7c2297 * bfd-in.h, bfd.c, libbfd.h, reloc.c, seclet.h, section.c,
targets.c: Rename struct bfd_seclet_struct to struct bfd_seclet.
1992-11-05 13:17:38 +00:00
John Gilmore fefb4b30e6 Cleanup: Replace all uses of EXFUN in the BFD sources, with PARAMS.
* archures.c, reloc.c, section.c, tekhex.c:  Use PARAMS in
declaring pointers to functions.
* cache.c, elf.c:  Move static function decls to top, use PARAMS.
* seclet.h:  Declare external function with PARAMS.

* libbfd.h:  Update, based on changes in source code and chew.
1992-11-05 11:13:01 +00:00
John Gilmore 00539ee3b3 * bfd-in.h: Improve comments to make it clear that bfd.h is
the wrong place to edit this file.
* Makefile.in (install):  Install ansidecl.h and obstack.h in the
same places where we install bfd.h.
* libieee.h:  Add FIXME about removing limit on number of sections.
1992-11-05 08:17:56 +00:00
Sean Eric Fagan 061a65a56f (Duplicate change from p3.)
Only change coff auxent header fields when the circumstances require it.  or
at least warrant.
1992-11-04 21:57:47 +00:00
Ken Raeburn 9159aa3097 aoutx.h (some_aout_object_p): Section list should be set up properly already;
don't need to tweak "next" pointers.
1992-11-04 14:35:20 +00:00
Ian Lance Taylor 3fd7451e39 I'm eliminating the use of USG from binutils/ar.c, and nothing else in
binutils, bfd or opcodes uses it.

Mon Nov  2 12:36:14 1992  Ian Lance Taylor  (ian@cygnus.com)

	* config/delta88.mh, config/hp300.mh, config/hppahpux.mh,
	config/i386v.mh: removed -DUSG from HDEFINES.
	hosts/delta88.h, hosts/hp300.h, hosts/hppahpux.h, hosts/i386v.h:
	defined USE_UTIME.
	hosts/i386v.h: don't define POSIX_UTIME.
1992-11-02 20:41:14 +00:00
Steve Chamberlain b533ed9479 * ieee.c (ieee_slurp_sections): make a private copy of the
section's name before truncating it.
1992-10-31 00:15:10 +00:00
Steve Chamberlain 4e98653cf6 * hppa.c: add symbol_leading_char entry in transfer vec 1992-10-29 16:32:36 +00:00
Steve Chamberlain aff6e0b45a ,Wed Oct 28 16:11:57 1992 Steve Chamberlain (sac@thepub.cygnus.com)
* ieee.c (get_symbol): can now cope when two symbols of a
	different class, but the same index number occur consecutively.
	(get_section_entry): nicer name for sections being forward
	referenced. (ieee_archive_p): don't free the filename string,
	since it was never malloced.
1992-10-29 00:17:07 +00:00
John Gilmore 17f9c81775 (coff_write_object_contents): Zero timestamp field. 1992-10-28 21:44:39 +00:00
Ian Lance Taylor 98fd98bcb4 Moved in from p3:
Tue Oct 27 12:24:34 1992  Ian Lance Taylor  (ian@cygnus.com)

	* coffcode.h (coff_swap_aux_out): set the fcnary info before
	optionally setting the dimen info, since they are in the same
	memory locations.  Also zero out external auxent.
	(coff_write_symbol): don't zero external auxent; now done in
	coff_swap_aux_out.
1992-10-27 20:34:40 +00:00
Ian Lance Taylor 700b2ee3ef Fri Oct 23 13:55:35 1992 Ian Lance Taylor (ian@cygnus.com)
* Check fclose return value for errors.
	libbfd.h: bfd_cache_close now returns a boolean.
	cache.c (bfd_cache_delete): return fclose success value.
	(bfd_cache_close): return bfd_cache_delete return value.
	opncls.c (bfd_close, bfd_close_all_done): return result of
	bfd_cache_close.
1992-10-23 21:01:29 +00:00
Steve Chamberlain c26d7d179c Fri Oct 23 10:32:36 1992 Steve Chamberlain (sac@thepub.cygnus.com)
* seclet.c (rel): don't load sections without the SEC_LOAD bit.

Thu Oct 15 10:16:35 1992  Steve Chamberlain  (sac@thepub.cygnus.com)

	* coff-m68k.c (m68k_howto2type, SELECT_RELOC): new function to
	work out a coff relocation type from a howto's attributes rather
	than using the input r_type field. This fixes PR1677 and allows
	conversion of a.out relocs to coff relocs.

	* coffcode.h (coff_write_relocs): if supplied a relocation
	relative to an absolute symbol, use the right symbol index.

	* reloc.c (bfd_perform_relocation): do a partial link for coff
	relocs right.
1992-10-23 17:34:37 +00:00
Ian Lance Taylor b26059aa44 Fri Oct 23 08:15:56 1992 Ian Lance Taylor (ian@cygnus.com)
* changes to support i386-sysv with shared libraries:
	* coffcode.h (sec_to_styp_flags): if TWO_DATA_SECS is defined,
	check for .data2; if _LIB is defined, check for it; map
	SEC_NEVER_LOAD to STYP_NOLOAD.
	(styp_to_sec_flags): map STYP_NOLOAD to SEC_NEVER_LOAD.
	(make_a_section_from_file): if TWO_DATA_SECS, accept .data2.
	(coff_write_object_contents): force vaddr of .lib to 0; set scnptr
	if section has contents, not just if it is loadable; if
	TWO_DATA_SECS, check for .data2
	(coff_set_section_contents): set vma of .lib section to number of
	.lib sections.
	* coff-i386.c: define TWO_DATA_SECS; use a special CALC_ADDEND;
	don't define coff_write_armap to bsd_write_armap.
	* hosts/i386v.h: don't include <utime.h>, since it is not provided
	by SVR3.2.
1992-10-23 15:28:15 +00:00
John Gilmore 7b107b1ec4 * config/a29k-aout.mt (DEFAULT_TARGET): Set to one that exists. 1992-10-21 10:47:13 +00:00
Per Bothner 58c319d00b Document changes to hosts directory. 1992-10-15 22:16:07 +00:00
John Gilmore 6803d8186f Now update it in the *right* place... 1992-10-15 11:39:56 +00:00
John Gilmore 4a8db3300d Insert copyright notices in all BFD files that need them.
Update copyrights on recently changed files to 1992.
Regularize first-line comments somewhat.
1992-10-15 10:59:13 +00:00
John Gilmore b1b819bdc7 * bfd-in.h (file_ptr): Update comments, make FIXME re off_t. 1992-10-15 10:34:13 +00:00