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