]> Git Repo - binutils.git/blob - bfd/ChangeLog
Tue Apr 8 18:09:29 1997 Jamie Lokier <[email protected]>
[binutils.git] / bfd / ChangeLog
1 Tue Apr  8 18:09:29 1997  Jamie Lokier  <[email protected]>
2
3         * stabs.c (struct stab_section_info): New field
4         `cumulative_skips'.
5         (_bfd_link_section_stabs): Fill the above array.
6         (_bfd_stab_section_offset): Use `cumulative_skips' to
7         speed up offset calculation.
8
9 Tue Apr  8 00:01:31 1997  Jeffrey A Law  ([email protected])
10
11         * elf-mn10300.c (mn10300_elf_relax_section): Don't forget the
12         addend for non pc-relative relocations.
13
14         * elf-m10300.c (bfd_elf32_mn10300_reloc): Remove prototype
15         for non-existent function.
16
17         * elf-m10300.c (mn10300_elf_relax_section): New function.
18         (mn10300_elf_relax_delete_bytes): Likewise.
19         (mn10300_elf_symbol_address_p): Likewise.
20         (mn10300_elf_get_relocated_section_contents): Likewise.
21         (bfd_elf32_bfd_relax_section): Define.
22         (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
23
24 Mon Apr  7 16:47:09 1997  Ian Lance Taylor  <[email protected]>
25
26         * configure.host: Set SHLIB_LIBS.
27         * configure.in: Substitute SHLIB_LIBS.
28         * configure: Rebuild.
29         * Makefile.in (SHLIB_LIBS): New variable.
30         ($(SHLIB)): Use $(SHLIB_LIBS).
31
32 Mon Apr  7 10:53:52 1997  Michael Snyder  <[email protected]>
33
34         * bfd-in.h bfd-in2.h: add bfd_section_lma macro to correspond
35         with bfd_section_vma.
36
37 Fri Apr  4 11:37:15 1997  Ian Lance Taylor  <[email protected]>
38
39         * configure.in: Update file names for bfd_elf32_mn10[23]00_vec.
40         Correct CPU file names for mn10[23]00.
41         * configure: Rebuild.
42
43         * bfd.c (bfd_record_phdr): Cast count to size_t before
44         subtraction.
45
46         * coff-ppc.c (dump_toc): Add cast to avoid warning from SunOS cc.
47         * coff-rs6000.c (xcoff_read_ar_hdr): Likewise.
48         (xcoff_write_archive_contents): LIkewise.
49         * elf32-mips.c (_bfd_mips_elf_set_section_contents): Likewise.
50         (mips_elf_create_procedure_table): Likewise.
51         * peicode.h (pe_print_idata): Likewise.
52         (pe_print_edata, pe_print_pdata, pe_print_reloc): Likewise.
53         * xcofflink.c (xcoff_get_section_contents): Likewise.
54         (_bfd_xcoff_canonicalize_dynamic_symtab): Likewise.
55         (xcoff_link_add_symbols): Likewise.
56         (xcoff_link_add_symbols): Likewise.
57
58         * ppcboot.c (ppcboot_set_arch_mach): Make static.
59         (ppcboot_bfd_print_private_bfd_data): Likewise.
60
61         * elf32-mips.c (elf_mips_ctor64_howto): Set complain_on_overflow
62         to complain_overflow_signed.
63
64 Thu Apr  3 11:51:54 1997  Ian Lance Taylor  <[email protected]>
65
66         * VERSION: Set to 2.8.1.
67
68         * Branched binutils 2.8.
69
70         * elf32-ppc.c (ppc_elf_check_relocs):  Don't check SEC_ALLOC when
71         deciding whether to copy a reloc into a shared object.
72         (ppc_elf_relocate_section): Likewise.  Relocate R_PPC_RELATIVE
73         relocs in unallocated sections.
74         * elf32-sparc.c (elf32_sparc_relocate_section): Relocate
75         R_SPARC_RELATIVE relocs in unallocated sections.
76
77 Wed Apr  2 16:19:41 1997  Mike Meissner  <[email protected]>
78
79         * elf32-ppc.c (ppc_elf_check_relocs): Undo March 26 change and
80         always create got section so that the _GLOBAL_OFFSET_TABLE_ label
81         is always created.
82
83 Wed Apr  2 10:49:07 1997  Ian Lance Taylor  <[email protected]>
84
85         * elflink.h (elf_link_add_object_symbols): Let a common symbol
86         override an uninitialized symbol from a shared library with a
87         smaller size.
88
89         * elf-m10200.c: Rename from elf32-mn10200.c.
90         * elf-m10300.c: Rename from elf32-mn10300.c.
91         * cpu-m10200.c: Rename from cpu-mn10200.c
92         * cpu-m10300.c: Rename from cpu-mn10300.c
93         * Makefile.in: Update accordingly.
94
95         * elf32-mips.c (elf_mips_ctor64_howto): New static variable.
96         (elf_mips_isa): Move to earlier in file.
97         (mips_reloc_map): Remove BFD_RELOC_CTOR entry.
98         (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_CTOR
99         specially.
100
101         * elf32-mips.c (mips16_jump_reloc): Print a warning rather than
102         calling abort.
103
104 Tue Apr  1 16:18:05 1997  Klaus Kaempf  <[email protected]>
105
106         * configure.com: New file.
107         * config.h-vms: Remove file.
108         * makefile.vms: Update for new configure scheme.
109
110 Mon Mar 31 23:28:39 1997  H.J. Lu  <[email protected]>
111
112         * libcoff-in.h (ppc_allocate_toc_section): Declare.
113         (ppc_process_before_allocation): Declare.
114         * libcoff.h: Rebuild.
115
116         * coffcode.h (coff_mkobject_hook): Declare if not a macro.
117
118 Mon Mar 31 16:29:50 1997  Joel Sherrill  <[email protected]>
119
120         * config.bfd (hppa*-*-rtems*): New target, like hppa-*-*elf*.
121
122 Mon Mar 31 16:11:35 1997  Ian Lance Taylor  <[email protected]>
123
124         * coff-a29k.c (coff_a29k_relocate_section): Don't use symndx as a
125         symbol index for a R_IHCONST reloc.
126
127 Mon Mar 31 15:40:59 1997  Philippe De Muyter  <[email protected]>
128
129         * targmatch.sed: Do not use \(\) recursively.
130
131 Fri Mar 28 14:44:08 1997  H.J. Lu  <[email protected]>
132
133         * m68klinux.c (MACHTYPE_OK): Define.
134         * i386linux.c (MACHTYPE_OK): Define.
135
136 Fri Mar 28 11:56:15 1997  Ian Lance Taylor  <[email protected]>
137
138         From David S. Miller <[email protected]> and H.J. Lu
139         <[email protected]>:
140         * sparclinux.c: New file.
141         * bfd-in.h (bfd_sparclinux_size_dynamic_sections): Declare.
142         * bfd-in2.h: Rebuild.
143         * config.bfd (sparc-*-linuxaout*, sparc-*-linux*): New targets.
144         * configure.in (sparclinux_vec): Add to list of vectors.
145         * configure: Rebuild.
146         * targets.c (sparclinux_vec): Declare.
147         (bfd_target_vector): Add sparclinux_vec.
148         * Makefile.in: Rebuild dependencies.
149         (BFD32_BACKENDS): Add sparclinux.o.
150         (BFD32_BACKENDS_CFILES): Add sparclinux.c.
151
152         * coff-mips.c (mips_ecoff_backend_data): Initialize new
153         bfd_coff_backend_data field.
154         * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
155
156         * config.bfd: Add bfd_elf64_{big,little}mips_vec to targ_selvecs
157         for mips*el*-*-linux* and mips*-*-linux*.  From H.J. Lu
158         <[email protected]> and Ralf Baechle <[email protected]>.
159
160         * bfd.c: Include "libiberty.h".
161         (strerror): Don't declare.
162         (bfd_errmsg): Call xstrerror rather than strerror.
163
164 Thu Mar 27 12:55:42 1997  Ian Lance Taylor  <[email protected]>
165
166         * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Generate a COPY
167         reloc even if the symbol is in the .bss section.
168         * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
169         * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
170         * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Likewise.
171
172         * coffcode.h (bfd_coff_backend_data): Add new field
173         _bfd_coff_default_section_alignment_power.
174         (bfd_coff_default_section_alignment_power): Define.
175         (bfd_coff_std_swap_table): Initialize new field.
176         * libcoff.h: Rebuild.
177         * cofflink.c (coff_link_add_symbols): Limit alignment of a common
178         symbol to the default section alignment.
179
180         * COPYING: Update FSF address.
181
182 start-sanitize-d30v
183 Thu Mar 27 00:45:57 1997  Martin M. Hunt  <[email protected]>
184
185         * elf32-d30v.c (elf_d30v_howto_table): Fix a typo in the 
186         21-bit absolute that made it act as a relative. 
187
188 end-sanitize-d30v       
189 Wed Mar 26 14:50:20 1997  Ian Lance Taylor  <[email protected]>
190
191         * elflink.c (_bfd_elf_create_linker_section): Don't set
192         bss_section and rel_section from existing sections.
193
194         * elf32-ppc.c (ppc_elf_check_relocs): Only create the got section
195         if it is needed.
196
197 Tue Mar 25 22:26:56 1997  Stu Grossman  ([email protected])
198
199         * aoutx.h (some_aout_object_p):  Change executable test to fix
200         problems with embedded a.out systems.
201
202 Tue Mar 25 14:35:37 1997  Ian Lance Taylor  <[email protected]>
203
204         * stabs.c (_bfd_stab_section_offset): New function.
205         * libbfd-in.h (_bfd_stab_section_offset): Declare.
206         * libbfd.h: Rebuild.
207         * elf32-i386.c (elf_i386_relocate_section): Adjust the offset of a
208         stab reloc.
209         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
210         * elf32-mips.c (mips_elf_relocate_section): Likewise.
211         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
212         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
213         * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
214
215         * stabs.c (_bfd_link_section_stabs): Copy over the first header
216         symbol.  Check for memory allocation failure of *psinfo.
217         (_bfd_write_section_stabs): Add psinfo parameter.  Change all
218         callers.  Set the value of the header symbol.
219         * libbfd-in.h (_bfd_write_section_stabs): Update declaration.
220         * libbfd.h: Rebuild.
221
222 start-sanitize-tic80
223 Mon Mar 24 20:07:29 1997  Fred Fish  <[email protected]>
224
225         * coff-tic80.c (tic80_howto_table): Add R_ABS entry.
226         (rtype2howto): Handle R_ABS reloc type.  Also abort on unhandled
227         reloc types, rather than silently failing to generate an output file.
228
229 end-sanitize-tic80
230 Mon Mar 24 13:41:00 1997  Ian Lance Taylor  <[email protected]>
231
232         * targmatch.sed: Use the hold space to put the #ifdef around the
233         the string constant.
234         * targets.c (UNSUPPORTED_TARGET): Don't define.
235         (find_target): Don't check for UNSUPPORTED_TARGET.
236         (bfd_set_default_target): Don't try to optimize by checking for
237         default.
238
239         * Makefile.in: Rebuild dependencies.
240         (ALL_MACHINES_CFILES): Add cpu-m32r.c.
241         (BFD32_BACKENDS_CFILES): Add elf32-m32r.c.
242         (elf32-m32r.o): Remove explicit target.
243
244         * config.bfd: Don't set targ_underscore for i[3456]86-*-gnu* or
245         i[3456]86-*-linux*.
246
247         * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Don't
248         count section symbols for sections that were created by the
249         linker, or are not allocatable or not loadable.
250         (elf32_sparc_finish_dynamic_sections): Output output section
251         symbols for section for which we made space for them.
252
253 Fri Mar 21 13:08:26 1997  Ian Lance Taylor  <[email protected]>
254
255         * elf32-sparc.c (elf32_sparc_size_dynamic_sections): If there is
256         no .rela.plt section, don't output a DT_PLTGOT dynamic entry.
257
258 Fri Mar 21 12:36:46 1997  Doug Evans  <[email protected]>
259
260         * elf32-m32r.c (m32r_elf_howto_table): Use special function for LO16.
261         (m32r_hi16_list): New static local.
262         (m32r_elf_hi16_reloc): Don't perform reloc, just queue it up.
263         (m32r_elf_do_hi16_reloc): Delete.
264         (m32r_elf_relocate_hi16): New function.
265         (m32r_elf_lo16_reloc): New function.
266         (m32r_elf_relocate_section): For HI16 relocs, scan for corresponding
267         LO16 reloc.
268
269         Mon Mar 10 16:03:31 1997  Doug Evans  <[email protected]>
270
271         * elf32-m32r.c (m32r_elf_create_linker_section): Delete.
272         (m32r_elf_add_symbol_hook): Rewrite _SDA_BASE_ support.
273         (m32r_elf_final_sda_base): New function.
274         (m32r_elf_relocate_section): Rewrite sdata support.
275         (m32r_elf_finish_dynamic_sections): Delete.
276
277 Thu Mar 20 12:39:02 1997  Ian Lance Taylor  <[email protected]>
278
279         Based on patches from Philippe De Muyter <[email protected]>.
280         * coff-svm68k.c: New file.  Just defines some macros and includes
281         coff-m68k.c.
282         * coff-m68k.c: Add functions to handle common addends, moved in
283         from cf-m68klynx.c.  Control them using COFF_COMMON_ADDEND macro.
284         Control whether relocs are visible using STATIC_RELOCS.
285         * cf-m68klynx.c: Simplify greatly: just define macros to control
286         coff-m68k.c.
287         * coff-aux.c: Likewise.  Just leave add_one_symbol routine.
288         * targets. (m68ksysvcoff_vec): Declare.
289         (bfd_target_vector): Add m68ksysvcoff_vec.
290         * config.bfd (m68*-motorola-sysv*): New target.
291         * configure.in (m68ksysvcoff_vec): New vector.
292         * configure: Rebuild.
293         * Makefile.in: Rebuild dependencies.
294         (BFD32_BACKENDS): Add coff-svm68k.o.
295         (BFD32_BACKENDS_CFILES): Add coff-svm68k.c.
296
297         * binary.c (binary_set_section_contents): Don't get misled if the
298         first section is not loadable.  From Matthew L. Martin
299         <[email protected]>.
300
301         * elflink.h (elf_bfd_final_link): Set the value of a section
302         symbol to the section address unless doing a relocateable link.
303
304 Tue Mar 18 23:03:17 1997  Richard Henderson  <[email protected]>
305
306         * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't create
307         .plt entry if we've taken the function's address.
308         (elf64_alpha_merge_gots): Merge collected flags info as well.
309
310 Tue Mar 18 22:40:09 1997  H.J. Lu  <[email protected]>
311
312         * Many files: Add function prototypes.
313         * cpu-m68k.c (bfd_default_scan_num_mach): Don't declare.
314         * ecofflink.c: Include "libcoff.h" and "libecoff.h".
315         * elf32-ppc.c (ppc_elf_fake_sections): Make static.
316         * opncls.c (bfd_openstreamr): Change stream parameter to PTR.
317         * peicode.h: Change several void * parameters to PTR.
318         * srec.c (srec_get_symbol_info): Make static.
319         * syms.c (bfd_symbol_is_absolute): Remove.
320         * Makefile.in: Rebuild dependencies.
321
322 Tue Mar 18 12:58:08 1997  Ian Lance Taylor  <[email protected]>
323
324         * elf32-m32r.c (m32r_elf_is_local_label_name): Remove.
325         (bfd_elf32_bfd_is_local_label): Don't define.
326
327         * xcofflink.c (_bfd_xcoff_bfd_final_link): Call bfd_malloc rather
328         than malloc.
329
330 Mon Mar 17 11:32:53 1997  Ian Lance Taylor  <[email protected]>
331
332         * bfd-in.h: Don't include obstack.h.
333         (struct bfd_hash_table): Change memory field to PTR.
334         * bfd.c (struct _bfd): Change memory field to PTR.
335         * bfd-in2.h: Rebuild.
336         * libbfd-in.h (bfd_release): Declare as function, don't define as
337         macro.
338         * libbfd.h: Rebuild.
339         * opncls.c: Include "objalloc.h" rather than "obstack.h".  Use
340         objalloc routines rather than obstack routines.
341         (obstack_chunk_alloc, obstack_chunk_free): Don't define.
342         (getpagesize): Don't define.
343         (_bfd_new_bfd): Don't set _bfd_chunksize.
344         (bfd_openr): Free new bfd and objalloc on failure.
345         (bfd_fdopenr, bfd_openstreamr, bfd_openw): Likewise.
346         (bfd_alloc_size): Remove.
347         (bfd_release): New function.
348         * hash.c: Include "objalloc.h" rather than "obstack.h".  Use
349         objalloc routines rather than obstack routines.
350         (obstack_chunk_alloc, obstack_chunk_free): Don't define.
351         * ecofflink.c: Include "objalloc.h" rather than "obstack.h".  Use
352         objalloc routines rather than obstack routines.
353         (obstack_chunk_alloc, obstack_chunk_free): Don't define.
354         (struct accumulate): Change memory to struct objalloc *.
355         * liboasys.h (oasys_data_type): Remove oasys_obstack field.
356         * dep-in.sed: Don't remove obstack.h from dependency list.
357         * Makefile.in: Rebuild dependencies.
358         (BFD_H_DEPS): Remove obstack.h.
359         (install): Don't install obstack.h.
360         * Many files: Don't include "obstack.h".
361         * VERSION: Bump.
362
363         * opncls.c (bfd_alloc_grow, bfd_alloc_finish): Remove.
364         * libbfd-in.h (bfd_alloc_grow, bfd_alloc_finish): Don't declare.
365         * libbfd.h: Rebuild.
366         * ieee.c (ieee_archive_p): Rewrite to not use bfd_alloc_grow.
367         * sunos.c (sunos_add_dynamic_symbols): Likewise.
368         * srec.c (srec_scan): Rewrite to not use obstack_1grow.
369
370         * opncls.c (bfd_alloc): Rename from bfd_alloc_by_size_t.  Remove
371         old version of bfd_alloc.
372         * libbfd-in.h (bfd_alloc_by_size_t): Don't declare.
373         * libbfd.h: Rebuild.
374         * Several files: Call bfd_alloc rather than bfd_alloc_by_size_t.
375
376 Sat Mar 15 15:24:18 1997  Ian Lance Taylor  <[email protected]>
377
378         * elf32-mips.c (mips_elf_is_local_label_name): Accept the generic
379         ELF local label syntax as well.
380
381 Sat Mar 15 10:16:42 1997  Fred Fish  <[email protected]>
382
383         * config.bfd (powerpc-*-beos*): New target.
384         * configure.in (powerpc-*-beos*): Add case that explicitly
385         does not set COREFILE for now.  A future BeOS version is
386         expected to support core files.
387         * configure: Regenerate with autoconf.
388
389 Fri Mar 14 16:43:22 1997  Ian Lance Taylor  <[email protected]>
390
391         * elf32-mips.c (mips_elf_check_relocs): Give an error if CALL16 is
392         seen with a local symbol, rather than crashing.
393
394         * elfcode.h (elf_slurp_symbol_table): Don't try to read the
395         version symbols if there aren't any.
396
397 start-sanitize-tic80
398 Thu Mar 13 16:38:30 1997  Fred Fish  <[email protected]>
399
400         * coff-tic80.c (coff_rtype_to_howto): Define
401         (coff_tic80_rtype_to_howto): Clone generic coff version and
402         add code to handle the funky TI "internal relocations".
403
404 end-sanitize-tic80
405 Thu Mar 13 14:08:53 1997  Ian Lance Taylor  <[email protected]>
406
407         * elflink.h (elf_link_add_object_symbols): Don't warn about type
408         or size changes because of a weak symbol.
409
410         * cisco-core.c (SIGEMT): Define if not defined.
411
412 Wed Mar 12 21:36:05 1997  Ian Lance Taylor  <[email protected]>
413
414         * elflink.h (elf_link_add_object_symbols): Use extsymoff when
415         setting ever.  Sanity check the version number.  Sort out copying
416         flags and other information when adding an indirect symbol.
417         (NAME(bfd_elf,size_dynamic_sections)): Preserve any dynamic
418         symbols added by the backend.  Clear the entire contents of the
419         versym section.
420         (elf_export_symbol): Ignore indirect symbols.
421         (elf_link_output_extsym): Accept a section without an owner in an
422         assert.
423         * elfcode.h (elf_slurp_symbol_table): Add a sanity check on the
424         version count.  Correct the allocation of x_versymp.
425
426         * elf32-mips.c (mips_elf_add_symbol_hook): Don't set the owner of
427         the magic sections used for SHN_MIPS_TEXT and SHN_MIPS_DATA.
428         Don't return bfd_und_section_ptr when info->shared.
429         (mips_elf_final_link): Set the alignment of .rtproc to 4, not 12.
430         (mips_elf_create_dynamic_sections): Correct type: ^= for &=.
431         (mips_elf_check_relocs): Resolve an indirect symbol in
432         sym_hashes.
433         (mips_elf_finish_dynamic_symbol): Don't change SHN_ABS into
434         SHN_MIPS_TEXT or SHN_MIPS_DATA.
435
436         * elf.c (bfd_elf_print_symbol): Tweak version output slightly.
437
438 Tue Mar 11 01:38:36 1997  Ian Lance Taylor  <[email protected]>
439
440         From Eric Youngdale <[email protected]>:
441         * elf-bfd.h (ELF_LINK_FORCED_LOCAL): Define.
442         * elf.c (bfd_elf_print_symbol): Correct errors in last change.
443         * elflink.h (elf_link_add_object_symbols): Handle cases in which a
444         versioned symbol appears in both a regular and a shared object.
445         (elf_link_assign_sym_version): Set ELF_LINK_FORCED_LOCAL when
446         appropriate.  Improve error message.
447         (struct elf_outext_info): Rename from elf_finfo_failed.  Change
448         all uses.  Add localsyms field.
449         (elf_bfd_final_link): When generating a shared library, call
450         elf_link_output_extsym to output all local symbols.
451         (elf_link_output_extsym): Handle symbols which were forced to
452         become local.
453
454 Sun Mar  9 23:08:49 1997  Ian Lance Taylor  <[email protected]>
455
456         From Eric Youngdale <[email protected]>:
457         * elf-bfd.h (elf_symbol_type): Add version field.
458         * elfcode.h (elf_slurp_symbol_table): Set version field.
459         * elflink.h (elf_link_add_object_symbols): When creating an
460         indirect symbol for a default version symbol, set DEF_DYNAMIC if
461         appropriate.  Set up an indirection from the nondefault version of
462         the symbol as well.
463         (NAME(bfd_elf,size_dynamic_sections)): Call
464         elf_link_assign_sym_version before checking whether there are any
465         versions.  Always record the version name as a dynamic symbol.
466         Initialize counters.
467         (elf_link_assign_sym_version): After finding a version, see if a
468         symbol should be forced to local scope.  Create a new version
469         definition if appropriate.
470         (elf_link_output_extsym): Correct indirect symbol handling.
471         * elf.c (bfd_elf_print_symbol): Print version information.
472         (bfd_section_from_shdr): Turn version sections into BFD sections.
473         (elf_fake_sections): Only copy cverdefs and cverrefs into sh_info
474         if sh_info is not already set.
475         (_bfd_elf_copy_private_section_data): Copy sh_info for version
476         sections.
477         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Tell
478         _bfd_stringtab_add to copy the name into permanent memory if
479         appropriate.
480
481 Fri Mar  7 11:55:31 1997  H.J. Lu  <[email protected]>
482
483         * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Fully parenthesize.
484
485 Fri Mar  7 10:37:30 1997  Ian Lance Taylor  <[email protected]>
486
487         * coffcode.h (bfd_coff_backend_data): Change
488         _bfd_coff_compute_section_file_positions to return a boolean
489         value.  Change all callers.
490         (coff_compute_section_file_positions): Change return type to
491         boolean.  If the size of the last section changed, then output a
492         zero byte at the end of the file.
493         * libcoff.h: Rebuild.
494
495         * xcofflink.c (_bfd_xcoff_bfd_final_link): Always allocate space
496         for at least 6 output symbols.
497         (xcoff_write_global_symbol): When emitting TOC entry relocs, also
498         emit a TC csect to represent the space they take up.  For an XO
499         symbol, just emit a reference, not a csect.
500
501         * Makefile.in ($(SHLINK)): Just use ln -s, not ln -sf, since
502         Solaris doesn't like the combined options, and the -f is
503         unnecessary.
504         (stamp-tshlink, install): Likewise.
505
506         * elf32-mips.c (mips_elf_relocate_section): Correct R_MIPS16_26
507         handling when little endian.
508
509 Thu Mar  6 13:51:51 1997  Jeffrey A Law  ([email protected])
510
511         * elf32-mn10300.c (mn10300_elf_final_link_relocate): New function.
512         (mn10300_elf_relocate_section): Likewise.
513         (elf_backend_relocate_section): Define.
514
515         * elf32-mn10300.c (reloc_type): Remove PCREL{8,16,32}_{1,2}BYTE
516         relocs.  Replace them with generic PCREL_{8,16,32} relocs.
517         (elf32_mn10300_howto_table): Likewise.
518         (elf32_mn10300_reloc_map): Likewise.
519         (bfd_elf32_mn10300_reloc): Delete unused function.
520
521 Thu Mar  6 12:19:59 1997  Fred Fish  <[email protected]>
522
523 start-sanitize-tic80
524         * coff-tic80.c (rtype2howto): If passed a relocation type we don't
525         understand, just set the howto field to NULL, and the caller will
526         print an appropriate error message.
527 end-sanitize-tic80
528         * coffcode.h (coff_slurp_reloc_table): Pull duplicate declarations and
529         code fragment out of both legs of #ifdef RELOC_PROCESSING ... #endif
530         block.  Use NULL for initializations of "ptr" rather than bare 0.
531         * coff-h8300.c: Fix typo in comment.
532         * coff-h8500.c: Ditto.
533         * coff-w65.c: Ditto
534         * coff-z8k.c: Ditto.
535         
536 Wed Mar  5 13:59:09 1997  Doug Evans  <[email protected]>
537
538         * elf32-m32r.c (m32r_elf_do_10_pcrel_reloc): Fix overflow calc.
539         (m32r_elf_relax_section, m32r_elf_relax_delete_bytes,
540         m32r_elf_get_relocated_section_contents): First pass at relax support.
541
542 Mon Mar  3 13:27:09 1997  Ulrich Drepper  <[email protected]>
543
544         * elflink.h (elf_link_add_object_symbols): Use correct sh_size
545         entry for reading verdef records.
546         Use correct braces for computing increments of extverdaux and
547         exteverdef record pointers.
548
549 start-sanitize-tic80
550 Sun Mar  2 22:47:54 1997  Fred Fish  <[email protected]>
551
552         * coff-tic80.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set this to 2
553         instead of 4.
554
555 end-sanitize-tic80
556 Sun Mar  2 16:25:35 1997  Ian Lance Taylor  <[email protected]>
557
558         * elflink.h (elf_link_find_version_dependencies): Check that
559         DEF_REGULAR is not set as well as checking that DEF_DYNAMIC is
560         set.
561
562 start-sanitize-tic80
563 Fri Feb 28 16:52:40 1997  Fred Fish  <[email protected]>
564
565         * coffcode.h (coff_set_flags): Add case for TIC80_ARCH_MAGIC.
566
567 end-sanitize-tic80
568 Fri Feb 28 15:06:45 1997  Ian Lance Taylor  <[email protected]>
569
570         * targets.c (bfd_default_vector): Make non-const.
571         (find_target): New static function, broken out of
572         bfd_find_target.
573         (bfd_set_default_target): New function.
574         (bfd_find_target): Call find_target.  When defaulting, use
575         bfd_default_vector[0] if it is not NULL.
576         * libbfd-in.h (bfd_default_vector): Adjust declaration.
577         * bfd-in2.h, libbfd.h: Rebuild.
578
579         * syms.c (bfd_is_local_label): Return false if the symbol has no
580         name.
581         * coff-i960.c (coff_i960_is_local_label_name): New function.
582         (coff_bfd_is_local_label_name): Define.
583         * coff-m68k.c (m68k_coff_is_local_label_name): New function.
584         (coff_bfd_is_local_label_name): Define.
585         * coff-rs6000.c (xcoff_is_local_label_name): New function.
586         (coff_bfd_is_local_label_name): Define.
587         * elf.c (_bfd_elf_is_local_label_name): Treat symbols beginning
588         with .. or _.L_ as local.
589         * elf32-i386.c (elf_i386_is_local_label_name): New function.
590         (bfd_elf32_bfd_is_local_label_name): Define.
591         * evax-alpha.c (evax_bfd_is_local_label_name): Treat symbols
592         beginning with $ as local.
593
594 Thu Feb 27 18:36:23 1997  Ian Lance Taylor  <[email protected]>
595
596         * aoutx.h (aout_link_write_symbols): Use bfd_is_local_label_name
597         rather than comparing against info->lprefix.
598         * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
599         * elflink.h (elf_link_input_bfd): Likewise.
600         * linker.c (_bfd_generic_link_output_symbols): Likewise.
601         * xcofflink.c (xcoff_link_input_bfd): Likewise.
602
603         * elfxx-target.h (bfd_elfNN_bfd_is_local_label_name): Define as
604         _bfd_elf_is_local_label_name if not already defined.
605         * elf.c (_bfd_elf_is_local_label_name): New function.
606         * elf-bfd.h (_bfd_elf_is_local_label_name): Declare.
607
608         * coff-m88k.c (coff_bfd_is_local_label_name): Define.
609         (m88k_is_local_label_name): New static function.
610
611         * coffcode.h (coff_bfd_is_local_label_name): Define as
612         _bfd_coff_is_local_label_name if not already defined.
613         * coffgen.c (_bfd_coff_is_local_label_name): New function.
614         * libcoff-in.h (_bfd_coff_is_local_label_name): Declare.
615         * libcoff.h: Rebuild.
616         
617         * targets.c (BFD_JUMP_TABLE_SYMBOLS): Change _bfd_is_local_label
618         to _bfd_is_local_label_name.
619         (bfd_target): Likewise.
620         * syms.c (bfd_is_local_label): Define as function, not macro.
621         (bfd_is_local_name): Define.
622         * libbfd.c (bfd_generic_is_local_label_name): Rename from
623         bfd_generic_is_local_label, and take a string rather than a
624         symbol.
625         * libbfd-in.h (_bfd_nosymbols_bfd_is_local_label): Don't define.
626         (_bfd_nosymbols_bfd_is_local_label_name): Define.
627         (bfd_generic_is_local_label): Don't declare.
628         (bfd_generic_is_local_label_name): Declare.
629         * bfd-in2.h, libbfd.h: Rebuild.
630         * All backends: Change local_label to local_label_name.
631
632         * elf32-mips.c (struct mips_got_info): Add assigned_gotno field.
633         (mips_elf_relocate_got_local): Change return type to boolean.
634         Don't assume that the first zero entry is unassigned; instead, use
635         assigned_gotno.
636         (mips_elf_relocate_section): Check return value of
637         mips_elf_relocate_got_local.
638         (mips_elf_create_got_section): Initialize assigned_gotno field.
639
640 start-sanitize-d30v
641 Wed Feb 26 15:19:51 1997  Martin M. Hunt  <[email protected]>
642
643         * elf32-d30v.c (bfd_elf_d30v_reloc): Add code to do 32-bit
644         relocations.
645
646 end-sanitize-d30v       
647 Wed Feb 26 13:33:03 1997  Ian Lance Taylor  <[email protected]>
648
649         * elflink.h (elf_link_input_bfd): Don't skip symbols from sections
650         that have no contents merely because linker_mark is not set.
651
652 Tue Feb 25 18:51:35 1997  Stan Shebs  <[email protected]>
653
654         * config.bfd (mips*-*-lnews*): New target.
655         * coff-mips.c (mips_relocate_section): Make assert compare
656         content byteorder instead of header byteorder.
657         (ecoff_biglittle_vec): New BFD, big-endian headers, little-endian
658         data.
659         * targets.c (bfd_target_vector): Add ecoff_biglittle_vec.
660         * configure.in (ecoff_biglittle_vec): Add case.
661         * configure: Update.
662
663 Tue Feb 25 00:32:49 1997  Ian Lance Taylor  <[email protected]>
664
665         * elf.c (elf_fake_sections): Use SHT_NOTE for any section whose
666         name begins with ".note".
667         (map_sections_to_segments): Add a PT_NOTE segment for any loadable
668         section whose name begins with ".note".
669         (get_program_header_size): Corresponding change.
670
671         * elf32-mips.c (mips_elf_relocate_section): Check for misaligned
672         jal and for jal overflow.
673
674 Mon Feb 24 17:53:14 1997  Ian Lance Taylor  <[email protected]>
675
676         From Eric Youngdale <[email protected]>:
677         * elflink.h (elf_link_add_archive_symbols): If a default symbol is
678         not found, try looking it up again without the version name.
679         (elf_link_add_object_symbols): Always link against the dynamic
680         symbol table of a dynamic object.  When linking against a dynamic
681         object, include version strings in symbol names, and set up
682         version information.  Add indirect symbols for default versions.
683         (elf_link_create_dynamic_sections): Add special version sections.
684         (struct elf_assign_sym_version_info): Define.
685         (struct elf_find_verdep_info): Define.
686         (NAME(bfd_elf,size_dynamic_sections)): Add verdefs parameter.  Set
687         up version sections.
688         (elf_adjust_dynamic_symbol): Ignore indirect symbols.
689         (elf_link_find_version_dependencies): New static function.
690         (elf_link_assign_sym_version): New static function.
691         (elf_link_renumber_dynsyms): New static function.
692         (struct elf_final_link_info): Add symver_sec field.
693         (elf_bfd_final_link): Initialize finfo.symver_sec.  Don't count
694         local symbols of a dynamic object.  Handle DT_VER* constants.
695         (elf_link_output_extsym): Simplify BFD_ASSERT checking for a
696         dynamic object.  Skip indirect symbols from ELF objects.  Remove
697         the version name before choosing a hash bucket.  Write out the
698         version information if appropriate.
699         (elf_link_input_bfd): Check for DYNAMIC, not ET_DYN.
700         * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
701         (bfd_elf64_size_dynamic_sections): Likewise.
702         * bfd-in2.h: Rebuild.
703         * elf-bfd.h (struct elf_link_hash_entry): Add verinfo field.
704         Change elf_link_hash_flags to unsigned short.
705         (ELF_LINK_HIDDEN): Define.
706         (struct elf_obj_tdata): Add fields dynversym_hdr, dynverref_hdr,
707         dynverdef_hdr, dynversym_section, dynverdef_section,
708         dynverref_section, cverdefs, cverrefs, verdef, verref.
709         (elf_dynversym, elf_dynverdef, elf_dynverref): Define.
710         (_bfd_elf_swap_verdef_in, _bfd_elf_swap_verdef_out): Declare.
711         (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Declare.
712         (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Declare.
713         (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Declare.
714         (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Declare.
715         (_bfd_elf_slurp_version_tables): Declare.
716         * elf.c (_bfd_elf_swap_verdef_in): New function.
717         (_bfd_elf_swap_verdef_out): Likewise.
718         (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Likewise.
719         (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Likewise.
720         (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Likewise.
721         (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Likewise.
722         (_bfd_elf_print_private_bfd_data): Add DT_VER* constants.  Print
723         version information if there is any.
724         (_bfd_elf_link_hash_newfunc): Initialize verinfo field.
725         (bfd_section_from_shdr): Handle SHT_GNU_ver* section types.
726         (elf_fake_sections): Handle .gnu.version* section names.
727         (assign_section_numbers): Handle SHT_GNU_ver* section types.
728         (_bfd_elf_slurp_version_tables): New function.
729         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't include
730         version name in string entered in dynamic hash table.
731         * elfcode.h: Include fnmatch.h.
732         * elf32-i386.c (elf_i386_relocate_section): Handle a dynamic
733         symbol which was forced to become local.
734         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
735         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
736         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
737         * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
738
739 Fri Feb 21 16:15:18 1997  Jeffrey A Law  ([email protected])
740
741         * elf32-mn10200.c (mn10200_elf_final_link_relocate): Simplify
742         somewhat.
743         (mn10200_elf_relax_section): Correctly compute a symbol's value
744         when the symbol is local, but not in the same section as we are
745         relaxing.  Implement abs24 -> abs16, imm24 -> imm16 and d24 -> d16
746         relaxing.
747
748 Fri Feb 21 13:55:14 1997  Doug Evans  <[email protected]>
749
750         * elf32-m32r.c: Rewrite to use ELF backend linker.
751         Store lower 16 bits of addend in R_M32R_HI16_[SU]LO insns.
752         Add small data area support (R_M32R_SDA16).
753         * reloc.c: Document BFD_RELOC_M32R_SDA16.
754         * bfd-in2.h,libbfd.h: Regenerated.
755
756 Thu Feb 20 23:50:31 1997  Jeffrey A Law  ([email protected])
757
758         * elf32-mn10200.c (mn10200_elf_relax_section): New function.
759         (mn10200_elf_relax_delete_bytes): Likewise.
760         (mn10200_elf_symbol_address_p): Likewise.
761         (mn10200_elf_get_relocated_section_contents): Likewise.
762         (bfd_elf32_bfd_relax_section): Define.
763         (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
764
765         * elf32-mn10200.c (mn10200_elf_final_link_relocate): New function.
766         (mn10200_elf_relocate_section): Likewise.
767         (elf_backend_relocate_section): Define.
768
769 start-sanitize-d30v
770 Tue Feb 18 17:22:59 1997  Martin M. Hunt  <[email protected]>
771
772         * Makefile.in, archures.c, config.bfd, configure.in, elf.c,
773         reloc.c, targets.c: New target, elf-*-D30V. 
774
775         * bfd-in2.h, configure, libbfd.h: Rebuilt.
776
777         * cpu-d30v.c, elf32-d30v.c: New files.
778         
779 end-sanitize-d30v       
780 Tue Feb 18 15:31:48 1997  Fred Fish  <[email protected]>
781
782         * reloc.c (struct reloc_howto_struct): Fix typo in comment.
783         * bfd-in2.h: Regenerated.
784 start-sanitize-tic80
785         * coff-tic80.c (RTYPE2HOWTO): Replace abort with real function.
786         (rtype2howto): Add function.
787         (tic80_howto_table): Add.
788 end-sanitize-tic80
789         
790 Tue Feb 18 11:41:00 1996  Dawn Perchik  <[email protected]>
791
792         * sysdep.h: Don't define errno in MSVC if error.h is included.
793
794 start-sanitize-v850
795 Tue Feb 18 10:04:13 1997  Jeffrey A Law  ([email protected])
796
797         * elf32-v850.c (v850_elf_relocate_section): Make sure r_symndx
798         is initialized before it is used.
799
800 end-sanitize-v850
801 Mon Feb 17 11:28:40 1997  Ian Lance Taylor  <[email protected]>
802
803         * hp300hpux.c (convert_sym_type): Don't convert a secondary common
804         symbol into a weak undefined symbol; leave it as a common symbol.
805
806 Fri Feb 14 19:08:03 1997  Ian Lance Taylor  <[email protected]>
807
808         * elflink.h (elf_link_add_object_symbols): Don't issue a warning
809         about a symbol defined in a dynamic object if it has already been
810         defined in a regular object.
811
812 Thu Feb 13 20:53:22 1997  Klaus Kaempf  ([email protected])
813
814         * makefile.vms: Add gcc flags to allow compiling with current gcc
815         snapshot
816         (targmatch.h): New dependency.
817
818         * reloc.c (BFD_RELOC_ALPHA_CODEADDR): New relocation for
819         openVMS/Alpha.
820         * evax.h (ALPHA_R_CODEADDR): New relocation.
821         * evax-alpha.c (ALPHA_R_CODEADDR): 64 bit procedure relocation for
822         openVMS/Alpha.
823         * evax-etir.c (ALPHA_R_CODEADDR): Output object code for this
824         relocation.
825         * bfd-in2.h, libbfd.h: Rebuild.
826
827         Restrict symbol length to 64 bytes, case preserving:
828         * evax-emh.c (_bfd_evax_write_emh): Remove case hacking.
829         * evax-misc.c (_bfd_evax_case_hack_symbol): Remove.
830         (_bfd_evax_length_hash_symbol): Added.
831         * evax-etir.c (_bfd_evax_write_etir): Call
832         _bfd_evax_length_hash_symbol before output of symbol.
833         * evax-egsd.c (_bfd_evax_write_egsd): Likewise.
834         * evax.h (flag_hash_long_names, flag_show_after_trunc): Remove.
835
836         * evax-emh.c: Output filename to object file without path.
837
838         * evax-egsd.c: New sections for local and global commons.
839
840         * evax-alpha.c, evax-emh.c, evax-egsd.c, evax-etir.c,
841         evax-misc.c, evax.h: Remove 8 bit characters from copyright
842         notices.  Replace AXP with Alpha.
843
844 Wed Feb 12 18:10:30 1997  Ian Lance Taylor  <[email protected]>
845
846         * sunos.c (sunos_create_dynamic_sections): We need the dynamic
847         sections if we are creating a shared library.
848
849 Tue Feb 11 15:45:43 1997  Doug Evans  <[email protected]>
850
851         * configure.host (i386-windows): Don't set host64=true.
852
853 Tue Feb 11 15:27:32 1997  Ian Lance Taylor  <[email protected]>
854
855         * elf32-mips.c (reloc_type): Add R_MIPS16_GPREL.
856         (elf_mips16_gprel_howto): New static variable.
857         (mips16_gprel_reloc): New static function.
858         (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_GPREL.
859         (mips_info_to_howto_rel): Handle R_MIPS16_GPREL.
860         (mips_elf_relocate_section): Handle R_MIPS16_GPREL.
861         * reloc.c (BFD_RELOC_MIPS16_GPREL): Define.
862         * bfd-in2.h, libbfd.h: Rebuild.
863
864 Mon Feb 10 23:25:00 1997  Doug Evans  <[email protected]>
865
866         * elf32-m32r.c (elf_m32r_howto_table): Change partial_inplace to true
867         for R_M32R_{16,32,24,HI16_ULO,HI16_SLO,LO16}.
868
869 start-sanitize-r5900
870         Fri Feb  7 16:20:17 1997  Gavin Koch   <[email protected]>
871         
872         * config.bfd: add r5900
873         
874 end-sanitize-r5900        
875 Fri Feb  7 12:39:11 1997  Ian Lance Taylor  <[email protected]>
876
877         * elflink.h (elf_link_input_bfd): If we've discarded a section,
878         the output section will be the absolute section; don't print an
879         assertion message for that case when doing a relocateable link.
880
881 Thu Feb  6 16:55:43 1997  Ian Lance Taylor  <[email protected]>
882
883         * elf32-mips.c (FN_STUB, CALL_STUB, CALL_FP_STUB): Define.
884         (struct mips_elf_link_hash_entry): Add new fields fn_stub,
885         need_fn_sub, call_stub, and call_fp_stub.
886         (struct mips_elf_link_hash_table): Add field mips16_stubs_seen.
887         (mips_elf_link_hash_newfunc): Initialize new fields.
888         (mips_elf_link_hash_table_create): Likewise.
889         (mips_elf_relocate_section): Redirect relocations to use mips16
890         stubs when appropriate.
891         (mips_elf_check_relocs): Attach stub sections to the appropriate
892         symbol.  Set need_fn_stub when appropriate.
893         (mips_elf_always_size_sections): New static function.
894         (mips_elf_check_mips16_stubs): New static function.
895         (elf_backend_always_size_sections): Define.
896         * elf-bfd.h (struct elf_obj_tdata): Add local_stubs field.
897
898         * elflink.h (elf_link_input_bfd): Discard local symbols that are
899         attached to sections which are not being included in the link.
900
901 Wed Feb  5 13:20:17 1997  Ian Lance Taylor  <[email protected]>
902
903         * cofflink.c (_bfd_coff_generic_relocate_section): Ignore the
904         symbol value when computing the addend for a pc_relative
905         pcrel_offset reloc.
906
907 Mon Feb  3 11:54:06 1997  Ian Lance Taylor  <[email protected]>
908
909         * cofflink.c (_bfd_coff_generic_relocate_section): If doing a
910         relocateable link, just skip pc_relative pcrel_offset relocs.
911         * coff-arm.c (coff_arm_rtype_to_howto): Return a different howto
912         structure for an ARM26 reloc which can be resolved.
913         (coff_arm_adjust_symndx): Only convert ARM26 to ARM26D if the
914         reloc can be resolved.
915
916         * coff-h8300.c (h8300_reloc16_extra_cases): Correct off by one
917         error in overflow check for R_RELBYTE.
918
919 Fri Jan 31 14:07:27 1997  Ian Lance Taylor  <[email protected]>
920
921         * ieee.c (ieee_slurp_section_data): Pick up the start address.
922         From Mark Rasin <[email protected]>.
923
924         * aoutx.h (aout_link_write_symbols): Don't apply discard_l to
925         debugging symbols.
926
927 Wed Jan 29 00:00:49 1997  Jeffrey A Law  ([email protected])
928
929         * elf32-mn10200.c (reloc_type): Add 16bit pc-relative reloc.
930         (elf_mn10200_howto_table): Likewise.
931         (mn10200_reloc_map): Likewise.
932
933 Mon Jan 27 12:07:35 1997  Doug Evans  <[email protected]>
934
935         * reloc.c: Add relocs BFD_RELOC_M32R_{HI16_[US]LO,LO16}.
936         * bfd-in2.h, libbfd.h: Regenerated.
937         * elf32-m32r.c: Add support for them.
938
939 Mon Jan 27 12:25:02 1997  Ian Lance Taylor  <[email protected]>
940
941         * aout-arm.c (MY_swap_std_reloc_in): Remove unused r_length.
942         * elf32-ppc.c (ppc_elf_check_relocs): Remove unused plt.
943 start-sanitize-v850
944         * elf32-v850.c (v850_elf_final_link_relocate): Remove used
945         r_format and r_pcrel.  Always return a value.
946 end-sanitize-v850
947         * riscix.c (MY_final_link_callback): Define to dummy value.
948
949         * elf32-i386.c (elf_i386_size_dynamic_sections): When checking for
950         relocations against the text segment, look up the output name of
951         the reloc section.
952         * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
953         * elf32-mips.c (mips_elf_size_dynamic_sections): Likewise.
954         * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
955         * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
956         * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
957
958 start-sanitize-tic80
959 Wed Jan 22 15:40:28 1997  Fred Fish  <[email protected]>
960
961         * coff-tic80.c (tic80coff_vec): Use correct data put/get
962         routines for little endian data.
963         * coffcode.h (coff_write_object_contents): Set magic to
964         TIC80_ARCH_MAGIC for TIc80.
965
966 Tue Jan 21 12:32:43 1997  Fred Fish  <[email protected]>
967
968         * coff-tic80.c (tic80coff_vec): Change to little endian data
969         as the default.
970
971 end-sanitize-tic80
972 Thu Jan 16 17:45:57 1997  Ian Lance Taylor  <[email protected]>
973
974         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Change type of
975         auxiliary_filters parameter to be const char * const *.  Accept a
976         NULL terminated array.
977         * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
978         (bfd_elf32_size_dynamic_sections): Update declaration.
979         * bfd-in2.h: Rebuild.
980
981 Wed Jan 15 11:21:32 1997  Ian Lance Taylor  <[email protected]>
982
983         * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Treat a
984         NOTYPE symbol in a text section as a FUNC symbol.
985
986         * coffcode.h (coff_compute_section_file_positions): Force
987         relocbase to be aligned to COFF_DEFAULT_SECTION_ALIGNMENT_POWER.
988
989 Tue Jan 14 08:46:33 1997  Doug Evans  <[email protected]>
990
991         * libaout.h (machine_type): Reserve several values for sparclet.
992
993 start-sanitize-tic80
994 Mon Jan 13 22:39:08 1997  Michael Meissner  <[email protected]>
995
996         * config.bfd (tic80-*-*): Don't require 'coff'.
997
998 end-sanitize-tic80
999 start-sanitize-v850
1000 Mon Jan 13 19:36:25 1997  Michael Meissner  <[email protected]>
1001
1002         * elf32-v850.c (v850_elf_howto_table): Set the special_function
1003         table to v850_elf_reloc for all non-standard relocations.
1004         (v850_elf_check_relocs): Add check for h being non-null.
1005         (v850_elf_reloc): Add  R_V850_ZDA_OFFSET support.  Use switch
1006         statement instead of multiple ifs.
1007         (v850_elf_relocate_section): Fix up error message, don't just call
1008         abort.
1009
1010 end-sanitize-v850
1011 Mon Jan  6 13:28:35 1997  Jeffrey A Law  ([email protected])
1012
1013         * elf32-mn10200.c (elf_mn10200_howto): Don't ever set partial-inplace.
1014         Use bfd_elf_generic_reloc as special function for all relocs.
1015         (bfd_elf32_mn10200_reloc): Remove unnecessary function.
1016
1017         * elf32-mn10200.c (elf_mn10200_howto): Set pcrel_offset for
1018         24bit pc-relative reloc.
1019
1020 start-sanitize-tic80
1021 Fri Jan  3 16:33:00 1997  Fred Fish  <[email protected]>
1022
1023         * Makefile.in (coff-tic80.o): Add coffcode.h to dependency list.
1024         * coff-tic80.c (tic80coff_vec): Data byte order is big endian and
1025         header byte order is little endian.  Use correct bfd_get and
1026         bfd_put routines for little endian headers.
1027         * coffcode.h (coff_set_arch_mach_hook): Set arch to
1028         bfd_arch_tic80 for TIC80_ARCH_MAGIC number.
1029
1030 end-sanitize-tic80
1031 Fri Jan  3 16:54:08 1997  Jeffrey A Law  ([email protected])
1032
1033         * reloc.c: Add BFD_RELOC_24.
1034         * elf32-mn10200.c (enum reloc_type): Add 24bit and pcrel relocs.
1035         (elf_mn10200_howto, mn10200_reloc_map): Corresponding changes.
1036         * bfd-in2.h, libbfd.h: Rebuilt.
1037
1038 Fri Jan  3 16:58:31 1997  Richard Henderson  <[email protected]>
1039
1040         elf64-alpha multiple .got rewrite:
1041
1042         * elf-bfd.h (struct elf_backend_data): Add always_size_sections entry.
1043         (bfd_elf*_mkobject): Don't define here ...
1044         * elfxx-target.h: ... but rather here.  Default always_size_sections
1045         hook to NULL.
1046         * elf.c (elf_mkobject): Rename to bfd_elf_mkobject, since that was 
1047         what the #defines in elf-bfd.h transmuted it to anyway.
1048
1049         * section.c: Add SEC_LINKER_CREATED flag.
1050         * bfd-in2.h: Rebuild.
1051         * elf32-i386.c (elf_i386_check_relocs): Add SEC_LINKER_CREATED to
1052         relocation section flags.
1053         (elf_i386_size_dynamic_sections): Use SEC_LINKER_CREATED instead of
1054         SEC_IN_MEMORY to recognize generated bits.
1055         * elf32-m68k.c (elf_m68k_check_relocs, elf_m68k_size_dynamic_sections):
1056         Likewise.
1057         * elf32-mips.c (mips_elf_final_link, mips_elf_create_dynamic_sections,
1058         mips_elf_create_compact_rel_section, mips_elf_create_got_section,
1059         mips_elf_check_relocs, mips_elf_size_dynamic_sections): Likewise.
1060         * elf32-ppc.c (ppc_elf_create_linker_section,
1061         ppc_elf_size_dynamic_sections): Likewise.
1062         * elf32-sparc.c (elf32_sparc_check_relocs,
1063         elf32_sparc_size_dynamic_sections): Likewise.
1064         * elflink.c (_bfd_elf_create_got_section): Add SEC_LINKER_CREATED to 
1065         section flags.
1066         (_bfd_elf_create_dynamic_sections): Likewise.
1067         (_bfd_elf_make_linker_section_rela): Likewise.
1068         * elflink.h (elf_link_create_dynamic_sections): Likewise.
1069         (bfd_elf,size_dynamic_sections): Call the always_size_sections hook.
1070         (elf_bfd_final_link): Use SEC_LINKER_CREATED instead of SEC_IN_MEMORY
1071         to identify generated bits.
1072         (elf_link_input_bfd): Likewise.
1073
1074         * elf64-alpha.c: Rewrite everything touching relocations.
1075
1076 start-sanitize-v850
1077 Fri Jan  3 11:42:53 1997  Michael Meissner  <[email protected]>
1078
1079         * elf32-v850.c (all functions and static variables): Go through
1080         and regularize names to be of the form v850_elf_<xxx>.
1081         (toplevel): Include <elf/v850.h>.
1082         (enum reloc_type): Move to include/elf/v850.h.
1083         (v850_elf_check_relocs): For common variables, if the variable is
1084         referenced by a R_V850_{SDA,ZDA,TDA} relocation, put the variable
1085         into the appropriate section.
1086         (elf_backend_check_relocs): Define.
1087
1088 Tue Dec 31 15:15:28 1996  Michael Meissner  <[email protected]>
1089
1090         * elf32-v850.c (elf_v850_howto_table): Fix some spacing.
1091
1092 end-sanitize-v850
1093 Tue Dec 31 14:44:50 1996  Ian Lance Taylor  <[email protected]>
1094
1095         * config.bfd (mips*el-*-linux*): New target.
1096         (mips*-*-linux*): New target.
1097
1098         * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Clean up.
1099         Return a useful value.
1100
1101         * Makefile.in (ALL_CFLAGS): Add -D_GNU_SOURCE.
1102
1103         * configure.in: Check ac_cv_func_mmap_fixed_mapped, not
1104         ac_cv_func_mmap.
1105         * configure: Rebuild.
1106         * configure.host: Use ac_cv_func_mmap_fixed_mapped instead of
1107         ac_cv_func_mmap in bfd/configure.host.
1108
1109         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Add
1110         filter_shlib and auxiliary_filter_shlib parameters.
1111         * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_AUXILIARY and
1112         DT_FILTER.
1113         * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
1114         (bfd_elf64_size_dynamic_sections): Likewise.
1115         * bfd-in2.h: Rebuild.
1116
1117 Mon Dec 30 18:48:52 1996  Ian Lance Taylor  <[email protected]>
1118
1119         * xcofflink.c (xcoff_build_ldsyms): When exporting all defined
1120         symbols, don't export a symbol which is defined by an object in an
1121         archive which contains shared objects.
1122
1123 start-sanitize-tic80
1124 Mon Dec 30 16:12:58 1996  Fred Fish  <[email protected]>
1125
1126         * archures.c (enum bfd_architecture): Add bfd_arch_tic80
1127         for TI TMS320c80 (MVP).
1128         (bfd_archures_list): Add bfd_tic80_arch.
1129         * bfd-in2.h: Regenerate by running "make headers".
1130
1131 Sun Dec 29 16:18:52 1996  Fred Fish  <[email protected]>
1132
1133         * cpu-tic80.c (bfd_tic80_arch): Add struct.
1134         * configure.in (case $vec): Correct typo, "tb" not "tp".
1135         Also add cofflink.o for tic80coff_vec.
1136         * configure: Regenerate with autoconf.
1137
1138 end-sanitize-tic80
1139 Mon Dec 30 11:54:56 1996  Ian Lance Taylor  <[email protected]>
1140
1141         * libbfd.c: Patch up the mmap code so that it is only built if BFD
1142         is configured with --with-mmap.
1143
1144 start-sanitize-tic80
1145 Sun Dec 29 10:48:57 1996  Fred Fish  <[email protected]>
1146
1147         * Makefile.in (BFD32_BACKENDS): Add coff-tic80.o
1148         (ALL_MACHINES): Add cpu-tic80.o
1149         (cpu-tic80.o, coff-tic80.o): Add dependencies.
1150         * coff-tic80.c: Add skeleton, cloned from another coff config.
1151         * coffcode.h (coff_write_object_contents): Set magic to TIC80MAGIC
1152         for TIc80.
1153
1154 end-sanitize-tic80
1155 Fri Dec 27 20:56:41 1996  Fred Fish  <[email protected]>
1156
1157         * TODO: Correct a misspelling.
1158 start-sanitize-tic80
1159         * coff-tic80.c: New file for TI TMS320C80 (MVP).
1160         * cpu-tic80.c: New file for TI TMS320C80 (MVP).
1161         * configure.in (case $vec): Add tic80coff_vec entry.
1162         * configure: Regenerate with autoconf.
1163         * archures.c (bfd_tic80_arch): Declare.
1164         * bfd-in2.h (enum bfd_architecture): Add bfd_arch_tic80.
1165         * config.bfd (case ${targ}): Add tic80*-*-coff* target.
1166         * targets.c (tic80coff_vec): Add decl as extern bfd_target.
1167         (bfd_target_vector): Add tic80coff_vec entry.
1168 end-sanitize-tic80
1169
1170 Fri Dec 27 11:48:12 1996  H.J. Lu  <[email protected]>
1171
1172         * elflink.h (elf_buckets): Add some more values for larger
1173         binaries.
1174
1175 Thu Dec 26 18:36:54 1996  Ian Lance Taylor  <[email protected]>
1176
1177         * Makefile.in (install): Move subdir_do out of conditional. From
1178         Fred Fish <[email protected]>.
1179
1180 Wed Dec 18 10:04:30 1996  Jeffrey A Law  ([email protected])
1181
1182         * elf32-mn10200.c (enum reloc_type): Enable basic 8, 16, and
1183         32 bit relocs.
1184         (elf_mn10200_howto_table): Likewise.
1185         (mn10200_reloc_map): Likewise.
1186
1187 Tue Dec 17 11:09:36 1996  Ian Lance Taylor  <[email protected]>
1188
1189         * elf32-mips.c (mips_elf_add_symbol_hook): Add 1 to the value of a
1190         mips16 symbol during the link.
1191         (mips_elf_finish_dynamic_symbol): Subtract 1 from the value of a
1192         mips16 symbol.
1193         (mips_elf_link_output_symbol_hook): New static function.
1194         (elf_backend_link_output_symbol_hook): Define.
1195
1196         * elf.c (bfd_elf_print_symbol): Print the st_other field if it is
1197         not zero.
1198
1199 Mon Dec 16 14:38:39 1996  Ian Lance Taylor  <[email protected]>
1200
1201         * elf.c (bfd_section_from_shdr): Don't check for reloc sections
1202         against SEC_DEBUGGING sections here (revert patch of December 5).
1203         * elfcode.h (elf_object_p): Check for them here, instead.
1204
1205 Sun Dec 15 14:46:06 1996  Ian Lance Taylor  <[email protected]>
1206
1207         * elfcode.h (elf_slurp_reloc_table): Add dynamic parameter.
1208         * elf.c (_bfd_elf_canonicalize_reloc): Pass new argument to
1209         slurp_reloc_table.
1210         (_bfd_elf_get_dynamic_reloc_upper_bound): New function.
1211         (_bfd_elf_canonicalize_dynamic_reloc): New function.
1212         * elf-bfd.h (struct elf_size_info): Update declaration of
1213         slurp_reloc_table.
1214         (_bfd_elf_get_dynamic_reloc_upper_bound): Declare.
1215         (_bfd_elf_canonicalize_dynamic_reloc): Declare.
1216         * elfxx-target.h: Use new dynamic reloc routines by default.
1217         * elf64-mips.c (mips_elf64_slurp_reloc_table): Add dynamic
1218         parameter.
1219
1220 Fri Dec 13 13:18:49 1996  Dan Wilder  <[email protected]>
1221
1222         * coffcode.h (coff_set_flags): Use MC68KBCSMAGIC for bfd_arch_m68k
1223         if NAMES_HAVE_UNDERSCORE is defined.
1224
1225 Fri Dec 13 11:13:23 1996  Doug Evans  <[email protected]>
1226
1227         * libaout.h (enum machine_type): Change M_SPARCLET from 142 to 131.
1228
1229 Thu Dec 12 15:07:20 1996  Michael Meissner  <[email protected]>
1230
1231         * elf32-ppc.c (ppc_elf_check_relocs): Move R_PPC_PLTREL24 into the
1232         supported relocs.
1233
1234 Thu Dec 12 14:55:41 1996  Ian Lance Taylor  <[email protected]>
1235
1236         * elflink.h (elf_link_add_object_symbols): Only add a weak
1237         symbol if the real definition is in the dynamic symbol table.
1238         After finding the real definition, then, if it is dynamic, add the
1239         weak symbol to the dynamic symbol table.
1240
1241         * coff-aux.c (coff_m68k_aux_link_add_one_symbol): Make static.
1242
1243         * ppcboot.c (ppcboot_set_arch_mach): Don't define; it's a
1244         function.
1245         (ppcboot_bfd_print_private_bfd_data): Don't take the address of an
1246         array.
1247
1248 Tue Dec 10 23:23:52 1996  Jeffrey A Law  ([email protected])
1249
1250         * elf32-mn10300.c (reloc_type): Remove big endian mn10300 reloc
1251         variants.
1252         (elf32_mn10300_howto_table, mn10300_reloc_map): Likewise.
1253         (bfd_elf32_mn10300_reloc): Write data in little endian format.
1254         * reloc.c: Remove mn10300 big endian relocs.
1255         * bfd-in2.h, libbfd.h: Rebuilt.
1256
1257         * elf32-mn10200.c: Update from elf32-mn10300.c.
1258  
1259 Fri Dec  6 15:18:05 1996  Jeffrey A Law  ([email protected])
1260
1261         * elf32-mn10300.c (elf_symbol_leading_char): Define.
1262
1263         * elf32-mn10300.c: Add some comments.
1264
1265 Fri Dec  6 17:16:43 1996  Ian Lance Taylor  <[email protected]>
1266
1267         * ihex.c (ihex_scan): Always initialize buf before jumping to
1268         error_return.
1269         (ihex_read_section): Likewise.
1270
1271 Thu Dec  5 22:29:18 1996  Jeffrey A Law  ([email protected])
1272
1273         * elf32-mn10300.c (elf_mn10300_howto_table): Don't set partial-
1274         inplace for most relocs.
1275
1276 Thu Dec  5 13:24:46 1996  Ian Lance Taylor  <[email protected]>
1277
1278         * elflink.h (elf_link_add_object_symbols): Calling check_relocs
1279         even if SEC_ALLOC is not set.
1280         * elf32-i386.c (elf_i386_check_relocs): Don't check SEC_ALLOC
1281         when deciding whether to copy a reloc into a shared object.
1282         (elf_i386_relocate_section): Likewise.
1283         * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
1284         (elf32_sparc_relocate_section): Likewise.
1285         * elf32-i386.c (elf_i386_check_relocs): Don't set SEC_ALLOC in a
1286         reloc section if it is not set in the source section.
1287         * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
1288         * elf.c (bfd_section_from_shdr): Mark a reloc section associated
1289         with a SEC_DEBUGGING section as SEC_DEBUGGING.
1290
1291 Wed Dec  4 14:18:13 1996  Michael Meissner  <[email protected]>
1292
1293         * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): #if 0 code that
1294         expects a .got.plt until we actually create it.
1295
1296 Mon Dec  2 12:13:51 1996  Ian Lance Taylor  <[email protected]>
1297
1298         * cofflink.c (_bfd_coff_generic_relocate_section): Print an error
1299         message for bfd_reloc_outofrange, rather than aborting.  From
1300         Philippe De Muyter <[email protected]>.
1301
1302         * cofflink.c (_bfd_coff_final_link): If there aren't any relocs in
1303         a relocateable link, don't try to process them.  From Heinz Wrobel
1304         <[email protected]>.
1305
1306 Mon Dec  2 00:39:24 1996  Jeffrey A Law  ([email protected])
1307
1308         * elf32-mn10300.c (mn10300_info_howto): Renamed from
1309         mn10300_info_howto_rel.  Tweak reloc argument to be an
1310         Elf32_Internal_Rela.
1311         (USE_RELA): Define instead of USE_REL.
1312         (elf_info_to_howto, elf_info_howto_rel): Corresponding changes.
1313
1314 Sun Dec  1 00:18:59 1996  Peter Schauer  ([email protected])
1315
1316         * configure.in, configure:  Handle mips*-sgi-irix6*.
1317         * irix-core.c (irix_core_core_file_p):  Accept CORE_MAGICN32
1318         core files.
1319
1320 Wed Nov 27 12:10:25 1996  Ian Lance Taylor  <[email protected]>
1321
1322         * elf32-i386.c (elf_i386_relocate_section): Warn about a
1323         relocation against a symbol defined in a section with no output
1324         section.
1325
1326 Tue Nov 26 11:07:31 1996  Ian Lance Taylor  <[email protected]>
1327
1328         * aclocal.m4 (BFD_CC_FOR_BUILD): Don't require AC_C_CROSS.
1329         * configure, config.in: Rebuild with autoconf 2.12.
1330
1331         * elf-bfd.h (struct elf_link_hash_entry): Add other field.
1332         * elf.c (_bfd_elf_link_hash_newfunc): Initialize other field.
1333         (swap_out_syms): Set st_other from existing st_other field.
1334         * elflink.h (elf_link_add_object_symbols): Store st_other in hash
1335         table other field.
1336         (elf_link_output_extsym): Set the other field from the global hash
1337         table entry.
1338         * elf32-mips.c (enum reloc_type): Add R_MIPS16_26.
1339         (elf_mips16_jump_howto): New static variable.
1340         (mips16_jump_reloc): New static function.
1341         (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_JMP.
1342         (mips_info_to_howto_rel): Handle R_MIPS16_26.
1343         (mips_elf_relocate_section): Handle R_MIPS16_26.  Handle R_MIPS_26
1344         to a mips16 symbol.
1345         * reloc.c (BFD_RELOC_MIPS16_JMP): Add to list of relocs.
1346         * bfd-in2.h, libbfd.h: Rebuild.
1347         * cpu-mips.c (arch_info_struct): Add mips:16 entry.
1348
1349 Mon Nov 25 11:23:32 1996  Ian Lance Taylor  <[email protected]>
1350
1351         * configure.host: Use long long for mips-sgi-irix6*.
1352
1353         * coffswap.h (coff_swap_scnhdr_out): Make line number overflow
1354         only a warning.  From Philippe De Muyter <[email protected]>.
1355
1356 Mon Nov 25 08:52:29 1996  Jeffrey A Law  ([email protected])
1357
1358         * elf32-mn10300.c (bfd_elf32_mn10300_reloc): New function.
1359         (enum reloc_type): Add more reloc types.
1360         (elf32_mn10300_howto_table): Update for new reloc types.
1361         (elf32_mn10300_reloc_map): Update for new reloc types.
1362         * reloc.c: Add some new relocs for the mn10300 series.
1363         * bfd-in2.h, libbfd.h: Rebuilt.
1364         
1365 Sat Nov 23 13:26:18 1996  Jeffrey A Law  ([email protected])
1366
1367         * som.c (setup_sections): Don't lose for a space which has
1368         no data, but some symbols.
1369
1370 Fri Nov 22 11:32:13 1996  Ian Lance Taylor  <[email protected]>
1371
1372         * sunos.c (struct sunos_link_hash_table): Add got_needed field.
1373         (sunos_link_hash_table_create): Initialize got_needed.
1374         (sunos_create_dynamic_sections): Only set .got section size if it
1375         is not already set.  Set got_needed.
1376         (bfd_sunos_size_dynamic_sections): Check got_needed.  Only set
1377         sdynptr, and only handle dynamic sections, if dynamic sections are
1378         needed.
1379         (sunos_scan_std_relocs): Pass false to create_dynamic_sections.
1380         Initialize .got section.
1381         (sunos_scan_ext_relocs): Likewise.
1382         (sunos_write_dynamic_symbol): Set up PLT entry even if this is not
1383         a dynamic symbol.
1384         (sunos_finish_dynamic_link): Check got_needed.  Only set up
1385         dynamic linking information if needed.
1386
1387 Thu Nov 21 10:31:31 1996  Rob Savoye  ([email protected])
1388         
1389         * config.bfd: Added VersaDOS format to the Ericsson configuration.
1390
1391 Wed Nov 20 16:31:31 1996  Jeffrey A Law  ([email protected])
1392
1393         * elf32-mn10300.c: Rough cut at relocs for the mn10300.
1394
1395 Wed Nov 13 08:12:38 1996  Jeffrey A Law  ([email protected])
1396
1397         * Makefile.in (elf32-d10v.o): Don't depend on elf/d10v.h
1398         anymore.
1399
1400 Tue Nov 12 13:30:00 1996  Dawn Perchik  <[email protected]>
1401
1402         * filemode.c: Include sysdep.h.
1403         * ihex.c: Add casts to eliminate compiler warnings.
1404         * sunos.c: Add casts to eliminate compiler warnings.
1405
1406 Mon Nov 11 10:37:02 1996  Michael Meissner  <[email protected]>
1407
1408         * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Create .got.plt
1409         section.
1410         (ppc_elf_check_relocs): Add support for R_PPC_LOCAL24PC.  Make
1411         appropriate relocations in the .so file if shared.
1412         (ppc_elf_relocate_section): Ditto.
1413
1414 Tue Oct 29 15:03:02 1996  Doug Evans  <[email protected]>
1415
1416         * elf32-m32r.c (elf_m32r_howto_table, R_M32R_24): Use
1417         complain_overflow_unsigned.
1418
1419 Tue Oct 29 12:53:46 1996  Martin M. Hunt  <[email protected]>
1420
1421         * elf32-d10v.c (elf_d10v_howto_table): Don't complain on
1422         overflows for R_D10V_16 and R_D10V_18.
1423
1424 Tue Oct 29 13:23:53 1996  Ian Lance Taylor  <[email protected]>
1425
1426         * ieee.c (ieee_write_section_part): Use LMA rather than VMA.
1427         (do_with_relocs): Likewise.
1428         (do_as_repeat): Likewise.
1429         (copy_expression): Likewise.
1430
1431 Fri Oct 25 16:56:40 1996  Ian Lance Taylor  <[email protected]>
1432
1433         * ieee.c (ieee_write_external_part): Correctly record whether
1434         there is an external part.
1435
1436 start-sanitize-v850
1437 Thu Oct 24 14:32:52 1996  Jeffrey A Law  ([email protected])
1438
1439         * elf32-v850.c (elf32_v850_bfd_final_link_relocate): Correctly
1440         handle tda offsets for sld.w and sst.w instructions.
1441         Fix alignment check in sld.w and sst.w tda reloc handling.
1442
1443 end-sanitize-v850
1444 Thu Oct 24 09:08:47 1996  Stu Grossman  ([email protected])
1445
1446         * aclocal.m4, configure:  Set USE_BINARY_FOPEN for *-*-windows.
1447
1448 start-sanitize-v850
1449 Wed Oct 23 00:53:16 1996  Jeffrey A Law  ([email protected])
1450
1451         * elf32-v850.c: Add comments about assumptions about
1452         char, short & long sizes.
1453         (elf32_v850_bfd_final_link_relocate): Fix sign extension
1454         problems for several relocs.
1455
1456         * elf32-v850.c (elf32_v850_howto_table): Fix typo in
1457         R_V850_SDA_OFFSET entry.
1458
1459 end-sanitize-v850
1460 Wed Oct 23 00:20:34 1996  Ian Lance Taylor  <[email protected]>
1461
1462         * xcofflink.c (bfd_xcoff_import_symbol): Don't allocate ldsym.
1463         Store import file index in ldindx.
1464         (xcoff_build_ldsyms): Assume that ldsym was not previously
1465         allocated.  For an imported symbol, copy ldindx into l_ifile.
1466
1467 start-sanitize-v850
1468 Tue Oct 22 19:20:38 1996  Jeffrey A Law  ([email protected])
1469
1470         * elf32-v850.c (elf_v850_howto_table): Fix ordering of
1471         R_V850_ZDA_OFFSET and R_V850_TDA_OFFSET.  Fix various
1472         fields in R_V850_TDA_OFFSET.
1473         (elf32_v850_bfd_final_link_relocate): Tweak pc-relative
1474         relocs to work more like other relocs.  Handle R_V850_TDA_OFFSET
1475         relocations.
1476
1477         * elf32-v850.c: Include bfdlink.h.
1478         (bfd_elf32_v850_reloc): Return an error if we get a reloc
1479         we can't handle.
1480         (elf32_v850_bfd_final_link_relocate): New function.
1481         (v850_elf_relocation_section): Likewise.
1482         (elf_backend_relocate_section): Define.
1483
1484 end-sanitize-v850
1485 Tue Oct 22 17:22:43 1996  Ian Lance Taylor  <[email protected]>
1486
1487         * binary.c (binary_set_section_contents): Ignore sections which
1488         don't have SEC_LOAD and SEC_ALLOC set.
1489
1490 Mon Oct 21 12:13:05 1996  Jeffrey A Law  ([email protected])
1491
1492         * linker.c (_bfd_generic_final_link): Avoid losing static
1493         symbols in the .bss section.
1494
1495 Mon Oct 21 10:54:58 1996  Ian Lance Taylor  <[email protected]>
1496
1497         * elf32-mips.c (elf_mips_howto_table): Describe R_MIPS_64.
1498         (mips32_64bit_reloc): New static function.
1499         (mips_reloc_map): Add entry for BFD_RELOC_64.
1500         (mips_elf_relocate_section): Handle R_MIPS_64.
1501
1502         * linker.c (default_indirect_link_order): Print an error message
1503         when attempting to do a relocateable link with different object
1504         file formats, rather than calling abort.
1505
1506 Thu Oct 17 10:43:29 1996  Doug Evans  <[email protected]>
1507
1508         * reloc.c (m32r relocs): Rename them.
1509         * bfd-in2.h, libbfd.h: Regenerated.
1510         * elf32-m32r.c: Update.
1511         (m32r_elf_10_pcrel_reloc): New function.
1512         (elf_m32r_howto_table, R_M32R_10_PCREL entry): Use it.
1513         (elf_m32r_howto_table, R_M32R_24 entry): Fix {src,dst}_masks.
1514
1515 Wed Oct 16 11:24:35 1996  Jeffrey A Law  ([email protected])
1516
1517         * linker.c (_bfd_generic_final_link): Set "linker_mark" for
1518         all sections that will be included in the output file.
1519         (_bfd_generic_link_output_symbols): Discard symbols in sections
1520         which are being discarded.
1521
1522 start-sanitize-v850
1523
1524         * elf32-v850.c (enum reloc_type): Add R_V850_SDA_OFFSET,
1525         R_V850_TDA_OFFSET and R_V850_ZDA_OFFSET.
1526         (elf_v850_howto_table): Corresponding changes.
1527         (elf_v850_reloc_map): Corresponding changes.
1528         * reloc.c: Add additional V850 relocations.
1529         * bfd-in2.h, libbfd.h: Rebuilt.
1530
1531         * elf32-v850.c (bfd_elf32_v850_reloc): Mask out bits we
1532         no longer want in pc-relative relocs.
1533
1534 Tue Oct 15 22:17:37 1996  Jeffrey A Law  ([email protected])
1535
1536         * elf32-v850.c (bfd_elf32_v850_reloc): Don't silently
1537         accept a reloc against an undefined sybmol!
1538
1539 Tue Oct 15 16:17:28 1996  Stu Grossman  ([email protected])
1540
1541         * elf32-v850.c:  Define elf_symbol_leading_char to be '_'.
1542
1543 end-sanitize-v850
1544 Tue Oct 15 12:40:41 1996  Ian Lance Taylor  <[email protected]>
1545
1546         * VERSION: Bump for new relocation.
1547
1548         * hosts/i386bsd.h: If NBPG is not defined, define it as
1549         PAGE_SIZE, for recent versions of FreeBSD.
1550
1551 Mon Oct 14 12:37:26 1996  Ian Lance Taylor  <[email protected]>
1552
1553         * configure.host: Use `long long' as the 64 bit type on a Solaris
1554         host, since both gcc and the SunPRO compilers support it.
1555
1556 Mon Oct 14 11:17:24 1996  Richard Henderson  <[email protected]>
1557
1558         * reloc.c: Create a new BFD_RELOC_ALPHA_ELF_LITERAL.  It was a 
1559         mistake to have reused the ECOFF LITERAL for ELF since they have
1560         different semantics.
1561         * elf64-alpha.c (elf_reloc_map): Map from ELF_LITERAL.
1562         * bfd-in2.h, libbfd.h: Rebuild.
1563
1564         * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Trap .got
1565         section overflow.
1566
1567         * elf64-alpha.c (elf64_alpha_relocate_section): Do not emit a
1568         dynamic relocation for an undefweak symbol when we are building
1569         a static executable.
1570
1571 Thu Oct 10 11:15:06 1996  Stan Shebs  <[email protected]>
1572
1573         * mpw-make.sed (config.bfd, targmatch.sed): Edit references to
1574         point explicitly to srcdir.
1575         (targmatch.h): Edit references to point explicitly to objdir.
1576
1577 Thu Oct 10 14:14:23 1996  Ian Lance Taylor  <[email protected]>
1578
1579         * config.bfd: When setting targ_cpu, don't get confused by
1580         linux-gnu.
1581
1582 Tue Oct  8 08:51:19 1996  Stu Grossman  ([email protected])
1583
1584         * configure.host:  Add support for windows host (a build done
1585         under the Microsoft build environment).
1586
1587 Tue Oct  8 11:40:16 1996  Ian Lance Taylor  <[email protected]>
1588
1589         * elflink.h (elf_link_add_object_symbols): If a symbol is a weak
1590         definition in a dynamic object, add it to the dynamic symbol table
1591         if any dynamic object mentions it.  Reverts part of last patch.
1592
1593         * sunos.c (struct sunos_link_hash_table): Add got_base field.
1594         (sunos_link_hash_table_create): Initialize got_base.
1595         (bfd_sunos_size_dynamic_sections): If the .got section is more
1596         than 0x1000 bytes, set __GLOBAL_OFFSET_TABLE_ and got_base to
1597         0x1000.
1598         (sunos_check_dynamic_reloc): Subtract got_base from a base
1599         relative relocation.
1600
1601         * elf32-mips.c (elf_mips_isa): New static function.
1602         (_bfd_mips_elf_merge_private_bfd_data): Don't warn about linking
1603         -mips1 and -mips2 code together, or -mips3 and -mips4 code.
1604
1605 Mon Oct  7 11:44:17 1996  Ian Lance Taylor  <[email protected]>
1606
1607         * archive.c (do_slurp_coff_armap): Only treat archive as little
1608         endian for i960 COFF.
1609
1610 Fri Oct  4 13:49:01 1996  Ian Lance Taylor  <[email protected]>
1611
1612         * coffcode.h (coff_compute_section_file_positions): Adjust sofar
1613         by the change in size of the section when EXEC_P is not set.
1614
1615         * coff-m68k.c (coff_rtype_to_howto): Define if not defined.
1616         (m68kcoff_rtype_to_howto): New static function.
1617         * cf-m68klynx.c (coff_m68k_lynx_rtype_to_howto): Add the section
1618         VMA to the addend for a PC relative reloc.
1619
1620         * dep-in.sed: Rework backslash loop a bit to avoid bug in sed on
1621         HP/UX 10.20.
1622         * Makefile.in: Rebuild dependencies.
1623
1624         * dep-in.sed: Remove ../bfd/sysdep.h, since it will appear when
1625         som.h is included.
1626
1627 Fri Oct  4 11:41:39 1996  Jeffrey A Law  ([email protected])
1628
1629         * Makefile.in: Remove explicit dependencies for mn10200 and
1630         mn10300 files.
1631         (ALL_MACHINE_CFILES): Add cpu-mn10200.c and cpu-mn10300.c.
1632         (BFD32_BACKENDS_CFILES): Add elf32-mn10200.c and elf32-mn10300.c
1633         (dependencies): Rebuilt.
1634
1635 Thu Oct  3 16:57:51 1996  Ian Lance Taylor  <[email protected]>
1636
1637         * cofflink.c (coff_link_add_symbols): Set obj_coff_keep_syms
1638         during this function.
1639
1640         * elflink.c (_bfd_elf_create_linker_section): Only use an existing
1641         section if the flags are compatible.
1642
1643         * configure.in: Add havevecs, and put it in tdefaults.
1644         * mpw-config.in: Likewise.
1645         * configure: Rebuild.
1646         * targmatch.sed: New file; a sed script to build targmatch.h from
1647         config.bfd.
1648         * config.bfd: Add #if, #endif, and comments for targmatch.h.
1649         * targets.c: Include "fnmatch.h".
1650         (struct targmatch): Define.
1651         (bfd_target_match): Define by including targmatch.h.
1652         (bfd_find_target): If the target is not found by name, search for
1653         it as a configuration triplet.
1654         * Makefile.in: Rebuild dependencies.
1655         (BFD32_BACKENDS): Add aout-arm.o, aout-sparcle.o, hp300bsd.o,
1656         i386dynix.o, m68k4knetbsd.o, and riscix.o.
1657         (BFD32_BACKENDS_CFILES): Add aout-arm.c, aout-sparcle.c,
1658         hp300bsd.c, i386dynix.c, m68k4knetbsd.c, and riscix.c.
1659         (HFILES): Add targmatch.h.  Also, alphabetize and reindent.
1660         (CFILES): Remove i386dynix.c and hp300bsd.c.
1661         (targmatch.h): New target.
1662         (do_clean): Remove targmatch.h.
1663
1664         * configure.in: Add BFD_NEED_DECLARATION(getenv).
1665         * acconfig.h: Add NEED_DECLARATION_GETENV.
1666         * configure, config.in: Rebuild.
1667         * sysdep.h: If NEED_DECLARATION_GETENV, declare getenv.
1668         * aout-adobe.c (aout_adobe_object_p): Don't declare getenv.
1669
1670 Thu Oct  3 09:29:09 1996  Jeffrey A Law  ([email protected])
1671
1672         * cpu-mn10x00.c, elf32-mn10x00: Removed.
1673         * cpu-mn10200.c, cpu-mn10300.c: New files.
1674         * elf32-mn10200.c, elf32-mn10300.c: New files.
1675         * Makefile.in: Break mn10x00 support into two separate
1676         configurations, mn10200 and mn10300.
1677         * archures.c, config.bfd, configure.in, elf.c, targets.c: Likewise.
1678         * bfd-in2.h, configure: Rebuilt.
1679
1680 Thu Oct  3 15:38:19 1996  Jason Molenda  ([email protected])
1681
1682         * Makefile.in (do_clean): Move config.log to do_distclean.
1683
1684 Wed Oct  2 21:40:55 1996  Jeffrey A Law  ([email protected])
1685
1686         * cpu-mn10x00.c, elf32-mn10x00.c: New files.
1687         * Makefile.in (ALL_MACHINES): Add cpu-mn10x00.o.
1688         (BFD32_BACKENDS): Similarly for elf32-mn10x00.o.
1689         (elf32-mn10x00.o): Add dependencies.
1690         * archures.c (enum bfd_architecture): Add bfd_arch_mn10x00.
1691         (bfd_mn10x00_arch): Declare.
1692         (bfd_archures_list): Add bfd_mn10x00_arch.
1693         * config.bfd: Add mn10x00-*-*.
1694         * configure.in: Add bfd_elf32_mn10x00_vec.
1695         * elf.c (prep_headers): Handle bfd_arch_mn10x00.
1696         * targets.c (bfd_elf32_mn10x00_vec): Declare.
1697         (bfd_target_vector): Add bfd_elf32_mn10x00_vec.
1698         * bfd-in2.h, configure: Rebuilt.
1699         
1700 Wed Oct  2 15:46:45 1996  Klaus Kaempf  <[email protected]>
1701
1702         openVMS/Alpha: Provide filename and case_hack flags via
1703         symbol table from gas.
1704         Add case_hack code for symbol output from vax/vms.
1705         * evax-alpha.c (evax_initialize): Remove filename handling,
1706         filename is provided via symbol table.
1707         (evax_get_symtab): Use local symbol count when setting up table.
1708         * evax-egsd.c (_bfd_evax_slurp_egsd): Print correct name when
1709         debugging.
1710         (_bfd_evax_write_egsd): Skip file name symbol.
1711         * evax-emh.c (get_vms_time_string): Local function now.
1712         (_bfd_evax_write_emh): Extract source filename and case_hack flags
1713         from symbol table.
1714         * evax_write_etir (_bfd_evax_write_etir): Pass all symbol names
1715         through _bfd_evax_case_hack_symbol.
1716         * evax-misc.c (hash_string, _bfd_evax_case_hack_symbol): New
1717         functions.
1718         (_bfd_evax_basename): Removed.
1719         (_bfd_get_vms_time_string): Moved to evax-emh.c.
1720         * evax.h (evax_private_data_struct): Remove filename.
1721         (flag_hash_long_names, flag_show_after_trunc,
1722         flag_no_hash_mixed_case, vms_name_mapping): New flags for
1723         vms_case_hack.
1724
1725 Wed Oct  2 12:02:02 1996  Ian Lance Taylor  <[email protected]>
1726
1727         * freebsd.h (N_GET_MAGIC_NET): Don't use ntohl.
1728         (N_GETMID_NET, N_GETFLAG_NET): Likewise.
1729         (NO_SWAP_MAGIC): Don't define.
1730         (SWAP_MAGIC): Define.
1731
1732         * cofflink.c (_bfd_coff_link_input_bfd): Don't crash if there is
1733         no hash table entry for a global symbol.
1734
1735 Tue Oct  1 16:14:22 1996  Joel Sherrill  <[email protected]>
1736
1737         * config.bfd (mips*-*-rtems*): New target, like mips*-*-elf*.
1738
1739 Tue Oct  1 12:31:39 1996  Ian Lance Taylor  <[email protected]>
1740
1741         * cofflink.c (coff_link_add_symbols): Don't override a meaningful
1742         symbol type with T_NULL.  Warn if symbol type changes.  Based on
1743         patch from Philippe De Muyter <[email protected]>.
1744
1745         * elflink.h (elf_link_add_object_symbols): Only put a symbol from
1746         a dynamic object in the dynamic symbol table if it is referenced
1747         or defined by a regular object.
1748
1749 start-sanitize-v850
1750 Fri Sep 27 18:41:07 1996  Stu Grossman  ([email protected])
1751
1752         * elf32-v850.c (bfd_elf32_v850_is_local_label):  New function to
1753         remove dwarf local labels.  Shrinks binaries by a factor of 3!
1754
1755 end-sanitize-v850
1756 Mon Sep 23 13:33:00 1996  Ian Lance Taylor  <[email protected]>
1757
1758         * elf32-ppc.c (ppc_elf_add_symbol_hook): Create the .sbss section
1759         by hand, rather than by calling bfd_make_section.
1760
1761 Mon Sep 23 09:23:41 1996  Doug Evans  <[email protected]>
1762
1763         * reloc.c: Rename m32r relocs.
1764         * bfd-in2.h, libbfd.h: Rebuilt.
1765         * elf32-m32r.c: Update.
1766
1767 Fri Sep 20 11:43:43 1996  Ian Lance Taylor  <[email protected]>
1768
1769         * aoutx.h (aout_link_input_section_ext): When doing a relocateable
1770         link, adjust the symbol index of a base relative reloc.  Don't
1771         change the addend of a PC relative reloc if pcrel_offset is set.
1772         * sunos.c (bfd_sunos_size_dynamic_sections): Don't do anything for
1773         a relocateable link.
1774
1775         * reloc.c (bfd_perform_relocation): Apply the relocation even if
1776         it is zero, in case src_mask matters.
1777         (bfd_install_relocation): Likewise.
1778
1779 Thu Sep 19 11:03:06 1996  Ian Lance Taylor  <[email protected]>
1780
1781         * xcofflink.c (xcoff_link_add_symbols): Always initialize
1782         keep_syms.
1783         (_bfd_xcoff_bfd_final_link): Don't set target_index
1784         to an uninitialized value.
1785
1786 Tue Sep 17 14:18:31 1996  Ian Lance Taylor  <[email protected]>
1787
1788         * coffcode.h (coff_slurp_line_table): Warn about illegal symbol
1789         indices, rather than crashing.
1790         (coff_slurp_reloc_table): Likewise.  Check whether the howto field
1791         is NULL.
1792         * coff-sh.c (sh_relocate_section): Check for an illegal symbol
1793         index.
1794
1795 Mon Sep 16 12:39:36 1996  Ian Lance Taylor  <[email protected]>
1796
1797         * coff-arm.c (aoutarm_std_reloc_howto): Change dst_mask for ARM26D
1798         reloc to 0.
1799         (coff_arm_adjust_symndx): New static function.
1800         (coff_adjust_symndx): Define.
1801
1802         * srec.c (srec_scan): Accept multiple symbols on a single line.
1803         From Pascal Martin <[email protected]>.
1804
1805         * README: New file.
1806
1807 Fri Sep 13 14:32:42 1996  Doug Evans  <[email protected]>
1808
1809         * aoutf1.h (MY_bfd_merge_private_bfd_data): Define.
1810         (sunos_merge_private_bfd_data): New function.
1811
1812 Fri Sep 13 15:50:57 1996  Ian Lance Taylor  <[email protected]>
1813
1814         * bfd.c (bfd_copy_private_bfd_data): Switch on output BFD rather
1815         than input BFD.
1816         (bfd_merge_private_bfd_data): Likewise.
1817         * section.c (bfd_copy_private_section_data): Likewise.
1818         * syms.c (bfd_copy_private_symbol_data): Likewise.
1819         * bfd-in2.h: Rebuild.
1820         * aout-target.h (MY_bfd_copy_private_section_data): Check that
1821         both BFD's are the right flavour.
1822         * ecoff.c (_bfd_ecoff_bfd_copy_private_bfd_data): Likewise.
1823         * elf.c (_bfd_elf_copy_private_symbol_data): Likewise.
1824         * elf32-mips.c (_bfd_mips_elf_copy_private_bfd_data): Likewise.
1825         (_bfd_mips_elf_merge_private_bfd_data): Likewise.
1826         * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Likewise.
1827         (ppc_elf_merge_private_bfd_data): Likewise.
1828         * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Likewise.
1829         * peicode.h (pe_bfd_copy_private_section_data): Likewise.
1830
1831         * elf32-hppa.c (elf_hppa_howto_table): Fill in some fields for
1832         R_PARISC_DIR32, so that _bfd_stab_section_find_nearest_line passes
1833         its sanity check.
1834
1835 Thu Sep 12 11:45:57 1996  Doug Evans  <[email protected]>
1836
1837         * reloc.c: Add m32r relocs.
1838         * bfd-in2.h, libbfd.h: Rebuilt.
1839         * cpu-m32r.c,elf32-m32r.c: New files.
1840
1841 Thu Sep 12 11:10:05 1996  Ian Lance Taylor  <[email protected]>
1842
1843         * ieee.c (ieee_vec): Set symbol_leading_char field to '_'.
1844
1845 Wed Sep 11 11:57:56 1996  Ian Lance Taylor  <[email protected]>
1846
1847         * tekhex.c (first_phase): Change type parameter from char to int.
1848         (out): Likewise.
1849         (pass_over): Change func to expect int, not char.
1850
1851         * elf.c (assign_file_positions_for_segments): Test SEC_ALLOC
1852         rather than SEC_LOAD when aligning the file offset for the first
1853         section in a segment.
1854
1855 Tue Sep 10 16:18:30 1996  Fred Fish  <[email protected]>
1856
1857         * syms.c (coff_section_type): Make arg const.
1858         * irix-core.c (irix_core_core_file_p): Remove extraneous extra arg
1859         to make_bfd_asection().
1860         * elf-bfd.h (bfd_section_from_phdr): Add prototype.
1861         * elfcode.h (bfd_section_from_phdr): Remove prototype.
1862         (_bfd_elf_stringtab_init): Remove prototype.
1863
1864         * netbsd-core.c (swap_abort): Add prototype.
1865         * aix386-core.c (swap_abort): Ditto & make static
1866         * hpux-core.c (swap_abort): Ditto & make static.
1867         * irix-core.c (swap_abort): Ditto & make static.
1868         * ptrace-core.c (swap_abort): Ditto & make static.
1869         * trad-core.c (swap_abort): Ditto & make static.
1870         * coffswap.h (coff_swap_reloc_in): Ditto.
1871         (coff_swap_reloc_out): Ditto.
1872         (coff_swap_filehdr_in): Ditto.
1873         (coff_swap_filehdr_out): Ditto.
1874         (coff_swap_sym_in): Ditto.
1875         (coff_swap_sym_out): Ditto.
1876         (coff_swap_aux_in): Ditto.
1877         (coff_swap_aux_out): Ditto.
1878         (coff_swap_lineno_in): Ditto.
1879         (coff_swap_lineno_out): Ditto.
1880         (coff_swap_aouthdr_in): Ditto.
1881         (coff_swap_aouthdr_out): Ditto.
1882         (coff_swap_scnhdr_in): Ditto.
1883         (coff_swap_scnhdr_out): Ditto.
1884         * ihex.c (ihex_sizeof_headers): Ditto.
1885         * tekhex.c (getsym): Ditto.
1886         (find_chunk): Ditto & make static.
1887         (insert_byte): Ditto.
1888         (first_phase): Ditto.
1889         (pass_over): Ditto.
1890         (tekhex_get_symtab): Ditto & make static.
1891         (tekhex_get_symtab_upper_bound): Ditto & make static.
1892         (tekhex_mkobject): Ditto.
1893         (tekhex_object_p): Ditto.
1894         (move_section_contents): Ditto.
1895         (tekhex_get_section_contents): Ditto.
1896         (tekhex_set_arch_mach): Ditto & make static.
1897         (tekhex_set_section_contents): Ditto.
1898         (writevalue): Ditto.
1899         (writesym): Ditto.
1900         (out): Ditto.
1901         (tekhex_write_object_contents): Ditto.
1902         (tekhex_sizeof_headers): Ditto.
1903         (tekhex_make_empty_symbol): Ditto.
1904         (tekhex_get_symbol_info): Ditto.
1905         (tekhex_print_symbol): Ditto.
1906         * irix-core.c (make_bfd_asection): Ditto.
1907         (irix_core_core_file_p): Ditto.
1908         (irix_core_core_file_failing_command): Ditto.
1909         (irix_core_core_file_failing_signal): Ditto.
1910         (irix_core_core_file_matches_executable_p): Ditto.
1911         (irix_core_make_empty_symbol): Ditto.
1912         * coff-mips.c (mips_bfd_reloc_type_lookup): Ditto.
1913         * srec.c (srec_new_symbol): Ditto.
1914         (srec_get_section_contents): Ditto.
1915         (srec_set_arch_mach): Ditto.
1916         (srec_set_section_contents): Ditto.
1917         (internal_srec_write_object_contents): Ditto.
1918         (srec_write_object_contents): Ditto.
1919         (symbolsrec_write_object_contents): Ditto.
1920         (srec_sizeof_headers): Ditto.
1921         (srec_make_empty_symbol): Ditto.
1922         (srec_get_symtab_upper_bound): Ditto.
1923         (srec_get_symtab): Ditto.
1924         (srec_print_symbol): Ditto and make static.
1925         * elf.c (elf_read): Ditto
1926         (assign_section_numbers): Ditto.
1927         (elf_fake_sections): Ditto.
1928         (sym_is_global): Ditto.
1929         (elf_map_symbols): Ditto.
1930         (get_program_header_size): Ditto.
1931         * coffgen.c (make_a_section_from_file): Ditto.
1932         (coff_real_object_p): Ditto.
1933         (fixup_symbol_value): Ditto.
1934         (build_debug_section): Ditto.
1935         (copy_name): Ditto.
1936         * syms.c (coff_section_type): Ditto.
1937         
1938 Mon Sep  9 22:36:01 1996  Jeffrey A Law  ([email protected])
1939
1940         * bfd-in2.h: Rebuilt after m32r changes.
1941
1942 Mon Sep  9 12:31:22 1996  Doug Evans  <[email protected]>
1943
1944         * config.bfd,configure.in,configure: Add m32r support.
1945         * Makefile.in,archures.c,elf.c,targets.c: Likewise.
1946         * config.bfd: Keep target list alphabetically sorted.
1947
1948 start-sanitize-v850
1949 Mon Sep  9 11:48:41 1996  Jeffrey A Law  ([email protected])
1950
1951         * elf32-v850.c (bfd_elf32_v850_reloc, case R_V850_HI16): Don't forget
1952         to add in the constant part found in the instruction itself.
1953         (case R_V850_HI16_S): Likewise.
1954
1955 end-sanitize-v850 
1956 Fri Sep  6 17:04:39 1996  Martin M. Hunt  <[email protected]>
1957
1958         * elf32-d10v.c (elf_d10v_howto_table): Modify the size of R_D10V_16
1959         and R_D10V_18 to be 1 (word).
1960
1961 Thu Sep  5 15:23:08 1996  Ian Lance Taylor  <[email protected]>
1962
1963         * stabs.c (_bfd_link_section_stabs): If the output_section field
1964         of either section is bfd_abs_section, then the linker is
1965         discarding the section and we should not optimize it.
1966
1967 Tue Sep  3 12:16:20 1996  Doug Evans  <[email protected]>
1968
1969         * Makefile.in (aout-sparcle.o): New target.
1970         * aoutf1.h (TARGET_IS_BIG_ENDIAN_P): Don't define if little endian.
1971         * config.bfd (sparclet-*-aout*): Add case.
1972         * configure.in (sparcle_aout_vec): Add case.
1973         * configure: Regenerated.
1974         * targets.c (sparcle_aout_vec): Declare.
1975         (bfd_target_vector): Add sparcle_aout_vec.
1976         * aout-sparcle.c: New file.
1977
1978 start-sanitize-v850
1979 Tue Sep  3 00:57:02 1996  Jeffrey A Law  ([email protected])
1980
1981         * elf32-v850.c (bfd_elf32_v850_reloc): Fix handling of
1982         low order sign bit propogation for R_V850_HI16_S.
1983
1984         * elf32-v850.c (bfd_elf32_v850_reloc): New function for
1985         handling V850 specific relocs.
1986         (elf_v850_howto_table): Use the new function for some
1987         relocations.  Twiddle masks & shifts for some relocs.
1988         Set partial_inplace where needed.
1989
1990 end-sanitize-v850
1991 Mon Sep  2 12:12:34 1996  Ian Lance Taylor  <[email protected]>
1992
1993         * cpu-mips.c: Add an explicit mips:3000 entry, and change the
1994         default architecture to a machine number of 0.
1995         * elf32-mips.c (_bfd_mips_elf_object_p): Set the machine number
1996         for E_MIPS_ARCH_1.
1997         (_bfd_mips_elf_merge_private_bfd_data): If the machine number of
1998         the output BFD is the default, set it from the first input BFD.
1999
2000 start-sanitize-v850
2001 Sun Sep  1 18:38:01 1996  Jeffrey A Law  ([email protected])
2002
2003         * elf32-v850.c (elf_v850_howto_table): All the 16bit relocs
2004         insert at bitpos zero.  The HI16 relocs are shifted right
2005         by 16 bits.  Fix src_mask for all relocs.
2006         (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME): Define.  The V850 is
2007         little endian!
2008         (TARGET_BIG_SYM, TARGET_BIG_NAME): Remove.  The V850 is little
2009         endian!
2010
2011 end-sanitize-v850
2012 Sun Sep  1 15:41:08 1996  Ian Lance Taylor  <[email protected]>
2013
2014         * rs6000-core.c (rs6000coff_core_file_matches_executable_p):
2015         Rewrite to use BFD file read routines and to avoid using a fixed
2016         length for the file name.
2017
2018 start-sanitize-v850
2019 Sat Aug 31 10:22:25 1996  Jeffrey A Law  ([email protected])
2020
2021         * elf32-v850.c (enum reloc_type): Add R_V850_{32,16,8}.
2022         (elf_v850_howto_table): Add support for R_V850_{32,16,8}.
2023         (v850_reloc_map): Add translation from BFD_RELOC_{32,16,8}
2024         to R_V850_{32,16,8}.
2025
2026 Fri Aug 30 18:06:04 1996  J.T. Conklin  <[email protected]>
2027
2028         * elf32-v850.c (reloc_type): Add R_V850_HI16_S.
2029         (elf_v850_howto_table): Add info for HI16_S reloc.
2030         (v850_reloc_map): Add HI_16_S reloc.
2031         * reloc.c: Define BFD_RELOC_V850_* relocs.
2032
2033 end-sanitize-v850
2034 Fri Aug 30 11:49:19 1996  Ian Lance Taylor  <[email protected]>
2035
2036         Add SH ELF support.
2037         * elf32-sh.c: New file.
2038         * elf.c (prep_headers): Handle bfd_arch_sh.
2039         * elfcode.h (write_relocs): Handle absolute symbol.
2040         * elf-bfd.h (_bfd_elf32_link_read_relocs): Declare.
2041         (_bfd_elf64_link_read_relocs): Declare.
2042         * elflink.h (NAME(_bfd_elf,link_read_relocs)): Rename from
2043         elf_link_read_relocs.  Make globally visible.  Change all
2044         callers.
2045         (elf_link_input_bfd): Get external symbols from cache in
2046         symtab_hdr->contents.  Get contents from cache in
2047         elf_section_data.
2048         * elfxx-target.h (bfD_elfNN_bfd_relax_section): Only define if not
2049         already defined.
2050         * reloc.c: Define BFD_RELOC_SH_* relocs.
2051         * libbfd-in.h (_bfd_sh_align_load_span): Declare.
2052         * coff-sh.c (sh_insns_conflict): Fix a return value.
2053         (_bfd_sh_align_load_span): New globally visible function, broken
2054         out of sh_align_load.
2055         (sh_align_load): Call _bfd_sh_align_load_span.
2056         (sh_swap_insns): Change relocs parameter to PTR.
2057         * bfd-in2.h, libbfd.h: Rebuild.
2058         * targets.c (bfd_elf32_sh_vec): Declare.
2059         (bfd_elf32_shl_vec): Declare.
2060         * config.bfd (sh-*-elf*): New target.
2061         * configure.in (bfd_elf32_sh_vec): New target vector.
2062         (bfd_elf32_shl_vec): New target vector.
2063         * configure: Rebuild.
2064         * Makefile.in: Rebuild dependencies.
2065         (BFD32_BACKENDS): Add elf32-sh.o.
2066         (BFD32_BACKENDS_CFILES): Add elf32-sh.c.
2067
2068         * elf.c (map_sections_to_segments): Check that LMA does not skip a
2069         page before checking D_PAGED.
2070
2071         * ihex.c (ihex_scan): Removed unnecessary extbase variable.
2072         (ihex_write_object_contents): Remove extbase; always use segbase
2073         instead.
2074
2075 Thu Aug 29 16:52:17 1996  Michael Meissner  <[email protected]>
2076
2077         * configure.in (i[345]86-*-*): Recognize i686 for pentium pro.
2078         * configure.host (i[345]86-*-*): Ditto.
2079         * config.bfd (i[345]86-*-*): Ditto.
2080         * configure: Regenerate.
2081
2082         * config.bfd (i[3456]86-*-dgux*): Recognize as a synonym for x86
2083         elf.
2084
2085 Tue Aug 27 09:18:18 1996  Jeffrey A Law  ([email protected])
2086
2087         * elf32-hppa.c (hppa_elf_gen_reloc_type): Add new argument.
2088         * elf32-hppa.h (hppa_elf_gen_reloc_type): Update prototype.
2089         * som.c (hppa_som_gen_reloc_type): Add new argument.  If
2090         we encounter an R_DATA_ONE_SYMBOL reloc against a symbol that
2091         will have an ST_CODE type, change the symbol's type to ST_DATA.
2092         * som.c (hppa_som_gen_reloc_type): Update prototype.
2093
2094 Tue Aug 27 00:12:22 1996  Ian Lance Taylor  <[email protected]>
2095
2096         * elf32-mips.c (mips_elf_check_relocs): Set dynobj if needed for
2097         R_MIPS_32 and R_MIPS_REL32.  Set sgot and g as soon as possible.
2098         (mips_elf_size_dynamic_sections): Don't require .got to exist.
2099         (mips_elf_finish_dynamic_sections): Likewise.
2100
2101 Thu Aug 22 10:54:38 1996  Ian Lance Taylor  <[email protected]>
2102
2103         * configure.host (HLDENV): New variable to set.  Set it for
2104         *-*-sysv4*, since those linkers may not support -R but they always
2105         support LD_RUN_PATH.
2106
2107         * libieee.h (NSECTIONS): Don't define.
2108         (ieee_data_struct): Change section_table to asection **.  Add
2109         section_table_size.
2110         * ieee.c (get_section_entry): If the table isn't big enough, make
2111         it bigger.
2112         (ieee_slurp_sections): Remove assertion about number of sections.
2113         (ieee_object_p): Adjust initialization of ieee to match changes to
2114         the structure.
2115
2116         * xcofflink.c (xcoff_mark): Don't copy relocs for undefined
2117         symbols merely because we are generating a shared library.
2118         (xcoff_build_ldsyms): Don't set up global linkage code for an
2119         undefined symbol merely because we are generating a shared
2120         library.
2121
2122 start-sanitize-v850
2123 Tue Aug 20 15:06:05 1996  J.T. Conklin  <[email protected]>
2124         
2125         * Makefile.in (ALL_MACHINES): Add cpu-v850.o.
2126         (BFD32_BACKENDS) Add elf32-v850.o.
2127         * archures.c: Add bfd_v850_arch.
2128         * bfd-in2.h: Add bfd_v850_arch.
2129         * config.bfd (v850-*-*): New target.
2130         * configure: (bfd_elf32_v850_vec) New vector.
2131         * configure.in: (bfd_elf32_v850_vec) New vector.
2132         * cpu-v850.c: New file.
2133         * elf.c (prep_headers): Added case bfd_arch_v850.
2134         * elf32-v850.c: New file.
2135         * targets.c (bfd_elf32_v850_vec): New vector.
2136         
2137 end-sanitize-v850
2138 Fri Aug 16 16:25:35 1996  Ian Lance Taylor  <[email protected]>
2139
2140         * xcofflink.c (xcoff_link_add_dynamic_symbols): Create and define
2141         a function code symbol for an XMC_XO symbol.
2142
2143 Thu Aug 15 12:33:29 1996  Stan Shebs  <[email protected]>
2144
2145         * mpw-config.in: Update editing of autoconf vars to reflect
2146         Jul 18 configure.in change.
2147         * mpw-make.sed: Update editing of include pathnames to be
2148         more general, add @DASH_C_FLAG@ to explicit compile rule edit.
2149
2150 Thu Aug 15 10:35:13 1996  Richard Henderson  <[email protected]>
2151
2152         * elf64-alpha.c (elf64_alpha_output_extsym): The section from
2153         which to offset to get the .plt entry address is ".plt".
2154
2155 Thu Aug 15 16:40:30 1996  James G. Smith  <[email protected]>
2156
2157         * reloc.c: (BFD_RELOC_ARM_THUMB_ADD, BFD_RELOC_ARM_THUMB_IMM,
2158         BFD_RELOC_ARM_THUMB_SHIFT, BFD_RELOC_ARM_THUMB_OFFSET):
2159         Added, for internal use by the ARM gas.
2160         * libbfd.h: Rebuilt
2161         * bfd-in2.h: Rebuilt
2162
2163 Wed Aug 14 17:02:09 1996  Richard Henderson  <[email protected]>
2164
2165         * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Correct typo
2166         in section dynidx start.
2167
2168 Tue Aug 13 14:35:38 1996  Ian Lance Taylor  <[email protected]>
2169
2170         * elf.c (_bfd_elf_make_section_from_shdr): Treat sections whose
2171         name begins with .gnu.linkonce as SEC_LINK_ONCE.  This is an
2172         optimization for g++.
2173
2174 Tue Aug 13 17:04:40 1996  Michael Meissner  <[email protected]>
2175
2176         * elf32-ppc.c (ppc_elf_merge_private_bfd_data): If one module has
2177         the -mrelocatable-lib bit set and the other doesn't, clear the
2178         -mrelocatable-lib bit in the header.
2179
2180 Sat Aug 10 22:59:17 1996  Ian Lance Taylor  <[email protected]>
2181
2182         * elflink.h (elf_link_add_object_symbols): Do not resolve a common
2183         symbol against a STT_FUNC symbol in a shared library.
2184
2185 Fri Aug  9 12:44:57 1996  Ian Lance Taylor  <[email protected]>
2186
2187         * xcofflink.c (xcoff_link_add_dynamic_symbols): If a descriptor
2188         symbol is found, automatically define the corresponding function
2189         code.
2190
2191         * cofflink.c (coff_link_add_symbols): Only set (*sym_hash)->numaux
2192         if sym.n_numaux is not zero.
2193         (_bfd_coff_link_input_bfd): Permit the symbol and the hash table
2194         entry to disagree about the number of aux entries if the symbol
2195         has zero.
2196
2197         * elf32-mips.c (mips_elf_check_relocs): Create the .rel.dyn
2198         section if it might be needed, not just if info->shared.
2199         (mips_elf_adjust_dynamic_symbol): Make room for a null element at
2200         the start of .rel.dyn if we are going to use it.
2201         (mips_elf_finish_dynamic_sections): Only clear the first element
2202         of .rel.dyn if the size is greater than zero.
2203
2204 Thu Aug  8 16:24:55 1996  Ian Lance Taylor  <[email protected]>
2205
2206         * xcofflink.c (xcoff_link_input_bfd): If we already called the
2207         undefined_symbol callback for a symbol, then don't issue any more
2208         warnings about loader relocs.
2209         (_bfd_ppc_xcoff_relocate_section): Don't do any further processing
2210         after calling the undefined_symbol callback.
2211
2212         * xcofflink.c (XCOFF_MULTIPLY_DEFINED): Define.
2213         (xcoff_link_add_symbols): Permit multiple definitions of a symbol
2214         as the AIX linker seems to do.
2215
2216 Thu Aug  8 12:21:56 1996  Klaus Kaempf  <[email protected]>
2217
2218         * evax-alpha.c (evax_alpha_vec): Corrected flags, cleanup.
2219         (evax_initialize): Remove evax_reloc_table.
2220         (evax_close_and_cleanup): Ditto.
2221         (reloc_nil): Ditto.
2222         (alpha_howto_table): Remove ALPHA_R_SWREL32 and ALPHA_R_SWREL64
2223         entries.
2224         (evax_bfd_reloc_type_lookup): Ditto.
2225         * evax-egsd.c (_bfd_evax_slurp_egsd): Add a few casts; set
2226         cooked_size == raw_size.
2227         * evax-emh.c (_bfd_evax_register_filename): Remove.
2228         * evax-etir.c (etir_stc): Allow ETIR_S_C_STC_xx commands.
2229         * evax-misc.c (add_new_contents): Malloc section at full size.
2230         (_bfd_save_evax_section): Memcpy section contents directly.
2231         * evax.h (ALPHA_R_SWREL32, ALPHA_R_SWREL64): Remove.
2232         (evax_reloc_table): Remove.
2233
2234         * hosts/alphavms.h (O_ACCMODE): Define if needed.
2235
2236         * makefile.vms: Add better support for DEC C compilation
2237         Add evax.h dependencies
2238
2239         * reloc.c (bfd_get_reloc_size): Add case for 16 byte reloc.
2240         (BFD_RELOC_SWREL32,BFD_RELOC_SWREL64): Remove.
2241         (BFD_RELOC_ALPHA_BASEREG): Remove.
2242         * bfd-in2.h, libbfd.h: Rebuild.
2243
2244 Thu Aug  8 08:17:32 1996  Stu Grossman  ([email protected])
2245
2246         * archive.c (bsd_write_armap):  Ifdef around calls to getuid and
2247         getgid if _WIN32 is defined.
2248         * opncls.c (bfd_fdopenr):  Remove unnecessary WINGDB ifdef.
2249
2250 Wed Aug  7 23:19:00 1996  Stu Grossman  ([email protected])
2251
2252         * aoutx.h bfd-in.h bfd-in2.h opncls.c riscix.c som.c targets.c:
2253         Change NO_FLAGS to BFD_NO_FLAGS to avoid conflict with an HPUX
2254         include file.
2255         * libbfd.c:  Create dummy getpagesize() macro if HAVE_GETPAGESIZE
2256         isn't defined.
2257
2258 Wed Aug  7 14:11:44 1996  Philippe De Muyter  <[email protected]>
2259
2260         * configure.in: Call BFD_NEEDED_DECLARATION on strstr and
2261         realloc.
2262         * acconfig.h (NEED_DECLARATION_STRSTR): New macro.
2263         (NEED_DECLARATION_REALLOC): New macro.
2264         * configure, config.in: Rebuild.
2265         * sysdep.h (strstr): Declare if NEED_DECLARATION_STRSTR.
2266         (realloc): Declare if NEED_DECLARATION_REALLOC.
2267
2268         * aclocal.m4 (BFD_NEED_DECLARATION): Include <string.h> or
2269         <strings.h> if they exist.
2270
2271         * ieee.c (ieee_set_section_contents): Cast bfd_alloc return.
2272
2273 Wed Aug  7 12:12:03 1996  Ian Lance Taylor  <[email protected]>
2274
2275         * cpu-i386.c (i8086_arch): Architecture info for the i8086.
2276
2277         Based on patches from Eric Valette <[email protected]>:
2278         * elf32-i386.c (enum reloc_type): Add FIRST_INVALID_RELOC,
2279         LAST_INVALID_RELOC, R_386_16, R_386_PC16, R_386_8, R_386_PC8.
2280         (elf_howto_table): Add entries for new relocs.
2281         (elf_i386_reloc_type_lookup): Handle new relocs.
2282         (elf_i386_info_to_howto): Just call abort.
2283         (elf_i386_info_to_howto_rel): Check that the reloc type is valid.
2284         (elf_i386_relocate_section): Likewise.
2285
2286 Tue Aug  6 12:54:56 1996  Martin M. Hunt  <[email protected]>
2287
2288         * elf32-d10v.c (elf_d10v_howto_table): Added R_D10V_32.
2289
2290 Mon Aug  5 13:42:41 1996  Ian Lance Taylor  <[email protected]>
2291
2292         * elf.c (_bfd_elf_make_section_from_shdr): For a loadable section,
2293         only get the LMA from the phdr if they are in the same part of the
2294         file.
2295
2296         * elf.c (map_sections_to_segments): Rewrite tests for starting a
2297         new segment to make them more comprehensible.  If the relationship
2298         between the LMA and the VMA changed, start a new segment.  Don't
2299         check dynsec when deciding whether to start a new segment for a
2300         writeable section; -N will now handle this.
2301
2302 Thu Aug  1 22:43:08 1996  Jeffrey A Law  ([email protected])
2303
2304         * libhppa.h: Remove "esel" changes.  Not the right approach.
2305         * som.c: Corresponding changes.
2306         (som_bfd_derive_misc_symbol_info): Use ST_DATA for symbols
2307         which don't have a SOM symbol type associated with them.
2308         Reverses a 1994 change.
2309
2310 Wed Jul 31 15:50:55 1996  Ian Lance Taylor  <[email protected]>
2311
2312         Make ld -N more reasonable for ELF:
2313         * elf.c (map_sections_to_segments): If D_PAGED is not set, set
2314         phdr_in_section to false, and always use a single load segment.
2315         (elf_sort_sections): Sort sections by LMA after VMA.
2316         (assign_file_positions_for_segments): If D_PAGED is not set, don't
2317         align to maxpagesize.
2318         (assign_file_positions_except_relocs): Likewise.
2319         * elfcode.h (elf_object_p): If a section is loaded but not page
2320         aligned, clear D_PAGED.
2321
2322 Wed Jul 31 15:00:12 1996  James G. Smith  <[email protected]>
2323
2324         * reloc.c: (BFD_RELOC_ARM_OFFSETIMM8, BFD_RELOC_ARM_HWLITERAL):
2325         Added, for internal use by the ARM gas.
2326         * libbfd.h: Rebuilt
2327         * bfd-in2.h: Rebuilt
2328
2329 Tue Jul 30 14:14:57 1996  Jeffrey A Law  ([email protected])
2330
2331         * libhppa.h (R_HPPA_ESEL): New field selector.
2332         (e_esel): Similarly.
2333         * som.c (hppa_som_gen_reloc_type): If we encounter an e_esel,
2334         then generate R_COMP2 (PUSH_SYM), R_DATA_EXPR fixup stream.
2335         (som_write_fixups): Handle R_DATA_EXPR just like R_CODE_EXPR.
2336
2337 Tue Jul 30 13:31:27 1996  Ian Lance Taylor  <[email protected]>
2338
2339         * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Do the regular
2340         archive search before looking for stripped dynamic objects.
2341
2342 Fri Jul 26 17:51:39 1996  Ian Lance Taylor  <[email protected]>
2343
2344         * xcofflink.c (xcoff_build_ldsyms): Make exporting an undefined
2345         symbol a warning rather than an error.
2346
2347 Wed Jul 24 12:02:53 1996  Ian Lance Taylor  <[email protected]>
2348
2349         * elf.c (assign_file_positions_for_segments): Track the virtual
2350         memory position separately from the file position, and use it to
2351         compute the alignment adjustment.
2352
2353 Tue Jul 23 10:43:31 1996  Martin M. Hunt  <[email protected]>
2354
2355         * elf32-d10v.c (elf_d10v_howto_table): Changed all relocs to "long"
2356         and fixed mask on R_D10V_10_PCREL_L.
2357
2358 Mon Jul 22 15:30:30 1996  Ian Lance Taylor  <[email protected]>
2359
2360         * elf64-mips.c: Include "aout/ar.h".
2361         (mips_elf64_slurp_armap): New static function.
2362         (mips_elf64_write_armap): New static function.
2363         (bfd_elf64_archive_*): Define.
2364         * elfxx-target.h (bfd_elfNN_archive_p): Define if not defined.
2365         Use instead of bfd_generic_archive_p.
2366         (bfd_elfNN_write_archive_contents): Define if not defined.  Use
2367         instead of _bfd_write_archive_contents.
2368         (bfd_elfNN_mkdarchive): Define if not defined.  Use instead of
2369         _bfd_generic_mkarchive.
2370         (TARGET_BIG_SYM): If bfd_elfNN_archive_functions is defined, use
2371         bfd_elfNN_archive in BFD_JUMP_TABLE_ARCHIVE rather than
2372         _bfd_archive_coff.
2373         (TARGET_LITTLE_SYM): Likewise.
2374         * archive.c (bfd_slurp_armap): Check for and reject an archive map
2375         name of /SYM64/.
2376         * Makefile.in: Rebuild dependencies.
2377
2378         * elf32-mips.c (_bfd_mips_elf_final_write_processing): Handle
2379         SHT_MIPS_LIBLIST, SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and
2380         SHT_MIPS_EVENTS sections.
2381         (_bfd_mips_elf_section_from_shdr): Handle SHT_MIPS_IFACE,
2382         SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and SHT_MIPS_EVENTS
2383         sections.
2384         (_bfd_mips_elf_fake_sections): Likewise.
2385
2386         * libecoff.h (ecoff_data_type): Add rdata_in_text field.
2387         * ecoff.c (ecoff_compute_section_file_positions): Copy
2388         rdata_in_text from backend info to tdata.  Clear it if any data
2389         section comes before .rdata.
2390         (_bfd_ecoff_write_object_contents): Use rdata_in_text field in
2391         tdata rather than backend info.
2392
2393 Fri Jul 19 18:15:51 1996  Ian Lance Taylor  <[email protected]>
2394
2395         * configure.in: Fix test for whether a compiler has a 64 bit
2396         type.  From Jim Wilson <[email protected]>.
2397
2398 Thu Jul 18 15:39:10 1996  Ian Lance Taylor  <[email protected]>
2399
2400         * configure.host (mips-sgi-irix6*): New host.
2401
2402         * configure.in: Set and substitute VERSION, BFD_HOST_64BIT_LONG
2403         (replacing HOST_64BITLONG), BFD_HOST_64_BIT_DEFINED,
2404         BFD_HOST_64_BIT, and BFD_HOST_U_64_BIT.  Add bfd-in2.h:bfd-in2.h
2405         to AC_OUTPUT call.
2406         * configure: Rebuild.
2407         * bfd-in.h (BFD_ARCH_SIZE): Define as @wordsize@, not @WORDSIZE@.
2408         (BFD_HOST_64_BIT): Define conditionally.
2409         (BFD_HOST_U_64_BIT): Define when BFD_HOST_64_BIT is defined.
2410         (bfd_vma): Typedef as BFD_HOST_U_64_BIT.
2411         (symvalue, bfd_size_type): Likewise.
2412         * bfd-in2.h: Rebuild.
2413         * Makefile.in (do_clean): Remove bfd-tmp.h.
2414         (do_distclean): Remove bfd-in3.h.
2415         (stmp-bfd.h): Just do copy-if-change bfd-in3.h bfd.h.
2416         (bfd-in3.h): New target.
2417
2418         * config.bfd (sparc-*-sysv4*): Don't build sunos_big_vec.  From
2419         Andrew Gierth <[email protected]>.
2420
2421         * configure.host: Set INSTALL_SHLIB.
2422         * configure.in: Call AC_SUBST (INSTALL_SHLIB).
2423         * configure: Rebuild.
2424         * Makefile.in (install): Use @INSTALL_SHLIB@.
2425
2426         * config.bfd (mips*-*-irix6*): New target.
2427         * configure.host: Handle Irix 6 shared library like Irix 5.
2428
2429         * xcofflink.c (xcoff_link_add_symbols): Don't check an XMC_TD
2430         symbol for a magic name.
2431         (xcoff_link_input_bfd): Don't change the reloc symbol for an
2432         XMC_TD symbol.
2433         (_bfd_ppc_xcoff_relocate_section): Don't get the TOC offset for an
2434         XMC_TD symbol.
2435
2436 Thu Jul 18 11:36:31 1996  Stan Shebs  <[email protected]>
2437
2438         * mpw-config.in: Add ELF support to mips config, create the
2439         elf32-target.h file in the object dir.
2440         * mpw-make.sed: Edit elfXX-target.h refs at beginnings of lines.
2441
2442 Wed Jul 17 18:02:32 1996  Kim Knuttila  <[email protected]>
2443
2444         * coff-ppc.c: Redid debug scheme - numerous fprintf's gone.
2445         Also removed most abort calls, in favor of using bfd reporting.
2446
2447 Wed Jul 17 14:51:52 1996  Martin M. Hunt  <[email protected]>
2448
2449         * Makefile.in (ALL_MACHINES): Add cpu-d10v.o.
2450         (BFD32_BACKENDS) Add elf32-d10v.o.
2451         * archures.c: Add bfd_d10v_arch.
2452         * bfd-in2.h: Add bfd_d10v_arch.
2453         * config.bfd (d10v-*-*): New target.
2454         * configure: (bfd_elf32_d10v_vec) New vector.
2455         * configure.in: (bfd_elf32_d10v_vec) New vector.
2456         * cpu-d10v.c: New file.
2457         * elf.c (prep_headers): Added case bfd_arch_d10v.
2458         * elf32-d10v.c: New file.
2459         * libbfd.h: Rebuild.
2460         * reloc.c (BFD_RELOC_D10V_10_PCREL_R, BFD_RELOC_D10V_10_PCREL_L,
2461         BFD_RELOC_D10V_18, BFD_RELOC_D10V_18_PCREL): Define.
2462         * targets.c (bfd_elf32_d10v_vec): New vector.
2463         
2464 Wed Jul 17 10:58:55 1996  Kim Knuttila  <[email protected]>
2465
2466         * coff-ppc.c (coff_ppc_relocate_section): Removed bogus fprintf
2467
2468 Tue Jul 16 23:49:02 1996  Stu Grossman  ([email protected])
2469
2470         * archures.c bfd-in2.h:  Add bfd_mach_i386_i386 and
2471         bfd_mach_i386_i8086 machine types.
2472
2473 Wed Jul 10 12:42:56 1996  Ian Lance Taylor  <[email protected]>
2474
2475         * ecoff.c (_bfd_ecoff_new_section_hook): Set SEC_CODE for _INIT
2476         and _FINI sections.
2477
2478 Wed Jul 10 11:18:21 1996  Richard Henderson  <[email protected]>
2479
2480         * coffcode.h (coff_set_section_contents): A/UX does not require
2481         special handling of the _LIB section.
2482
2483 Tue Jul  9 15:52:20 1996  Jeffrey A Law  ([email protected])
2484
2485         * coff-h8300.c (h8300_reloc16_extra_cases): Use the correct
2486         value for R_RELBYTE.
2487
2488         * reloc16.c (bfd_coff_reloc16_relax_section): Only "shrinks"
2489         array if one was allocated.
2490
2491 Tue Jul  9 12:21:54 1996  Ian Lance Taylor  <[email protected]>
2492
2493         From Kazumoto Kojima <[email protected]>:
2494         * elf32-mips.c (struct mips_elf_link_hash_table): Add new fields
2495         use_rld_obj_head and rld_value.
2496         (mips_elf_link_hash_table_create): Initialize new fields.
2497         (mips_elf_add_symbol_hook): Mark __rld_obj_head symbol as
2498         dynamic.
2499         (mips_elf_create_dynamic_sections): Create .rld_map section.  If
2500         __rld_obj_head symbol not seen, create an __rld_map symbol.
2501         (mips_elf_size_dynamic_sections): Make space in .rld_map section.
2502         Create a DT_MIPS_RLD_MAP entry rather than a DT_DEBUG entry.
2503         (mips_elf_finish_dynamic_symbol): Save value of __rld_map or
2504         __rld_obj_head symbol.
2505         (mips_elf_finish_dynamic_sections): Handle DT_MIPS_RLD_MAP.
2506
2507 Mon Jul  8 16:18:03 1996  Ian Lance Taylor  <[email protected]>
2508
2509         * elf32-mips.c (mips_reloc_map): Remove BFD_RELOC_32_PCREL entry.
2510
2511         * elf32-ppc.c (ppc_elf_howto_raw): For R_PPC_ADDR16_HA, use
2512         ppc_elf_addr16_ha_reloc.
2513         (ppc_elf_addr16_ha_reloc): New static function.
2514
2515         * coff-mips.c (struct mips_hi): Define.
2516         (mips_refhi_list): New static variable.
2517         (mips_refhi_addr, mips_refhi_addend): Remove.
2518         (mips_refhi_reloc): Maintain a list of unmatched REFHI relocs.
2519         (mips_reflo_reloc): Process mips_refhi_list.
2520         (mips_relhi_list): New static variable.
2521         (mips_relhi_addr, mips_relhi_addend): Remove.
2522         (mips_relhi_reloc): Maintain a list of unmatched RELHI relocs.
2523         (mips_rello_reloc): Process mips_relhi_list.
2524         (mips_relocate_section): Permit an arbitrary number of REFHI or
2525         RELHI relocs before the associated REFLO or RELLO reloc.
2526
2527 Fri Jul  5 19:27:49 1996  Ian Lance Taylor  <[email protected]>
2528
2529         * aout-target.h (MY(callback)): Set reloc_count fields.
2530
2531 Thu Jul  4 12:00:37 1996  Ian Lance Taylor  <[email protected]>
2532
2533         * sunos.c (sunos_add_dynamic_symbols): Don't create dynamic
2534         sections unless this is a SunOS link.
2535
2536         * VERSION: Set to 2.7.1.
2537
2538         * Released binutils 2.7.
2539
2540 Wed Jul  3 14:59:47 1996  Ian Lance Taylor  <[email protected]>
2541
2542         * i386aout.c: Include "aout/aout64.h".
2543         (i386aout_write_object_contents): New static function.
2544         (MY_write_object_contents): Define.
2545
2546         * netbsd.h (MY(write_object_contents)): Make sure that
2547         adjust_sizes_and_vmas is called before fiddling with the magic
2548         number.
2549
2550 Tue Jul  2 23:30:39 1996  Ian Lance Taylor  <[email protected]>
2551
2552         * stabs.c (_bfd_link_section_stabs): Fix casts of psinfo.
2553
2554 Sun Jun 30 13:34:33 1996  Ian Lance Taylor  <[email protected]>
2555
2556         * libbfd-in.h (itos, stoi): Don't define.
2557         * libbfd.h: Rebuild.
2558         * i386lynx.c (KEEPIT): Define as udata.i.
2559         (NAME(lynx,swap_std_reloc_out)): Don't use stoi.
2560         (NAME(lynx,swap_ext_reloc_out)): Likewise.
2561         * riscix.c (riscix_swap_std_reloc_out): Use udata.i rather than
2562         flags.  Don't use stoi.
2563
2564         * elf32-mips.c (ELF_MAGPAGESIZE): Change definition to 0x1000.
2565
2566         * elf.c (map_sections_to_segments): Don't start a new segment for
2567         a writable section if it's on the same page as the previous
2568         segment.  Reset the writable variable for a readonly section.
2569
2570 Sat Jun 29 16:18:51 1996  Kim Knuttila  <[email protected]>
2571
2572         * peicode.h (coff_swap_aouthdr_in): Missing initializations of
2573         first_thunk_address, thunk_size, and import_table_size.
2574         * peicode.h: Improved some diagnostics regarding edata sections.
2575
2576         * coff-ppc.c (coff_ppc_relocate_section): Earlier error check
2577         on IMGLUE relocs.
2578         (coff_ppc_relocate_section): Improved diagnostic for large TOCDEFN's.
2579         (TARGET_LITTLE_SYM): Added missing D_PAGED.
2580
2581 Fri Jun 28 13:48:45 1996  Ian Lance Taylor  <[email protected]>
2582
2583         * xcofflink.c (xcoff_link_check_ar_symbols): An undefined symbol
2584         with XCOFF_DEF_DYNAMIC set is really defined.
2585         (xcoff_link_check_dynamic_ar_symbols): Likewise.
2586         (xcoff_link_add_symbols): Only create special sections if using an
2587         XCOFF hash table.
2588
2589         * reloc.c (bfd_perform_relocation): Handle xcoff-powermac like
2590         aixcoff-rs6000.
2591         (bfd_install_relocation): Likewise.
2592
2593 Fri Jun 28 11:17:00 1996  Richard Henderson  <[email protected]>
2594
2595         * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add flags
2596         field.
2597         (ALPHA_ELF_LINK_HASH_LU_ADDR): Define.
2598         (ALPHA_ELF_LINK_HASH_LU_MEM): Define.
2599         (ALPHA_ELF_LINK_HASH_LU_FUNC): Define.
2600         (elf64_alpha_link_hash_newfunc): Initialize flags field.
2601         (elf64_alpha_check_relocs): Record types of LITUSE entries that
2602         are found for LITERAL relocs.
2603         (elf64_alpha_adjust_dynamic_symbol): If a symbol has its address
2604         taken, we cannot generate a .plt entry for the symbol.
2605
2606 Thu Jun 27 11:24:29 1996  Ian Lance Taylor  <[email protected]>
2607
2608         * configure.in: Add AC_ISC_POSIX, and check for setitimer and
2609         sysconf functions (for gprof).
2610         * configure, config.in: Rebuild.
2611
2612 Wed Jun 26 16:29:02 1996  Ian Lance Taylor  <[email protected]>
2613
2614         * ecoff.c (_bfd_ecoff_archive_p): Check the first object file in
2615         an archive if it has a map.  If the object file has the wrong
2616         xvec, reject it.
2617
2618         * coff-alpha.c (alpha_adjust_reloc_in): Set the addend for a
2619         BRADDR, SREL16, SREL32, or SREL64 reloc against an external
2620         symbol.
2621         (alpha_relocate_section): Likewise.
2622
2623         * coffswap.h (coff_swap_reloc_out): Use RELSZ, not sizeof.
2624         (coff_swap_filehdr_out): Use FILHSZ, not sizeof.
2625         (coff_swap_sym_out): Use SYMESZ, not sizeof.
2626         (coff_swap_aux_out): Use AUXESZ, not sizeof.
2627         (coff_swap_lineno_out): Use LINESZ, not sizeof.
2628         (coff_swap_aouthdr_out): Use AOUTSZ, not sizeof.
2629         (coff_swap_scnhdr_out): Use SCNHSZ, not sizeof.
2630         * peicode.h: Corresponding changes.
2631
2632 Tue Jun 25 15:28:34 1996  Michael Meissner  <[email protected]>
2633
2634         * elflink.h (elf_create_pointer_linker_section): Comment out code
2635         dealing with making GOT pointers negative of the GOT symbol for
2636         now.
2637
2638 Tue Jun 25 11:41:24 1996  Richard Henderson  <[email protected]>
2639
2640         * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't
2641         increment the .rela.plt size until after we're done creating the
2642         .plt entry.
2643         (elf64_alpha_finish_dynamic_symbol): Change .plt entry to load the
2644         .rela.plt offset directly rather than calculating it.
2645
2646 Mon Jun 24 17:15:10 1996  Jason Molenda  ([email protected])
2647  
2648         * Makefile.in, (bindir, libdir, datadir, mandir, infodir, includedir): 
2649         Use autoconf-set values.
2650         * doc/Makefile.in (bindir, libdir, datadir, mandir, infodir, 
2651         includedir, INSTALL, INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set 
2652         values.
2653         (docdir): Deleted.
2654         * configure.in (AC_PREREQ): autoconf v2.5 or higher.
2655         * configure: Rebuilt.
2656  
2657 Mon Jun 24 22:50:35 1996  Jeffrey A Law  ([email protected])
2658
2659         * som.c (som_write_fixups): Fix typo in R_END_TRY for exception
2660         handling code > 1k away.
2661
2662 Mon Jun 24 18:41:06 1996  Michael Meissner  <[email protected]>
2663
2664         * elflink.h (elf_create_pointer_linker_section): If DEBUG is
2665         defined, output whenever the symbol is updated.
2666
2667 Mon Jun 24 17:58:12 1996  Jouke Numan  <[email protected]>
2668
2669         * elf.c (elf_fake_sections): Don't set sh_addr of a non SEC_ALLOC
2670         section to 0 if user_set_vma is set.
2671         * elflink.h (elf_bfd_final_link): Likewise.
2672
2673 Sun Jun 23 20:42:51 1996  Doug Evans  <[email protected]>
2674
2675         Partially undo patch of Jun 20.
2676         * coffcode.h (coff_set_alignment_hook): Use COFF_IMAGE_WITH_PE.
2677         (coff_compute_section_file_positions): Likewise.
2678         (coff_write_object_contents): Likewise.  Re-add deleted code, but
2679         use #ifdef COFF_WITH_PE, not COFF_OBJ_WITH_PE.
2680         * peicode.h (pe_bfd_copy_private_bfd_data): Re-add #ifdef.
2681
2682 Fri Jun 21 17:38:15 1996  Joel Sherrill  <[email protected]>
2683
2684         * config.bfd: Add support for *-*-rtems* configurations.
2685         
2686 Fri Jun 21 15:19:59 1996  Ian Lance Taylor  <[email protected]>
2687
2688         * elf.c (prep_headers): Add bfd_arch_alpha case.
2689
2690 Fri Jun 21 12:35:27 1996  Richard Henderson  <[email protected]>
2691
2692         * elf64-alpha.c: New file.
2693         * config.bfd (alpha-*-linuxecoff*): New target.
2694         (alpha-*-linux*, alpha-*-elf*): New targets.
2695         * configure.in (bfd_elf64_alpha_vec): New vector.
2696         * configure: Rebuild.
2697         * targets.c (bfd_elf64_alpha_vec): Declare.
2698         (bfd_target_vector): Add bfd_elf64_alpha_vec if BFD64.
2699         * reloc.c (BFD_RELOC_ALPHA_GPDISP): Define.
2700         * bfd-in2.h, libbfd.h: Rebuild.
2701         * Makefile.in: Rebuild dependencies.
2702         (BFD64_BACKENDS): Add elf64-alpha.o.
2703         (BFD64_BACKENDS_CFILES): Add elf64-alpha.c.
2704
2705 Thu Jun 20 18:14:25 1996  Ian Lance Taylor  <[email protected]>
2706
2707         * ecoff.c (ecoff_armap_hash): If hlog is 0, just return 0, rather
2708         than relying on a right shift of 32.
2709
2710 Thu Jun 20 11:00:57 1996  Doug Evans  <[email protected]>
2711
2712         * coffcode.h (coff_set_alignment_hook): Change COFF_IMAGE_WITH_PE
2713         ifdef to COFF_WITH_PE.
2714         (coff_compute_section_file_positions): Likewise.
2715         (coff_write_object_contents): Likewise.  Delete COFF_OBJ_WITH_PE.
2716         * pe-{arm,i386,ppc}.c (COFF_OBJ_WITH_PE): Delete.
2717         * peicode.h (pe_bfd_copy_private_bfd_data): Delete ifdef
2718         COFF_IMAGE_WITH_PE, always include.
2719
2720         * peicode.h (coff_swap_scnhdr_out): ".drectve" doesn't have trailing 0.
2721
2722 Wed Jun 19 11:37:52 1996  Ian Lance Taylor  <[email protected]>
2723
2724         * elf.c (map_sections_to_segments): Fix up the test for -Ttext to
2725         approximate the correct answer if SIZEOF_HEADERS was not used.
2726
2727         * binary.c (binary_set_section_contents): Set section file
2728         position based on LMA rather than VMA.
2729
2730 Wed Jun 19 11:19:25 1996  Manfred Hollstein KS/EIC5 60/3/142 #40283  <[email protected]>
2731
2732         * linker.c (_bfd_generic_link_output_symbols): Don't output any
2733         symbols if info->strip == strip_all.
2734
2735 Tue Jun 18 15:17:36 1996  Jeffrey A. Law  <[email protected]>
2736
2737         * coff-h8300.c: Remove #if 0 code.
2738         (compatable): Don't allow mixing/matching of different architectures.
2739         
2740         * archures.c (bfd_mach_h8300s): Add.
2741         * bfd-in2.h: Rebuilt.
2742         * coff-h8300.c (funcvec_hash_newfunc): Handle H8/S too.
2743         (BADMAG): Likewise.
2744         (h8300_reloc16_estimate): Likewise.
2745         (h8300_reloc16_extra_cases): Likewise.
2746         (h8300_bfd_link_add_symbols): Likewise.
2747         * coffcode.h (coff_set_arch_mach_hook): Likewise.
2748         (coff_set_flags): Likewise.
2749         * cpu-h8300.c (h8300_scan): Likewise.
2750         Add H8/S to bfd_h8300_arch list.
2751
2752 Tue Jun 18 14:42:58 1996  Klaus Kaempf  <[email protected]>
2753
2754         Added support for Alpha OpenVMS:
2755         * evax.h, evax-alpha.c, evax-egsd.c, evax-emh.c: New files.
2756         * evax-etir.c, evax-misc.c, hosts/alphavms.h: New files.
2757         * config.h-vms, makefile.vms: New files.
2758         * config.bfd (alpha-*-*vms*): New target.
2759         * configure.in (evax_alpha_vec): New target vector.
2760         * configure: Rebuild.
2761         * reloc.c (BFD_RELOC_SWREL32, BFD_RELOC_SWREL64): Define.
2762         (BFD_RELOC_ALPHA_LINKAGE, BFD_RELOC_ALPHA_BASEREG): Define.
2763         * targets.c (bfd_target_evax_flavour): Define.
2764         (evax_alpha_vec): Declare.
2765         (bfd_target_vector): Add ecoffalpha_little_vec and evax_alpha_vec
2766         if BFD64 is defined.
2767         * bfd-in2.h, libbfd.h: Rebuild.
2768         * Makefile.in: Rebuild dependencies.
2769         (BFD64_BACKENDS): Add evax-alpha.o, evax-egsd.o, evax-etir.o,
2770         evax-emh.o, and evax-misc.o.
2771         (BFD64_BACKENDS_CFILES): Add evax-alpha.c, evax-egsd.c,
2772         evax-etir.c, evax-emh.c, and evax-misc.c.
2773         (HFILES): Add evax.h.
2774
2775 Tue Jun 18 13:54:18 1996  Ian Lance Taylor  <[email protected]>
2776
2777         * coff-h8300.c (h8300_reloc16_extra_cases): Make name a const
2778         pointer.
2779         (h8300_bfd_link_add_symbols): Likewise.
2780
2781 Mon Jun 17 10:06:50 1996  Jeffrey A. Law  <[email protected]>
2782
2783         * som.h (R_HPPA_BEGIN_TRY, R_HPPA_END_TRY): Define.
2784         * som.c (som_write_fixups): Handle R_BEGIN_TRY and R_END_TRY.
2785
2786 Mon Jun 17 12:49:11 1996  Ian Lance Taylor  <[email protected]>
2787
2788         * elf32-mips.c (mips_elf_relocate_section): Don't create a reloc
2789         for R_MIPS_REL32 and R_MIPS_32 relocs if no dynamic sections were
2790         created.
2791         (mips_elf_check_relocs): Only create .rel.dyn for R_MIPS_REL32 and
2792         R_MIPS_32 relocs if creating a shared library.
2793
2794 Thu Jun 13 20:14:51 1996  Doug Evans  <[email protected]>
2795
2796         * peicode.h (add_data_entry): Use pei_section_data rather than
2797         _cooked_size.  Corresponds to May 13 change in coffcode.h.
2798
2799 Thu Jun 13 10:23:40 1996  Ian Lance Taylor  <[email protected]>
2800
2801         * cofflink.c (_bfd_coff_final_link): Handle long section names.
2802         * coffcode.h (coff_write_object_contents): If there are long
2803         section names, always set the f_symptr field, even if there are no
2804         symbols.
2805         * peicode.h (coff_swap_filehdr_in): Don't clear the f_symptr field
2806         if there are no symbols.
2807
2808         * coffgen.c (make_a_section_from_file): Check return value of
2809         _bfd_coff_read_string_table.
2810         (coff_real_object_p): Check return value of
2811         make_a_section_from_file.
2812         (_bfd_coff_read_string_table): Check that there are some symbols
2813         before trying to read the string table size.
2814
2815 Wed Jun 12 11:16:37 1996  Ian Lance Taylor  <[email protected]>
2816
2817         * xcofflink.c (xcoff_link_add_symbols): When considering whether
2818         to replace a symbol in a dynamic object with a symbol from another
2819         dynamic object, do the replacement if the existing symbol is
2820         global linkage code.
2821
2822         * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Check explicitly
2823         for _ptrgl, and treat it as global linkage code.
2824
2825         * aoutx.h (NAME(aout,find_nearest_line)): Notice if we find a
2826         filename or N_SO symbol past the offset, and use it to indicate
2827         that there is no line number or function when appropriate.
2828
2829 Tue Jun 11 15:24:48 1996  Ian Lance Taylor  <[email protected]>
2830
2831         * xcofflink.c (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR for a
2832         common symbol defined by the linker.  Don't export function code
2833         even if export_defineds is set.
2834
2835 Mon Jun 10 11:57:27 1996  Jeffrey A Law  ([email protected])
2836
2837         * coff-h8300.c (howto_table): Add new entries for R_BCC_INV
2838         and R_JMP_DEL.
2839         (rtype2howto): Handle R_BCC_INV and R_JMP_DEL.
2840         (h8300_symbol_address_p): New function.
2841         (h8300_reloc16_estimate): Eliminate jumps made unnecessary by
2842         relaxing.
2843
2844 Sun Jun  9 16:30:20 1996  Jeffrey A Law  ([email protected])
2845
2846         * coff-h8300.c (h8300_reloc16_estimate): Fix many minor spacing
2847         problems.
2848         (h8300_reloc16_estimate, cases R_JMP1, R_JMP2): Adjust "dot"
2849         correctly for the two variants.  Allow relaxing if the target
2850         is 128 bytes away since after relaxation it'll be 126 bytes away.
2851         (h8300_reloc16_estimate, case R_PCRWORD): Correctly adjust
2852         "dot" and "value".  Allow relaxing if the target is 128 bytes
2853         away since after relaxation it'll be 126 bytes away.
2854         * reloc16.c (bfd_coff_reloc16_relax_section): Keep relaxing
2855         the given section until nothing changes.
2856
2857 Thu Jun  6 15:24:45 1996  Richard Henderson  <[email protected]>
2858
2859         * ecoff.c (_bfd_ecoff_new_section_hook): Remove the _PDATA
2860         alignment hack--we can get the lnnoptr info another way without
2861         suddenly increasing the alignment requirements.  Set the flags for
2862         the _PDATA section.
2863         (ecoff_compute_section_file_positions): Do so.
2864
2865 Thu Jun  6 11:24:37 1996  Ian Lance Taylor  <[email protected]>
2866
2867         * ieee.c (ieee_write_object_contents): Put a timestamp in the file
2868         to keep the HP emulator database happy.
2869
2870         * config.bfd: Recognize powerpc-*-linux* and powerpcle-*-linux*.
2871         From Kevin Buettner <[email protected]>.
2872
2873 Wed Jun  5 15:16:04 1996  Ian Lance Taylor  <[email protected]>
2874
2875         * aoutx.h (translate_to_native_sym_flags): Don't try to print the
2876         name of a NULL section.
2877
2878 Tue Jun  4 18:53:58 1996  Ian Lance Taylor  <[email protected]>
2879
2880         * linker.c (_bfd_generic_link_add_one_symbol): If notice_all is
2881         set, always call the notice callback.
2882
2883         * VERSION: Increment for bfdlink.h change.
2884
2885 Mon Jun  3 11:01:53 1996  Ian Lance Taylor  <[email protected]>
2886
2887         * coff-sh.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set to 4.
2888         (sh_relax_delete_bytes): Correct handling of differently sized
2889         trailing alignment reloc.
2890
2891         * bfd-in.h: Use #error if BFD_HOST_64_BIT can not be defined.
2892         * bfd-in2.h: Rebuild.
2893         * configure.in: Warn if there is no known 64 bit type.
2894         * configure: Rebuild.
2895
2896         * Makefile.in: Rebuild dependencies.
2897         (BFD32_BACKENDS): Add ppcboot.o.
2898         (BFD32_BACKENDS_CFILES): Add ppcboot.c.
2899
2900         * elf32-mips.c (mips_elf_size_dynamic_sections): Initialize c.
2901         From Per Fogelstrom <[email protected]>.
2902
2903 Sat Jun  1 21:49:58 1996  Ian Lance Taylor  <[email protected]>
2904
2905         * elf64-mips.c (bfd_mips_elf64_swap_reginfo_in)
2906         (bfd_mips_elf64_swap_reginfo_out): Move from here...
2907         * elf32-mips.c (bfd_mips_elf64_swap_reginfo_in)
2908         (bfd_mips_elf64_swap_reginfo_out): ...to here.
2909
2910 Fri May 31 13:51:28 1996  Ian Lance Taylor  <[email protected]>
2911
2912         * elf64-mips.c: Improve reloc special_functions and handling of
2913         SHT_MIPS_OPTIONS section.
2914         * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Rename from
2915         mips_elf_hi16_reloc and make globally visible.
2916         (_bfd_mips_elf_lo16_reloc): Rename from mips_elf_lo16_reloc and
2917         make globally visible.
2918         (_bfd_mips_elf_got16_reloc): Rename from mips_elf_got16_reloc and
2919         make globally visible.
2920         (_bfd_mips_elf_gprel16_reloc): Rename from mips_elf_gprel16_reloc
2921         and make globally visible.
2922         (gprel16_with_gp): Check howto->src_mask before using value in
2923         insn.
2924         (_bfd_mips_elf_gprel32_reloc): Rename from mips_elf_gprel32_reloc
2925         and make globally visible.
2926         (gprel32_with_gp): Check howto->src_mask before fetching value.
2927         (bfd_mips_elf_swap_options_in): New function.
2928         (bfd_mips_elf_swap_options_out): New function.
2929         (_bfd_mips_elf_set_private_flags): Rename from
2930         mips_elf_set_private_flags and make globally visible.
2931         (_bfd_mips_elf_copy_private_bfd_data): Rename from
2932         mips_elf_copy_private_bfd_data and make globally visible.
2933         (_bfd_mips_elf_merge_private_bfd_data): Rename from
2934         mips_elf_merge_private_bfd_data and make globally visible.
2935         (_bfd_mips_elf_section_from_shdr): Accept .MIPS.options as a name
2936         for a SHT_MIPS_OPTIONS section.
2937         (mips_elf32_section_from_shdr): Handle SHT_MIPS_OPTIONS section.
2938         (_bfd_mips_elf_fake_sections): Consider .MIPS.options to be the
2939         name of a SHT_MIPS_OPTIONS section.
2940         (_bfd_mips_elf_set_section_contents): New function.
2941         (mips_elf32_section_processing): Set the GP value in a
2942         SHT_MIPS_OPTIONS section.
2943         (_bfd_mips_elf_find_nearest_line): Rename from
2944         mips_elf_find_nearest_line and make globally visible.
2945         (bfd_elf32_set_section_contents): Define.
2946         * elf-bfd.h (_bfd_mips_elf_hi16_reloc): Declare.
2947         (_bfd_mips_elf_lo16_reloc): Declare.
2948         (_bfd_mips_elf_gprel16_reloc): Declare.
2949         (_bfd_mips_elf_got16_reloc): Declare.
2950         (_bfd_mips_elf_gprel32_reloc): Declare.
2951         (_bfd_mips_elf_set_private_flags): Declare.
2952         (_bfd_mips_elf_copy_private_bfd_data): Declare.
2953         (_bfd_mips_elf_merge_private_bfd_data): Declare.
2954         (_bfd_mips_elf_find_nearest_line): Declare.
2955         (_bfd_mips_elf_set_section_contents): Declare.
2956
2957         * elf32-hppa.c (elf32_hppa_info_to_howto): Rename from
2958         elf_info_to_howto.
2959         (elf_info_to_howto): Define.
2960         * elf32-sparc.c (elf32_sparc_info_to_howto): Rename from
2961         elf_info_to_howto.
2962         (elf_info_to_howto): Define.
2963         * elf64-sparc.c (sparc64_elf_info_to_howto): Rename from
2964         elf_info_to_howto.
2965         (elf_info_to_howto): Define.
2966
2967         * coff-w65.c (h8300_reloc16_estimate): Rename R_MOVB[12] to
2968         R_MOV16B[12], to match change in coff/internal.h.
2969
2970 Thu May 30 12:38:49 1996  Ian Lance Taylor  <[email protected]>
2971
2972         * elf64-mips.c: Extensive additions to provide better support for
2973         writing files and for gas.
2974         * elf32-mips.c (_bfd_mips_elf_object_p): New function, broken out
2975         of mips_elf_object_p.
2976         (mips_elf32_object_p): Rename from mips_elf_object_p; call
2977         _bfd_mips_elf_object_p.
2978         (_bfd_mips_elf_final_write_processing): Rename from
2979         mips_elf_final_write_processing and make globally visible.
2980         (_bfd_mips_elf_fake_sections): Rename from
2981         mips_elf_fake_sections and make globally visible.
2982         (_bfd_mips_elf_section_from_bfd_section): Rename from
2983         mips_elf_section_from_bfd_section and make globally visible.
2984         (_bfd_mips_elf_section_processing): New function, broken out of
2985         mips_elf_section_processing.
2986         (mips_elf32_section_processing): Rename from
2987         mips_elf_section_processing; call
2988         _bfd_mips_elf_section_processing.
2989         (_bfd_mips_elf_symbol_processing): Rename from
2990         mips_elf_symbol_processing and make globally visible.
2991         (_bfd_mips_elf_read_ecoff_info): Rename from
2992         mips_elf_read_ecoff_info and make globally visible.
2993         (mips_elf32_ecoff_debug_swap): Rename from
2994         mips_elf_ecoff_debug_swap.
2995         * elf.c (_bfd_elf_symbol_from_bfd_symbol): Use asymbol rather than
2996         struct symbol_cache_entry.
2997         (_bfd_elf_validate_reloc): New function, moved in from
2998         elfcode.h:validate_reloc.
2999         * elfcode.h (validate_reloc): Remove; moved into elf.c and renamed
3000         to _bfd_elf_validate_reloc.  Change all callers.
3001         * elf-bfd.h (bfd_section_from_shdr): Declare.
3002         (_bfd_elf_symbol_from_bfd_symbol): Declare.
3003         (_bfd_elf_validate_reloc): Declare.
3004         (_bfd_mips_elf_object_p): Declare.
3005         (_bfd_mips_elf_fake_sections): Declare.
3006         (_bfd_mips_elf_section_from_bfd_section): Declare.
3007         (_bfd_mips_elf_section_processing): Declare.
3008         (_bfd_mips_elf_symbol_processing): Declare.
3009         (_bfd_mips_elf_read_ecoff_info): Declare.
3010         (_bfd_mips_elf_final_write_processing): Declare.
3011         * elfxx-target.h (bfd_elfNN_get_reloc_upper_bound): Don't define
3012         if already defined.
3013
3014         * elf32-mips.c (mips_elf_object_p): Handle E_MIPS_ARCH_4.
3015         (mips_elf_final_write_processing): Likewise.
3016
3017 Wed May 29 16:15:29 1996  Ian Lance Taylor  <[email protected]>
3018
3019         64-bit MIPS ELF ABI objdump support:
3020         * elf64-mips.c: New file.
3021         * Makefile.in: Rebuild dependencies.
3022         (BFD64_BACKENDS): Add elf64-mips.o.
3023         (BFD64_BACKENDS_CFILES): Add elf64-mips.c.
3024         * config.bfd (mips*el-*-elf*) Add bfd_elf64_bigmips_vec and
3025         bfd_elf64_littlemips_vec to targ_selvecs.
3026         (mips*-*-elf*): Likewise.
3027         * confingure.in: Add bfd_elf64_bigmips_vec and
3028         bfd_elf64_littlemips_vec to vector switch.
3029         * configure: Rebuild.
3030         * elf32-mips.c (_bfd_mips_elf_section_from_shdr): New function,
3031         broken out of mips_elf_section_from_shdr.
3032         (mips_elf32_section_from_shdr): Rename from
3033         mips_elf_section_from_shdr.  Call new function.
3034         (elf_backend_section_from_shdr): Update name of renamed function.
3035         * elf-bfd.h (struct elf_size_info): Change second parameter of
3036         write_out_phdrs to be const.  Likewise for second parameter of
3037         swap_symbol_out.
3038         (struct bfd_elf_section_data): Add rel_hdr2 field.
3039         (bfd_elf32_swap_symbol_in): Change second parameter to be const.
3040         (bfd_elf32_swap_symbol_out): Likewise.
3041         (bfd_elf32_swap_reloc_in): Likewise.
3042         (bfd_elf32_swap_reloc_out): Likewise.
3043         (bfd_elf32_swap_reloca_in): Likewise.
3044         (bfd_elf32_swap_reloca_out): Likewise.
3045         (bfd_elf32_swap_phdr_in): Likewise.
3046         (bfd_elf32_swap_phdr_out): Likewise.
3047         (bfd_elf32_swap_dyn_in): Likewise.
3048         (bfd_elf32_swap_dyn_out): Likewise.
3049         (bfd_elf32_slurp_symbol_table): Declare.
3050         (bfd_elf32_write_shdrs_and_ehdr): Declare.
3051         (bfd_elf32_write_out_phdrs): Declare.
3052         (bfd_elf64_swap_symbol_in): Change second parameter to be const.
3053         (bfd_elf64_swap_symbol_out): Likewise.
3054         (bfd_elf64_swap_reloc_in): Likewise.
3055         (bfd_elf64_swap_reloc_out): Likewise.
3056         (bfd_elf64_swap_reloca_in): Likewise.
3057         (bfd_elf64_swap_reloca_out): Likewise.
3058         (bfd_elf64_swap_phdr_in): Likewise.
3059         (bfd_elf64_swap_phdr_out): Likewise.
3060         (bfd_elf64_swap_dyn_in): Likewise.
3061         (bfd_elf64_swap_dyn_out): Likewise.
3062         (bfd_elf64_slurp_symbol_table): Declare.
3063         (bfd_elf64_write_shdrs_and_ehdr): Declare.
3064         (bfd_elf64_write_out_phdrs): Declare.
3065         (_bfd_mips_elf_section_from_shdr): Declare.
3066         * elf.c (bfd_section_from_shdr): Remove assertion requiring
3067         SHT_REL/SHT_RELA to match use_rela_p.  If there is already a reloc
3068         section for the section, add the new one to rel_hdr2.  Increment
3069         reloc_count rather than setting it.
3070         * elfcode.h (elf_slurp_symbol_table): Define name as macro.
3071         Remove static declaration.
3072         (elf_write_shdrs_and_ehdr): Define name as macro.
3073         (elf_write_out_phdrs): Likewise.
3074         (elf_swap_ehdr_in, elf_swap_ehdr_out): Declare.
3075         (elf_swap_shdr_in, elf_swap_shdr_out): Declare.
3076         (elf_swap_symbol_in): Change second parameter to be const.
3077         (elf_swap_symbol_out): Likewise.
3078         (elf_swap_ehdr_in, elf_swap_ehdr_out): Likewise.
3079         (elf_swap_shdr_in, elf_swap_shdr_out): Likewise.
3080         (elf_swap_phdr_in, elf_swap_phdr_out): Likewise.
3081         (elf_swap_reloc_in, elf_swap_reloc_out): Likewise.
3082         (elf_swap_reloca_in, elf_swap_reloca_out): Likewise.
3083         (elf_write_out_phdrs): Rename from write_out_phdrs.  Change second
3084         parameter to be const.  Make non-static.
3085         (elf_write_shdrs_and_ehdr): Rename from write_shdrs_and_ehdr.
3086         Make non-static.
3087         (elf_slurp_symbol_table): Make non-static.
3088         (NAME(_bfd_elf,size_info)): Update names of renamed functions.
3089         * elfxx-target.h (elf_info_to_howto): Define if not defined.
3090         (elf_backend_size_info): Likewise.
3091         (elfNN_bed): Use elf_backend_size_info.
3092         * targets.c (bfd_elf64_bigmips_vec): Declare.
3093         (bfd_elf64_littlemips_vec): Declare.
3094         (bfd_target_vector): Add bfd_elf64_bigmips_vec and
3095         bfd_elf64_littlemips_vec if BFD64 is defined.
3096         
3097         * libbfd.c (bfd_get_file_window): Add cast to fprintf argument.
3098
3099 Tue May 28 11:42:08 1996  Ian Lance Taylor  <[email protected]>
3100
3101         * coff-sh.c (sh_relax_delete_bytes): Insert nop instructions, not
3102         zeroes, in alignment holes.
3103
3104         * configure: Rebuild with autoconf 2.10.
3105
3106         * aoutx.h (NAME(aout,find_nearest_line)): Make room for the
3107         potential leading underscore in the allocated buffer.
3108
3109 Fri May 24 14:28:38 1996  Michael Meissner  <[email protected]>
3110
3111         * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not put small common
3112         symbols into .sbss if this is a relocatable link.
3113
3114 Thu May 23 12:26:24 1996  Ian Lance Taylor  <[email protected]>
3115
3116         * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Warn about
3117         undefined symbols when creating a shared library.
3118
3119 Fri May 17 13:54:15 1996  Ian Lance Taylor  <[email protected]>
3120
3121         * coff-sh.c: Add a bunch of new code and static const arrays to
3122         support aligning loads and stores on four byte memory boundaries.
3123         Also:
3124         (sh_coff_howtos): Add entries for R_SH_CODE, R_SH_DATA and
3125         R_SH_LABEL.
3126         (sh_relax_section): Look for R_SH_CODE relocs.  If we find one,
3127         call sh_align_loads.
3128         (sh_relax_delete_bytes): Don't mark R_SH_CODE or R_SH_DATA relocs
3129         as unused.
3130
3131 Thu May 16 16:34:13 1996  Ian Lance Taylor  <[email protected]>
3132
3133         * cache.c (bfd_open_file): Unlink the file before opening it for
3134         write.  From Marty Leisner <[email protected]>.
3135
3136         * opncls.c (bfd_fdopenr): Set opened_once.
3137
3138 Tue May 14 12:35:32 1996  Ian Lance Taylor  <[email protected]>
3139
3140         * som.c (som_slurp_reloc_table): Clear external_relocs cache after
3141         freeing it.
3142
3143         * libbfd.c: Remove #ifdef FILE_OFFSET_IS_CHAR_INDEX, and compile
3144         the code unconditionally.
3145
3146 Mon May 13 19:51:37 1996  Ian Lance Taylor  <[email protected]>
3147
3148         * libcoff-in.h (struct pei_section_tdata): Define structure.
3149         (pei_section_data): Define macro.
3150         * libcoff.h: Rebuild.
3151         * coffcode.h (coff_set_alignment_hook): If COFF_IMAGE_WITH_PE,
3152         store s_paddr field in pei_section_data.
3153         (coff_compute_section_file_positions): Use pei_section_data rather
3154         than _cooked_size, and don't overwrite an existing value.
3155         (coff_write_object_contents): If COFF_OBJ_WITH_PE, set s_paddr to
3156         0.  If COFF_IMAGE_WITH_PE, set s_paddr to pei_section_data.
3157         * peicode.h (coff_bfd_copy_private_section_data): Define if
3158         COFF_IMAGE_WITH_PE.
3159         (pe_bfd_copy_private_section_data): New static function if
3160         COFF_IMAGE_WITH_PE.
3161
3162 Wed May  8 16:10:38 1996  Ian Lance Taylor  <[email protected]>
3163
3164         * srec.c (srec_set_arch_mach): Write as a function rather than a
3165         macro definition.
3166
3167         * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): If an archive has
3168         no map, just check each member in turn to see whether it is
3169         required.
3170
3171 Wed May  8 09:17:34 1996  Michael Meissner  <[email protected]>
3172
3173         * ppcboot.c (ppcboot_object_p): Check for type 0x41 in partition
3174         table.  Call BFD_ASSERT to validate header size, instead of
3175         calling fatal.
3176         (ppcboot_bfd_print_private_bfd_data): Put quotes around partition
3177         name.
3178
3179 Tue May  7 16:10:19 1996  Michael Meissner  <[email protected]>
3180
3181         * ppcboot.c: New target for looking at PPCbug boot records.
3182
3183         * config{ure.in,.bfd}: Add support for ppcboot target.
3184         * targets.c: Ditto.
3185         * configure: Regenerate.
3186                 
3187 Tue May  7 11:15:19 1996  Jeffrey A Law  ([email protected])
3188
3189         * coff-h8300.c (howto_table): Update names to match recent
3190         changes to include/coff/internal.h.  Fix minor errors in the
3191         existing relocs.  Add R_MOVL1 and R_MOVL2.
3192         (rtype2howto): Similarly.
3193         (h8300_reloc16_estimate): Rewrite to simplify, fix bugs in the
3194         existing relaxing code  and peform more relaxing.
3195         (h8300_reloc16_extra_cases): Likewise.
3196
3197 Mon May  6 18:24:09 1996  Jeffrey A Law  ([email protected])
3198
3199         * reloc16.c (bfd_coff_reloc16_get_value): Handle common
3200         symbols correctly.
3201
3202 Sat May  4 05:08:45 1996  Peter Schauer  ([email protected])
3203
3204         * elfcode.h (elf_object_p):  Reject generic ELF target if
3205         e_machine matches an alternate machine code in a specific backend.
3206
3207         * netbsd-core.c (netbsd_core_vec):  Remove initializer for
3208         obsolete align_power_min field.
3209
3210 Fri May  3 13:07:35 1996  Jeffrey A Law  ([email protected])
3211
3212         * coff-h8300.c (reloc_howto_type): Add howto entry for
3213         R_PCRWORD_B.
3214         (rtype2howto): Handle R_PCRWORD_B.
3215         (h8300_reloc16_extra_cases): Handle R_PCRWORD_B.
3216         (h8300_reloc_16_estimate): Likewise.  Try to turn a 16bit
3217         pc-relative branch (R_PCRWORD) into an 8bit pc-relative
3218         branch (R_PCWORD_B).
3219
3220 Fri May  3 10:47:41 1996  Ian Lance Taylor  <[email protected]>
3221
3222         * aoutx.h (translate_from_native_sym_flags): Set the section for
3223         BSF_CONSTRUCTOR symbols.
3224
3225         * cofflink.c (_bfd_coff_link_input_bfd): Correct setting of
3226         last_bf_index.
3227
3228 Wed May  1 18:39:32 1996  Doug Evans  <[email protected]>
3229
3230         * coffcode.h (coff_write_object_contents): In comdat section lookup,
3231         stop looking when section is found.
3232
3233 Wed May  1 14:17:57 1996  Ian Lance Taylor  <[email protected]>
3234
3235         * coffcode.h (STRING_SIZE_SIZE): Define.
3236         (styp_to_sec_flags): Handle long symbol names when looking for the
3237         section symbol.
3238         (bfd_coff_backend_data): Add _bfd_coff_long_section_names field.
3239         (bfd_coff_long_section_names): Define.
3240         (coff_write_object_contents): Handle long section names.
3241         (bfd_coff_std_swap_table): Initialize new field.
3242         * libcoff.h: Rebuild.
3243         * coffgen.c (make_a_section_from_file): Handle long section
3244         names.
3245         (coff_write_symbols): Handle long section names.
3246         * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
3247         * coff-mips.c (mips_ecoff_backend_data): Likewise.
3248         * pe-arm.c (COFF_LONG_SECTION_NAMES): Define.
3249         * pei-arm.c (COFF_LONG_SECTION_NAMES): Define.
3250         * pe-i386.c (COFF_LONG_SECTION_NAMES): Define.
3251         * pei-i386.c (COFF_LONG_SECTION_NAMES): Define.
3252         * pe-ppc.c (COFF_LONG_SECTION_NAMES): Define.
3253         * pei-ppc.c (COFF_LONG_SECTION_NAMES): Define.
3254
3255         * bout.c (b_out_callback): Set lma of sections.
3256         (b_out_bfd_get_relocated_section_contents): Rename in_abfd
3257         parameter to output_bfd.  Used input_bfd instead of output_bfd in
3258         several places.
3259
3260 Tue Apr 30 17:56:39 1996  Ian Lance Taylor  <[email protected]>
3261
3262         * aoutx.h (translate_from_native_sym_flags): Don't create
3263         SEC_CONSTRUCTOR sections.
3264         * ecoff.c (ecoff_set_symbol_info): Likewise.
3265
3266         * elf32-mips.c (mips_elf_copy_private_bfd_data): Copy elf_gp.
3267         From Don Bowman <[email protected]>.
3268
3269 Tue Apr 30 17:06:32 1996  Doug Evans  <[email protected]>
3270
3271         * coff-arm.c (armcoff_little_vec): If COFF_WITH_PE is defined, add
3272         SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
3273
3274 Mon Apr 29 13:15:17 1996  Ian Lance Taylor  <[email protected]>
3275
3276         * elf32-mips.c (struct mips_elf_link_hash_entry): Add
3277         mips_32_relocs field.
3278         (mips_elf_link_hash_newfunc): Initialize mips_32_relocs field.
3279         (mips_elf_relocate_section): Copy R_MIPS_REL32 and R_MIPS_32
3280         relocs against a global symbol which is not defined in a regular
3281         file.
3282         (mips_elf_check_relocs): For a R_MIPS_REL32 or R_MIPS_32 reloc
3283         against a global symbol, increment mips_32_relocs.
3284         (mips_elf_adjust_dynamic_symbol): If mips_32_relocs is set, and
3285         the symbol is not defined in a regular file, make room in the
3286         .rel.dyn section.
3287
3288 Fri Apr 26 18:00:37 1996  Ian Lance Taylor  <[email protected]>
3289
3290         * ecoff.c (ecoff_compute_section_file_positions): Track the real
3291         file position and the virtual file position separately.  Set
3292         filepos information bsaed on the real file position.
3293         (_bfd_ecoff_set_section_contents): Handle .lib sections like the
3294         Jan 23 change to coffcode.h.
3295
3296         * som.c (som_slurp_symbol_table): Set the symbol count to the
3297         number of BFD symbols created.
3298
3299 Fri Apr 26 12:34:29 1996  Michael Meissner  <[email protected]>
3300
3301         * elf32-ppc.c (ppc_elf_check_relocs): Forward relocations to the
3302         output file if linking shared objects.  Loop to check all relocs,
3303         rather than returning false on first error.
3304
3305 Thu Apr 25 13:25:12 1996  Michael Meissner  <[email protected]>
3306
3307         * elf32-ppc.c (ppc_elf_create_linker_section): Add PLT case.
3308         (ppc_elf_additional_program_headers): If .interp section, bump #
3309         of program headers by 1.
3310         (ppc_elf_adjust_dynamic_symbol): Flesh out support.
3311         (ppc_elf_size_dynamic_sections): Add support for .plt section.
3312         (ppc_elf_check_relocs): Print out filename in debug code.  Enable
3313         PLT support.
3314         (ppc_elf_finish_dynamic_symbol): Add support for PLT's, beef up
3315         debug output.
3316         (ppc_elf_relocate_section): If the output section isn't defined,
3317         don't abort, just give an error message.
3318
3319         * elflink.c (_bfd_elf_create_dynamic_sections): If the section
3320         being created is .sdata or .sdata2, don't make the symbol dynamic.
3321
3322 Wed Apr 24 14:04:07 1996  Ian Lance Taylor  <[email protected]>
3323
3324         * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through the
3325         members of an archive for dynamic objects with no symbols, and
3326         pass them directly to check_archive_element.
3327         (xcoff_link_check_ar_symbols): Pass dynamic objects to
3328         xcoff_link_check_dynamic_ar_symbols.
3329         (xcoff_link_check_dynamic_ar_symbols): New static function.
3330
3331         * coff-rs6000.c (rs6000coff_vec): Change BFD_JUMP_TABLE_DYNAMIC
3332         from _bfd_nodynamic to _bfd_xcoff.
3333         * libcoff-in.h (_bfd_xcoff_get_dynamic_symtab_upper_bound):
3334         Declare.
3335         (_bfd_xcoff_canonicalize_dynamic_symtab): Declare.
3336         (_bfd_xcoff_get_dynamic_reloc_upper_bound): Declare.
3337         (_bfd_xcoff_canonicalize_dynamic_reloc): Declare.
3338         * libcoff.h: Rebuild.
3339         * xcofflink.c (xcoff_swap_ldrel_in): New static function.
3340         (xcoff_get_section_contents): New static function.
3341         (_bfd_xcoff_get_dynamic_symtab_upper_bound): New function.
3342         (_bfd_xcoff_canonicalize_dynamic_symtab): New function.
3343         (_bfd_xcoff_get_dynamic_reloc_upper_bound): New function.
3344         (xcoff_dynamic_reloc): New static variable.
3345         (_bfd_xcoff_canonicalize_dynamic_reloc): New function.
3346         (xcoff_link_add_dynamic_symbols): Use xcoff_get_section_contents.
3347         
3348 Tue Apr 23 12:48:42 1996  Ian Lance Taylor  <[email protected]>
3349
3350         * coff-sparc.c (bfd_coff_generic_reloc): Return bfd_reloc_ok even
3351         if reloc_entry->addend is not 0.
3352         (CALC_ADDEND): Just set the addend to reloc.r_offset.
3353
3354 Mon Apr 22 18:29:01 1996  Doug Evans  <[email protected]>
3355
3356         * elf32-sparc.c (_bfd_sparc_elf_howto_table): Fix spelling of
3357         R_SPARC_GLOB_JMP.
3358         * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
3359         Add entries for R_SPARC_[56].
3360         (sparc_reloc_map): Add entries for R_SPARC_[56].
3361
3362 Mon Apr 22 15:07:24 1996  Ian Lance Taylor  <[email protected]>
3363
3364         Optimize linking of stabs in sections as used in ELF and COFF.
3365         * stabs.c: New file.
3366         * libbfd-in.h (_bfd_link_section_stabs): Declare.
3367         (_bfd_write_section_stabs): Declare.
3368         (_bfd_write_stab_strings): Declare.
3369         * libbfd.h: Rebuild.
3370         * libcoff-in.h (struct coff_section_tdata): Add stab_info field.
3371         (struct coff_link_hash_table): Add stab_info field.
3372         * libcoff.h: Rebuild.
3373         * cofflink.c (_bfd_coff_link_hash_table_init): Initialize
3374         stab_info field.
3375         (coff_link_add_symbols): Call _bfd_link_section_stabs if
3376         appropriate.
3377         (_bfd_coff_final_link): Write out stab strings hash table.
3378         (_bfd_coff_link_input_bfd): Handle optimized stabs sections.
3379         * coff-ppc.c (ppc_bfd_coff_final_link): Write out stab strings
3380         hash table.
3381         * elf-bfd.h (struct elf_link_hash_table): Add stab_info field.
3382         (struct bfd_elf_section_data): Add stab_info field.
3383         * elf.c (_bfd_elf_link_hash_table_init): Initialize stab_info
3384         field.
3385         * elflink.h (elf_link_add_object_symbols): If appropriate, call
3386         _bfd_link_section_stabs.
3387         (elf_bfd_final_link): Write out stab strings hash table.
3388         (elf_link_input_bfd): Handle optimized stabs sections.
3389         * reloc.c (_bfd_final_link_relocate): Check address against
3390         _raw_size rather than _cooked_size.
3391         * Makefile.in: Rebuild dependencies.
3392         (BFD_LIBS): Add stabs.o
3393         (BFD_LIBS_CFILES): Add stabs.c.
3394
3395         * VERSION: Increment for bfdlink.h change.
3396
3397         * coffgen.c (coff_renumber_symbols): Correct handling of
3398         BSF_NOT_AT_END common symbols.
3399
3400 Fri Apr 19 19:21:56 1996  Ian Lance Taylor  <[email protected]>
3401
3402         * coff-ppc.c (record_toc): Add cast to avoid warning.
3403         (ppc_allocate_toc_section): Likewise.
3404         (coff_ppc_relocate_section): Remove ANSI C string concatenation.
3405         (ppc_coff_reloc_type_lookup): Remove unreached code.
3406         * coffcode.h (coff_write_object_contents): Don't take the address
3407         of an array.
3408         * peicode.h (pe_print_idata): Add casts to avoid warning.
3409         (pe_print_edata): Likewise.
3410         (pe_print_reloc): Remove ANSI C string concatenation.
3411
3412 Thu Apr 18 18:51:18 1996  Ian Lance Taylor  <[email protected]>
3413
3414         * libcoff-in.h (struct coff_final_link_info): Add last_bf_index
3415         and last_bf fields.
3416         * libcoff.h: Rebuild.
3417         * coffswap.h (coff_swap_aux_in): Swap endndx field for C_FCN
3418         symbols.
3419         (coff_swap_aux_out): Likewise.
3420         * peicode.h (coff_swap_aux_in): Likewise.
3421         (coff_swap_aux_out): Likewise.
3422         * coffgen.c (coff_pointerize_aux): Check endndx field for C_FCN
3423         symbols.
3424         * cofflink.c (_bfd_coff_final_link): Initialize last_bf_index
3425         field.
3426         (_bfd_coff_link_input_bfd): Check endndx field for C_FCN symbols.
3427         Fix up .bf endndx link fields.
3428         * coff-ppc.c (ppc_bfd_coff_final_link): Initialize last_bf_index
3429         field.
3430         * xcofflink.c (xcoff_link_input_bfd): Check endndx field for C_FCN
3431         symbols.
3432
3433 Wed Apr 17 12:08:24 1996  Michael Meissner  <[email protected]>
3434
3435         * pe{,i}-ppc.c (PPC_PE): Define instead of PPC, so that compiling
3436         on Solaris PowerPC systems doesn't get confused.
3437
3438         * ccffcode.h (coff_write_object_contents): Use #ifdef PPC_PE, not
3439         #ifdef PPC.
3440
3441         * elfcore.h (bfd_prstatus, bfd_fpregset): Add thread argument.
3442         (elf_corefile_note): If HAVE_SYS_PROCFS_H is not defined, don't
3443         update did_reg and did_reg2.
3444
3445 Wed Apr 17 13:07:37 1996  Ian Lance Taylor  <[email protected]>
3446
3447         * xcofflink.c (xcoff_link_input_bfd): Check for TOC overflow.
3448
3449         * linker.c (_bfd_generic_link_add_one_symbol): When calling the
3450         callback routines, pass h->root.string rather than name, in case
3451         copy is true and name is transient.
3452
3453 Tue Apr 16 16:36:38 1996  Stu Grossman  ([email protected])
3454
3455         * elfcore.h:  Add support for core files with multiple threads.
3456         (Primarily for Solaris.)
3457
3458 Tue Apr 16 13:44:08 1996  Ian Lance Taylor  <[email protected]>
3459
3460         * aoutx.h (NAME(aout,squirt_out_relocs)): Don't do anything if
3461         section->orelocation is NULL.
3462
3463         * coffgen.c (bfd_coff_get_syment): New function.
3464         (bfd_coff_get_auxent): New function.
3465         * bfd-in.h (bfd_coff_get_syment): Declare.
3466         (bfd_coff_get_auxent): Declare.
3467         * bfd-in2.h: Rebuild.
3468
3469 Mon Apr 15 19:06:59 1996  Ian Lance Taylor  <[email protected]>
3470
3471         * elf32-mips.c (struct mips_hi16): Define.
3472         (mips_hi16_addr, mips_hi16_addend): Remove.
3473         (mips_hi16_list): New static variable.
3474         (mips_elf_hi16_reloc): Maintain a list of unmatched HI16 relocs.
3475         (mips_elf_lo16_reloc): Process mips_hi16_list.
3476         (mips_elf_relocate_section): Permit an arbitrary number of HI16
3477         relocs before the associated LO16 reloc.
3478
3479 Wed Apr 10 00:23:53 1996  Ian Lance Taylor  <[email protected]>
3480
3481         * versados.c (versados_scan): Check bfd_alloc return value.
3482         (versados_object_p): Check all bfd_read return values.  Require
3483         that lang field be less than 10, to avoid confusion with Intel Hex
3484         files.
3485
3486         * libaout.h (WRITE_HEADERS): Write out the relocs even if there
3487         aren't any symbols.
3488         * aoutx.h (NAME(aout,swap_std_reloc_out)): Set r_index to N_ABS,
3489         not 0, for an absolute symbol.
3490         (NAME(aout,swap_ext_reloc_out)): Likewise.
3491
3492         * ihex.c (ihex_scan): Accept a length of 4 for record type 5.
3493         (ihex_write_object_contents): For a large start address, output
3494         the full 32 bit address in record type 5.
3495
3496         * ieee.c (ieee_write_byte): Change second parameter from bfd_byte
3497         to int to avoid promotion problems in prototype.
3498
3499 Tue Apr  9 11:44:21 1996  Ian Lance Taylor  <[email protected]>
3500
3501         * configure.host: Use ${srcdir} when looking for picfrag.
3502
3503         * configure.host: Switch on ${libdir}, not $(libdir).  From
3504         [email protected] (Alan Modra).
3505
3506         * aoutx.h (aout_link_add_symbols): Always call add_dynamic_symbols
3507         entry point, not just for DYNAMIC objects.
3508         * sunos.c (sunos_add_dynamic_symbols): Always call
3509         sunos_create_dynamic_sections.  If called with a non DYNAMIC
3510         object, don't do anything else.
3511         (sunos_add_one_symbol): Don't call sunos_create_dynamic_sections.
3512
3513 Mon Apr  8 12:09:36 1996  Ian Lance Taylor  <[email protected]>
3514
3515         * configure.in: Permit --enable-shared to specify a list of
3516         directories.
3517         * configure: Rebuild.
3518
3519         * configure.host: Set HLDFLAGS and SHLIB_CFLAGS for *-dec-osf*
3520         host when configuring with --enable-shard.
3521
3522 Fri Apr  5 12:24:13 1996  Ian Lance Taylor  <[email protected]>
3523
3524         * config.bfd: Add i[345]86-*-freebsdelf* target; from John Polstra
3525         <[email protected]>.
3526
3527         * linker.c (link_action): For WARN_ROW/warn, use MWARN, not CYCLE,
3528         to avoid crashing in bfd_hash_replace.
3529
3530         * sysdep.h: Use #ifdef, not #if.
3531
3532 Thu Apr  4 23:32:23 1996  Ian Lance Taylor  <[email protected]>
3533
3534         * config.in: Rebuild.
3535
3536 Thu Apr  4 18:49:09 1996  Fred Fish  <[email protected]>
3537
3538         * configure.in (mips-sony-bsd*): Fix typo in AC_DEFINE.
3539         (AC_CHECK_HEADERS): Check for sys/time.h
3540         (AC_HEADER_TIME): Add macro.
3541         * configure: Rebuild.
3542         * sysdep.h: Use TIME_WITH_SYS_TIME and HAVE_SYS_TIME_H
3543         to control what combination of <time> and <sys/time.h>
3544         get included.
3545         
3546 Tue Apr  2 13:11:53 1996  Doug Evans  <[email protected]>
3547
3548         * aoutf1.h (sunos_32_set_arch_mach): Handle M_SPARCLET.
3549         (aout_32_sunos4_write_object_contents): Likewise.
3550         * aoutx.h (NAME(aout,machine_type)): Handle
3551         bfd_mach_sparc_{sparclet,sparclite}.
3552         * archures.c (bfd_mach_sparc_{sparclet,sparclite}): Define.
3553         (bfd_mach_sparc_v9_p): Update.
3554         * cpu-sparc.c (arch_info_struct): Add entries for sparclet,sparclite.
3555         * libaout.h (enum machine_type): Add M_SPARCLET.
3556         * sunos.c (MACHTYPE_OK): Define.
3557         * bfd-in2.h: Regenerated.
3558
3559 Tue Apr  2 00:33:18 1996  Ian Lance Taylor  <[email protected]>
3560
3561         * elf-bfd.h (struct elf_link_hash_table): Add hgot field.
3562         * elf.c (_bfd_elf_link_hash_table_init): Initialize hgot field.
3563         * elflink.c (_bfd_elf_create_got_section): Store the
3564         _GLOBAL_OFFSET_TABLE_ hash table entry in the hgot field.
3565         * elf32-sparc.c (elf32_sparc_check_relocs): If the size of the
3566         global offset table goes over 0x1000, set the value of
3567         _GLOBAL_OFFSET_TABLE_ to 0x1000 into the section.
3568         (elf32_sparc_relocate_section): Subtract the offset of
3569         _GLOBAL_OFFSET_TABLE_ when handling GOT relocations.
3570
3571         * elfcode.h: Don't include <string.h>.
3572
3573 Mon Apr  1 10:39:24 1996  Jeffrey A Law  ([email protected])
3574
3575         * linker.c (_bfd_generic_link_hash_newfunc): Renamed from
3576         generic_link_hash_newfunc.  All references changed.
3577         * genlink.h (_bfd_generic_link_hash_newfunc): Declaration
3578         moved here from libbfd-in.h.
3579         * libbfd-in.h: Corresponding changes.
3580         * libbfd.h: Regenerated.
3581
3582 Mon Apr  1 12:35:36 1996  Ian Lance Taylor  <[email protected]>
3583
3584         * aoutx.h (aout_link_input_section_std): When reporting an
3585         overflow error, use the name of the symbol in the hash table if
3586         available.
3587         (aout_link_input_section_ext): Likewise.
3588
3589         * elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
3590         defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
3591
3592 Sun Mar 31 01:58:41 1996  steve chamberlain  <[email protected]>
3593
3594         * peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
3595         * coffcode.h (coff_compute_section_file_positions): Likewise.
3596         (coff_write_object_contents): Likewise.
3597         
3598 Fri Mar 29 12:44:36 1996  Ian Lance Taylor  <[email protected]>
3599
3600         * section.c (SEC_LINK_ONCE): Define.
3601         (SEC_LINK_DUPLICATES): Define.
3602         (SEC_LINK_DUPLICATES_DISCARD): Define.
3603         (SEC_LINK_DUPLICATES_ONE_ONLY): Define.
3604         (SEC_LINK_DUPLICATES_SAME_SIZE): Define.
3605         (SEC_LINK_DUPLICATES_SAME_CONTENTS): Define.
3606         * bfd-in2.h: Rebuild.
3607         * coffcode.h (sec_to_styp_flags): If COFF_WITH_PE, turn
3608         SEC_LINK_ONCE into IMAGE_SCN_LNK_COMDAT.
3609         (styp_to_sec_flags): If COFF_WITH_PE, turn IMAGE_SCN_LNK_REMOVE
3610         into SEC_EXCLUDE.  If IMAGE_SCN_LNK_COMDAT is set, set
3611         SEC_LINK_ONCE, and look through the symbol table for the setting
3612         for SEC_LINK_DUPLICATES.
3613         (coff_write_object_contents): If COFF_WITH_PE, if SEC_LINK_ONCE is
3614         set for a section, find the section symbol in the symbol table,
3615         and set the aux entry based on SEC_LINK_DUPLICATES.
3616         * coffgen.c (coff_print_symbol): Add a space before "checksum".
3617         * coff-arm.c (armcoff_big_vec): If COFF_WITH_PE is defined, add
3618         SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
3619         * coff-i386.c (i386coff_vec): Likewise.
3620         * coff-ppc.c (TARGET_LITTLE_SYM, TARGET_BIG_SYM): Likewise.
3621
3622         * VERSION: Bump to 2.6.1.
3623         * Makefile.in (stamp-h): Depend upon VERSION.
3624
3625 Thu Mar 28 23:48:49 1996  Jeffrey A Law  ([email protected])
3626
3627         * libbfd-in.h (generic_link_hash_newfunc): Add declaration.
3628         * libbfd.h: Rebuilt.
3629         * linker.c (generic_link_hash_newfunc): No longer static.
3630         * coffcode.h (coff_bfd_link_hash_create): Allow specific targets
3631         to override.
3632         * coff-h8300.c: Add two derived hash tables and their associated
3633         funtions and #defines for use by the h8300 linker.
3634         (h8300_reloc16_extra_cases, case R_MEM_INDIRECT): Create entries in
3635         the function vector as needed.  Place the address of the function
3636         vector entry in the location specified by the R_MEM_INDIRECT reloc.
3637         Rewrite the vectors section contents as necessary.
3638         (h8300_bfd_link_add_symbols): New function for the h8300 linker. 
3639         (coff_bfd_link_add_symbols): Define to use h8300 specific version.
3640         (coff_bfd_link_hash_table_create): Likewise.
3641
3642 Thu Mar 28 17:44:08 1996  Ian Lance Taylor  <[email protected]>
3643
3644         * libhppa.h: If gcc 2.7 or higher, declare all the functions with
3645         __attribute__ ((__unused__)) so that -Wall doesn't warn about
3646         them.
3647         (hppa_rebuild_insn): Pass pointer to correct type to
3648         low_sign_unext and dis_assemble_21.
3649
3650 Thu Mar 28 11:00:36 1996  Doug Evans  <[email protected]>
3651
3652         * config.bfd (sparc64-{sysv4*,solaris2*}): Delete.
3653         Stick with sparc-*-{sysv4*,solaris2*}.
3654
3655 Wed Mar 27 10:43:34 1996  Ian Lance Taylor  <[email protected]>
3656
3657         * peicode.h (coff_swap_aux_in): Swap in extra PE x_scn fields.
3658         (coff_swap_aux_out): Swap out extra PE x_scn fields.
3659         * coffswap.h (coff_swap_aux_in): Zero out extra PE x_scn fields.
3660         * coffgen.c (coff_print_symbol): If any of the extra PE x_scn
3661         fields is non-zero, print them.
3662
3663         * coff-ppc.c (ppc_record_toc_entry): Put inside COFF_IMAGE_WITH_PE
3664         ifdef.  Remove unused variables.
3665         (ppc_record_data_in_toc_entry): Ifdef out.  Removed unused
3666         variables.
3667         (ppc_mark_symbol_as_glue): Put inside COFF_IMAGE_WITH_PE ifdef.
3668         (get_symbol_value): Ifdef out.
3669         (pe_ppc_reloc): Ifdef out.  Remove unused variables.
3670         (coff_ppc_relocate_section): Remove unused variables.  Make
3671         fprintf strings and argument types correspond.  Put before_addr in
3672         DEBUG_RELOC ifdef.
3673         (dump_toc): Make fprintf strings and argument types correspond.
3674         (ppc_process_before_allocation): Remove unused variables.  Always
3675         return a value.
3676         (ppc_reflo_reloc): Ifdef out.
3677         (ppc_addr32nb_reloc): Ifdef out.
3678         (ppc_coff_rtype2howto): Make fprintf strings and argument types
3679         correspond.
3680         (coff_ppc_rtype_to_howto): Likewise.
3681         (ppc_coff_swap_sym_in_hook): Remove unused variables.
3682
3683         * peicode.h (pe_print_idata): Move otherwise unused variables into
3684         the #ifdef where they are used.  Always return a value.
3685         (pe_print_edata): Make fprintf strings and argument types
3686         correspond.  Always return a value.
3687         (pe_print_pdata): Removed unused variable addr_value.  Always
3688         return a value.
3689         (pe_print_reloc): Remove unused variable onaline.  Make fprintf
3690         strings and argument types correspond.  Always return a value.
3691
3692         * elf32-ppc.c (ppc_elf_fake_sections): Return true.
3693         (ppc_elf_finish_dynamic_symbol): Move definition of unused
3694         variable rela inside #if 0 section where it is used.
3695
3696         * ns32k.h: New file.
3697         * cpu-ns32k.h: Include ns32k.h.  Rename externally visible
3698         functions to start with _bfd_.
3699         * aout-ns32k.c: Include ns32k.h.  Change references to renamed
3700         functions in cpu-ns32k.h.
3701         * Makefile.in: Rebuild dependencies.
3702         (HFILES): Add ns32k.h.
3703
3704         * section.c (struct sec): Add linker_mark field.  Change
3705         user_set_vma and reloc_done to be single bit fields.
3706         (STD_SECTION): Update accordingly.
3707         * bfd-in2.h: Rebuild.
3708         * aoutx.h (NAME(aout,final_link)): Mark sections included in the
3709         link.
3710         (aout_link_input_bfd): Don't link unmarked sections.
3711         * cofflink.c (_bfd_coff_final_link): Mark sections included in the
3712         link.
3713         (_bfd_coff_link_input_bfd): Don't link unmarked sections.
3714         * coff-ppc.c (ppc_bfd_coff_final_link): Mark sections included in
3715         the link.
3716         * elflink.h (elf_bfd_final_link): Mark sections included in the
3717         link.
3718         (elf_link_input_bfd): Don't link unmarked sections.
3719         * xcofflink.c (_bfd_xcoff_bfd_final_link): Mark sections included
3720         in the link.
3721         (xcoff_link_input_bfd): Don't link unmarked sections.
3722
3723         * coffswap.h (coff_swap_scnhdr_out): Include section name in
3724         overflow error messages.
3725
3726 Tue Mar 26 15:46:18 1996  Ian Lance Taylor  <[email protected]>
3727
3728         * bfd.c (_bfd_default_error_handler): If _bfd_error_program_name
3729         is not set, print "BFD: " before the error message.
3730
3731         * configure.in: Use AC_CHECK_TOOL to find ar and ranlib.  From
3732         Miles Bader <[email protected]>.
3733         * configure: Rebuild.
3734
3735 Fri Mar 22 12:17:00 1996  Ian Lance Taylor  <[email protected]>
3736
3737         * xcofflink.c (xcoff_link_input_bfd): Fix scan for C_BINCL/C_EINCL
3738         symbols.
3739
3740         * config.bfd: Add ieee_vec to targ_selvecs for i960 targets and
3741         m68k-aout, m68k-coff, and m68k-elf targets.
3742
3743 Fri Mar 22 11:33:44 1996  Martin Anantharaman  <[email protected]>
3744
3745         * ieee.c: Changed #ifdef KEEPMINUSPCININST to #if KEEPMINUSPCININST.
3746         (ieee_generic_stat_arch_elt): Restructured to prevent
3747         ieee_object_p from being called repeatedly.
3748
3749 Thu Mar 21 11:00:47 1996  steve chamberlain  <[email protected]>
3750
3751         * coffcode.h (coff_write_object_contents):  Allocate
3752         buffers large enough for any FILEHDR or AOUTHDR.
3753
3754 Thu Mar 21 16:28:17 1996  David Mosberger-Tang  <[email protected]>
3755
3756         * ecofflink.c (lookup_line): New static function, renamed and
3757         slighly changed from old _bfd_ecoff_locate_line.
3758         (_bfd_ecoff_locate_line): Cache line number information.  Use
3759         lookup_line for actual lookup.
3760
3761 Thu Mar 21 14:59:11 1996  Michael Meissner  <[email protected]>
3762
3763         * peicode.h (pe_print_pdata): Warn if the .pdata section is not a
3764         multiple of 20 bytes.
3765
3766 Thu Mar 21 13:54:40 1996  Ian Lance Taylor  <[email protected]>
3767
3768         * ecoff.c (_bfd_ecoff_find_nearest_line): Use bfd_zalloc to
3769         allocate ecoff_find_line, and don't initialize by hand.
3770         * elf32-mips.c (mips_elf_find_nearest_line): Use bfd_zalloc for
3771         mips_elf_find_line, and don't call memset.
3772
3773         * coffcode.h (coff_compute_section_file_positions): If not
3774         producing a final executable, don't consider sofar when aligning
3775         the section to the correct size.
3776
3777 Wed Mar 20 16:53:12 1996  Ian Lance Taylor  <[email protected]>
3778
3779         * coffcode.h (coff_add_missing_symbols): Ifdef out.
3780         (coff_write_object_contents): Don't call coff_add_missing_symbols.
3781         * coffgen.c (coff_section_symbol): Ifdef out.
3782
3783 Mon Mar 18 12:54:41 1996  Ian Lance Taylor  <[email protected]>
3784
3785         * elf32-mips.c (mips_elf_gprel32_reloc): Initialize gp if
3786         output_bfd is not NULL.
3787
3788 Thu Mar 14 17:12:06 1996  Doug Evans  <[email protected]>
3789
3790         * coffgen.c (coff_get_normalized_symtab): Call bfd_zalloc instead
3791         of bfd_alloc (fixes fix_line not being initialized).
3792         Delete zeroing of fix_{value,tag,end,scnlen} fields.
3793
3794 Thu Mar 14 16:06:06 1996  Jeffrey A Law  ([email protected])
3795
3796         * coffcode.h: Allow specific backends to override the
3797         bfd_link_add_symbols routine.
3798
3799         * coff-h8300.c: Include genlink.h.
3800         (howto_table): Add R_MEM_INDIRECT.
3801         (rtype2howto): Support R_MEM_INDIRECT.
3802         (h8300_reloc16_extra_cases): Handle R_MEM_INDIRECT like R_RELBYTE
3803         for now.
3804         
3805 Tue Mar 12 12:41:17 1996  David Mosberger-Tang  <[email protected]>
3806
3807         * coff-alpha.c (alpha_relocate_section): Use
3808         info->callbacks_warning, rather than _bfd_error_handler, for
3809         "multiple gp" warning.
3810
3811 Tue Mar 12 12:10:55 1996  Ian Lance Taylor  <[email protected]>
3812
3813         * linker.c (bfd_wrapped_link_hash_lookup): New function.
3814         (_bfd_generic_link_add_one_symbol): Remove BFD_ASSERT on hash
3815         table string.  Use bfd_wrapped_link_hash_lookup.
3816         (_bfd_generic_link_write_global_symbol): Remove BFD_ASSERT on hash
3817         table string.
3818         * aoutx.h (aout_link_write_symbols): Use the name from the hash
3819         table, if any, when writing out symbols.
3820         (aout_link_input_section_std): Use the name from the hash table,
3821         if any, when reporting undefined symbols.
3822         (aout_link_input_section_ext): Likewise.
3823         (aout_link_reloc_link_order): Use bfd_wrapped_link_hash_lookup.
3824         * bout.c (get_value): Likewise.
3825         * cofflink.c (_bfd_coff_reloc_link_order): Likewise.
3826         * ecoff.c (ecoff_reloc_link_order): Likewise.
3827         * elflink.h (elf_link_add_object_symbols): Likewise.
3828         (elf_reloc_link_order): Likewise.       
3829         * linker.c (_bfd_generic_link_output_symbols): Likewise.
3830         (_bfd_generic_reloc_link_order): Likewise.
3831         (default_indirect_link_order): Likewise.
3832         * reloc16.c (bfd_coff_reloc16_get_value): Likewise.
3833         * sunos.c (sunos_add_one_symbol): Likewise.
3834         * xcofflink.c (xcoff_link_add_symbols): Likewise.
3835         (bfd_xcoff_link_count_reloc): Likewise.
3836         (xcoff_reloc_link_order): Likewise.
3837
3838         * ecoffswap.h (ecoff_swap_fdr_in): If ECOFF_64, turn 0xffffffff
3839         into -1 for intern->rss.
3840
3841         * configure: Rebuild with autoconf 2.8.
3842
3843 Mon Mar 11 12:28:31 1996  Ian Lance Taylor  <[email protected]>
3844
3845         * stab-syms.c (__define_stab_duplicate): Define.
3846         (bfd_get_stab_name): Rename from aout_stab_name.  Rewrite to use a
3847         switch.
3848         * bfd-in.h (bfd_get_stab_name): Declare.
3849         * bfd-in2.h: Rebuild.
3850         * Makefile.in: Rebuild dependencies.
3851         (BFD_LIBS): Add stab-syms.o.
3852         (BFD_LIBS_CFILES): Add stab-syms.c.
3853         (BFD32_BACKENDS): Remove stab-syms.o.
3854         (BFD32_BACKENDS_CFILES): Remove stab-syms.c.
3855         * configure.in: Don't list stab-syms.o in bfd_backends.
3856         * configure: Rebuild.
3857         * libaout.h (aout_stab_name): Don't declare.
3858         * aoutx.h (NAME(aout,get_symbol_info)): Call bfd_get_stab_name,
3859         not aout_stab_name.
3860
3861 Fri Mar  8 11:26:20 1996  Ian Lance Taylor  <[email protected]>
3862
3863         * elf.c (assign_file_positions_for_segments): Adjust file offset
3864         for section alignment even if SEC_LOAD is not set.
3865
3866 Tue Mar  5 12:02:23 1996  Ian Lance Taylor  <[email protected]>
3867
3868         * configure.in: Don't set SHLIB or SHLINK to an empty string,
3869         since they appear as targets in Makefile.in.
3870         * configure: Rebuild.
3871
3872         * sunos.c (sunos_scan_ext_relocs): If not making a shared library,
3873         don't fiddle with a symbol which is not defined anywhere.
3874
3875 Mon Mar  4 12:49:16 1996  Ian Lance Taylor  <[email protected]>
3876
3877         * xcofflink.c (xcoff_mark): Treat undefined imported symbols as
3878         though they are defined in a shared library.
3879         (xcoff_build_ldsyms): Likewise.
3880
3881         * coffgen.c (coff_find_nearest_line): Don't look at the line
3882         numbers for the section if section->lineno is NULL.
3883
3884         * elf.c (_bfd_elf_symbol_from_bfd_symbol): Print a useful error
3885         message rather than calling BFD_ASSERT.
3886         * elfcode.h (write_relocs): Check return value of
3887         _bfd_elf_symbol_from_bfd_symbol.
3888
3889 Fri Mar  1 09:42:59 1996  Michael Meissner  <[email protected]>
3890
3891         * elf32-ppc.c (ppc_elf_add_symbol_hook): Don't set SEC_LOAD flag
3892         for .sbss section.
3893
3894 Wed Feb 28 11:25:47 1996  Jeffrey A Law  ([email protected])
3895
3896         * libhppa.h (hppa_reloc_field_selector_type): Add R_HPPA_NLSEL
3897         and R_HPPA_NLRSEL.
3898         (e_nsel, e_nlsel, e_nlrsel): Undefine.  Add to
3899         hppa_reloc_field_selector_type_alt.
3900         (hppa_field_adjust): Handle e_nlsel, e_nlrsel.  Fix e_nsel handling.
3901         * som.c (hppa_som_gen_reloc_type): Handle N', NL' NLR' field
3902         selectors.
3903         (som_write_fixups): Finish handling of R_N0SEL and R_N1SEL.
3904
3905 Wed Feb 28 11:00:24 1996  Ian Lance Taylor  <[email protected]>
3906
3907         * elf.c (assign_file_positions_for_segments): Adjust the segment
3908         memory size for the alignment of a SEC_ALLOC section, not just a
3909         SEC_LOAD section.
3910
3911 Tue Feb 27 14:17:31 1996  Andreas Schwab  <[email protected]>
3912
3913         * m68klinux.c: New file.
3914         * hosts/m68klinux.h: New file.
3915         * config.bfd (m68*-*-linuxaout*, m68*-*-linux*): New targets.
3916         * configure.in (m68*-*-linux*): New native host.
3917         (m68klinux_vec): New vector.
3918         * configure: Rebuild.
3919         * targets.c (m68klinux_vec): Declare.
3920         * i386linux.c (bfd_i386linux_size_dynamic_sections): Renamed from
3921         bfd_linux_size_dynmic_sections to avoid clash with m68klinux.c.
3922         * bfd-in.h (bfd_i386linux_size_dynamic_sections): Rename
3923         declaration from bfd_linux_size_dynamic_sections.
3924         (bfd_m68klinux_size_dynamic_sections): Declare.
3925         * bfd-in2.h: Rebuild.
3926         * Makefile.in: Rebuild dependencies.
3927         (BFD32_BACKENDS): Add m68klinux.o.
3928         (BFD32_BACKENDS_CFILES): Add m68klinux.c.
3929
3930 Tue Feb 27 11:31:34 1996  Jeffrey A Law  ([email protected])
3931
3932         * libhppa.h (pa_arch): Add pa20.
3933         (hppa_reloc_field_selector_type): Add R_HPPA_NSEL.
3934         (e_nsel): Undefine.  Add to hppa_reloc_field_selector_type_alt.
3935         (hppa_field_adjust): Handle e_nsel.
3936         * som.c: Provide default definitions for many new relocs found only
3937         in hpux10 include files.
3938         (som_fixup_formats): Add several new relocs from hpux10.
3939         (som_hppa_howto_table): Add hpux10 relocs.
3940         (som_write_fixups): Handle R_N0SEL and R_N1SEL hpux10 relocs.
3941
3942 Mon Feb 26 12:52:48 1996  Stan Shebs  <[email protected]>
3943
3944         * mpw-make.sed: Edit out recent shared library support, and
3945         rules to rebuild .h files using doc/chew.
3946
3947 Mon Feb 26 14:48:39 1996  David Mosberger-Tang  <[email protected]>
3948
3949         * ecoff.c (ecoff_compute_section_file_positions): Adjust the file
3950         size even of sections with no contents.
3951
3952 Mon Feb 26 14:01:13 1996  Ian Lance Taylor  <[email protected]>
3953
3954         * cofflink.c (_bfd_coff_link_input_bfd): When merging, skip names
3955         starting with '$' the way we skip names starting with '.'.  When
3956         updating x_endndx, don't be fooled by an index which has been
3957         merged.
3958
3959         * cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
3960         struct/union/enum type with no elements.
3961
3962 Sat Feb 24 11:38:58 1996  Ian Lance Taylor  <[email protected]>
3963
3964         * bfd.c (bfd_errmsg): Handle a NULL return from strerror.
3965
3966         * archive.c (bfd_generic_archive_p): If the first file in the
3967         archive can not be recognized as an object, don't assume that this
3968         is the wrong format.
3969
3970         * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
3971         format is not bfd_object.
3972         (bfd_elf_get_dt_soname): Likewise.
3973
3974 Wed Feb 21 13:58:04 1996  Ian Lance Taylor  <[email protected]>
3975
3976         * coff-sh.c (sh_relax_delete_bytes): Correct range of R_SH_USES
3977         reloc.
3978
3979 Tue Feb 20 16:22:44 1996  J.T. Conklin  <[email protected]>
3980
3981         * bfd.c (tdata): Add netbsd_core_data.
3982         * bfd-in2.h: Regenerated.
3983
3984 Tue Feb 20 16:50:02 1996  Ian Lance Taylor  <[email protected]>
3985
3986         * sunos.c (SUNOS_CONSTRUCTOR): Define.
3987         (sunos_add_one_symbol): Don't let a symbol from a dynamic object
3988         override a constructor symbol.  Set SUNOS_CONSTRUCTOR when
3989         appropriate.
3990
3991         * bout.c (b_out_squirt_out_relocs): Use udata.i rather than flags
3992         to get the symbol index, matching 14 Jul 95 change.
3993
3994 Tue Feb 20 08:26:27 1996  Fred Fish  <[email protected]>
3995
3996         * coff-alpha.c (alpha_ecoff_get_relocated_section_contents):
3997         Remove duplicate definition of gp.
3998
3999 Mon Feb 19 12:37:41 1996  Ian Lance Taylor  <[email protected]>
4000
4001         * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Don't
4002         assume that we can set the GP value and then get the same value,
4003         since it won't be true if the output file is neither ELF nor
4004         ECOFF.
4005         * coff-mips.c (mips_adjust_reloc_in): Don't bother to use
4006         _bfd_get_gp_value here.
4007         (mips_gprel_reloc): Don't assume we can set and get the GP value.
4008         * elf32-mips.c (mips_elf_hi16_reloc): Get gp value from
4009         mips_elf_final_gp.
4010         (mips_elf_lo16_reloc): Likewise.
4011         (mips_elf_final_gp): Add pgp parameter.  Set it to the GP value.
4012         Don't require that the BFD be ELF.
4013         (mips_elf_gprel16_reloc): Get gp value from mips_elf_final_gp.
4014         (mips_elf_gprel32_reloc): Likewise.
4015         (mips_elf_relocate_section): Don't assume we can set and get the
4016         GP value.
4017         (mips_elf_finish_dynamic_symbol): Don't bother to use
4018         _bfd_get_gp_value here.
4019
4020         * elf32-mips.c (mips_elf_create_procedure_table): Initialize sv.
4021         Don't change epdr between malloc and free.  Be careful not to free
4022         NULL pointers.  Zero out the first RPDR.
4023
4024         * configure.host: On Linux, only pass -rpath option if $(libdir)
4025         is neither /lib nor /usr/lib.  From Alan Modra
4026         <[email protected]>.
4027
4028         * elf-bfd.h (struct elf_obj_tdata): Rename dt_needed_name to
4029         dt_name.
4030         (elf_dt_name): Rename from elf_dt_needed_name.
4031         * elf.c (bfd_elf_set_dt_needed_name): Use elf_dt_name, not
4032         elf_dt_needed_name.
4033         (bfd_elf_get_dt_soname): New function.
4034         * elflink.h (elf_link_add_object_symbols): Use elf_dt_name, not
4035         elf_dt_needed_name.  Save the SONAME back in elf_dt_name.
4036         * bfd-in.h (bfd_elf_get_dt_soname): Declare.
4037         * bfd-in2.h: Rebuild.
4038
4039 Mon Feb 19 02:50:23 1996  Doug Evans  <[email protected]>
4040
4041         * elf32-sparc.c (elf32_sparc_reloc_type_lookup): Renamed from
4042         _bfd_sparc_elf_reloc_type_lookup.
4043         (bfd_elf32_bfd_reloc_type_lookup): Update.
4044         * elf64-sparc.c (SPARC64_OLD_RELOCS): Define.
4045         (sparc64_elf_howto_table): Define.
4046         (sparc_reloc_map): Define.
4047         (sparc64_elf_reloc_type_lookup): New function.
4048         (sparc_elf_wdisp16_reloc): New function.
4049         (elf_info_to_howto): Use sparc64_elf_howto_table.
4050         (sparc64_elf_relocate_section): Likewise.
4051         (bfd_elf64_bfd_reloc_type_lookup): Update.
4052
4053 Sun Feb 18 15:02:25 1996  Ian Lance Taylor  <[email protected]>
4054
4055         * configure.host: Check for 'do not mix' from native linker before
4056         trying to use -rpath.
4057
4058 Fri Feb 16 12:46:18 1996  Ian Lance Taylor  <[email protected]>
4059
4060         * bfd.c (_bfd_get_gp_value): New function.
4061         (_bfd_set_gp_value): New function.
4062         * libbfd-in.h (_bfd_get_gp_value): Declare.
4063         (_bfd_set_gp_value): Declare.
4064         * libbfd.h: Rebuild.
4065         * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
4066         _bfd_get_gp_value and _bfd_set_gp_value rather than referring
4067         directly to the fields in the tdata information.
4068         (alpha_relocate_section): Likewise.
4069         * coff-mips.c (mips_adjust_reloc_in): Likewise.
4070         (mips_gprel_reloc): Likewise.
4071         (mips_relocate_section): Likewise.
4072         * elf32-mips.c (mips_elf_hi16_reloc): Likewise.
4073         (mips_elf_lo16_reloc): Likewise.
4074         (mips_elf_final_gp): Likewise.
4075         (mips_elf_gprel16_reloc): Likewise.
4076         (mips_elf_gprel32_reloc): Likewise.
4077         (mips_elf_relocate_section): Likewise.
4078         (mips_elf_finish_dynamic_symbol): Likewise.
4079
4080         * bout.c (b_out_set_arch_mach): Recognize bfd_mach_i960_jx.
4081
4082 Thu Feb 15 11:29:13 1996  Ian Lance Taylor  <[email protected]>
4083
4084         * configure.in: Call AC_PROG_CC before configure.host.
4085         * configure: Rebuild.
4086         * configure.host: Don't set information which autoconf should
4087         figure out, namely CC, CFLAGS, LDFLAGS, AR, and RANLIB.
4088
4089         * configure.host: Remove go32 and win32 host information, since it
4090         should no longer be needed.
4091
4092         * elf.c (map_sections_to_segments): If we have a .dynamic section,
4093         then start a new segment rather than put a writable section in a
4094         readonly segment.
4095
4096         * configure.host: Set RPATH_ENVVAR.
4097
4098         * Makefile.in: Rebuild dependencies.
4099
4100         * elflink.c (_bfd_elf_create_linker_section): Remove unused
4101         zero_section variable.
4102
4103 Thu Feb 15 10:39:17 1996  H.J. Lu  <[email protected]>
4104
4105         * Makefile.in ($(srcdir)/bfd-in2.h): Rename target from bfd-in2.h.
4106         ($(srcdir)/libbfd.h): Rename from libbfd.h.
4107         ($(srcdir)/libcoff.h): Rename from libcoff.h.
4108
4109 Wed Feb 14 16:29:07 1996  Martin Anantharaman  <[email protected]>
4110
4111         * ieee.c (ieee_write_expression): Only use an R variable for a
4112         local symbol.  Don't output a zero offset.  Handle a zero address.
4113         (SRC_MASK, PCREL_OFFSET): Define based on KEEPMINUSPCININST.
4114         (rel32_howto, rel16_howto, rel8_howto): Use SRC_MASK and
4115         PCREL_OFFSET.
4116         (parse_expression): Don't try to handle multiple occurrences of a
4117         P variable.  Handle I variables differently from X variables.  Fix
4118         the order of minus expressions.
4119         (ieee_slurp_external_symbols): Generate an I variable for an NN
4120         record.  Fix handling of ATI and ATX records.
4121         (ieee_slurp_sections): Only set minimal section attributes.
4122         Adjust them later, based on the section contents.
4123         (ieee_object_p): Read in the file until just after the ME record.
4124         Call ieee_slurp_section_data to set the section flags.
4125         (do_one): Add iterations parameter.  Only repeat the first load
4126         item.  Set the section and file reloc flags.
4127         (ieee_slurp_section_data): Set section flags.  Pass iterations to
4128         do_one.
4129         (ieee_canonicalize_reloc): Handle I variables.
4130         (do_with_relocs): Only emit relocation size when necessary.
4131         Increase MAXRUN to 127.  Change ov to be assigned, and take
4132         src_mask and pcrel_offset into account.
4133         (ieee_write_data_part): Skip sections that are not loaded.
4134         (ieee_write_external_part): Don't output optional last entry of WX
4135         records.
4136         (ieee_write_me_part): Make setting of me_record neater.
4137         (ieee_generic_stat_arch_elt): Get the size of an archive element.
4138
4139         * syms.c (stt): Add entries for zerovars, vars, and code.
4140
4141         * elfcode.h (validate_reloc): New static function.
4142         (write_relocs): Call validate_reloc for non ELF relocs.
4143
4144         * elfxx-target.h (elf_symbol_leading_char): Define if not defined.
4145         (TARGET_BIG_SYM): Use elf_symbol_leading_char.
4146         (TARGET_LITTLE_SYM): Likewise.
4147
4148         * config.bfd (m68*-*-psos*): New target.
4149
4150 Tue Feb 13 15:56:22 1996  Bryan Ford  <[email protected]>
4151
4152         * i386msdos.c: Remove some #if 0 code.
4153         (msdos_write_object_contents): Don't include empty sections in the
4154         size computation, regardless of their address.
4155
4156 Tue Feb 13 15:36:37 1996  Michael Meissner  <[email protected]>
4157
4158         * elf32-ppc.c (ppc_elf_relocate_section): Don't segfault if dynboj
4159         is NULL, ie, the -r switch is used.
4160
4161 Tue Feb 13 14:35:15 1996  Ian Lance Taylor  <[email protected]>
4162
4163         * reloc.c (BFD_RELOC_MIPS_GOT_HI16): Define.
4164         (BFD_RELOC_MIPS_GOT_LO16): Define.
4165         (BFD_RELOC_MIPS_CALL_HI16, BFD_RELOC_MIPS_CALL_LO16): Define.
4166         * bfd-in2.h, libbfd.h: Rebuild.
4167         * elf32-mips.c (mips_reloc_map): Map new relocs.
4168
4169         * configure.host: Set HDLFLAGS for *-*-hpux with --enable-shared.
4170
4171         * Makefile.in ($(SHLINK)): Check ts against $(SHLIB), not
4172         $(SHLINK).
4173
4174         * ieee.c (get_symbol): Set the section to bfd_abs_section.
4175         (do_with_relocs): If EXEC_P is set and there are no relocs, use a
4176         simple number for the section address, rather than an expression.
4177         Limit the number of bytes between relocs to MAXRUN.
4178         (ieee_write_me_part): Set me_record to the file offset after the
4179         start address.
4180         (ieee_write_processor): New static function.
4181         (ieee_write_object_contents): Use ieee_write_processor.
4182
4183 Fri Feb  9 10:53:00 1996  Ian Lance Taylor  <[email protected]>
4184
4185         * configure.host: Use ${CC-gcc} when testing for -rpath on SunOS.
4186
4187         * coff-aux.c: Change include of aux.h to aux-coff.h.
4188
4189 Thu Feb  8 14:01:03 1996  Andreas Schwab  <[email protected]>
4190
4191         * elf32-m68k.c (elf_m68k_relocate_section): For a R_68K_RELATIVE
4192         relocation put the addend both in the reloc entry and the data.
4193         (elf_m68k_finish_dynamic_symbol): Likewise.  Mask out marker in
4194         GOT offset value.
4195
4196         * elf32-m68k.c (elf_m68k_relocate_section): If -Bsymbolic, resolve
4197         a R_68K_PCxx reloc against a defined global symbol directly.
4198         (elf_m68k_check_relocs): Don't count such a reloc.
4199
4200         * elf32-m68k.c (elf_m68k_check_relocs): Don't record a symbol with
4201         a PLTxx reloc as dynamic.  Disallow PLTxxO reloc against a local
4202         symbol for now, otherwise always record the symbol as dynamic.
4203         (elf_m68k_adjust_dynamic_symbol): If a symbol with a PLTxx reloc
4204         is not referenced by a dynamic object, and we are not making a
4205         shared object, then don't make a PLT entry.  If we do make a PLT
4206         entry, make sure the symbol has been recorded as dynamic.
4207
4208 Wed Feb  7 13:56:06 1996  Ian Lance Taylor  <[email protected]>
4209
4210         * configure.host: When making a shared library, set HLDFLAGS to
4211         pass an appropriate -rpath option.  Use the make variable SONAME
4212         as the shared library soname, rather than computing it here.  On
4213         SunOS, build stamp-tshlink in place of $(SHLINK).
4214         * Makefile.in (SONAME): New variable.
4215         ($(SHLINK)): Make a link to the transformed name, as well.
4216         (stamp-tshlink): New target.
4217         (install): Skip stamp-tshlink during install.
4218
4219 Wed Feb  7 13:37:39 1996  Michael Meissner  <[email protected]>
4220
4221         * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not assume that the
4222         linker sections have been set up yet.
4223
4224         * elf.c (make_mapping): Add an additional argument to suppress
4225         making the first section include the program headers.
4226         (map_sections_to_segments): If the user used -Ttext such that the
4227         program headers are on a different page, do not set the flags
4228         saying that this section includes the program headers.
4229
4230 Tue Feb  6 14:04:49 1996  J.T. Conklin  <[email protected]>
4231
4232         * configure.in (*-*-netbsd*): Set COREFILE to netbsd-core.c.
4233         don't define TRAD_HEADER.
4234         * configure: Rebuild.
4235
4236         * netbsd-core.c: New file, support for NetBSD core files.
4237         * hosts/*nbsd.h: Removed.
4238
4239 Tue Feb  6 11:47:49 1996  Doug Evans  <[email protected]>
4240
4241         * reloc.c (BFD_RELOC_SPARC_[567]): New reloc types.
4242         (BFD_RELOC_SPARC_LO7 reloc type): Deleted.
4243         * libbfd.h, bfd-in2.h: Regenerated.
4244         * elf32-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Renamed from
4245         bfd_elf32_bfd_reloc_type_lookup.
4246         (reloc_type{,_names}): Deleted.
4247         (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
4248         Add sparc64 relocs.
4249         (sparc_reloc_map): Add sparc64 relocs.
4250         (sparc_elf_notsupported_reloc): New static function.
4251         (sparc_elf_wdisp16_reloc): New static function.
4252         (elf32_sparc_check_relocs): Handle R_SPARC_WDISP{16,19}.
4253         (elf32_sparc_relocate_section): Likewise.
4254         (bfd_elf32_bfd_reloc_type_lookup): Define.
4255         * elf64-sparc.c (sparc64_elf_wdisp16_reloc): Deleted.
4256         (reloc_type{,_names}): Deleted.
4257         (elf_sparc_howto_table): Deleted.
4258         (sparc_reloc_map): Deleted.
4259         (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
4260         (bfd_elf64_bfd_reloc_type_lookup): Change from function to #define.
4261
4262 Tue Feb  6 12:12:22 1996  Ian Lance Taylor  <[email protected]>
4263
4264         * configure.host: Make SHLIB_CFLAGS include $(PICFLAG) on a
4265         *-*-hpux* host.
4266
4267         * Makefile.in (program_transform_name): New variable.
4268         (install): Transform library name before installing it.
4269
4270 Mon Feb  5 10:38:27 1996  Ian Lance Taylor  <[email protected]>
4271
4272         * archures.c (bfd_mach_i960_hx): Define.
4273         * bfd-in2.h: Rebuild.
4274         * cpu-i960.c (scan_960_mach): Accept machine "hx".
4275         (MATRIX): Expand entries for HX.
4276         (arch_info_struct): Add i960:hx entry.
4277         * bout.c (b_out_set_arch_mach): Handle bfd_mach_i960_hx.
4278         * coffcode.h (coff_set_arch_mach_hook): Handle F_I960HX.
4279         (coff_set_flags): Handle bfd_mach_i960_hx.
4280
4281         Support for building as a shared library, based on patches from
4282         Alan Modra <[email protected]>:
4283         * configure.in: Add AC_ARG_ENABLE for shared and commonbfdlib.
4284         New substitutions: ALLLIBS, PICFLAG, SHLIB, SHLIB_CC,
4285         SHLIB_CFLAGS, COMMON_SHLIB, PICLIST, SHLINK.
4286         * configure: Rebuild.
4287         * configure.host: If --enable-shared, adjust shared library stuff
4288         based on the host.  If the host is SunOS, and the linker supports
4289         -rpath, set HLDFLAGS to use it.
4290         * Makefile.in (ALLLIBS): New variable.
4291         (PICFLAG, SHLIB, SHLIB_CC, SHLIB_CFLAGS): New variables.
4292         (COMMON_SHLIB, SHLINK): New variables.
4293         (.c.o): If PICFLAG is set, compile twice, once PIC, once normal.
4294         (STAGESTUFF): Remove variable.
4295         (all): Depend upon $(ALLLIBS) and @PICLIST@ rather than
4296         $(TARGETLIB).
4297         (stamp-ofiles): New target, like old ofiles target, but build
4298         using a temporary file and move-if-change, and touch stamp-ofiles
4299         when done.
4300         (ofiles): Just depend upon stamp-ofiles.
4301         (stamp-piclist, piclist): New targets.
4302         ($(SHLIB), $(SHLINK)): New targets.
4303         (targets.o, archures.o): Build twice if PICFLAG is set.
4304         (do_mostlyclean): Remove pic/*.o.
4305         (do_clean): Remove stamp-ofiles, $(SHLIB), $(SHLINK), piclist, and
4306         stamp-piclist.
4307         (do_distclean): Remove pic and stamp-picdir.
4308         (install): Install shared libraries.
4309         ($(OFILES)): Depend upon stamp-picdir.
4310         (stamp-picdir): New target.
4311
4312         * libcoff-in.h: Add comment reminding people that libcoff.h is a
4313         generated file.
4314         * libcoff.h: Rebuild.
4315
4316         * elflink.h (elf_adjust_dynamic_symbol): Don't try to get the
4317         flavour of a section with no owner.
4318
4319         * elf32-mips.c (mips_elf_create_dynamic_sections): Clear
4320         ELF_LINK_NON_ELF flag.
4321         (mips_elf_create_got_section): Likewise.
4322
4323         * elf.c: Revert last change, since it breaks dynamic linking.
4324         * elf-bfd.h (struct elf_backend_data): Remove want_hdr_in_seg
4325         field.
4326         * elf32-mips.c (elf_backend_want_hdr_in_seg): Don't define.
4327         * elfxx-target.h (elf_backend_want_hdr_in_seg): Don't define.
4328         (elfNN_bed): Don't initialize want_hdr_in_seg field.
4329
4330 Sun Feb  4 20:45:13 1996  Michael Meissner  <[email protected]>
4331
4332         * elf.c (assign_file_positions_for_segments): If the backend does
4333         not want the elf header or the program headers in the address
4334         space, do not include them in the calculations.
4335
4336         * elf32-ppc.c (ppc_elf_additional_program_headers): New hook
4337         function to determine if we need additional program headers.
4338         (ppc_elf_modify_segment_map): Define as a NOP function for now.
4339         (ppc_elf_create_linker_section): .sdata2 is a read-only section.
4340
4341 Sat Feb  3 23:00:03 1996  Ian Lance Taylor  <[email protected]>
4342
4343         * coffcode.h: Move today's libcoff.h change into coffcode.h.
4344
4345 Sat Feb  3 15:43:44 1996  Fred Fish  <[email protected]>
4346
4347         * libcoff.h (bfd_coff_link_add_one_symbol): Combine macro args
4348         back into one line.  Some compilers (sunos 4.1.3 for example)
4349         won't accept args split across more than one line.
4350
4351 Fri Feb  2 11:42:15 1996  Steve Chamberlain  <[email protected]>
4352
4353         * aclocal.m4 (BFD_BINARY_FOPEN): Understand cygwin32.
4354         * configure: Regenerate.
4355
4356 Fri Feb  2 12:12:16 1996  Jeffrey A Law  ([email protected])
4357
4358         * elf32-hppa.c (elf32_hppa_backend_symbol_table_processing): Don't
4359         try to do arithmetic on a void *, cast it to a unsigned char * first.
4360
4361 Thu Feb  1 16:04:06 1996  Ian Lance Taylor  <[email protected]>
4362
4363         * elf-bfd.h (ELF_LINK_NON_ELF): Define.
4364         * elf.c (_bfd_elf_link_hash_newfunc): Set elf_link_hash_flags to
4365         ELF_LINK_NON_ELF.
4366         * elflink.h (elf_link_add_object_symbols): Reset ELF_LINK_NON_ELF
4367         flag for a newly defined symbol.
4368         (NAME(bfd_elf,record_link_assignment)): Likewise.
4369         (elf_adjust_dynamic_symbol): If ELF_LINK_NON_ELF is set, try to
4370         set the DEF or REF_REGULAR flags correctly.
4371
4372         * Makefile.in (bfd-in2.h): Make bfd.h, not protos, in docdir.
4373         (libbfd.h, libcoff.h): Corresponding change.
4374
4375         * elf32-i386.c (elf_i386_check_relocs): Don't record a symbol with
4376         a PLT32 reloc as dynamic.
4377         (elf_i386_adjust_dynamic_symbol): If a symbol with a PLT32 reloc
4378         is not referenced by a dynamic object, and we are not making a
4379         shared object, then don't make a PLT entry.  If we do make a PLT
4380         entry, make sure the symbol has been recorded as dynamic.
4381
4382 Wed Jan 31 17:23:32 1996  Steve Chamberlain  <[email protected]>
4383
4384         * coff-i386.c (coff_i386_reloc_type_lookup): Add BFD_RELOC_32_PCREL.
4385         * config.bfd (i[345]86-*-win32): Becomes i[345]86-*-cygwin32.
4386         (powerpcle-*-cygwin32): New.
4387         * peicode.h (add_data_entry): Get address from vma.
4388
4389 Wed Jan 31 16:23:57 1996  Michael Meissner  <[email protected]>
4390
4391         * elflink.c (_bfd_elf_create_linker_section): If the symbol
4392         attached to the section has already been created as an undefined
4393         symbol, treat it as if it hasn't been created yet.
4394
4395 Wed Jan 31 16:16:53 1996  Ian Lance Taylor  <[email protected]>
4396
4397         * elflink.h (elf_bfd_final_link): Don't output initial dummy
4398         symbol or section symbols if stripping all symbols and this is not
4399         a relocateable link.  Don't output the symbol string table if
4400         there are no symbols.
4401         (elf_link_flush_output_syms): Don't do anything if there are no
4402         symbols to flush.
4403
4404 Wed Jan 31 12:55:49 1996  Richard Henderson  <[email protected]>
4405
4406         * coff-aux.c: New file.
4407         * hosts/m68kaux.h: New file.
4408         * config.bfd (m68*-apple-aux*): New target.
4409         * configure.in (m68*-apple-aux*): New native host.
4410         (m68kaux_coff_vec): New vector.
4411         * configure: Rebuild.
4412         * targets.c (m68kaux_coff_vec): Declare.
4413         * coffcode.h (bfd_coff_backend_data): Add field
4414         _bfd_coff_link_add_one_symbol.
4415         (bfd_coff_link_add_one_symbol): Define.
4416         (compare_arelent_ptr): New static function if TARG_AUX.
4417         (coff_write_relocs): If TARG_AUX, sort the relocs.
4418         (coff_write_object_contents): Set A/UX aouthdr magic number.
4419         (coff_link_add_one_symbol): Define if not defined.
4420         (bfd_coff_std_swap_table): Initialize new field.
4421         * libcoff.h: Rebuild.
4422         * cofflink.c (coff_link_add_symbols): Call
4423         bfd_coff_link_add_one_symbol rather than
4424         _bfd_generic_link_add_one_symbol.
4425         * coff-m68k.c (COFF_PAGE_SIZE): Don't define if already defined.
4426         * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
4427         * coff-mips.c (mips_ecoff_backend_data): Likewise.
4428         * Makefile.in: Rebuild dependencies.
4429         (BFD32_BACKENDS): Add coff-aux.o.
4430         (BFD32_BACKENDS_CFILES): Add coff-aux.c.
4431
4432 Wed Jan 31 11:37:46 1996  Andreas Schwab  <[email protected]>
4433
4434         * elf32-m68k.c (elf_m68k_relocate_section): Fix R_68K_GOT*
4435         relocation; ignore addend with R_68K_{GOT,PLT}*O relocation.
4436
4437 Tue Jan 30 12:09:04 1996  Ian Lance Taylor  <[email protected]>
4438
4439         * Makefile.in (do_maintainer_clean): Remove $(srcdir)/bfd-in2.h,
4440         $(srcdir)/libbfd.h and $(srcdir)/libcoff.h.
4441         (maintainer-clean): Warn about deleting special files.
4442         (bfd-in2.h, libbfd.h, libcoff.h): New targets.
4443
4444         * elf32-hppa.c (elf32_hppa_relocate_section): Handle indirect and
4445         warning symbols correctly.
4446         * elf32-i386.c (elf_i386_relocate_section): Likewise.
4447         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
4448         * elf32-mips.c (mips_elf_relocate_section): Likewise.
4449         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
4450         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
4451         * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
4452
4453         * syms.c (_bfd_stab_section_find_nearest_line): Add casts to avoid
4454         warnings.
4455
4456 Mon Jan 29 14:27:24 1996  Kim Knuttila  <[email protected]>
4457
4458         * libcoff-in.h: aligned newly exported names with bfd naming 
4459         conventions. Removed an erroneous define of POWERPC_LE_PE.
4460         * libcoff.h: Rebuild.
4461         * cofflink.c, coff-ppc.c: the above function name changes
4462
4463 Mon Jan 29 13:06:28 1996  Ian Lance Taylor  <[email protected]>
4464
4465         From Basim Kadhim <[email protected]>:
4466         * ecoff.c (struct extsym_info): Define.
4467         (_bfd_ecoff_bfd_final_link): Pass a pointer to struct extsym_info
4468         to ecoff_link_write_external.
4469         (ecoff_link_write_external): Accept a struct extsym_info pointer.
4470         Strip symbols when appropriate.
4471
4472         Based on patches from Ronald F. Guilmette <[email protected]>:
4473         * syms.c (BSF_OBJECT): Define.
4474         (bfd_print_symbol_vandf): Print 'O' for BSF_OBJECT.
4475         * bfd-in2.h: Rebuild.
4476         * elfcode.h (elf_slurp_symbol_table): Set BSF_OBJECT for an
4477         STT_OBJECT symbol.
4478         * elf.c (swap_out_syms): Only set type to STT_OBJECT if BSF_OBJECT
4479         is set.
4480
4481         * elf32-i386.c (elf_i386_relocate_section): If -Bsymbolic, when
4482         copying relocs into a shared object, treat a defined global symbol
4483         as a local symbol.
4484         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
4485         * elf32-mips.c (mips_elf_relocate_section): Likewise.
4486         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
4487
4488         * elflink.h (elf_link_add_object_symbols): Only set weakdef to a
4489         real defined symbol, not to a weak defined symbol.
4490
4491 Mon Jan 29 11:34:36 1996  Kim Knuttila  <[email protected]>
4492
4493         * cofflink.c: removed the POWERPC_LE_PE hack, promoted some types
4494         and made a few static functions externs.
4495
4496         * coff-ppc.c (ppc_bfd_coff_final_link): new function, replaces the
4497         POWERPC_LE_PE hack in cofflink.
4498
4499         * libcoff-in.h: promoted the following from cofflink.c to allow
4500         _bfd_coff_final_link to be overridden -  STRING_SIZE_SIZE,
4501         coff_debug_merge_element, struct coff_debug_merge_type, 
4502         coff_debug_merge_hash_entry, coff_debug_merge_hash_table,
4503         coff_debug_merge_hash_table_init,  coff_debug_merge_hash_table_free,
4504         coff_debug_merge_hash_lookup, coff_link_section_info, 
4505         coff_final_link_info, coff_debug_merge_hash_newfunc,
4506         coff_write_global_sym, coff_link_input_bfd, coff_reloc_link_order.
4507
4508         * libcoff.h: re-gen'd
4509
4510 Fri Jan 26 18:33:35 1996  Ian Lance Taylor  <[email protected]>
4511
4512         * syms.c: Include "bfdlink.h".
4513         (struct stab_find_info): Define.
4514         (_bfd_stab_section_find_nearest_line): New function.
4515         * libbfd-in.h (_bfd_stab_section_find_nearest_line): Declare.
4516         * libbfd.h: Rebuild.
4517         * elf-bfd.h (struct elf_obj_tdata): Add line_info field.
4518         * elf.c (_bfd_elf_find_nearest_line): Try calling
4519         _bfd_stab_section_find_nearest_line before searching the ELF
4520         symbol table.  Find the closest STT_FUNC symbol, not the last one.
4521         * libcoff-in.h (coff_data_type): Add line_info field.
4522         * libcoff.h: Rebuild.
4523         * coffgen.c (coff_find_nearest_line): Try calling
4524         _bfd_stab_section_find_nearest_line before searching the COFF
4525         symbol table.
4526         * Makefile.in: Rebuild dependencies.
4527
4528 Fri Jan 26 16:11:19 1996  Michael Meissner  <[email protected]>
4529
4530         * elf32-ppc.c (R_PPC_EMB_SDA21 relocations): Make relocation size
4531         4 bytes, so we get the correct value when updating the register
4532         field in little endian mode.
4533
4534 Thu Jan 25 12:14:16 1996  Ian Lance Taylor  <[email protected]>
4535
4536         * libcoff-in.h (struct xcoff_tdata): Remove toc_section and
4537         entry_section fields.  Add sntoc and snentry fields.
4538         * libcoff.h: Rebuild.
4539         * coffcode.h (coff_mkobject_hook): Initialize sntoc and snentry,
4540         not toc_section and entry_section (the COFF file does not have any
4541         sections at this point).
4542         (coff_write_object_contents): Set o_snentry and o_sntoc from
4543         snentry and sntoc rather than entry_section and toc_section.
4544         * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy sntoc and
4545         snentry, not toc_section and entry_section.
4546         * xcofflink.c (bfd_xcoff_size_dynamic_sections): Don't set
4547         entry_section from hentry.
4548         (xcoff_link_input_bfd): If a defined symbol has XCOFF_ENTRY set,
4549         set snenty.
4550         (xcoff_link_input_bfd): Set sntoc, not toc_section.
4551         (xcoff_write_global_symbol): Get toc_section from sntoc, rather
4552         than using toc_section directly.
4553
4554         * archures.c: Add missing `.' in enum bfd_architecture.
4555         * bfd-in2.h: Rebuild.
4556
4557         * config.bfd (i[345]86-*-sco*elf*): Use bfd_elf32_i386_vec.  From
4558         Robert Lipe <[email protected]>.
4559
4560 Thu Jan 25 12:08:51 1996  Michael Meissner  <[email protected]>
4561
4562         * elf32-ppc.c (ppc_elf_size_dynamic_sections): Add .rela.sdata{,2}
4563         to sections we allocate.  Use bfd_zalloc to allocate initialial
4564         sections, not bfd_alloc.
4565         (ppc_elf_check_relocs): Remove BFD_ASSERTs for !shared from
4566         SDA{,2}I16 relocations.
4567         (ppc_elf_add_symbol_hook): Use the value of -G nn to determine
4568         whether to put something in .sbss or not.
4569         (ppc_elf_relocate_section): Add support for more relocations.  Add
4570         in sec->output_offset where appropriate.  Make error messages
4571         include the symbol name.
4572
4573         * elflink.c (_bfd_elf_create_linker_section): Lookup symbol before
4574         trying to add it to the symbol table, so _GLOBAL_OFFSET_TABLE_
4575         doesn't get redefined messages if -shared.
4576
4577         * elflink.h (elf_create_pointer_linker_section) Only bump RELA
4578         section if the rel_section field has been set up.
4579
4580 Wed Jan 24 20:40:26 1996  Michael Meissner  <[email protected]>
4581
4582         * elf32-ppc.c (ppc_elf_relocate_section): Fix typo in eabi
4583         relocations.
4584
4585 Wed Jan 24 10:38:34 1996  Doug Evans  <[email protected]>
4586
4587         * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Delete checking
4588         of flags, only flags used are controlled by mach number.  Bump up
4589         output file mach number to highest of input file mach numbers.
4590         (elf32_sparc_object_p): Watch for EF_SPARC_SUN_US1.
4591         (elf32_sparc_final_write_processing): Set EF_SPARC_SUN_US1 if v8plusa.
4592
4593         * config.bfd (sparc64-*-{sysv4*,solaris2*}): Comment out
4594         bfd_elf64_sparc_vec support.
4595
4596 Tue Jan 23 14:33:05 1996  Michael Meissner  <[email protected]>
4597
4598         * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Don't complain if
4599         the embedded bit is set on some objects and not on others.  Just
4600         or it together.
4601         (ppc_elf_relocate_section): Implement R_PPC_EMB_{SDA21,RELSDA}
4602         relocations.
4603
4604 Tue Jan 23 14:22:45 1996  Ian Lance Taylor  <[email protected]>
4605
4606         * coffcode.h (coff_new_section_hook): Don't try to align the
4607         .stabstr section.
4608
4609         * coffcode.h (coff_set_section_contents): Fix the handling of the
4610         .lib section to work even if the entire section contents are
4611         written at once.  From Gvran Uddeborg <[email protected]> and
4612         Robert Lipe <[email protected]>.
4613
4614 Mon Jan 22 18:45:51 1996  Michael Meissner  <[email protected]>
4615
4616         * elflink.h (elf_finish_pointer_linker_section): Don't allocate
4617         memory here for contents.
4618
4619         * elf32-ppc.c (ppc_elf_relocate_section): Bump up _SDA_BASE_ and
4620         _SDA2_BASE_ by 32768.
4621         (ppc_elf_size_dynamic_sections): #if out PLT code which we haven't
4622         started using.  Allocate contents for .sdata and .sdata2 sections
4623         also.
4624         (ppc_elf_check_relocs): Use bfd_get_section_name in debug message,
4625         rather than _name.
4626         (ppc_elf_finish_dynamic_symbol): Remove code that attempted to
4627         size _SDA{,2}_BASE_.
4628         (ppc_elf_relocate_section): Change how sdata{,2} relocations are
4629         done.
4630
4631 Mon Jan 22 08:52:04 1996  Doug Evans  <[email protected]>
4632
4633         * elflink.h (elf_finish_pointer_linker_section): Fix typo.
4634
4635         * archures.c (bfd_mach_sparc_v9): Renamed from bfd_mach_sparc64.
4636         (bfd_mach_sparc_{v8plus,v8plusa}): Define.
4637         (bfd_mach_sparc_v9a): Define.
4638         (bfd_mach_sparc_v9_p): Define.
4639         * bfd-in2.h: Regenerated.
4640         * aoutx.h (aout,machine_type): bfd_mach_sparc64 renamed to
4641         bfd_mach_sparc_v9.
4642         * elf64-sparc.c (sparc64_elf_object_p): Likewise.
4643         * config.bfd (sparc64-*-sysv4*,sparc64-*-solaris2*): Set targ_defvec
4644         to bfd_elf32_sparc_vec.
4645         * cpu-sparc.c (arch_info_struct): Renamed from sparc_arch_info.
4646         Add v8plus{,a} support.
4647         Add v9a support.
4648         (sparc_compatible): New function.
4649         * elf32-sparc.h: #include "elf/sparc.h".
4650         (elf32_sparc_merge_private_bfd_data, elf32_sparc_object_p,
4651         elf32_sparc_final_write_processing): New functions.
4652         (bfd_elf32_bfd_merge_private_bfd_data, elf_backend_object_p,
4653         elf_backend_final_write_processing): Define.
4654
4655 Mon Jan 22 11:21:51 1996  Michael Meissner  <[email protected]>
4656
4657         * elf-bfd.h (struct elf_link_hash_entry): Add
4658         linker_section_pointer field.
4659         (enum elf_linker_section_enum): Enumeration for new way of
4660         creating linker dynamic sections and symbols.
4661         (elf_linker_section{,_pointers}): New structures for creating
4662         dynamic sections and symbols.
4663         (elf_obj_tdata): Add linker_section_pointers and linker_section
4664         fields.
4665         (elf_local_ptr_offsets,elf_linker_section): New accessor macros.
4666         (_bfd_elf_create_linker_section): New declarations.
4667         (_bfd_elf_find_pointer_linker_section): Ditto.
4668         (bfd_elf{32,64}_{create,finish}_pointer_linker_section): Ditto.
4669         (_bfd_elf_make_linker_section_rela): Ditto.
4670
4671         * elf.c (_bfd_elf_link_hash_newfunc): Initialize new fields.
4672
4673         * elf32-ppc.c (ppc_elf_create_dynamic_sections): Delete.
4674         (ppc_elf_create_linker_section): New function to create the
4675         sections .got, .sdata, and .sdata2.
4676         (ppc_elf_size_dynamic_sections): Zap .rela.{sdata,sdata2} if
4677         needed.
4678         (ppc_elf_check_relocs): Support more of the eabi relocations.
4679         (ppc_elf_relocate_section): Ditto.
4680         (ppc_elf_finish_dynamic_symbols): Adjust _SDA{,2}_BASE_ by 32768
4681         if the .sdata{,2} + .sbss{,2} section size is > 32k.
4682
4683         * elflink.h (elf_create_pointer_linker_section): New function to
4684         create initialized pointers in dynamic linker sections.
4685         (elf_finish_pointer_linker_section): Actually intialize the
4686         pointers created above.
4687
4688         * elfcode.h (bfd_elf{32,64}_create_pointer_linker_section): New
4689         macros to provide both 32 and 64 bit versions of
4690         elf_create_pointer_linker_section.
4691         (bfd_elf{32,64}_finish_pointer_linker_section): New macros to
4692         provide both 32 and 64 bit versions of
4693         elf_finish_pointer_linker_section.
4694
4695         * elflink.c (_bfd_elf_create_linker_section): New function to
4696         create a linker section.
4697         (_bfd_elf_find_pointer_linker_section): Find a unique pointer to a
4698         given address in the linker pointer offsets created for a given
4699         symbol.
4700         (_bfd_elf_make_linker_section_rela): Make a RELA section
4701         corresponding to the generated linker section.
4702
4703 Sat Jan 20 08:36:10 1996  Doug Evans  <[email protected]>
4704
4705         * elf32-sparc.c (ELF_MACHINE_ALT1): Define.
4706
4707 Thu Jan 18 18:25:34 1996  Kim Knuttila  <[email protected]>
4708
4709         * coff-ppc.c (coff_ppc_relocate_section): changed TOCDEFN relocs.
4710         (coff_ppc_relocate_section): Handle special values for gcc built dlls.
4711         (dump_toc): fix diagnosing code to identify out-of-toc-bounds entries.
4712         Also begin the toc at 4 as an eye catcher ('31313131' marks the first
4713         toc entry in an objdump) for now.
4714         (ppc_do_last, ppc_get_last): New function - needed to save processing 
4715         the toc owner to the end.
4716         (ppc_coff_swap_sym_in_hook): Removed an incorrect hack for doing the 
4717         toc owner last.
4718
4719         * cofflink.c (_bfd_coff_final_link): Added a new hack to keep the 
4720         toc owner from being done till last. Must define POWERPC_LE_PC 
4721         to enable it.
4722
4723         * coffcode.h (coff_set_alignment_hook): alignment setting for .stab
4724
4725         * peicode.h (coff_swap_scnhdr_out): set section flags for stab/str
4726         to INFO.
4727         (coff_swap_aouthdr_out): Removed a non-working hack for computing the
4728         SizeOfImage for PowerPC. Ignore the size of the .junk section.
4729
4730 Thu Jan 18 17:42:12 1996  Ian Lance Taylor  <[email protected]>
4731
4732         * elfcore.h: Include <signal.h> before <sys/procfs.h>.
4733
4734 Wed Jan 17 12:40:14 1996  Ian Lance Taylor  <[email protected]>
4735
4736         * cpu-powerpc.c (arch_info_struct): Change last entry to not point
4737         back to first.
4738         (bfd_powerpc_arch): Point at first entry in arch_info_struct.
4739
4740 Tue Jan 16 15:10:49 1996  Ian Lance Taylor  <[email protected]>
4741
4742         * elf.c (assign_file_positions_for_segments): Don't increment file
4743         offset for a segment which contains no loadable sections.
4744
4745 Mon Jan 15 17:46:27 1996  Michael Meissner  <[email protected]>
4746
4747         * reloc.c: Add new PowerPC relocations.
4748         * {bfd-in2,libbfd}.h: Regenerate.
4749
4750         * elf32-ppc.c (ppc_elf_howto_raw): Add more PPC relocations.
4751         (ppc_elf_reloc_type_lookup): Lookup new relocations.
4752
4753 Mon Jan 15 14:29:44 1996  Ian Lance Taylor  <[email protected]>
4754
4755         * aoutx.h (howto_table_ext): Fix RELOC_BASE10 and RELOC_BASE22
4756         entries.
4757
4758         * sunos.c (sunos_scan_ext_relocs): Don't fail assert if
4759         info->shared.
4760
4761         * coffgen.c (coff_find_nearest_line): Don't try to cache
4762         information in sections that are not owned by a BFD.  From Richard
4763         Henderson <[email protected]>.
4764
4765         * elf32-mips.c: Numerous changes to dynamic linking code, mostly
4766         from Kazumoto Kojima <[email protected]>.
4767         * elflink.h (elf_link_output_extsym): Remove special check for
4768         _rld_new_interface.
4769
4770         * ecoffswap.h: Add prototypes for static functions.
4771
4772 Sun Jan 14 21:36:08 1996  Michael Meissner  <[email protected]>
4773
4774         * elf32-ppc.c (ppc_elf_{unsupported,std}_reloc): Remove functions.
4775         (ppc_elf_howto_raw): Remove ppc_elf_{unsupported,std}_reloc
4776         references.
4777         (ppc_elf_relocate_section):  No longer allow .sdata/.sbss sections
4778         to satisfy a TOC16 relocation.  Rewrite unsupported relocation
4779         support.  Begin support for R_PPC_SDA{2,}REL.
4780
4781 Sat Jan 13 09:36:52 1996  Michael Meissner  <[email protected]>
4782
4783         * elf32-ppc.c (ppc_elf_create_dynamic_sections): New function to
4784         create the .got and .got.neg sections.
4785         (ppc_elf_size_dynamic_sections): Call it.
4786         (ppc_elf_check_relocs): Call it.
4787         (ppc_elf_size_dynamic_sections): Support .got.neg, just like .got.
4788         (ppc_elf_check_relocs): Add error messages for relocations we
4789         don't yet support.  Do not include R_PPC_SDAREL16 like a GOT
4790         relocation.
4791
4792 Fri Jan 12 15:27:59 1996  Michael Meissner  <[email protected]>
4793
4794         * elf32-ppc.c (ppc_elf_fake_sections): Define, and handle the new
4795         section flags for V.4 and eabi.
4796
4797 Fri Jan 12 13:59:16 1996  Ian Lance Taylor  <[email protected]>
4798
4799         * elf.c (assign_file_positions_for_segments): If a segment
4800         contains no sections, don't mark it as readable.
4801
4802         * elf-bfd.h (_bfd_elf_section_from_bfd_section): Declare.
4803         * elfcode.h (_bfd_elf_section_from_bfd_section): Don't declare.
4804
4805         * elf.c (_bfd_elf_print_private_bfd_data): Dump contents of
4806         dynamic section, if there is one.
4807         * elf-bfd.h (struct elf_size_info): Add swap_dyn_in field.
4808         (bfd_elf32_swap_dyn_in): Change type of second parameter to PTR.
4809         (bfd_elf64_swap_dyn_in): Likewise.
4810         * elfcode.h (elf_swap_dyn_in): Change type of second parameter to
4811         PTR.
4812         (NAME(_bfd_elf,size_info)): Initialize swap_dyn_in field.
4813
4814         * elf32-i386.c (elf_i386_size_dynamic_sections): Don't create a
4815         DT_TEXTREL entry because of .rel.plt.  From Martin Pirker
4816         <[email protected]>.
4817
4818 Thu Jan 11 17:06:14 1996  Michael Meissner  <[email protected]>
4819
4820         * section.c (SEC_{EXCLUDE,SORT_ENTRIES}): New section flags for
4821         PowerPC V.4 and eabi.
4822         * bfd-in2.h: Regenerate.
4823         * libfd.h: Regenerate.
4824
4825         * elfxx-target.h (TARGET_{BIG,LITTLE}_SYM): Add new flags.
4826
4827         * elf32-ppc.c (ppc_elf_section_from_shdr): Support SHT_ORDERED
4828         section type and SHF_EXCLUDE section flag, turning them into the
4829         appropriate bfd section flag.
4830
4831 Thu Jan 11 11:23:30 1996  Ian Lance Taylor  <[email protected]>
4832
4833         * xcofflink.c (xcoff_link_add_symbols): Create the special
4834         sections if we see a DYNAMIC object, in case that is the only
4835         XCOFF input object we see.
4836         
4837         * elf32-mips.c: Extensive changes for a start at dynamic linking
4838         support, from Kazumoto Kojima <[email protected]>.
4839
4840         * elf-bfd.h (struct elf_backend_data): Add type_change_ok field.
4841         (struct elf_backend_data): Remove
4842         elf_backend_create_program_headers field.  Add
4843         elf_backend_additional_program_headers and
4844         elf_backend_modify_segment_map fields.
4845         * elfxx-target.h (elf_backend_type_change_ok): Define if not
4846         defined.
4847         (elf_backend_additional_program_headers): Likewise.
4848         (elf_backend_modify_segment_map): Likewise.
4849         (elf_backend_create_program_headers): Don't define.
4850         (elfNN_bed): Change to account for field changes.
4851         * elf.c (assign_file_positions_for_segments): Call new
4852         modify_segment_map backend function.  Don't call old
4853         create_program_headers backend function.
4854         (get_program_header_size): Call additional_program_headers rather
4855         than create_program_headers.
4856         * elflink.h (elf_link_add_object_symbols): Initialize
4857         type_change_ok from new backend field.
4858         (elf_link_output_extsym): Don't warn if _rld_new_interface is
4859         defined.
4860         (elf_reloc_link_order): Treat a reloc against a defined symbol as
4861         a reloc against the appropriate section.
4862
4863         * elf-bfd.h (struct bfd_elf_section_data): Add tdata field.
4864         (struct elf_obj_tdata): Rename ppc_flags_init field to flags_init.
4865         (elf_flags_init): Rename from elf_ppc_flags_init.
4866         * elf32-ppc.c (ppc_elf_set_private_flags): Use elf_flags_init, not
4867         elf_ppc_flags_init.
4868         (ppc_elf_copy_private_bfd_data): Likewise.
4869         (ppc_elf_merge_private_bfd_data): Likewise.
4870
4871         * elf32-m68k.c (howto_table): Change src_mask to 0 for all
4872         relocation entries.
4873
4874 Tue Jan  9 15:22:53 1996  David Mosberger-Tang  <[email protected]>
4875
4876         * coff-alpha.c (alpha_relocate_section): During final link, allow
4877         output .lita section to be bigger than 64k by adjusting gp value
4878         on a per-input section basis.
4879         * libecoff.h (struct ecoff_tdata): Add issued_multiple_gp_warning
4880         field.
4881         (struct ecoff_section_tdata): Add gp field.
4882
4883 Tue Jan  9 12:00:36 1996  Ian Lance Taylor  <[email protected]>
4884
4885         Handle Alpha ECOFF changes in OSF/1 3.2.
4886         * libecoff.h (struct ecoff_backend_data): Add get_elt_at_filepos
4887         field.
4888         * coff-alpha.c: Include "aout/ar.h".
4889         (alpha_ecoff_get_relocated_section_contents): Don't require an
4890         ALPHA_R_IGNORE reloc after an ALPHA_R_GPDISP reloc, since OSF/1
4891         3.2 doesn't generate one.
4892         (alpha_relocate_section): Likewise.
4893         (alpha_ecoff_slurp_armap): Define.
4894         (alpha_ecoff_slurp_extended_name_table): Define.
4895         (alpha_ecoff_construct_extended_name_table): Define.
4896         (alpha_ecoff_truncate_arname): Define.
4897         (alpha_ecoff_write_armap): Define.
4898         (alpha_ecoff_generic_stat_arch_elt): Define.
4899         (alpha_ecoff_update_armap_timestamp): Define.
4900         (ARFZMAG): Define.
4901         (alpha_ecoff_read_ar_hdr): New static function.
4902         (alpha_ecoff_get_elt_at_filepos): New static function.
4903         (alpha_ecoff_openr_next_archived_file): New static function.
4904         (alpha_ecoff_get_elt_at_index): New static function.
4905         (alpha_ecoff_backend_data): Initialize get_elt_at_filepos field.
4906         (ecoffalpha_little_vec): Change BFD_JUMP_TABLE_ARCHIVE from
4907         _bfd_ecoff to alpha_ecoff.
4908         * ecoff.c (ecoff_link_add_archive_symbols): Use get_elt_at_filepos
4909         field from backend structure, rather than always calling
4910         _bfd_get_elt_at_filepos.
4911         * coff-mips.c (mips_ecoff_backend_data): Initialize
4912         get_elt_at_filepos field.
4913         * archive.c (_bfd_generic_read_ar_hdr_mag): New function, copied
4914         from _bfd_generic_read_ar_hdr with minor changes.
4915         (_bfd_generic_read_ar_hdr): Use _bfd_generic_read_ar_hdr_mag.
4916         * libbfd-in.h (_bfd_generic_read_ar_hdr_mag): Declare.
4917         * libbfd.h: Rebuild.
4918
4919         * bfd-in.h (BFD_IN_MEMORY): Define.
4920         * libbfd-in.h (struct bfd_in_memory): Define.
4921         * libbfd.c (bfd_read): Handle BFD_IN_MEMORY flag.
4922         (bfd_get_file_window): Don't try to map a BFD_IN_MEMORY file.
4923         (bfd_write, bfd_stat): Abort if BFD_IN_MEMORY is set.
4924         (bfd_tell, bfd_flush, bfd_seek): Handle BFD_IN_MEMORY flag.
4925         * bfd.c (struct _bfd): Change iostream field from char * to PTR.
4926         (bfd_get_size): Handle BFD_IN_MEMORY flag.
4927         * cache.c (bfd_cache_close): Ignore BFD_IN_MEMORY files.
4928         (bfd_open_file): Cast to PTR, not char *, when setting iostream.
4929         (bfd_cache_lookup_worker): Abort if BFD_IN_MEMORY is set.
4930         * opncls.c (bfd_fdopenr): Cast to PTR, not char *, when setting
4931         iostream.
4932         (bfd_openstreamr): Likewise.
4933         * aoutx.h (NAME(aout,some_aout_object_p)): Only fstat iostream if
4934         BFD_IN_MEMORY is not set.
4935         * riscix.c (riscix_some_aout_object_p): Likewise.
4936         * bfd-in2.h, libbfd.h: Rebuild.
4937
4938         * targets.c (bfd_target): Add _bfd_get_elt_at_index field.
4939         (BFD_JUMP_TABLE_ARCHIVE): Add _get_elt_at_index.
4940         (bfd_get_elt_at_index): Define.
4941         * archive.c (_bfd_generic_get_elt_at_index): Rename from
4942         bfd_get_elt_at_index.  Change index parameter from int to
4943         symindex.
4944         * libbfd-in.h (_bfd_generic_get_elt_at_index): Declare.
4945         (_bfd_noarchive_get_elt_at_index): Define.
4946         (_bfd_archive_bsd_get_elt_at_index): Define.
4947         (_bfd_archive_coff_get_elt_at_index): Define.
4948         * bfd-in2.h, libbfd.h: Rebuild.
4949         * aout-target.h (MY_get_elt_at_index): Define if not defined.
4950         * coff-rs6000.c (xcoff_get_elt_at_index): Define.
4951         * ieee.c (ieee_get_elt_at_index): Define.
4952         * libecoff.h (_bfd_ecoff_get_elt_at_index): Define.
4953         * oasys.c (oasys_get_elt_at_index): Define.
4954         * som.c (som_get_elt_at_index): Define.
4955
4956         * ecoff.c (_bfd_ecoff_find_nearest_line): Don't restrict line
4957         numbers to the .text section.
4958
4959 Mon Jan  8 17:00:57 1996  Ian Lance Taylor  <[email protected]>
4960
4961         * ieee.c (ieee_write_debug_part): Change return type to boolean.
4962         If there is a SEC_DEBUGGING section, get the contents of the debug
4963         information part from it.
4964         (ieee_set_section_contents): Store the contents of a SEC_DEBUGGING
4965         section in memory.
4966         (ieee_write_object_contents): Check ieee_write_debug_part return.
4967
4968 Thu Jan  4 17:12:37 1996  Fred Fish  <[email protected]>
4969
4970         * config.bfd (i[345]86-*-freebsd*): Add target.
4971         * configure.in (i386freebsd_vec): Add vec.
4972         * configure: Regenerate.
4973         * Makefile.in (BFD32_BACKENDS): Add i386freebsd.o.
4974         (BFD32_BACKENDS_CFILES): Add i386freebsd.c.
4975         Rebuild dependencies..
4976         * freebsd.h: New file.
4977         * i386freebsd.c: New file.
4978         * targets.c (i386freebsd_vec): Declare.
4979         (bfd_target_vector): Add i386freebsd_vec.
4980         * i386linux.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
4981         * i386netbsd.c (SEGMENT_SIZE):  Define as TARGET_PAGE_SIZE
4982         
4983 Thu Jan  4 16:27:46 1996  Ian Lance Taylor  <[email protected]>
4984
4985         * ieee.c (ieee_slurp_debug): New static function.
4986         (ieee_object_p): Call it.
4987         (ieee_slurp_section_data): Skip debugging sections.
4988         (ieee_get_reloc_upper_bound): Likewise.
4989         (ieee_get_section_contents): Likewise.
4990         (ieee_canonicalize_reloc): Likewise.
4991         (ieee_write_section_part): Likewise.
4992         (ieee_write_debug_part): Likewise.
4993         (ieee_write_data_part): Likewise.
4994         (init_for_output): Likewise.
4995
4996 Wed Jan  3 19:42:47 1996  Michael Meissner  <[email protected]>
4997
4998         * elf32-ppc.c (ppc_elf_relocate_section): Make @GOT relocations
4999         work.
5000         (ppc_elf_howto_raw): Just use bfd_elf_generic_reloc for all howto
5001         relocs, since ppc_elf_relocate_section handles the linker case.
5002         (ppc_elf_{addr16_ha,got16,toc16,brtaken}_reloc): Delete, no longer
5003         used.
5004         (ppc_elf_{addr16_ha,got16,toc16,brtaken}_inner): Merge these into
5005         ppc_elf_relocate_section since that is now the only caller.
5006         (ppc_elf_relocate_section): Ditto.
5007
5008 Wed Jan  3 15:11:30 1996  Ian Lance Taylor  <[email protected]>
5009
5010         * coffcode.h (coff_write_object_contents): If we don't know the
5011         section of the entry point for an XCOFF executable, always set the
5012         entry address to -1.
5013
5014 Tue Jan  2 14:17:15 1996  Michael Meissner  <[email protected]>
5015
5016         * elf.c (bfd_section_from_shdr): Add support for note sections.
5017
5018 Tue Jan  2 13:10:25 1996  Ian Lance Taylor  <[email protected]>
5019
5020         * bfd-in.h (struct _symbol_info): Add stab_type field.
5021         * bfd-in2.h: Rebuild.
5022         * aoutx.h (NAME(aout,get_symbol_info)): Set stab_type.
5023
5024         * elf32-ppc.c: Remove trailing newline from calls to
5025         _bfd_error_handler.
5026         (ppc_elf_merge_private_bfd_data): Only warn about endianness
5027         difference if target endianness is known.
5028
5029 Thu Dec 21 12:43:49 1995  Michael Meissner  <[email protected]>
5030
5031         * elf32-ppc.c (ppc_elf_howto_raw): Add a phony reloc to handle the
5032         old style TOC16 references without using R_PPC_GOT.
5033         (ppc_reloc_type): Ditto.
5034         (ppc_elf_reloc_type_lookup): Add support for TOC16.
5035         (ppc_elf_toc16_inner): Renamed from ppc_elf_got16_inner.
5036         (ppc_elf_toc16_reloc): Renamed from ppc_elf_toc16_reloc.
5037         (ppc_elf_got16_{inner,reloc}): Stubs for real GOT support.
5038         (ppc_elf_check_relocs): New function for GOT/PLT support that is
5039         work in progress.
5040         (ppc_elf_adjust_dynamic_symbol): Ditto.
5041         (ppc_elf_adjust_dynindx): Ditto.
5042         (ppc_elf_size_dynamic_sections): Ditto.
5043         (ppc_elf_finish_dynamic_symbol): Ditto.
5044         (ppc_elf_finish_dynamic_sections): Ditto.
5045         (ELF_DYNAMIC_INTERPRETER): Define.
5046
5047 Wed Dec 20 19:14:18 1995  Ken Raeburn  <[email protected]>
5048
5049         * elf.c (copy_private_bfd_data): When attaching sections to
5050         segments ignore sections that won't be allocated.  Patch from
5051         Andreas Schwab.
5052
5053 Tue Dec 19 20:01:43 1995  Ken Raeburn  <[email protected]>
5054
5055         * config.bfd: Match on m68k-cbm-* only if OS doesn't match
5056         anything else.
5057
5058 Tue Dec 19 16:38:59 1995  Ian Lance Taylor  <[email protected]>
5059
5060         * coff-i960.c (CALC_ADDEND): Define.
5061         (coff_i960_relocate_section): Add the input section VMA to the
5062         addend for PC relative relocs.
5063
5064 Sun Dec 17 20:11:55 1995  Kim Knuttila  <[email protected]>
5065
5066         * peicode.h (pe_print_pdata): Must test the entire entry for zero
5067         to correctly terminate.
5068
5069 Fri Dec 15 12:05:57 1995  Ian Lance Taylor  <[email protected]>
5070
5071         * targets.c (enum bfd_endian): Define.
5072         (bfd_target): Rename byteorder_big_p to byteorder, and change it
5073         from boolean to enum bfd_endian.  Change header_byteorder_big_p
5074         correspondingly.
5075         * bfd-in.h (bfd_big_endian, bfd_little_endian): New macros.
5076         (bfd_header_big_endian, bfd_header_little_endian): New macros.
5077         * bfd-in2.h: Rebuild.
5078         * All targets: Change initialization of byteorder and
5079         header_byteorder to use enum bfd_endian values rather than
5080         booleans.
5081         * All files: Change all references to byteorder_big_p and
5082         header_byteorder_big_p to use new bfd_*_endian macros.
5083
5084         * coffgen.c (make_a_section_from_file): Set lma to s_paddr, not
5085         s_vaddr.
5086         * coffcode.h (coff_write_object_contents): Set s_paddr to lma, not
5087         vma.
5088         * ecoff.c (_bfd_ecoff_write_object_contents): Likewise.
5089
5090 Fri Dec 15 07:32:09 1995  steve chamberlain  <[email protected]>
5091
5092         * pe[i]-i386.c (TARGET_UNDERSCORE): Define to '_'.
5093
5094 Thu Dec 14 13:45:37 1995  Ian Lance Taylor  <[email protected]>
5095
5096         * ieee.c: Lots of minor cleanups.  Make many functions return
5097         errors rather than calling abort.  Also:
5098         (ieee_write_twobyte): Remove; change callers to call existing
5099         ieee_write_2bytes function.
5100         (ieee_write_expression): Don't output the section twice when
5101         outputting a local symbol.  Don't emit an extraneous zero if there
5102         is only one term.
5103         (ieee_slurp_sections): Set the lma as well as the vma.
5104         (ieee_archive_p): Use bfd_alloc_grow rather than an obstack.
5105
5106         * ihex.c (ihex_set_arch_mach): Don't accept any architecture, just
5107         a recognized one or bfd_arch_unknown.
5108         (ihex_get_symtab_upper_bound): Define as bfd_0l, to permit objcopy
5109         to succeed.
5110         (ihex_get_symtab): Likewise.
5111
5112 Wed Dec 13 15:44:06 1995  Ian Lance Taylor  <[email protected]>
5113
5114         * aoutx.h: Include <ctype.h>.
5115         (struct aout_link_includes_table): Define.
5116         (struct aout_link_includes_totals): Define.
5117         (struct aout_link_includes_entry): Define.
5118         (aout_link_includes_lookup): Define macro.
5119         (struct aout_final_link_info): Add includes field.
5120         (aout_link_includes_newfunc): New static function.
5121         (NAME(aout,final_link)): Initialize includes hash table.
5122         (aout_link_write_symbols): Eliminate duplicate N_BINCL entries.
5123
5124 Wed Dec 13 10:52:14 1995  Stan Shebs  <[email protected]>
5125
5126         * mpw-config.in: Match on mips-*-* instead of mips-idt-ecoff.
5127
5128 Wed Dec 13 11:07:45 1995  Kim Knuttila  <[email protected]>
5129
5130         * coff-ppc.c (coff_ppc_relocate_section): removed debugging code.
5131
5132 Tue Dec 12 17:42:06 1995  Kim Knuttila  <[email protected]>
5133
5134         * peicode.h (pe_print_reloc): New function to dump the .reloc section.
5135         (pe_print_private_bfd_data): call pe_print_reloc.
5136         * coffcode.h (coff_set_alignment_hook): .reloc section alignment.
5137         * coff-ppc.c (in_reloc_p): Added missing non-eligible relocs. Spiffed
5138         up some debugging as well.
5139
5140 Tue Dec 12 11:34:23 1995  Ian Lance Taylor  <[email protected]>
5141
5142         * config.bfd: Handle sparc-*-elf*.  From Ronald F. Guilmette
5143         <[email protected]>.
5144
5145 Fri Dec  8 17:47:07 1995  Ian Lance Taylor  <[email protected]>
5146
5147         * elflink.h (elf_link_add_object_symbols): Set section_count to 0
5148         when setting sections to NULL.
5149
5150 Wed Dec  6 17:05:37 1995  Ian Lance Taylor  <[email protected]>
5151
5152         * xcofflink.c (struct xcoff_loader_info): Add export_defineds
5153         field.
5154         (bfd_xcoff_size_dynamic_sections): Add export_defineds parameter.
5155         (xcoff_build_ldsyms): If export_defineds is set, set XCOFF_EXPORT
5156         for all symbols.
5157         * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
5158         * bfd-in2.h: Rebuild.
5159
5160 Mon Dec  4 16:40:47 1995  Kim Knuttila  <[email protected]>
5161
5162         * coffcode.h (coff_set_alignment_hook): Removed some debugging printf's
5163
5164 Mon Dec  4 11:25:39 1995  Ian Lance Taylor  <[email protected]>
5165
5166         * ihex.c (ihex_scan): Handle record types 4 and 5.
5167         (ihex_object_p): Permit types 4 and 5.
5168         (ihex_set_section_contents): Remove check for out of range
5169         addresses.
5170         (ihex_write_object_contents): Generate types 4 and 5.
5171
5172         * elflink.h (elf_link_output_extsym): Just ignore warning and
5173         indirect references to symbols which don't really exist.
5174
5175 Sun Dec  3 19:00:27 1995  Kim Knuttila  <[email protected]>
5176
5177         * peicode.h (pe_print_idata): Minor format fixes
5178         (pe_print_edata): New function. Under private printing, this formats
5179         the edata section of a PE file.
5180         (pe_print_private_bfd_data): Added call to pe_print_edata.
5181
5182 Sun Dec  3 16:46:54 1995  Richard Earnshaw ([email protected])
5183
5184         * aout-arm.c (MY_swap_std_reloc_out): Use KEEPIT to get the symbol
5185         index, don't call stoi.
5186
5187 Fri Dec  1 14:46:51 1995  Ian Lance Taylor  <[email protected]>
5188
5189         * srec.c (srec_scan): Set lma as well as vma.
5190
5191         * ihex.c: New file; support for Intel Hex format.
5192         * targets.c (enum bfd_flavour): Add bfd_target_ihex_flavour.
5193         (ihex_vec): Declare.
5194         (bfd_target_vector): Always include ihex_vec.
5195         * bfd.c (struct _bfd): Add ihex_data field to tdata union.
5196         * Makefile.in: Rebuild dependencies.
5197         (BFD_LIBS): Add ihex.o
5198         (BFD_LIBS_CFILES): Add ihex.c.
5199         * bfd-in2.h: Rebuild.
5200
5201         * elf.c (assign_file_positions_for_segments): Sort the sections in
5202         each segment.
5203         (get_program_header_size): Return the right size if segment_map is
5204         not NULL.
5205         (copy_private_bfd_data): Don't bother to sort the sections.
5206
5207         * bfd.c (bfd_record_phdr): New function.
5208         * bfd-in.h (bfd_record_phdr): Declare.
5209         * bfd_in2.h: Rebuild.
5210
5211         * elf32-sparc.c (elf32_sparc_relocate_section): Remove bogus
5212         BFD_ASSERT.
5213
5214         * libbfd.c (bfd_malloc, bfd_realloc): New functions.
5215         (bfd_zmalloc): Return PTR, not char *.  Take size_t, not
5216         bfd_size_type.
5217         * libbfd-in.h (bfd_malloc, bfd_realloc): Declare.
5218         (bfd_zmalloc): Change declaration.
5219         * libbfd.h: Rebuild.
5220         * Many files: Use bfd_malloc and bfd_realloc rather than malloc
5221         and realloc.  Don't set bfd_error_no_memory if they fail.
5222
5223 Thu Nov 30 19:32:26 1995  Kim Knuttila  <[email protected]>
5224
5225         * coff-ppc.c: Added macros to tidy up toc cell treatment. Numerous
5226         uses as well. Added a new howto to deal with TOCREL16 relocs that 
5227         are TOCDEFN as well.
5228         (coff_ppc_relocate_section): Expanded treatment of ADDR32NB relocs
5229         to handle RVA relocs from dlltool.
5230         (ppc_coff_rtype2howto): TOCDEFN reloc addition.
5231         (coff_ppc_rtype_to_howto): TOCDEFN reloc addition.
5232         (ppc_coff_reloc_type_lookup): TOCDEFN reloc addition.
5233
5234         * coffcode.h (coff_set_alignment_hook): check idata$X sections 
5235         to get the right section alignment.
5236
5237 Thu Nov 30 16:48:18 1995  Ian Lance Taylor  <[email protected]>
5238
5239         * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
5240         p_paddr if p_paddr is zero.
5241         (make_mapping): Set includes_filehdr and includes_phdrs for first
5242         PT_LOAD segment.
5243         (map_sections_to_segments): Set includes_phdrs for PT_PHDR
5244         segment.
5245         (assign_file_positions_for_segments): Handle includes_filehdr and
5246         includes_phdrs.  Remove special handling of PT_PHDR and first
5247         PT_LOAD segments.
5248         (copy_private_bfd_data): Set includes_filehdr and includes_phdr
5249         when appropriate.  Remove special handling of PT_PHDR segment.
5250         Use a more complex condition for when a section is included in a
5251         segment to handle Solaris linker oddities.
5252
5253 Thu Nov 30 11:17:33 1995  Manfred Hollstein KS/EF4A 60/1F/110 #40283  <[email protected]>
5254
5255         * coff-m88k.c (howto_table): Reformatted for easier reading;
5256         special_function now points to new function m88k_special_reloc.
5257         (howto_hvrt16): Function previously used for handling HVRT16 relocs
5258         removed.
5259         (rtype2howto): Do not add reloc's r_offset to the addend, this will
5260         be done correctly by m88k_special_reloc.
5261         (reloc_processing): New function to be used by RELOC_PROCESSING.
5262         (RELOC_PROCESSING): Define to call reloc_processing.
5263
5264 Wed Nov 29 12:42:36 1995  Ian Lance Taylor  <[email protected]>
5265
5266         * peicode.h (pe_print_idata): Call malloc rather than xmalloc.
5267         (pe_print_pdata): Likewise.
5268
5269         * opncls.c (bfd_alloc_by_size_t): Set bfd_error_no_memory if
5270         obstack_alloc fails.
5271         (bfd_alloc_finish): Set bfd_error_no_memory if obstack_finish
5272         fails.
5273         * libbfd.c (bfd_zmalloc): Set bfd_error_no_memory if malloc fails.
5274         * Many files: don't set bfd_error_no_memory if one of the above
5275         routines fails.
5276
5277         * elf.c (assign_file_positions_for_segments): Don't adjust p_paddr
5278         if p_paddr_valid is set.
5279         (copy_private_bfd_data): New static function.
5280         (_bfd_elf_copy_private_section_data): Call copy_private_bfd_data.
5281
5282         * elf.c (assign_file_positions_for_segments): Fix case where extra
5283         program headers were allocated.
5284
5285         * elf.c (_bfd_elf_print_private_bfd_data): New function.
5286         * elf-bfd.h (_bfd_elf_print_private_bfd_data): Declare.
5287         * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define to
5288         _bfd_elf_print_private_bfd_data.
5289
5290         * coff-alpha.c (alpha_ecoff_swap_reloc_in): Don't abort if
5291         r_symndx is RELOC_SECTION_NONE for an ALPHA_R_IGNORE reloc.
5292         Change a RELOC_SECTION_LITA symndx to RELOC_SECTION_ABS.
5293         (alpha_ecoff_swap_reloc_out): Change RELOC_SECTION_ABS to
5294         RELOC_SECTION_LITA for ALPHA_R_IGNORE.
5295         (alpha_adjust_reloc_out): For ALPHA_R_IGNORE, don't change
5296         RELOC_SECTION_ABS to RELOC_SECTION_NONE.
5297
5298 Tue Nov 28 16:59:50 1995  Ian Lance Taylor  <[email protected]>
5299
5300         * elf-bfd.h (struct elf_obj_tdata): Add segment_map field.
5301         * elf.c (make_mapping): New static function.
5302         (map_sections_to_segments): New static function.
5303         (elf_sort_sections): New static function.
5304         (assign_file_positions_for_segments): New static function.
5305         (map_program_segments): Remove.
5306         (get_program_header_size): Remove sorted_hdrs, count, and
5307         maxpagesize parameters.  Simplify.
5308         (assign_file_positions_except_relocs): When generating an
5309         executable, use assign_file_positions_for_segments.
5310         (elf_sort_hdrs): Remove.
5311         (_bfd_elf_sizeof_headers): Remove eliminated parameters from call
5312         to get_program_header_size.
5313
5314 Mon Nov 27 12:27:46 1995  Ian Lance Taylor  <[email protected]>
5315
5316         * hp300hpux.c (MY(callback)): Set lma as well as vma.
5317
5318         * configure, config.in: Regenerate with autoconf 2.7.
5319
5320         * elf32-i386.c (elf_backend_plt_readonly): Set correctly, to 1.
5321         * elf32-sparc.c (elf_backend_plt_readonly): Set correctly, to 0.
5322
5323 Wed Nov 22 12:02:09 1995  Ian Lance Taylor  <[email protected]>
5324
5325         * ecoff.c (_bfd_ecoff_new_section_hook): Handle .rconst section.
5326         (ecoff_sec_to_styp_flags): Likewise.
5327         (_bfd_ecoff_styp_to_sec_flags): Handle STYP_RCONST.
5328         (ecoff_set_symbol_info): Handle scRConst.
5329         (ecoff_slurp_reloc_table): Handle RELOC_SECTION_RCONST.
5330         (ecoff_compute_section_file_positions): Handle .rconst section.
5331         (_bfd_ecoff_write_object_contents): Likewise.
5332         (ecoff_link_check_archive_element): Handle scRConst.
5333         (ecoff_link_add_externals): Likewise.
5334         (ecoff_link_write_external): Handle .rconst section.
5335         (ecoff_reloc_link_order): Likewise.
5336         * ecofflink.c (bfd_ecoff_debug_accumulate): Handle scRConst.
5337         * coff-alpha.c (alpha_convert_external_reloc): Handle .rconst
5338         section.
5339         (alpha_relocate_section): Handle RELOC_SECTION_RCONST.
5340
5341         * sunos.c (sunos_scan_dynamic_symbol): Only set written if the
5342         DEF_DYNAMIC flag is set.
5343
5344 Tue Nov 21 13:25:29 1995  Ken Raeburn  <[email protected]>
5345
5346         * host-aout.c: If TRAD_HEADER is defined, include it.
5347
5348 Tue Nov 21 13:03:57 1995  Ian Lance Taylor  <[email protected]>
5349
5350         * aclocal.m4 (AC_PROG_CC): Remove local definition.
5351         (BFD_BINARY_FOPEN): Require AC_CANONICAL_SYSTEM.
5352         (BFD_NEED_DECLARATION): New function.
5353         * configure.in: Use BFD_NEED_DECLARATION.
5354         * acconfig.h: Put NEED_DECLARATION_* in @TOP@ section.
5355         * configure, config.in: Rebuild with autoconf 2.6.
5356
5357         * xcofflink.c (bfd_xcoff_size_dynamic_sections): Clear
5358         special_sections before returning when called with a non XCOFF
5359         BFD.
5360
5361         * coffgen.c (coff_renumber_symbols): Sort common symbols with
5362         global symbols.
5363
5364         * coffcode.h (coff_compute_section_file_positions): Only pad the
5365         previous section to force file alignment when creating an
5366         executable.
5367
5368 Mon Nov 20 14:54:09 1995  Ian Lance Taylor  <[email protected]>
5369
5370         * coffcode.h (coff_compute_section_file_positions): If
5371         RS6000COFF_C, set up the .debug section.
5372
5373         * xcofflink.c (xcoff_link_input_bfd): Adjust the TOC anchor value
5374         if it is not large enough to accomodate the entire TOC area with
5375         signed 16 bit offsets.
5376         (xcoff_write_global_symbol): Handle negative TOC offsets in global
5377         linkage code.
5378         (_bfd_ppc_xcoff_relocate_section): Adjust relocations against a
5379         TOC anchor to use the TOC value used in the output file.
5380
5381 Sat Nov 18 18:01:41 1995  Ian Lance Taylor  <[email protected]>
5382
5383         * coffgen.c (_bfd_coff_get_external_symbols): Cast malloc return.
5384         (_bfd_coff_read_string_table): Likewise.
5385
5386 Sat Nov 18 19:43:04 1995  Richard Earnshaw ([email protected])
5387
5388         * pe-arm.c: Fix typos.
5389         * coff-arm.c: Likewise.
5390
5391 Fri Nov 17 16:22:04 1995  Kim Knuttila  <[email protected]>
5392
5393         * coff-ppc.c (list_ele): Added "cat"egory member.
5394         (record_toc): New category parameter (priv or pub).
5395         (ppc_record_toc_entry): Check to see if toc bounds exceeded.
5396         (ppc_process_before_allocation): Removed embrionic data-in-toc from
5397         the mainline. It addes extra toc cells in error.
5398         (ppc_coff_swap_sym_in_hook): Added some documentation.
5399         (dump_toc): Can now diagnose "virtual toc" chicanery.
5400
5401 Fri Nov 17 10:41:25 1995  Philippe De Muyter  <[email protected]>
5402
5403         * elf-bfd.h (struct elf_link_hash_table): Change type of
5404         dynsymcount and bucketcount fields from size_t to bfd_size_type.
5405
5406 Fri Nov 17 10:02:58 1995  Ian Lance Taylor  <[email protected]>
5407
5408         * coffcode.h (coff_pointerize_aux_hook): I960 version: don't
5409         pointerize C_LEAFSTAT or C_LEAFEXT entries.
5410
5411         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Only create
5412         DT_INIT and DT_FINI entries if the _init or _fini symbol is
5413         defined or mentioned in a regular file.
5414
5415 Thu Nov 16 15:16:42 1995  Kim Knuttila  <[email protected]>
5416
5417         * coff-ppc.c (ppc_record_data_in_toc_entry): new function
5418         (coff_ppc_relocate_section): Handle TOCDEFN attribute
5419         (coff_ppc_relocate_section): Correct REL24 handling
5420         (ppc_process_before_allocation): Correct TOCDEFN handling
5421
5422         * peicode.h (dir_names): Added name descriptions
5423
5424 Thu Nov 16 03:38:03 1995  Ken Raeburn  <[email protected]>
5425
5426         * VERSION: Updated to cygnus-2.6.
5427
5428 Wed Nov 15 19:30:07 1995  Ken Raeburn  <[email protected]>
5429
5430         * targets.c (m68k4knetbsd_vec): Declare.
5431
5432 Wed Nov 15 18:05:52 1995  Ian Lance Taylor  <[email protected]>
5433
5434         * targets.c (bfd_target): Change type of second argument to
5435         _bfd_print_private_bfd_data from void * to PTR.
5436         * libbfd-in.h (_bfd_generic_bfd_print_private_bfd_data): Cast
5437         using PTR rather than void *.
5438         * bfd-in2, libbfd.h: Rebuild.
5439         * peicode.h (pe_print_private_bfd_data): Change vfile from void *
5440         to PTR.
5441         * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define as
5442         _bfd_generic_bfd_print_private_bfd_data rather than casting
5443         bfd_true.
5444
5445 Wed Nov 15 04:09:14 1995  Ken Raeburn  <[email protected]>
5446
5447         * Makefile.in (.dep1): Fix stupid typo in last change.  Remove any
5448         "DO NOT DELETE" lines or blank lines that mkdep writes on some
5449         systems.
5450         (BFD_LIBS_CFILES, ALL_MACHINES_CFILES, BFD32_BACKENDS_CFILES,
5451         BFD64_BACKENDS_CFILES): New variables.
5452         (CFILES): Use them.
5453         
5454 Tue Nov 14 11:52:23 1995  Ian Lance Taylor  <[email protected]>
5455
5456         * peicode.h (coff_swap_aouthdr_out): For PPC PE, start isize at 0,
5457         not at the file position of the first section.
5458         * coffcode.h (coff_compute_section_file_positions): Avoid using
5459         unportable #elif.
5460         (coff_write_object_contents): When generating a PPC PE executable
5461         with no symbols, round up the file size to a COFF_PAGE_SIZE
5462         boundary.
5463         * cofflink.c (_bfd_coff_final_link): If there are no symbols,
5464         don't write out a string table.
5465
5466         * elf.c (bfd_section_from_shdr): When using a different section
5467         header, pass the new one to _bfd_elf_make_section_from_shdr.
5468         (elf_fake_sections): Don't set sh_info and sh_entsize fields.
5469         (elf_map_symbols): Add section VMA to symbol value when comparing
5470         against 0.
5471         (_bfd_elf_compute_section_file_positions): Only build symbol table
5472         if there are some symbols.  Set file offset of symtab and strtab
5473         sections.
5474         (assign_file_positions_except_relocs): Remove dosyms parameter.
5475         Change all callers.  Never set file offset of symtab and strtab
5476         sections.
5477         (_bfd_elf_copy_private_section_data): New function.
5478         (MAP_ONESYMTAB, MAP_DYNSYMTAB, MAP_STRTAB, MAP_SHSTRTAB): Define.
5479         (_bfd_elf_copy_private_symbol_data): New function.
5480         (swap_out_syms): Check for special mapping of st_shndx created by
5481         copy_private_symbol_data.
5482         * elfxx-target.h: Use new copy routines.
5483         * elf-bfd.h (_bfd_elf_copy_private_symbol_data): Declare.
5484         (_bfd_elf_copy_private_section_data): Declare.
5485
5486         * config.bfd (sh-*-*): Set targ_defvec to shcoff_vec.
5487
5488         * coffcode.h (coff_slurp_symbol_table): If COFF_WITH_PE, handle
5489         C_NT_WEAK.
5490
5491         * coff-sh.c (shlcoff_vec): Use _bfd_generic_archive_p, not
5492         _bfd_dummy_target, matching the recent change to archive
5493         recognition.
5494
5495 Mon Nov 13 13:24:38 1995  Ian Lance Taylor  <[email protected]>
5496
5497         * libbfd.c (bfd_get_file_window): Use casts to avoid doing
5498         arithmetic on PTR types.
5499
5500         * aout-target.h (MY(callback)): Set the lma of the sections.
5501
5502         * ecoff.c (ecoff_reloc_link_order): Turn a reloc against a defined
5503         symbol into a reloc against the section.
5504
5505 Mon Nov 13 07:31:35 1995  Kim Knuttila  <[email protected]>
5506
5507         * coff-ppc.c (ppc_coff_link_hash_entry): added support for inline
5508         glue for the relocs: IMGLUE and IFGLUE.
5509         (record_toc): new function - tracks toc contents
5510         (ppc_mark_symbol_as_glue): new function - supports the IMGLUE reloc
5511         (coff_ppc_relocate_section): Added support and fixes for IMGLUE/IFGLUE
5512         (ppc_coff_rtype2howto): removed invalid IMGLUE hack
5513         (coff_ppc_rtype_to_howto): removed invalid IMGLUE hack
5514         (ppc_record_toc_entry): Removed a debug define (duh)
5515
5516         * peicode.h (coff_swap_scnhdr_out): Fixed invalid strcmp for ".reldata"
5517         (pe_print_idata): New function - formats the idata section data
5518         (pe_print_pdata): New function - formats the pdata section data
5519         (pe_print_private_bfd_data): calls to above
5520
5521 Sun Nov 12 12:23:24 1995  Stan Shebs  <[email protected]>
5522
5523         * Makefile.in (bfd_libs_here, etc): Provide empty definitions.
5524         * coff-rs6000.c (rs6000coff_vec): Add conditional defines
5525         TARGET_SYM and TARGET_NAME for vector and BFD name.
5526         * coff-pmac.c (pmac_xcoff_vec): Remove.
5527         (TARGET_SYM, TARGET_NAME): Define.
5528         * coffcode.h (coff_set_arch_mach_hook) [POWERMAC]: Set the
5529         machine to 0, not all PowerMacs are 601s.
5530
5531 Fri Nov 10 12:10:14 1995  Ian Lance Taylor  <[email protected]>
5532
5533         * elfcode.h (elf_object_p): Read in any program headers.
5534         * elf.c (_bfd_elf_make_section_from_shdr): Adjust section lma
5535         based on the program headers, if any.
5536         (elf_fake_sections): Set sh_addr from the vma, not the lma.
5537         (map_program_segments): Set p_paddr of program headers based on
5538         the lma.
5539
5540 Thu Nov  9 13:01:31 1995  Ian Lance Taylor  <[email protected]>
5541
5542         * archive.c (bfd_generic_archive_p): Preserve tdata in case of
5543         failure.
5544
5545         * aoutx.h (NAME(aout,final_link)): Report a reasonable error when
5546         trying to do a relocateable link with a non-a.out object file.
5547
5548         * archive.c (bfd_generic_archive_p): Check the first object file
5549         in an archive even if target_defaulted is set.  If the object file
5550         has the wrong xvec, reject it.
5551
5552         * aoutx.h (NAME(aout,set_section_contents)): If a section can not
5553         be represented, report the name via _bfd_error_handler.
5554         (translate_to_native_sym_flags): Likewise.
5555         * elf32-mips.c (mips_elf_final_link): Likewise.
5556         * oasys.c (oasys_write_sections): Likewise.
5557
5558         * coffcode.h (coff_set_alignment_hook): Write RS6000COFF_C version
5559         which checks for STYP_OVRFLO sections.
5560         (coff_compute_section_file_positions): If RS6000COFF_C, handle
5561         reloc and lineno count overflows.
5562         (coff_write_object_contents): Call coff_count_linenumbers before
5563         coff_compute_section_file_positions.  If RS6000COFF_C, handle
5564         reloc and lineno count overflows.
5565         * xcofflink.c (_bfd_xcoff_bfd_final_link): Count line numbers and
5566         relocs before dealing with .pad sections.  Count overflow section
5567         headers when handling .pad sections.
5568
5569         * coffcode.h (coff_write_object_contents): Set a.out vstamp to 1
5570         if RS6000COFF_C.
5571
5572         * xcofflink.c (XCOFF_DESCRIPTOR): Define.
5573         (struct xcoff_link_hash_table): Add descriptor_section and
5574         special_sections fields.
5575         (_bfd_xcoff_bfd_link_hash_table_create): Initialize new fields.
5576         (xcoff_link_add_symbols): Set linkage section alignment.  Create
5577         descriptor section.  Check for magic symbol names (_text, etc.),
5578         and record them in special_sections if found.  Set
5579         XCOFF_DESCRIPTOR flag for a function descriptor, and set its
5580         descriptor field to point back to the function code symbol.
5581         (xcoff_sweep): Always mark the special descriptor_section.
5582         (bfd_xcoff_export_symbol): Check whether the symbol might be a
5583         function descriptor, and mark it if it is.
5584         (bfd_xcoff_size_dynamic_sections): Add new special_sections
5585         parameter, and fill it in.  Allocate space for the descriptor
5586         section.
5587         (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR flag when defining
5588         global linkage code.  If an undefined function descriptor is
5589         exported, arrange to define it.  Warn about any other undefined
5590         exported symbol.
5591         (_bfd_xcoff_bfd_final_link): Write out the descriptor section.
5592         (xcoff_write_global_symbol): Create a function descriptor when
5593         necessary.
5594         * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
5595         * bfd-in2.h: Rebuild.
5596
5597 Thu Nov  9 08:40:23 1995  Kim Knuttila  <[email protected]>
5598
5599         * coff-ppc.c (ppc_coff_link_hash_entry): new types for hashing
5600         (ppc_coff_link_hash_table): new types for hashing
5601         (ppc_coff_link_hash_newfunc): hash entry constructor
5602         (ppc_coff_link_hash_table_init): hash table initializer
5603         (ppc_coff_link_hash_table_create): hash table constructor
5604         (ppc_record_toc_entry): changed references to hash table
5605         (coff_ppc_relocate_section): changed references to hash table
5606
5607         * libcoff-in.h (coff_link_hash_entry): removed toc_offset
5608         * libcoff.h: Rebuild
5609
5610         * cofflink.c (_bfd_coff_link_hash_newfunc): removed toc_offset init
5611         (coff_link_add_symbols): removed toc_offset init
5612
5613 Thu Nov  9 04:00:38 1995  Ken Raeburn  <[email protected]>
5614
5615         * Makefile.in (.dep1): Make sure the file mkdep is to write exists
5616         first.
5617
5618         * configure.in: Added new option --with[out]-mmap.  Set USE_MMAP
5619         if it is given and mmep is available.
5620         * acconfig.h: Undef USE_MMAP.
5621         * configure, config.in: Regenerated.
5622         * aoutx.h: If USE_MMAP is not defined, do all symbol and string
5623         table handling the old way.
5624         (aout_get_external_symbols): Don't complain if last byte of string
5625         table is nonzero.
5626         * libbfd.c [HAVE_MADVISE]: Include sys/types.h and sys/mman.h.
5627         (bfd_free_window) [! USE_MMAP]: Don't define.
5628         (bfd_get_file_window,
5629         _bfd_generic_get_section_contents_in_window) [! USE_MMAP]: Abort.
5630
5631 Wed Nov  8 20:03:44 1995  Eric Freudenthal <[email protected]>
5632
5633         * coff-a29k.c (SIGN_EXTEND_HWORD): Use ~0xffff rather than
5634         0xffff0000.
5635
5636 Wed Nov  8 11:31:11 1995  Ian Lance Taylor  <[email protected]>
5637
5638         * coff-a29k.c (a29k_reloc): Change handling of R_IREL reloc to be
5639         compatible with AMD generated COFF files.  Try to support both AMD
5640         and GNU formats simultaneously.
5641         (coff_a29k_relocate_section): Likewise.
5642
5643         * libbfd.c (bfd_get_file_window): Change writable parameter from
5644         int to boolean; update all callers.  Pass MAP_SHARED if not
5645         writable--it's required on Solaris.  Cast fprintf argument to
5646         avoid warning.
5647         * bfd-in.h (bfd_get_file_window): Update declaration.
5648         * bfd-in2.h: Rebuild.
5649         * aoutx.h: Update calls to bfd_get_file_window.
5650
5651         * xcofflink.c (XCOFF_DEF_DYNAMIC): Rename from XCOFF_REF_DYNAMIC.
5652         Change all uses.
5653         (xcoff_swap_ldhdr_in): New static function.
5654         (xcoff_swap_ldsym_in): New static function.
5655         (xcoff_find_reloc): Handle the case of a single reloc correctly.
5656         (xcoff_link_add_symbols): If we just created a descriptor, pass it
5657         to _bfd_generic_link_add_one_symbol, to save a hash lookup.
5658         Handle XTY_ER/XMC_XO symbols correctly.
5659         (xcoff_link_add_dynamic_symbols): Rewrite to read .loader symbols
5660         rather than normal symbol table.
5661         (bfd_xcoff_import_symbol): It's not an error if the symbol is
5662         already defined with the same absolute value.
5663         (xcoff_mark): When considering called symbols, check whether the
5664         descriptor is from a dynamic object, rather than the symbol
5665         itself.
5666         (xcoff_build_ldsyms): Likewise.
5667
5668         * libbfd.c (bfd_get_file_window): Change return type to boolean.
5669         Cast realloc and malloc return values.  If malloc or realloc fail,
5670         set bfd_error_no_memory.
5671         * bfd-in.h (bfd_get_file_window): Change type to boolean.
5672         * bfd-in2.h: Rebuild.
5673
5674 Tue Nov  7 11:53:48 1995  Kim Knuttila  <[email protected]>
5675
5676         * coff-ppc.c (ppc_record_toc_entry): new function.
5677         (in_reloc_p): changed return value.
5678         (coff_ppc_relocate_section): much rework.
5679         (ppc_allocate_toc_section): new function.
5680         (ppc_process_before_allocation): new function.
5681         (ppc_coff_swap_sym_in_hook): new function.
5682
5683         * cofflink.c (_bfd_coff_link_hash_newfunc): initialize toc_offset.
5684         (coff_link_add_symbols): initialize toc_offset.
5685
5686         * peicode.h (coff_swap_sym_in): Added coff_swap_sym_in_hook
5687         (coff_swap_aouthdr_out): Added more sections to the data
5688         dictionary for the pe file header. Also changed linker version
5689         number on the ppc side.
5690         (dir_names): small improvements to the dictionary printing.
5691         (pe_mkobject_hook): save the file level flags.
5692
5693         * libcoff-in.h (coff_link_hash_entry): added toc_offset field
5694         (pe_tdata): added real_flags field
5695         (coff_tdata): added local_toc_sym_map and access macro
5696
5697         * libcoff.h (coff_link_hash_entry): added toc_offset field
5698         (pe_tdata): added real_flags field
5699         (coff_tdata): added local_toc_sym_map and access macro
5700
5701         * coffcode.h (coff_set_alignment_hook): added hook for PE.
5702         (coff_mkobject): init for local_toc_sym_map
5703         (coff_write_object_contents): set the internal_a.magic to
5704         IMAGE_NT_OPTIONAL_HDR_MAGIC which appears to be what other
5705         ppc compilers use.
5706
5707 Tue Nov  7 13:48:58 1995  Ian Lance Taylor  <[email protected]>
5708
5709         * ecofflink.c (_bfd_ecoff_locate_line): Keep looking through stabs
5710         entries until both the line number address and the function name
5711         address are too large.
5712
5713         * configure.in: Call AC_CHECK_PROG to find and cache AR.
5714         * configure: Rebuilt.
5715
5716         * aclocal.m4 (BFD_CC_FOR_BUILD): Don't define CC_FOR_BUILD if it
5717         is defined in the environment.
5718
5719 Tue Nov  7 10:57:24 1995  Jeffrey A Law  ([email protected])
5720
5721         * som.c (som_get_section_contents_in_window): Define to use
5722         generic version.
5723
5724 Mon Nov  6 17:13:15 1995  Harry Dolan  <[email protected]>
5725
5726         * coff-i860.c: New file, based on coff-i386.c.
5727         * cpu-i860.c: New file, based on cpu-i386.c.
5728         * hosts/i860mach3.h: New file, based on hosts/i386mach3.h.
5729         * config.bfd (i860-*-mach3*, i860-*-osf1*, i860-*-coff*): New
5730         targets, using i860coff_vec.
5731         * configure.in (i860-*-mach3*, i860-*-osf1*): New hosts, using
5732         trad-core.o and hosts/i860mach3.h.
5733         (i860coff_vec): Use coff-i860.o and cofflink.o.
5734         * configure: Rebuild.
5735         * Makefile.in: Rebuild dependencies.
5736         (ALL_MACHINES): Add cpu-i860.o.
5737         (BFD32_BACKENDS): Add coff-i860.o.
5738         (CFILES): Add cpu-i860.c and coff-i860.c.
5739         * targets.c (i860coff_vec): Declare.
5740         (bfd_target_vector): Add &i860coff_vec. 
5741         * archures.c (bfd_i860_arch): Declare.
5742         (bfd_archures_list): Add &bfd_i860_arch.
5743         * coffcode.h (coff_set_arch_mach_hook): Handle I860 magic number.
5744         (coff_set_flags): Handle bfd_arch_i860.
5745         (coff_write_object_contents): Handle I860 a.out magic number.
5746
5747 Mon Nov  6 14:34:07 1995  Ian Lance Taylor  <[email protected]>
5748
5749         * xcofflink.c (xcoff_link_add_symbols): Set the alignment power of
5750         the created .tc section to 2.
5751         (xcoff_mark): Don't keep a .loader reloc for a call to an
5752         undefined symbol when creating a shared library.
5753         (xcoff_build_ldsyms): When creating a shared library, generate
5754         global linkage code for a call to an undefined symbol.
5755
5756 Sun Nov  5 21:44:13 1995  Ken Raeburn  <[email protected]>
5757
5758         * Makefile.in (CFILES): Rebuild list from BFD_LIBS, ALL_MACHINES,
5759         BFD32_BACKENDS, BFD64_BACKENDS.
5760         (.dep1): Put mkdep output in a separate file.
5761         Rebuilt dependencies.
5762
5763         * ecoff.c (_bfd_ecoff_slurp_armap): Cast _bfd_read_ar_hdr return
5764         value.
5765
5766         Permit use of mmap when available:
5767
5768         * configure.in: Check for mmap, madvise, mprotect.
5769         * config.in, configure: Regenerated.
5770
5771         * libbfd.c (struct _bfd_window_internal): Define type.
5772         (bfd_init_window, bfd_free_window, bfd_get_file_window): New
5773         functions.
5774         (ok_to_map): New static variable for debugging.
5775         (_bfd_generic_get_section_contents_in_window): New function.
5776         * bfd-in.h (bfd_window_internal): Declare type.
5777         (bfd_window): Define type.
5778         (bfd_init_window, bfd_free_window, bfd_get_file_window): Declare.
5779         * libbfd-in.h (_bfd_generic_get_section_contents_in_window):
5780         Declare.
5781
5782         * libaout.h (struct aoutdata): Add two window fields.
5783         (obj_aout_sym_window, obj_aout_string_window): New macros.
5784         * aoutx.h (some_aout_object_p): Initialize windows.
5785         (aout_get_external_symbols): Get symbol data and strings in
5786         windows instead of explicitly allocated buffers.
5787         (slurp_symbol_table): Free window instead of memory.
5788         (bfd_free_cached_info): Release windows instead of freeing storage
5789         directly.
5790         (aout_link_free_symbols): Ditto.
5791
5792         * targets.c (bfd_target): Add new field for
5793         get_section_contents_in_window.
5794         (BFD_JUMP_TABLE_GENERIC): Updated.
5795         * aout-adobe.c, aout-target.h, binary.c, bout.c, coff-alpha.c,
5796         coff-mips.c, elfxx-target.h, i386msdos.c, i386os9k.c, ieee.c,
5797         libcoff-in.h, oasys.c, srec.c, tekhex.c, versados.c: Added new
5798         macros for get_section_contents_in_window field.
5799
5800 Sat Nov  4 12:23:26 1995  Fred Fish  <[email protected]>
5801
5802         * core.c: Renamed to corefile.c
5803         * makefile.dos (OBJS): Change core.o to corefile.o
5804         * Makefile.in (CFILES, BFD_LIBS): Use corefile.c instead of core.c
5805         
5806 start-sanitize-gm
5807 Sat Nov  4 10:16:54 1995  Stu Grossman  ([email protected])
5808
5809         * config.bfd (mips*-*-magic*):  Add bfd_elf32_bigmips_vec to
5810         targ_selvecs to allow debugging under Irix-5 native.
5811
5812 end-sanitize-gm
5813 Fri Nov  3 15:54:59 1995  Ian Lance Taylor  <[email protected]>
5814
5815         * xcofflink.c (xcoff_link_add_symbols): Rename local variable sub
5816         to o.  Clobber and restore the list of new csects around the call
5817         to _bfd_generic_link_add_one_symbol, in case it wants to report a
5818         linker error and the linker wants to read the symbol table.  Reset
5819         the line number count of a real section even if it has no relocs.
5820         (_bfd_xcoff_bfd_final_link): If shared, set the DYNAMIC flag.
5821
5822         * coffgen.c (_bfd_coff_read_string_table): Warn if the string size
5823         is too small.
5824
5825 Thu Nov  2 23:16:39 1995  Ian Lance Taylor  <[email protected]>
5826
5827         * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Don't warn about
5828         an undefined symbol in a shared link.
5829
5830         * linker.c (_bfd_generic_link_add_one_symbol): Correct type of
5831         oldtype from bfd_link_order_type to bfd_link_hash_type.  From
5832         [email protected] (Philippe De Muyter).
5833
5834 Wed Nov  1 14:26:02 1995  Manfred Hollstein KS/EF4A 60/1F/110 #40283  <[email protected]>
5835
5836         * coff-m88k.c (rtype2howto): New static function.
5837         (RTYPE2HOWTO): Use it rather than a macro definition.
5838
5839         * coffcode.h (coff_write_object_contents): set internal_a.magic
5840         to PAGEMAGICPEXECPAGED #if defined (M68) && !defined (LYNXOS).
5841
5842         * configure.in: m68*-motorola-sysv* does not use ptrace-core.o;
5843         define TRAD_HEADER to new file hosts/delta68.h.
5844         m88*-motorola-sysv*, however, does use ptrace-core.o.
5845         * hosts/delta68.h: New file.
5846
5847         * ptrace-core.c (ptrace_unix_core_file_p): change bfd_zmalloc to
5848         bfd_zalloc; provide proper parm abfd to calls to bfd_zalloc.
5849
5850 Wed Nov  1 13:51:54 1995  Ken Raeburn  <[email protected]>
5851
5852         * i386linux.c (MY(vec)): Declare before use.
5853
5854 Wed Nov  1 11:45:07 1995  Ian Lance Taylor  <[email protected]>
5855
5856         * reloc16.c (bfd_coff_reloc16_get_relocated_section_contents):
5857         Pass input_bfd, not in_bfd, to bfd_coff_reloc16_extra_cases.
5858
5859         * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
5860         BFD is not of the right type.
5861         (bfd_elf_get_needed_list): Likewise.
5862         * i386linux.c (bfd_linux_size_dynamic_sections): Likewise.
5863         * sunos.c (bfd_sunos_get_needed_list): Likewise.
5864         * xcofflink.c (XCOFF_XVECP): Define.
5865         (bfd_xcoff_link_record_set): Don't do anything if the BFD is not
5866         of the right type.
5867         (bfd_xcoff_import_symbol): Likewise.
5868         (bfd_xcoff_export_symbol): Likewise.
5869         (bfd_xcoff_link_count_reloc): Likewise.
5870         (bfd_xcoff_record_link_assignment): Likewise.
5871         (bfd_xcoff_size_dynamic_sections): Likewise.
5872
5873         * sunos.c (sunos_scan_ext_relocs): Only check the reloc symbol
5874         table index against the number of symbols for a base relative
5875         reloc.
5876
5877         * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Change from macro to
5878         static function.
5879         * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Set
5880         full_aouthdr flag here...
5881         (_bfd_xcoff_bfd_final_link): ...not here.
5882
5883 Tue Oct 31 12:52:02 1995  Fred Fish  <[email protected]>
5884
5885         * libelf.h:  Rename to elf-bfd.h to avoid conflict with
5886         systems that have a system <libelf.h>.
5887         * Makefile.in: Globally replace libelf.h with elf-bfd.h.
5888         * bfd.c, elf.c, elf32-arc.c, elf32-gen.c, elf32-hppa.c,
5889         elf32-hppa.h, elf32-i386.c, elf32-i860.c, elf32-m68k.c,
5890         elf32-m88k.c, elf32-mips.c, elf32-ppc.c, elf32-sparc.c,
5891         elf64-gen.c, elf64-sparc.c, elfcode.h, elflink.c,
5892         elfxx-target.h: Include elf-bfd.h rather than libelf.h.
5893         * elfxx-target.h: Change libelf.h reference to elf-bfd.h.
5894
5895 Tue Oct 31 15:30:07 1995  David Mosberger-Tang  <[email protected]>
5896
5897         * ecoff.c (ecoff_set_symbol_info): Add new parameter weak.  If
5898         set, set BSF_WEAK in symbol.  Change all callers.
5899         (ecoff_get_extr): Set weakext based on BSF_WEAK.
5900         (ecoff_link_add_externals): If weakext is set, pass BSF_WEAK to
5901         _bfd_generic_link_add_one_symbol.
5902         (ecoff_indirect_link_order): Check that the section tdata relocs
5903         are not NULL before using them.
5904
5905         * configure.in (alpha*-*-linux*): Set COREFILE to trad-core.o and
5906         define TRAD_HEADER as hosts/alphalinux.h.
5907         * configure: Rebuild.
5908         * hosts/alphalinux.h: New file.
5909         * trad-core.c (trad_unix_core_file_p): Cast u.u_ar0 to bfd_vma,
5910         not int.
5911
5912 Tue Oct 31 12:34:11 1995  Ian Lance Taylor  <[email protected]>
5913
5914         * coffcode.h (coff_slurp_symbol_table): Accept C_BCOMM and
5915         C_ECOMM storage classes.
5916
5917         * xcofflink.c (xcoff_mark_symbol): New static function, broken out
5918         of xcoff_mark.
5919         (xcoff_mark): Call xcoff_mark_symbol.
5920         (bfd_xcoff_export_symbol): Call xcoff_mark_symbol.
5921         (bfd_xcoff_link_count_reloc): Call xcoff_mark_symbol rather than
5922         doing it by hand.
5923         (xcoff_build_ldsyms): Build a .loader symbol for an export symbol.
5924
5925 Mon Oct 30 14:53:48 1995  Ian Lance Taylor  <[email protected]>
5926
5927         * xcofflink.c (struct xcoff_final_link_info): Add new line_filepos
5928         field.
5929         (xcoff_find_reloc): New static function.
5930         (xcoff_link_add_symbols): Use it.
5931         (_bfd_xcoff_bfd_final_link): Set finfo.line_filepos.
5932         (xcoff_link_input_bfd): Handle C_BINCL and C_EINCL.  Don't
5933         relocate the value of C_DECL.
5934
5935         * elf.c (elf_fake_sections): Remove bogus BFD_ASSERT.
5936
5937 Sat Oct 28 01:25:34 1995  steve chamberlain  <[email protected]>
5938
5939         * cofflink.c (_bfd_coff_generic_relocate_section): Make
5940         callback decide what goes in .relocs.
5941         * pe[i]-i386.c (TARGET_UNDERSCORE): Define.
5942         * peicode.h (pe_mkobject_hook): Only copy aouthdr if
5943         there is one.
5944
5945 Sat Oct 28 01:51:02 1995  Ian Lance Taylor  <[email protected]>
5946
5947         * xcofflink.c (xcoff_link_add_symbols): Handle csects in the
5948         absolute section.
5949
5950 Fri Oct 27 18:14:39 1995  Ian Lance Taylor  <[email protected]>
5951
5952         * xcofflink.c: More improvements, mostly to fix handling of
5953         constructors and a few other special cases.
5954         * coff-rs6000.c (rs6000coff_vec): Set symbol_leading_char back to
5955         zero, reverting yesterday's change.
5956         * bfd-in.h (bfd_xcoff_link_record_set): Declare.
5957         (bfd_xcoff_link_count_reloc): Declare.
5958         (bfd_xcoff_record_link_assignment): Declare.
5959         * bfd-in2.h: Rebuild.
5960
5961 Fri Oct 27 14:42:15 1995  Niklas Hallqvist  <[email protected]>
5962
5963         * PORTING, aout-arm.c, aout-encap.c, aout-target.h,
5964         aoutx.h, gen-aout.c, host-aout.c, hp300bsd.c, i386aout.c
5965         i386bsd.c, i386dynix.c, i386linux.c, i386lynx.c, i386mach3.c,
5966         i386netbsd.c, m68klynx.c, m88kmach3.c, mipsbsd.c, newsos3.c,
5967         ns32knetbsd.c, pc532-mach.c, riscix.c, sparclynx.c, sparcnetbsd.c:
5968         Change PAGE_SIZE to TARGET_PAGE_SIZE.
5969
5970         * m68knetbsd.c: Ditto as well as add support for the m68k4k object
5971         format.
5972
5973         * netbsd.h: Double ditto (incl. m68k4k support).  NetBSD's text
5974         segments includes the a.out header.  See to that the magic number
5975         *always* is big-endian.
5976
5977         * config.bfd: Add m68*-hp*-netbsd* case.  Cross-pollinate m68k and
5978         m68k4k NetBSD configurations.
5979
5980         * configure.in, configure: Separate i386 & mips NetBSD
5981         configurations from other BSD ones.  Don't assume DEC is the only
5982         thing NetBSD/mips run on.  Add {m68k,ns32k,sparc}-*-netbsd*
5983         configurations.  Add support for m68k4k NetBSD object format.
5984
5985         * libaout.h: Added M_68K4K_NETBSD magic.
5986
5987         * m68k4knetbsd.c: New file.
5988         
5989         * hosts/{m68k,sparc}nbsd.h: Don't define HOST_BIG_ENDIAN_P.
5990
5991         * hosts/nbsd.h: Define HOST_BIG_ENDIAN_P according to
5992         <machine/endian.h>.
5993
5994         * hosts/mipsnbsd.h: New file.
5995         
5996 start-sanitize-gm
5997 Fri Oct 27 09:41:51 1995  Stu Grossman  ([email protected])
5998
5999         * config.bfd:  Add config stuff for mips*-*-magic* to set
6000         targ_defvec to ecoff_big_vec.
6001
6002 end-sanitize-gm
6003 Thu Oct 26 14:16:47 1995  Ian Lance Taylor  <[email protected]>
6004
6005         * xcofflink.c: Numerous changes to get closer to a working XCOFF
6006         linker.
6007         * libcoff-in.h (struct xcoff_tdata): Add full_aouthdr,
6008         toc_section, and entry_section fields.
6009         (struct xcoff_section_tdata): Remove ldrel_count field.
6010         * libcoff.h: Rebuild.
6011         * coffcode.h (coff_mkobject_hook): Initialize new xcoff_data
6012         fields.
6013         (coff_compute_section_file_positions): If RS6000COFF_C, generate
6014         full a.out header if full_aouthdr is set in xcoff_data.
6015         (coff_write_object_contents): Likewise.  Set o_snentry and o_sntoc
6016         based on sections stored in xcoff_data.
6017         * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy new xcoff_data
6018         fields.
6019         (xcoff_reloc_type_lookup): Handle BFD_RELOC_CTOR.
6020         (rs6000coff_vec): Set symbol_leading_char to '.'.
6021         * coffgen.c (coff_get_symbol_info): If fix_value is set, fix the
6022         value stored in ret rather than returning a pointer value.
6023         
6024 Wed Oct 25 23:10:39 1995  Michael Meissner  <[email protected]>
6025
6026         * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Remove MAC
6027         format for now.
6028
6029 Wed Oct 25 16:19:27 1995  Jeffrey A Law  ([email protected])
6030
6031         * som.c (som_slurp_string_table): Allocate the strings with malloc
6032         since they're free'd by free_cached_info.
6033         (som_slurp_symbol_table): Similarly for the symbol table.
6034
6035 Wed Oct 25 14:59:22 1995  Per Bothner  <[email protected]>
6036
6037         * Makefile.in (diststuff):  Don't make headers.
6038
6039 Wed Oct 25 11:32:54 1995  Ian Lance Taylor  <[email protected]>
6040
6041         * Makefile.in: Rebuild dependencies.
6042
6043         * sunos.c (bfd_sunos_record_link_assignment): Don't do anything if
6044         output_bfd is not SunOS.
6045         (bfd_sunos_size_dynamic_sections): Likewise.  Don't scan relocs of
6046         non-SunOS input files.
6047
6048         * xcofflink.c: Extensive changes to support linking shared objects
6049         and generating a .loader section.
6050         * libcoff-in.h (struct xcoff_tdata): Add import_file_id field.
6051         (struct xcoff_section_tdata): Add lineno_count, first_symndx,
6052         last_symndx, and ldrel_count fields.
6053         * libcoff.h: Rebuild.
6054         * coff-rs6000.c (xcoff_howto_table): Correct reloc names.
6055         * coffcode.h (styp_to_sec_flags): Don't set any flags if STYP_PAD
6056         is set.
6057         * bfd-in.h (bfd_xcoff_import_symbol): Declare.
6058         (bfd_xcoff_export_symbol): Declare.
6059         (bfd_xcoff_size_dynamic_sections): Declare.
6060         * bfd-in2.h: Rebuild.
6061
6062 Tue Oct 24 17:44:20 1995  Stan Shebs  <[email protected]>
6063
6064         * configure.in: Add xcofflink.o to pmac_xcoff_vec.
6065         * configure: Rebuild.
6066         * mpw-config.in: Add xcofflink.c.o to powerpc-apple-macos.
6067         * coff-pmac.c: Include coff-rs6000.c instead of duplicating its
6068         contents.
6069         (pmac_xcoff_vec): Update to use new xcoff support.
6070         * coff-rs6000.c (xcoff_generic_stat_arch_elt): Make static.
6071         (xcoff_write_armap): Declare buf as unsigned char.
6072         * xcofflink.c (xcoff_link_add_symbols): Declare a local as PTR.
6073
6074         * mpw-make.sed: Generalize subdir_do edit.
6075         
6076 Tue Oct 24 10:25:01 1995  Jeffrey A Law  ([email protected])
6077
6078         * hppabsd-core.c (make_bfd_asection): Initialize asect->filepos
6079         correctly.  Don't initialize asect->vma.
6080
6081 Fri Oct 20 13:23:48 1995  Ken Raeburn  <[email protected]>
6082
6083         * opncls.c (_bfd_new_bfd): If _bfd_chunksize wasn't preset, use
6084         something a little less than the page size.
6085
6086 Thu Oct 19 13:06:09 1995  Ian Lance Taylor  <[email protected]>
6087
6088         * coff-i960.c (coff_i960_adjust_symndx): Clear *adjustedp.
6089
6090 Wed Oct 18 16:20:08 1995  steve chamberlain  <[email protected]>
6091
6092         * coff-i386.c (coff_i386_reloc_type_lookup): New.
6093         * coffcode.h (coff_write_object_contents): If .bss is before
6094         .data us that as data_start.
6095         * cofflink.c (_bfd_coff_generic_relocate_section): Get reloc
6096         calc correct.
6097         * peicode.h (add_data_entry): Use _cooked_size of data directory.
6098         (coff_swap_outhdr_out): Hardwire in version number.
6099         
6100 Wed Oct 18 16:50:54 1995  Ken Raeburn  <[email protected]>
6101
6102         * sunos.c (sunos_add_dynamic_symbols): Rename local variables
6103         major and minor to *_vno, since the former are also macros in
6104         SunOS header files.  Cast result of bfd_alloc to appropriate
6105         type.
6106
6107         * coffgen.c (coff_find_nearest_line): Cast used_by_bfd value
6108         before assigning to sec_data.
6109
6110 Wed Oct 18 13:25:17 1995  Ian Lance Taylor  <[email protected]>
6111
6112         * ecoff.c (_bfd_ecoff_find_nearest_line): The offset argument is
6113         now relative to the section, not absolute.
6114         * ecofflink.c (_bfd_ecoff_locate_line): Use the right symbol to
6115         get the file name when there is a N_SO directory name.  When
6116         handling stabs, remember that section->vma was added to the
6117         offset.
6118
6119 Tue Oct 17 18:24:54 1995  Ian Lance Taylor  <[email protected]>
6120
6121         * sunos.c (struct sunos_link_hash_table): Add needed field.
6122         (sunos_link_hash_table_create): Call bfd_release, not free.
6123         (sunos_link_hash_table_create): Initialize needed field.
6124         (sunos_add_dynamic_symbols): Record needed objects.
6125         (bfd_sunos_get_needed_list): New function.
6126         * bfd-in.h (bfd_sunos_get_needed_list): Declare.
6127         * bfd-in2.h: Rebuild.
6128
6129 Mon Oct 16 14:43:59 1995  steve chamberlain  <[email protected]>
6130
6131         * libcoff-in.h (pe_data_type.in_reloc_p): New.
6132
6133 Mon Oct 16 10:52:50 1995  Ian Lance Taylor  <[email protected]>
6134
6135         * bfd-in.h (struct bfd_link_needed_list): Rename from
6136         bfd_elf_link_needed_list.
6137         * bfd-in2.h: Rebuild.
6138         * elf.c, elflink.h, libelf.h: Corresponding changes.
6139
6140         Add start at AIX linker support; no shared libraries yet.
6141         * xcofflink.c: New file.
6142         * configure.in (rs600coff_vec): Use xcofflink.o.
6143         * configure: Rebuild.
6144         * libcoff-in.h (struct xcoff_tdata): Add csects and debug_indices
6145         fields.
6146         (struct xcoff_section_tdata): Define.
6147         (xcoff_section_data): Define macro.
6148         (_bfd_xcoff_bfd_link_hash_table_create): Declare.
6149         (_bfd_xcoff_bfd_link_add_symbols): Declare.
6150         (_bfd_xcoff_bfd_final_link): Declare.
6151         (_bfd_ppc_xcoff_relocate_section): Declare.
6152         * libcoff.h: Rebuild.
6153         * coff-rs6000.c: Clean up a bit.
6154         (xcoff_mkobject): Default modtype to 1L, not RE.  Initialize
6155         cputype, csects, and debug_indices.
6156         (xcoff_copy_private_bfd_data): Copy cputype.
6157         (xcoff_howto_table): Rename from rs6000coff_howto_table.
6158         (xcoff_rtype2howto): Rename from rs6000coff_rtype2howto.
6159         (xcoff_reloc_type_lookup): Rename from
6160         rs6000coff_reloc_type_lookup.
6161         (coff_relocate_section): Define.
6162         (_bfd_xcoff_sizeof_headers): Define.
6163         (_bfd_xcoff_bfd_get_relocated_section_contents): Define.
6164         (_bfd_xcoff_bfd_relax_section): Define.
6165         (_bfd_xcoff_bfd_link_split_section): Define.
6166         (rs6000coff_vec): For BFD_JUMP_TABLE_LINK, use _bfd_xcoff, not
6167         coff.
6168         * coffcode.h (coff_compute_section_file_positions): If AIX,
6169         increment sofar by SMALL_AOUTSZ if not executable.
6170         (coff_write_object_contents): If AIX, always output an a.out
6171         header; if not executable, header size of SMALL_AOUTSZ.
6172         * hash.c (struct bfd_strtab_hash): Add xcoff field.
6173         (_bfd_stringtab_init): Initialize xcoff field.
6174         (_bfd_xcoff_stringtab_init): New function.
6175         (_bfd_stringtab_add): In XCOFF mode, leave two bytes for length.
6176         (_bfd_stringtab_emit): In XCOFF mode, write out length.
6177         * libbfd-in.h (_bfd_xcoff_stringtab_init): Declare.
6178         * libbfd.h: Rebuild.
6179         * Makefile.in: Rebuild dependencies.
6180         (BFD32_BACKENDS): Add xcofflink.o.
6181         (CFILES): Add xcofflink.c.
6182
6183         * elf32-mips.c (mips_elf_symbol_processing): Set SEC_ALLOC, not
6184         SEC_NO_FLAGS, for .acommon section.  From Peter Schauer
6185         <[email protected]>.
6186
6187 Sat Oct 14 21:36:02 1995  Michael Meissner  <[email protected]>
6188
6189         * coff-ppc.c (in_reloc_p): Add, clone from coff-i386.c.
6190
6191 Fri Oct 13 17:48:43 1995  Ken Raeburn  <[email protected]>
6192
6193         * acconfig.h (HAVE_SYS_PROCFS_H): Undef, with comment.
6194         * config.in: Regenerated.
6195
6196         * opncls.c (getpagesize) [!HAVE_GETPAGESIZE]: Define as 2048.
6197         (_bfd_chunksize): New variable.
6198         (_bfd_new_bfd): Set it to getpagesize() if negative, and use it
6199         for obstack chunk size.
6200         * configure.in: Check for getpagesize.
6201         * configure: Regenerated.
6202
6203         Mon Sep 25 22:49:32 1995  Andreas Schwab  <[email protected]>
6204
6205         * trad-core.c (rawptr): Make it a local variable of
6206         ptrace_unix_core_file_p.
6207
6208 Fri Oct 13 11:22:01 1995  steve chamberlain  <[email protected]>
6209
6210         * coff-arm.c (in_reloc_p): New.
6211         * coff-i386.c (in_reloc_p): New.
6212         * coffcode.h: Allways include peicode.h if COFF_WITH_PE.
6213         (coff_write_object_contents): Only set has_reloc_section
6214         if PE_IMAGE.
6215         * cofflink.c (_bfd_coff_generic_relocate_section): Call
6216         in_reloc_p to decide if reloc should be emitted.
6217         * libcoff.h (pe_data_type.in_reloc_p): New.
6218         * peicode.h (pe_mkobject): Initialize in_reloc_p.
6219
6220 Wed Oct 11 00:49:29 1995  Ian Lance Taylor  <[email protected]>
6221
6222         * cofflink.c (_bfd_coff_internal_syment_name): Move to coffgen.c.
6223         (_bfd_coff_read_internal_relocs): Likewise.
6224         * coffgen.c (_bfd_coff_internal_syment_name): Copy from coffgen.c.
6225         (_bfd_coff_read_internal_relocs): Likewise.
6226
6227         * elflink.h (elf_link_add_object_symbols): Correct conditions
6228         under which type and size change warnings are issued.
6229
6230 Tue Oct 10 18:32:46 1995  Ian Lance Taylor  <[email protected]>
6231
6232         * coffgen.c (coff_count_linenumbers): Don't count line numbers for
6233         a symbol which is not in a real section.
6234         (coff_write_native_symbol): Corresponding change.
6235
6236         * cofflink.c (_bfd_coff_link_hash_newfunc): Rename from
6237         coff_link_hash_newfunc and make non-static.
6238         (_bfd_coff_link_hash_table_init): New function, broken out of
6239         _bfd_coff_link_hash_table_create.
6240         (_bfd_coff_link_hash_table_create): Use it.
6241         (process_embedded_commands): Make static.
6242         * libcoff-in.h ((_bfd_coff_link_hash_newfunc): Declare.
6243         (_bfd_coff_link_hash_table_init): Declare.
6244         * libcoff.h: Rebuild.
6245
6246         * coffcode.h (coff_mkobject_hook): If RS6000COFF_C, set cputype
6247         field in XCOFF tdata.
6248         (coff_set_arch_mach_hook): Check ifdef RS6000COFF_C, not ifdef
6249         U802ROMAGIC, for clarity.  Try to set arch and machine correctly
6250         based on cputype stored in a.out header, or in n_type of initial
6251         .file symbol.
6252         (coff_write_object_contents): Set cputype correctly in a.out
6253         header.
6254         (coff_slurp_symbol_table): Add casts to file_ptr to avoid
6255         warnings.
6256         * coffswap.h (coff_swap_aouthdr_in): Swap in cputype field.
6257         (coff_swap_aouthdr_out): Swap out cputype field.  Don't clear
6258         old resv1 field.
6259         * libcoff-in.h (struct xcoff_tdata): Add cputype field.
6260         * libcoff.h: Rebuild.
6261
6262         * cpu-rs6000.c (rs6000_compatible): New static function.
6263         (bfd_rs6000_arch): Use it.
6264         * cpu-powerpc.c (powerpc_compatible): New static function.
6265         (arch_info_struct): Define various flavours of PowerPC.
6266         (bfd_powerpc_arch): Use powerpc_compatible.  Point at
6267         arch_info_struct.
6268
6269 Tue Oct 10 10:50:46 1995  Fred Fish  <[email protected]>
6270
6271         * Makefile.in (FLAGS_TO_PASS):  Remove BISON.
6272
6273 Tue Oct 10 01:28:29 1995  Ian Lance Taylor  <[email protected]>
6274
6275         * elflink.h (elf_link_add_object_symbols): Don't warn about
6276         changing the size or type if the old definition was weak.
6277
6278 Mon Oct  9 11:24:08 1995  Ian Lance Taylor  <[email protected]>
6279
6280         * coffcode.h (combined_entry_type): Add fix_line field.
6281         (coff_slurp_line_table): Warn if we try to set the lineno field of
6282         a symbol twice.
6283         (coff_slurp_symbol_table): If RS6000COFF_C, handle C_BINCL and
6284         C_EINCL by setting fix_line.  Fix C_BSTAT symbol value.
6285         * coffgen.c (coff_mangle_symbols): Handle fix_line.
6286         (coff_write_symbol): Only use N_DEBUG if the symbol is in the
6287         absolute section.
6288         (coff_print_symbol): Print fix_value symbols in a useful fashion.
6289         * libcoff.h: Rebuild.
6290
6291         * libcoff-in.h (struct xcoff_tdata): Define.
6292         (xcoff_data): Define.
6293         * bfd.c (struct _bfd): Add xcoff_obj_data field to tdata union.
6294         * bfd-in2.h, libcoff.h: Rebuild.
6295         * coff-rs6000.c (xcoff_mkobject): New static function.
6296         (coff_mkobject): Define.
6297         (xcoff_copy_private_bfd_data): New static function.
6298         (coff_bfd_copy_private_bfd_data): Define.
6299         (rs6000coff_howto_table): Change R_TOC complain_on_overflow from
6300         signed to bitfield.
6301         (rs6000coff_vec): Add DYNAMIC to object_flags.
6302         * coffcode.h (sec_to_styp_flags): If RS6000COFF_C, handle .pad and
6303         .loader sections specially.
6304         (coff_new_section_hook): If RS6000COFF_C, get the .text and .data
6305         section alignment from the XCOFF tdata information.
6306         (coff_mkobject_hook): If RS6000COFF_C, set DYNAMIC based on
6307         F_SHROBJ, and copy the extra a.out header information into the
6308         XCOFF tdata structure.
6309         (coff_write_object_contents): If RS6000COFF_C, set F_SHROBJ,
6310         F_DYNLOAD and the extra a.out header information.
6311         (coff_slurp_symbol_table): Set BSF_NOT_AT_END for a C_EXT or
6312         C_HIDEXT symbol with attached csect information.
6313         * coffswap.h (coff_swap_aouthdr_in): If RS6000COFF_C, swap
6314         in the o_maxdata field.
6315         (coff_swap_aouthdr_out): If RS6000COFF_C, swap extra XCOFF fields.
6316         * coffgen.c (coff_renumber_symbols): Don't move any symbol to the
6317         end if BSF_NOT_AT_END is set.
6318
6319         * targets.c (bfd_target): Rename _bfd_read_ar_hdr field to
6320         _bfd_read_ar_hdr_fn.
6321         * libbfd-in.h (_bfd_read_ar_hdr): Update accordingly.
6322         * bfd-in2.h, libbfd.h: Rebuild.
6323         * archive.c (_bfd_get_elt_at_filepos): Cast _bfd_read_ar_hdr
6324         return value.
6325         (do_slurp_bsd_armap, do_slurp_coff_armap): Likewise.
6326         (bfd_slurp_bsd_armap_f2): Likewise.
6327         (_bfd_slurp_extended_name_table): Likewise.
6328
6329 Fri Oct  6 16:18:35 1995  Ken Raeburn  <[email protected]>
6330
6331         Mon Sep 25 22:49:32 1995  Andreas Schwab  <[email protected]>
6332
6333         * archive.c (bfd_get_next_mapent): Return BFD_NO_MORE_SYMBOLS
6334         when the symbol table is empty.
6335
6336         * elf32-m68k.c (elf_m68k_size_dynamic_sections): Don't reserve
6337         space for section symbols, since we don't output them either.
6338         (elf_m68k_adjust_dynindx): Removed.
6339
6340         * ptrace-core.c (rawptr): Make it a local variable of
6341         ptrace_unix_core_file_p.
6342
6343 Fri Oct  6 12:24:47 1995  Michael Meissner  <[email protected]>
6344
6345         * coff-rs6000.c (xcoff_write_archive_contents): Return false, not
6346         NULL.
6347
6348         * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Add NT, and
6349         Mac object file formats.
6350
6351 Fri Oct  6 12:04:02 1995  Ian Lance Taylor  <[email protected]>
6352
6353         * coffgen.c (coff_fix_symbol_name): Don't try to set up file
6354         auxent if there isn't one.
6355         (coff_write_symbols): If there is no file auxent, use SYMNMLEN
6356         rather than FILNMLEN as the maximum name length.
6357
6358         * coffcode.h (bfd_coff_backend_data): Add new field
6359         _bfd_coff_print_aux.
6360         (bfd_coff_print_aux): New static function.
6361         (coff_pointerize_aux_hook (RS6000COFF_C version)): Pointerize the
6362         scnlen field of an XTY_LD csect aux entry.
6363         (coff_print_aux): New static function.
6364         (coff_slurp_symbol_table): Don't pointerize scnlen field; now done
6365         in coff_pointerize_aux_hook.
6366         (bfd_coff_std_swap_table): Initialize new field.
6367         * coffgen.c (coff_print_symbol): Call bfd_coff_print_aux.
6368         * libcoff.h: Rebuild.
6369         * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
6370         * coff-mips.c (mips_ecoff_backend_data): Likewise.
6371
6372         * coffcode.h (coff_write_object_contents): On AIX, clear F_RELFLG
6373         if there are symbols, for native AIX ld compatibility.
6374
6375         * coffcode.h (bfd_coff_backend_data): Add new field
6376         _bfd_coff_pointerize_aux_hook.
6377         (coff_pointerize_aux_hook): Define as a function if RS6000COFF_C
6378         or I960, and as 0 otherwise.
6379         (bfd_coff_std_swap_table): Initialize new field.
6380         * libcoff.h: Rebuild.
6381         * coffgen.c (coff_pointerize_aux): Change parameters  to take
6382         symbol pointer instead of type and class, and to take aux index.
6383         Call _bfd_coff_pointerize_aux_hook if it is defined.
6384         (coff_get_normalized_symtab): Always call coff_pointerize_aux.
6385         * coff-alpha.c (alpha_ecoff_backend_data): Initialize all fields.
6386         * coff-mips.c (mips_ecoff_backend_data): Likewise.
6387
6388         * coff-rs6000.c: Add full support for AIX archives.  Rewrite old
6389         read-only/host-only support.
6390
6391         * coffcode.h (coff_slurp_symbol_table): Set C_HIDEXT symbols to be
6392         BSF_LOCAL.
6393         (OTHER_GLOBAL_CLASS): Do not define to be C_HIDEXT if
6394         RS6000COFF_C.
6395
6396         * targets.c (bfd_target): Add _bfd_read_ar_hdr field.  Modify
6397         BFD_JUMP_TABLE_ARCHIVE accordingly.
6398         * libbfd-in.h (_bfd_snarf_ar_hdr): Don't declare.
6399         (_bfd_compute_and_write_armap): Declare.
6400         (_bfd_generic_read_ar_hdr): Declare.
6401         (_bfd_read_ar_hdr): Define.
6402         (_bfd_noarchive_read_ar_hdr): Define.
6403         (_bfd_archive_bsd_read_ar_hdr): Define.
6404         (_bfd_archive_coff_read_ar_hdr): Define.
6405         * archive.c: Change all callers of _bfd_snarf_ar_hdr to call
6406         _bfd_read_ar_hdr instead.
6407         (_bfd_generic_read_ar_hdr): Rename from _bfd_snarf_ar_hdr.
6408         (_bfd_compute_and_write_armap): Rename from
6409         compute_and_write_armap.  Make non-static.  Change all callers.
6410         * ecoff.c (_bfd_ecoff_slurp_armap): Call _bfd_read_ar_hdr rather
6411         than _bfd_snarf_ar_hdr.
6412         * aout-target.h (MY_read_ar_hdr): Define if not defined.
6413         * ieee.c (ieee_read_ar_hdr): Define.
6414         * libecoff.h (_bfd_ecoff_read_ar_hdr): Define.
6415         * oasys.c (oasys_read_ar_hdr): Define.
6416         * som.c (som_read_ar_hdr): Define.
6417         * bfd-in2.h, libbfd.h: Rebuild.
6418
6419 Thu Oct  5 14:04:07 1995  steve chamberlain  <[email protected]>
6420
6421         * peicode.c (coff_swap_filehdr_in): If symptr is
6422         zero, there aren't any symbols, even if nsyms is set.
6423
6424 Thu Oct  5 11:45:02 1995  Ian Lance Taylor  <[email protected]>
6425
6426         * libecoff.h (struct ecoff_backend_data): Add adjust_headers
6427         field.
6428         * ecoff.c (ecoff_sec_to_styp_flags): Check for various Alpha
6429         sections, and set styp correctly for them: .got, .hash, .dynamic,
6430         .liblist, .rel.dyn, .conflic, .dynstr, .dynsym, .comment.
6431         (_bfd_ecoff_styp_to_sec_flags): Check for various Alpha section
6432         types.
6433         (ecoff_sort_hdrs): New static function.
6434         (ecoff_compute_section_file_positions): Return boolean, not void.
6435         Sort the sections by VMA before looking through them.  Put the
6436         first non SEC_ALLOC section on a new page.  Put every SEC_ALLOC
6437         section on an appropriate boundary within the page.
6438         (ecoff_compute_reloc_file_positions): Check return value of
6439         ecoff_compute_section_file_positions.
6440         (_bfd_ecoff_set_section_contents): Likewise.
6441         (_bfd_ecoff_write_object_contents): Check for various Alpha
6442         section types when incrementing text_size and data_size.  Call
6443         adjust_headers backend function if it exists.
6444         * coff-alpha.c (alpha_adjust_headers): New static function.
6445         (alpha_ecoff_backend_data): Initialize adjust_headers field.
6446         * coff-mips.c (mips_ecoff_backend_data): Likewise.
6447
6448         * hosts/i386bsd.h: Restore file incorrectly deleted on Sep 6.
6449
6450 Wed Oct  4 18:15:02 1995  Jeff Law  ([email protected])
6451
6452         * rs6000-core.c (CORE_VERSION_1): Use CORE_VERSION_1 instead
6453         of ALTERNATE_AIX_CORE_FORMAT.
6454         * configure.in (aix4): No longer need CORE_FLAGS.
6455         * configure: Updated.
6456
6457 Wed Oct  4 15:36:36 1995  Ken Raeburn  <[email protected]>
6458
6459         NS32k changes from Ian Dall:
6460         * aoutx.h (MY_final_link_relocate, MY_relocate_contents): New
6461         macros.
6462         (aout_link_input_section_std, aout_link_input_section_ext,
6463         aout_link_reloc_link_order): Call them instead of _bfd_*
6464         versions.
6465         * aout-target.h (MY_exec_header_not_counted): New macro, defaults
6466         to zero.
6467         (backend_data): Use it instead of hardcoded zero.
6468
6469         * aout-ns32k.c (CTOR_TABLE_RELOC_HOWTO): New macro.
6470         (MY_swap_std_reloc_out): Use udata.i for KEEPIT, don't call stoi.
6471
6472         * ns32knetbsd.c: Include bfd.h.
6473         (MY_text_includes_header, MY_bfd_reloc_type_lookup): New macros.
6474         (MY_bfd_reloc_type_lookup): Declare function too.
6475         * pc532-mach.c (set_sizes): Don't declare.
6476         (MY_text_includes_header, MY_exec_header_not_counted): Define.
6477         (backend_data, MY_backend_data): Don't define.
6478
6479         * config.bfd: Treat ns32k-pc532-ux* like ns32k-pc532-mach*, and
6480         ns32k-*-lites* like ns32k-*-netbsd*.
6481
6482         * hosts/nbsd.h: Swap order of sys/vmparam.h and sys/param.h, to
6483         compile on lites.
6484
6485 Wed Oct  4 14:15:52 1995  Ian Lance Taylor  <[email protected]>
6486
6487         * coffcode.h (coff_write_object_contents): Restore setting
6488         f_timdat to 0, deleted on August 22.
6489
6490 Tue Oct  3 16:28:32 1995  steve chamberlain  <[email protected]>
6491
6492         * coffcode.h (coff_bfd_copy_private_symbol_data,
6493         coff_bfd_copy_private_section_data,
6494         coff_bfd_copy_private_bfd_data): ifdef to allow overrides.
6495         * peicode.h (coff_bfd_copy_private_bfd_data): New
6496         (pe_bfd_copy_private_bfd_data): New.
6497         (coff_swap_scnhdr_in): Swap bss size into the right place.
6498         (pe_print_private_bfd_data): Add some newlines.
6499
6500 Tue Oct  3 11:53:04 1995  Jeff Law  ([email protected])
6501
6502         * som.c (setup_sections): Don't die if a space has no subspaces.
6503
6504 Mon Oct  2 14:08:55 1995  Ian Lance Taylor  <[email protected]>
6505
6506         * elflink.h (elf_link_add_object_symbols): Don't let a weak
6507         dynamic symbol override a common symbol.  Don't change the size or
6508         type if they have been set and the new symbol is not a definition.
6509         Warn if the size or type changes.
6510
6511 Sun Oct  1 01:34:41 1995  Jeff Law  ([email protected])
6512
6513         * som.c (som_begin_writing): Don't write the symbol table or
6514         symbol  strings.
6515         (som_finish_writing): Write them here.  Place them after the
6516         subspace data, but before the relocs.
6517
6518 Fri Sep 29 11:01:55 1995  Ian Lance Taylor  <[email protected]>
6519
6520         * sunos.c (sunos_add_one_symbol): Just pass false, not
6521         info->shared_library, to sunos_create_dynamic_sections.
6522         (sunos_scan_ext_relocs): Don't warn about a reloc in the .text
6523         section.
6524         (sunos_check_dynamic_reloc): Remove .text section assertion.
6525
6526 Thu Sep 28 18:48:47 1995  Stan Shebs  <[email protected]>
6527
6528         * config.bfd: Add powerpc-*-macos*, powerpc-*-mpw*.
6529         * configure, configure.in: Add pmac_xcoff_vec case.
6530         * Makefile.in (BFD32_BACKENDS): Add coff-pmac.o.
6531         * coff-pmac.c: New file, PowerMac XCOFF support.
6532         * coffcode.h (coff_set_arch_mach_hook): Add PowerMac case.
6533         * targets.c (pmac_xcoff_vec): Declare.
6534
6535         * mpw-config.in: Various changes to be compatible with the
6536         autoconf-based configury.
6537         * mpw-make.sed: New file, sed commands to translate Unix
6538         makefile into MPW syntax.
6539         * mpw-make.in: Remove.
6540         * hosts/mpw.h: Remove.
6541         * bfd-in.h, bfd-in2.h: If MPW, include the file that defines
6542         true and false as enums, then define TRUE_FALSE_ALREADY_DEFINED.
6543
6544 Thu Sep 28 17:06:23 1995  steve chamberlain  <[email protected]>
6545
6546         * binary.c (binary_get_symtab): Return an empty string on error.
6547         * opncls.c (bfd_fdpenr): Change WIN32 restriction to WINGDB.
6548
6549 Thu Sep 28 15:30:44 1995  Kim Knuttila  <krk@nellie>
6550
6551         * coff-ppc.c: Reformatted according to gnu conventions
6552                       Removed irrelevant "if 0" code
6553
6554 Thu Sep 28 11:19:53 1995  Ian Lance Taylor  <[email protected]>
6555
6556         * hp300hpux.c (convert_sym_type): Treat secondary symbols as weak
6557         symbols rather than as indirect symbols.
6558         (MY(slurp_symbol_table)): Don't do anything special about
6559         secondary symbols.
6560
6561         * coffcode.h (coff_new_section_hook): Make sure that the alignment
6562         of .ctors and .dtors sections is no larger than 2.
6563
6564         * sunos.c (sunos_add_one_symbol): Don't change
6565         bfd_link_hash_common to bfd_link_hash_new, since it may be on the
6566         undef list.
6567         (bfd_sunos_record_link_assignment): Don't put __DYNAMIC in the
6568         dynamic symbols when creating a shared library.
6569         (sunos_scan_ext_relocs): Handle relocs correctly when creating a
6570         shared library.
6571         (sunos_scan_dynamic_symbol): Don't mark the __DYNAMIC symbol as
6572         written even if it is not defined in a regular object.
6573         (sunos_write_dynamic_symbol): Use plt_offset for the address of
6574         the jump table reloc.  Add an assertion.  Use RELOC_JMP_SLOT
6575         rather than the constant 22.
6576         (sunos_check_dynamic_reloc): Handle creating a shared library.
6577         (sunos_finish_dynamic_link): Set the first entry in the GOT to
6578         zero when creating a shared library.
6579         * aoutx.h (NAME(aout,final_link)): If there is a symbol __DYNAMIC,
6580         write it out at the start of the symbol table.
6581
6582         * Makefile.in (BFD32_BACKENDS): Add coff-arm.o.
6583
6584 Thu Sep 28 00:58:05 1995  Doug Evans  <[email protected]>
6585
6586         * config.bfd: Add arm-*-coff.
6587         * configure.in, configure: Add armcoff_{little,big}_vec.
6588         * targets.c (armcoff_{little,big}_vec): Declare.
6589         (bfd_target_vector): Add armcoff_{little,big}_vec.
6590         * coff-arm.c (armcoff_{little,big}_vec): Always define.
6591
6592 Wed Sep 27 10:37:14 1995  Ian Lance Taylor  <[email protected]>
6593
6594         * targets.c (bfd_find_target): Remove debugging code.
6595
6596 Wed Sep 27 07:23:39 1995  Kim Knuttila  <krk@nellie>
6597
6598         * coff-ppc.c, pe-ppc.c, pei-ppc.c: Initial bfd for coff/PE 
6599         support on powerpc.
6600         * Makefile.in: added *-ppc files
6601         * coffcode.h: ppc MAGIC, and use peicode.h rather than coffswap.h to
6602         allow pe based .o's to be shared with other tools on ppc/NT
6603         * config.bfd: added powerpc[le]-[pe|winnt] config support
6604         * configure, configure.in: added bfd_powerpc[le]_pe[i]_vec 
6605         * peicode.h: Added more section flags for PE on ppc
6606                      Added coff_swap_filehdr_out to allow peicode.h to be
6607                      used for non-image PE files on ppc.
6608                      Check for image, or not, before copying pe_opthdr
6609         * targets.c: Added new bfd's
6610         * targets.c: Removed two inactive bfds that shouldn't have made it this
6611                      far.
6612
6613 Tue Sep 26 14:06:41 1995  Michael Meissner  <[email protected]>
6614
6615         * elf32-ppc.c (ppc_reloc_type): Rename from reloc_type, and use
6616         explicit values to initialize all relocs.  Change all users.
6617         (ppc_elf_brtaken_inner): New function to handle branch predicition
6618         relocs.
6619         (ppc_elf_brtaken_reloc): Ditto.
6620         (ppc_elf_howto_raw): Use new functions.  Make sure all unsupported
6621         relocs use ppc_elf_unsupported_reloc.
6622         (ppc_elf_merge_private_bfd_data): Keep track of whether an error
6623         needs to be reported.
6624         (ppc_elf_relocate_section): Support branch prediction relocs.
6625
6626 Tue Sep 26 12:48:05 1995  Ian Lance Taylor  <[email protected]>
6627
6628         * bfd.c (bfd_assert): Remove \n from string passed to
6629         _bfd_error_handler.
6630
6631         * coff-i386.c: (TWO_DATA_SECS): Don't define.
6632         * coffcode.h (bfd_coff_backend_data): Remove _bfd_make_section_hook.
6633         (bfd_coff_make_section_hook): Don't define.
6634         (coff_make_section_hook): Remove.
6635         (sec_to_styp_flags): Remove TWO_DATA_SECS case.
6636         (styp_to_sec_flags): Likewise.
6637         (coff_write_object_contents): Likewise.
6638         (bfd_coff_std_swap_table): Don't initialize make_section_hook
6639         field.
6640         * libcoff.h: Rebuild.
6641         * coffgen.c (make_a_section_from_file): Just call
6642         bfd_make_section_anyway, not bfd_make_section or
6643         bfd_coff_make_section_hook.
6644         * ecoff.c (_bfd_ecoff_make_section_hook): Remove.
6645         * libecoff.h (_bfd_ecoff_make_section_hook): Don't declare.
6646         * coff-alpha.c (alpha_ecoff_backend_data): Don't initialize
6647         make_section_hook field.
6648         * coff-mips.c (mips_ecoff_backend_data): Likewise.
6649
6650         * aoutx.h (translate_from_native_sym_flags): Don't try to stuff
6651         pointers into value field for warning and indirect symbols; just
6652         leave the value field alone.
6653         * linker.c (generic_link_add_symbol_list): Use next symbol for
6654         warning and indirect symbols, rather than looking in symbol value.
6655         * ecoff.c (ecoff_set_symbol_info): Remove indirect_ptr_ptr
6656         parameter.  Change all callers.  Remove support for indirect
6657         symbols; it didn't work anyhow.
6658         (_bfd_ecoff_slurp_symbol_table): Remove indirect_ptr variable.
6659         * syms.c: Change comments about BSF_WARNING and BSF_INDIRECT.
6660         * bfd-in2.h: Rebuild.
6661
6662 Mon Sep 25 16:04:09 1995  Michael Meissner  <[email protected]>
6663
6664         * elf32-ppc.c (ppc_elf_howto_raw): For all 14-bit branch relocs,
6665         go back to telling the tools this reloc operates on 32 bits.
6666
6667 Mon Sep 25 11:48:02 1995  Ian Lance Taylor  <[email protected]>
6668
6669         * aout-adobe.c (aout_adobe_callback): Use _bfd_error_handler
6670         rather than a direct fprintf.
6671         * archive.c (_bfd_write_archive_contents): Likewise.
6672         * coffcode.h (coff_slurp_symbol_table): Likewise.
6673         * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Likewise.
6674         (ppc_elf_unsupported_reloc): Likewise.
6675         (ppc_elf_relocate_section): Likewise.
6676         * i386linux.c (linux_tally_symbols): Likewise.
6677         (linux_finish_dynamic_link): Likewise.
6678         * osf-core.c (osf_core_core_file_p): Likewise.
6679         * rs6000-core.c (rs6000coff_get_section_contents): Likewise.
6680         * som.c (som_sizeof_headers): Likewise.
6681         * srec.c (srec_bad_byte): Likewise.
6682         * bfd.c (bfd_assert): Likewise.  Also change file to be const.
6683         * libbfd-in.h (bfd_assert): Declare first parameter const.
6684         * libbfd.h: Rebuild.
6685         * coff-a29k.c (a29k_reloc): Don't bother to fprintf; returning
6686         bfd_reloc_overflow is enough.
6687         * coff-h8300.c (rtype2howto): Don't bother to fprintf; just abort.
6688         * coff-h8500.c (rtype2howto): Likewise.
6689         * coff-z8k.c (rtype2howto): Likewise.
6690         * coffcode.h (dummy_reloc16_extra_cases): Likewise.
6691         * elf.c (_bfd_elf_get_lineno): Likewise.
6692         (_bfd_elf_no_info_to_howto): Likewise.
6693         (_bfd_elf_no_info_to_howto_rel): Likewise.
6694         * hp300hpux.c (convert_sym_type): Likewise.
6695         (MY(swap_std_reloc_in)): Likewise.
6696         * elf.c (bfd_section_from_shdr): Remove #if 0 sections.
6697
6698         * libaout.h (struct aoutdata): Add line_buf field.
6699         * aoutx.h (NAME(aout,find_nearest_line)): Remove statics buffer
6700         and filename_buffer.  Instead, use a malloc buffer stored in the
6701         new line_buf field.  Remove length restrictions.
6702
6703         * coffgen.c (string_size): Remove static variable.
6704         (debug_string_size, debug_string_section): Likewise.
6705         (coff_fix_symbol_name): Add string_size_p, debug_string_section_p,
6706         and debug_string_size_p parameters.  Use them instead of the
6707         global variables.  Change all callers.
6708         (coff_write_symbol): Likewise.
6709         (coff_write_alien_symbol, coff_write_native_symbol): Likewise.
6710         (coff_write_symbols): Add local variables to replace removed
6711         global variables.
6712
6713         * libcoff-in.h (struct coff_section_tdata): Add offset, i,
6714         function, and line_base fields.
6715         * libcoff.h: Rebuild.
6716         * coffgen.c (coff_find_nearest_line): Use section tdata to cache
6717         information, rather than using static variables.
6718
6719         * sunos.c (sunos_read_dynamic_info): Adjust offsets in an NMAGIC
6720         file.  From Peter DeWolf <[email protected]>.
6721
6722         * init.c (initialized): Remove static variable.
6723         (bfd_init): Don't bother setting initialized.
6724         (bfd_check_init): Remove.
6725         * opncls.c (_bfd_new_bfd): Don't call bfd_check_init.
6726         * libbfd.h: Rebuild.
6727
6728 Sat Sep 23 01:22:23 1995  Peter Schauer  ([email protected])
6729
6730         * rs6000-core.c (rs6000coff_core_p):  Don't check the core file
6731         size for full core dumps. Copy core file header to private data.
6732         (rs6000coff_core_file_failing_command,
6733         rs6000coff_core_file_failing_signal):  New functions to extract
6734         the file name and terminating signal from the core file.
6735         * coff-rs6000.c:  Use them.
6736
6737 Fri Sep 22 17:44:47 1995  Ian Lance Taylor  <[email protected]>
6738
6739         Change arch info to be const, initialized at compile time.
6740         * archures.c: Reindent many functions.  Change CONST to const.
6741         (bfd_arch_info_type): Make arch_name const.  Remove disassemble;
6742         nothing set it anyhow.  Make next const.
6743         (bfd_arch_info_list): Remove.
6744         (bfd_archures_list): Rename from archures_init_table.  Change from
6745         a table of function pointers to a table of bfd_arch_info_type
6746         structure addresses.
6747         (bfd_scan_arch): Rewrite accordingly.  Return a const pointer.
6748         (bfd_lookup_arch): Likewise.
6749         (bfd_set_arch_info): Rewrite accordingly.  Change argument to be a
6750         const pointer.
6751         (bfd_default_arch_struct): Make const.
6752         (bfd_arch_init, bfd_arch_linkin): Remove.
6753         (bfd_get_arch_info): Return a const pointer.
6754         * init.c (bfd_init): Don't call bfd_arch_init.
6755         * bfd.c (struct _bfd): Make arch_info const.
6756         * bfd-in2.h: Rebuild.
6757         * libbfd.h: Rebuild.
6758         * configure.in: Put & before everything in $selarchs.
6759         * configure: Rebuild.
6760         * cpu-*.c: Change bfd_*_arch from a function which calls
6761         bfd_arch_linkin to a const structure.
6762         * ieee.c (ieee_object_p): Make arch const.
6763
6764 Fri Sep 22 16:23:18 1995  Michael Meissner  <[email protected]>
6765
6766         * reloc.c (bfd_reloc_code_type): Add relocations to support all of
6767         PowerPC V.4.
6768         * bfd-in2.h: Regenerate.
6769         * libbfd.h: Regenerate.
6770
6771         * elf32-ppc.c (reloc_type): Update names to match current draft.
6772         (ppc_elf_howto_raw): Mark 14 bit relocs as short sized and PC
6773         relative.  Update names to current V.4 draft.
6774         (ppc_elf_reloc_type_lookup): Add support for more relocations.
6775         (ppc_elf_relocate_section): Rename relocations to match draft.
6776
6777 Thu Sep 21 21:53:18 1995  Michael Meissner  <[email protected]>
6778
6779         * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Allow modules
6780         compiled with -mrelocatable-lib to be linked with either normal
6781         modules or -mrelocatable modules.
6782
6783 Wed Sep 20 12:03:26 1995  Ian Lance Taylor  <[email protected]>
6784
6785         * coffcode.h (coff_write_object_contents): Clear the vstamp field
6786         in the a.out header.
6787
6788         * aoutx.h (NAME(aout,swap_ext_reloc_out)): Don't set r_extern for
6789         a reloc against a local symbol, even if it's not a section.
6790
6791 Tue Sep 19 17:02:26 1995  Ian Lance Taylor  <[email protected]>
6792
6793         * targets.c (bfd_target): Remove unused align_power_min field.
6794         * bfd-in2.h: Rebuild.
6795         * All backends: Remove initialization of align_power_min.
6796
6797 Tue Sep 19 14:02:21 1995  steve chamberlain  <[email protected]>
6798
6799         * peicode.h (coff_swap_scnhdr_out): Get sizes for BSS right.
6800
6801 Mon Sep 18 14:35:01 1995  Arne H. Juul  <[email protected]>
6802
6803         * config.bfd (mips-dec-netbsd*): New target.
6804         * configure.host (mips-dec-netbsd*): New host.
6805         * configure.in (mips-dec-netbsd*): New native.
6806         * configure: Rebuild.
6807
6808 Fri Sep 15 10:24:36 1995  Ian Lance Taylor  <[email protected]>
6809
6810         Make the COFF backend linker merge common types:
6811         * cofflink.c (struct coff_debug_merge_element): Define.
6812         (struct coff_debug_merge_type): Define.
6813         (struct coff_debug_merge_hash_entry): Define.
6814         (struct coff_debug_merge_hash_table): Define.
6815         (coff_debug_merge_hash_table_init): Define.
6816         (coff_debug_merge_hash_table_free): Define.
6817         (coff_debug_merge_hash_lookup): Define.
6818         (struct coff_final_link_info): Add debug_merge field.
6819         (coff_debug_merge_hash_newfunc): New static function.
6820         (_bfd_coff_final_link): Allocate and free debug_merge table.
6821         (coff_link_input_bfd): Merge identical enum, struct and union
6822         types.
6823
6824 Thu Sep 14 14:53:58 1995  Ian Lance Taylor  <[email protected]>
6825
6826         Convert i960 COFF to use COFF backend linker.
6827         * coff-i960.c (coff_i960_relocate): Use a coff_section_data
6828         structure to store the symbol being used.
6829         (coff_i960_start_final_link): New static function.
6830         (coff_i960_relocate_section): New static function.
6831         (coff_i960_adjust_symndx): New static function.
6832         (coff_start_final_link): Define.
6833         (coff_relocate_section): Define.
6834         (coff_adjust_symndx): Define.
6835         * coffcode.h (bfd_coff_backend_data): Add new callback function
6836         _bfd_coff_start_final_link.
6837         (bfd_coff_start_final_link): Define.
6838         (coff_start_final_link): Define if not defined.
6839         (bfd_coff_std_swap_table): Add coff_start_final_link.
6840         * cofflink.c (_bfd_coff_internal_syment_name): Make globally
6841         visible.
6842         (_bfd_coff_final_link): Call bfd_coff_start_final_link if the
6843         function callback is not NULL.
6844         * libcoff-in.h (struct coff_section_tdata): Add tdata field.
6845         (_bfd_coff_internal_syment_name): Declare.
6846         * libcoff.h: Rebuild.
6847         * configure.in (icoff_big_vec): Add cofflink.o.
6848         (icoff_little_vec): Likewise.
6849         * configure: Rebuild.
6850
6851 Wed Sep 13 17:38:23 1995  Fred Fish  <[email protected]>
6852
6853         * Makefile.in (clean-info): Remove extraneous tab from line
6854         following action.
6855
6856 Wed Sep 13 13:27:53 1995  Ian Lance Taylor  <[email protected]>
6857
6858         * cofflink.c (coff_link_input_bfd): Fail if a section with no
6859         contents has relocs.
6860
6861 Thu Sep 12 12:45:34 1995  steve chamberlain  <[email protected]>
6862
6863         * coffcode.h (coff_compute_section_file_positions): Keep the
6864         raw size safe. 
6865         (coff_write_object_contents): Remember if it's a relocatable
6866         file.
6867         * libcoff-in.h (pe_data_type): New member 'has_reloc_section'
6868         * peicode.h (coff_swap_filehdr_out): Clear not-reloc flag
6869         if relocatable file. Swap out saved raw size.
6870
6871 Tue Sep 12 12:14:33 1995  Ian Lance Taylor  <[email protected]>
6872
6873         * Makefile.in (do_maintainer_clean): Rename from do_realclean.
6874         (maintainer-clean): Rename from realclean, passing
6875         maintainer-clean down to subdirectories, but leave realclean as a
6876         synonym.
6877
6878         * linker.c (_bfd_generic_link_add_one_symbol): Pass symbol name to
6879         warning callback.
6880
6881         * dep-in.sed: Remove config.h from generated dependencies.
6882
6883         * sunos.c (sunos_slurp_dynamic_symtab): New static function,
6884         broken out of sunos_canonicalize_dynamic_symtab.
6885         (sunos_canonicalize_dynamic_symtab): Call new function
6886         sunos_slurp_dynamic_symtab.
6887         (sunos_add_dynamic_symbols): Add three new parameters.  Return the
6888         dynamic symbol table to the caller.
6889         * aoutx.h (aout_link_add_symbols): Permit add_dynamic_symbols
6890         callback to override the symbols being read.
6891         * libaout.h (struct aout_backend_data): Add three new parameters
6892         to add_dynamic_symbols callback.
6893
6894         Extensive minor changes to avoid various gcc warnings.  Also:
6895         * Makefile.in (BFD32_BACKENDS): Remove coff-arm.o.
6896         * archures.c (bfd_arch_info_type): Change mach field from long to
6897         unsigned long.
6898         (bfd_lookup_arch): Change machine parameter from long to unsigned
6899         long.
6900
6901 Mon Sep 11 10:55:47 1995  Ian Lance Taylor  <[email protected]>
6902
6903         * sunos.c (sunos_scan_std_relocs): Fix BFD_ASSERT: it's OK to find
6904         a symbol with a non-zero plt_offset.
6905
6906 Fri Sep  8 11:47:24 1995  Ian Lance Taylor  <[email protected]>
6907
6908         * elfcode.h (align_file_position): Remove; not used.
6909
6910         * configure.in: Only check for <sys/procfs.h> on a native system,
6911         and make sure it defines prstatus_t.
6912         * configure: Rebuild.
6913
6914 Thu Sep  7 12:48:01 1995  Ian Lance Taylor  <[email protected]>
6915
6916         * sunos.c (sunos_write_dynamic_symbol): Correct m68k abort test.
6917
6918         * config.in: Rename from config.h.in.
6919         * configure.in: Call AC_CONFIG_HEADER with config.h:config.in.
6920         Check for config.h:config.in when creating stamp-h.
6921         * configure: Rebuild.
6922         * Makefile.in (stamp-h): Depend upon config.in rather than
6923         config.h.in.  Set CONFIG_HEADERS to config.h:config.in when
6924         calling config.status.
6925
6926         * Makefile.in (do_distclean): Remove config.h and stamp-h.
6927         (Makefile): Just rebuild Makefile.
6928         (config.h, stamp-h): New targets.
6929         * configure.in: Create stamp-h when rebuilding config.h.
6930         * configure: Rebuild.
6931
6932 Wed Sep  6 15:00:33 1995  Ian Lance Taylor  <[email protected]>
6933
6934         * configure.in: Call AC_CONFIG_HEADER.  Substitute
6935         HOST_64BIT_LONG.  Check that various header files exist.  Check
6936         that fcntl exists.  Call BFD_BINARY_FOPEN.  Check whether malloc
6937         and/or free need to be declared.  Don't make a link to sysdep.h.
6938         Define TRAD_HEADER for various hosts.
6939         * configure: Rebuild.
6940         * configure.host: Don't set my_host.  Add definitions taken from
6941         host header files for various entries.  Remove entries which now
6942         do nothing.
6943         * acconfig.h: New file.
6944         * config.h.in: New file, built by autoheader.
6945         * sysdep.h: New file.
6946         * Makefile.in (do_distclean): Don't remove sysdep.h.
6947         (RECONFIG): Remove.
6948         (LOCAL_H_DEPS): New variable.
6949         ($(BFD_LIBS)): Use $(LOCAL_H_DEPS) rather than libbfd.h and
6950         $(RECONFIG).
6951         ($(BFD_MACHINES), $(BFD_BACKENDS)): Likewise.
6952         ($(OPTIONAL_BACKENDS)): Likewise.
6953         (stmp-bfd.h): Just substitute for BFD_HOST_64BIT_LONG, rather than
6954         looking through sysdep.h.
6955         * bfd-in.h (BFD_HOST_64BIT_LONG): Define; set by Makefile.
6956         (BFD_HOST_64_BIT): Define based on BFD_HOST_64BIT_LONG.
6957         (fprintf_vma, sprintf_vma): Likewise.
6958         (int64_type, uint64_type): Don't define.
6959         * bfd-in2.h: Rebuild.
6960         * archures.c, bfd.c, srec.c: Include <ctype.h>.
6961         * elfcore.h: Check HAVE_SYS_PROCFS_H rather than HAVE_PROCFS.
6962         * lynx-core.c: Include stuff from old hosts/lynx.h.
6963         * opncls.c (bfd_fdopenr): Check HAVE_FNCTL and defined (F_GETFL),
6964         rather than NO_FCNTL.
6965         * targets.c (bfd_target_list): Check HOST_HPPAHPUX and ! __STDC__
6966         rather than NATIVE_HPPAHPUX_COMPILER.
6967         * trad-core.c: Don't include <errno.h>.  Include TRAD_HEADER if it
6968         is defined.
6969         * hosts/*.h: Remove all header files which merely include,
6970         declare, and define things.  Leave header files which define
6971         information needed by trad-core.c.
6972
6973         * aclocal.m4 (BFD_BINARY_FOPEN): Define.
6974         (BFD_CC_FOR_BUILD): Define.
6975         * configure.in: Use BFD_CC_FOR_BUILD.
6976         * configure: Rebuild.
6977
6978 Tue Sep  5 19:35:28 1995  Ian Lance Taylor  <[email protected]>
6979
6980         * aclocal.m4: Don't try to grep ../Makefile if it doesn't exist.
6981         * configure: Rebuild.
6982
6983         * coff-sparc.c (CALC_ADDEND): Don't set the addend to the value of
6984         a global symbol.
6985
6986 Tue Sep  5 12:48:26 1995  Jason Molenda   ([email protected])
6987
6988         * config.bfd: i386pe_ve -> i386pe_vec.
6989
6990 Mon Sep  4 14:02:43 1995  Ian Lance Taylor  <[email protected]>
6991
6992         * configure.host: Incorporate host Makefile fragments by setting
6993         shell variables.
6994         * configure.in: Call AC_PROG_CC.  Substitute CFLAGS, HDEFINES and
6995         AR.  Call AC_PROG_INSTALL.  Substitute CC_FOR_BUILD, choosing a
6996         value based on whether the code is being compiled by a cross
6997         compiler.  Don't substitute host_makefile_frag or frags.
6998         * aclocal.m4: New file to define local AC_PROG_CC.
6999         * configure: Rebuild.
7000         * Makefile.in (INSTALL): Set to @INSTALL@.
7001         (INSTALL_PROGRAM): Set to @INSTALL_PROGRAM@.
7002         (INSTALL_DATA): Set to @INSTALL_DATA@.
7003         (AR): Set to @AR@.
7004         (CC): Define as @CC@.
7005         (CFLAGS): Set to @CFLAGS@.
7006         (CC_FOR_BUILD): Set to @CC_FOR_BUILD@.
7007         (@host_makefile_frag@): Remove.
7008         (ALL_CFLAGS): Change $(HDEFINES) to @HDEFINES@.  Move $(CFLAGS)
7009         after other options.
7010         (config.status): Remove dependency upon @frags@.
7011         * config/*.mh, config/README: Remove.
7012
7013         * config.bfd: Rewrite to incorporate the contents of the Makefile
7014         fragments by setting shell variables, rather than merely returning
7015         the name of a Makefile fragment.
7016         * configure.in: Use shell variables set by config.bfd rather than
7017         looking at the target Makefile fragment files.  Don't substitute
7018         target_makefile_frag.  Do substitute TDEFINES.
7019         * configure: Rebuild.
7020         * Makefile.in (@target_makefile_frag@): Remove.
7021         (ALL_CFLAGS): Change $(TDEFINES) to @TDEFINES@.
7022         * config/*.mt: Remove.
7023
7024 Mon Sep  4 03:13:28 1995  Ken Raeburn  <[email protected]>
7025
7026         * configure.in: Put changequote lines around "i[345]86" patterns
7027         section of core file support.
7028
7029 Sun Sep  3 11:31:58 1995  Jeff Law  ([email protected])
7030
7031         * som.c (som_bfd_print_private_bfd_data): Define to use the
7032         generic version.
7033
7034 Fri Sep  1 17:08:40 1995  steve chamberlain  <[email protected]>
7035
7036         * peicode.h (coff_swap_aouthdr_in): Add ImageBase to
7037         entry, text_start and data_start.
7038
7039 Fri Sep  1 18:06:28 1995  Ian Lance Taylor  <[email protected]>
7040
7041         * Makefile.in (OFILES): Remove $(TDEPFILES).
7042         * config/apollo.mt (TDEPFILES): Remove.
7043         * config/README: Update.
7044
7045         * configure.in: For a native configuration, set COREFILE and
7046         COREFLAG based on the canonical host name.
7047         * configure: Rebuild.
7048         * Makefile.in: Rebuild dependencies.
7049         (ALL_CFLAGS): Add @COREFLAG@.
7050         (OFILES): Replace $(HDEPFILES) with @COREFILE@.
7051         * coff-rs6000.c: Check AIX_CORE rather than HOST_AIX for core file
7052         support routines.  Check LYNX_CORE rather than HOST_LYNX.
7053         * lynx-core.c: Check LYNX_CORE rather than HOST_LYNX.
7054         * i386lynx.c: Likewise.
7055         * m68klynx.c: Likewise.
7056         * sparclynx.c: Likewise.
7057         * rs6000-core.c: Check AIX_CORE rather than HOST_AIX.
7058         * *-core.c: Comment changes.
7059         * config/decstation.mh (HDEPFILES): Remove.
7060         (HDEFINES): Remove -DTRAD_CORE.
7061         * config/irix3.mh (RANLIB): Remove.
7062         * config/irix4.mh (HDEPFILES, RANLIB): Remove.
7063         (HDEFINES): Remove -DIRIX_CORE.
7064         * config/riscos.mh (RANLIB, HDEPFILES): Remove.
7065         (HDEFINES): Remove -DTRAD_CORE.
7066         * config/ncr3000.mh (AR_FLAGS, RANLIB): Remove.
7067         * config/ultra3.mh (RANLIB): Remove.
7068         * config/aix4.mh, config/alphaosf.mh, config/amix.mh: Remove.
7069         * config/apollo.mh, config/delta68.mh, config/delta88.mh: Remove.
7070         * config/dpx2.mh, config/esix.mh, config/harris.mh: Remove.
7071         * config/hp300.mh, config/hp300bsd.mh, config/hppabsd.mh: Remove.
7072         * config/hppahpux.mh, config/hppaosf.mh: Remove.
7073         * config/i386aix.mh, config/i386bsd.mh: Remove.
7074         * config/i386linux.mh, config/i386mach3.mh: Remove.
7075         * config/i386sco.mh, config/i386v.mh, config/i386v4.mh: Remove.
7076         * config/irix5.mh, config/m88kmach3.mh, config/mipsbsd.mh: Remove.
7077         * config/mipsmach3.mh, config/news-mips.mh: Remove.
7078         * config/news.mh, config/pc532mach.mh, config/riscix.mh: Remove.
7079         * config/rs600.mh, config/rs6000lynx.mh: Remove.
7080         * config/solaris2.mh, config/stratus.mh: Remove.
7081         * config/symmetry.mh, config/sysv4.mh, config/tahoe.mh: Remove.
7082         * config/vaxbsd.mh, config/vaxult.mh, config/vaxult2.mh: Remove.
7083
7084 Fri Sep  1 15:18:50 1995  Kazumoto Kojima  <[email protected]>
7085
7086         * elflink.h (elf_bfd_final_link): Don't change a DT_INIT or
7087         DT_FINI entry if the appropriate symbol is not in the hash table.
7088
7089         * libelf.h (struct elf_backend_data): Add create_program_headers
7090         and want_hdr_in_seg fields.
7091         * elfxx-target.h (elf_backend_want_hdr_in_seg): Define if not
7092         defined.
7093         (elf_backend_create_program_headers): Likewise.
7094         (elfNN_bed): Initialize create_program_headers and
7095         want_hdr_in_seg.
7096         * elf.c (get_program_header_size): Call create_program_headers
7097         backend routine.
7098         (map_program_segments): Check want_hdr_in_seg backend field.  Call
7099         create_program_headers backend routine.
7100
7101         * elf.c (assign_file_positions_except_relocs): Align non allocated
7102         sections when creating an executable.
7103
7104         * elfcode.h (elf_swap_phdr_in): Make non static.
7105         (elf_swap_phdr_out): Make non static.
7106         * libelf.h (bfd_elf32_swap_phdr_in): Declare.
7107         (bfd_elf32_swap_phdr_out): Declare.
7108         (bfd_elf64_swap_phdr_in): Declare.
7109         (bfd_elf64_swap_phdr_out): Declare.
7110
7111         * ecofflink.c (ecoff_collect_shuffle): New static function.
7112         (_bfd_ecoff_get_accumulated_pdr): New function.
7113         (_bfd_ecoff_get_accumulated_sym): New function.
7114         (_bfd_ecoff_get_accumulated_ss): New function.
7115         * libbfd-in.h (_bfd_ecoff_get_accumulated_pdr): Declare.
7116         (_bfd_ecoff_get_accumulated_sym): Declare.
7117         (_bfd_ecoff_get_accumulated_ss): Declare.
7118         * libbfd.h: Rebuild.
7119
7120 Fri Sep  1 13:20:25 1995  Ian Lance Taylor  <[email protected]>
7121
7122         * libecoff.h (_bfd_ecoff_bfd_print_private_bfd_data): Fix typo.
7123
7124         * elflink.h (elf_link_add_object_symbols): Handle indirect and
7125         warning symbols.  If any section is named .gnu.warning.XXX, treat
7126         the contents as a warning to be issued if the symbol XXX is
7127         referenced.
7128         (elf_link_output_extsym): For an indirect or warning symbol, just
7129         output the symbol it points to.
7130
7131         * linker.c (_bfd_link_hash_newfunc): Don't bother to set bfd_error
7132         if bfd_hash_allocate fails, since it will already be set.
7133         (generic_link_hash_newfunc): Likewise.
7134         (archive_hash_newfunc): Likewise.
7135         (hash_entry_bfd): New static function.
7136         (_bfd_generic_link_add_one_symbol): Pass new arguments to warning
7137         callback.  Allocate a new warning using the hash table newfunc.
7138         Use bfd_hash_replace to update the entry in the hash table, rather
7139         than assuming we can copy the fields with structure assignment.
7140
7141         * hash.c (bfd_hash_replace): New function.
7142         * bfd-in.h (bfd_hash_replace): Declare.
7143         * bfd-in2.h: Rebuild.
7144
7145 Fri Sep  1 08:12:50 1995  James G. Smith  <[email protected]>
7146
7147         * config.bfd: Add mips*vr4300-*-elf* target.
7148         * config/mipsbvr4300.mt: Added.
7149
7150 See file ChangeLog.2
7151
7152 \f
7153 Local Variables:
7154 mode: change-log
7155 left-margin: 8
7156 fill-column: 74
7157 version-control: never
7158 End:
This page took 0.45438 seconds and 4 git commands to generate.