* elf-m10300.c (bfd_mn10300_elf_merge_private_bfd_data): New function.
[binutils-gdb.git] / bfd / ChangeLog
1 Tue Jun 30 09:55:03 1998 Jeffrey A Law (law@cygnus.com)
2
3 * elf-m10300.c (bfd_mn10300_elf_merge_private_bfd_data): New function.
4 (bfd_elf32_bfd_merge_private_bfd_data): Define.
5
6 Thu Jun 25 18:31:41 1998 Richard Henderson <rth@cygnus.com>
7
8 ELF Section-level Garbage Collection:
9 * bfd.c (bfd_gc_sections): New.
10 * aout-adobe.c: Hook to default implementation.
11 * aout-target.h, aout-tic30.c, binary.c, bout.c: Likewise.
12 * coff-alpha.c, coff-mips.c, coff-rs6000.c, coffcode.h: Likewise.
13 * evax-alpha.c, i386msdos.c, i386os9k.c, ieee.c: Likewise.
14 * ihex.c, nlm-target.h, oasys.c, ppcboot.c, srec.c: Likewise.
15 * tekhex.c, versados.c: Likewise.
16 * libbfd-in.h (_bfd_nolink_bfd_gc_sections): New.
17 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_gc_sections.
18
19 * reloc.c (BFD_RELOC_VTABLE_INHERIT, BFD_RELOC_VTABLE_ENTRY): New.
20 (bfd_generic_gc_sections): New.
21 * section.c (SEC_KEEP): New.
22 (asection): Add gc_mark member.
23
24 * elfcode.h (elf_gc*): New name remappings.
25 * elflink.h (elf_link_input_bfd): Don't set contents on stabs
26 sections to be excluded.
27 (elf_gc_mark, elf_gc_sweep, elf_gc_sweep_symbol): New.
28 (elf_gc_propogate_vtable_entries_used): New.
29 (elf_gc_smash_unused_vtentry_relocs): New.
30 (elf_gc_sections, elf_gc_record_vtinherit, elf_gc_record_vtentry): New.
31 (elf_gc_common_finalize_got_offsets): New.
32 (elf_gc_allocate_got_offsets, elf_gc_common_final_link): New.
33 * elfxx-target.h: Add and default gc hooks.
34
35 * elf-bfd.h (struct elf_link_hash_entry): Swap got_offset/plt_offset
36 for unions.
37 (struct elf_obj_tdata): Likewise for local_got_offsets.
38 * elf.c, elf-i386.c, elf32-m68k.c, elf32-mips.c: Update all uses.
39 * elf32-ppc.c, elf32-sparc.c, elf64-alpha.c: Likewise.
40 * elf64-sparc.c, elflink.h: Likewise.
41
42 * elf-bfd.h (struct elf_link_hash_entry): Add vtable members.
43 (ELF_LINK_HASH_MARK): Define.
44 (struct elf_backend_data): Add GC hooks.
45 * elf.c (_bfd_elf_link_hash_newfunc): Zero vtable members.
46
47 * elf-m10300.c (mn10300_elf_check_relocs): New.
48 (mn10300_elf_gc_mark_hook): New.
49 (R_MN10300_GNU_VTINHERIT, R_MN10300_GNU_VTENTRY): New.
50 (elf_mn10300_howto, mn10300_reloc_map): Handle them.
51 (mn10300_elf_final_link_relocate): Likewise.
52 (mn10300_elf_relocate_section): Likewise.
53 (elf_backend_can_gc_sections): Define.
54 * elf32-mips.c (R_MIPS_GNU_VTINHERIT, R_MIPS_GNU_VTENTRY): New.
55 (elf_mips_gnu_vtinherit_howto, elf_mips_gnu_vtentry_howto): New.
56 (bfd_elf32_bfd_reloc_type_lookup): Handle them.
57 (mips_info_to_howto_rel): Likewise.
58 (mips_elf_relocate_section): Likewise.
59 (mips_elf_check_relocs): Likewise.
60 (mips_elf_gc_mark_hook, mips_elf_gc_sweep_hook): New.
61 (elf_backend_can_gc_sections): Define.
62 * elf32-ppc.c (R_PPC_GNU_VTINHERIT, R_PPC_GNU_VTENTRY): New.
63 (ppc_elf_howto_raw): Handle them.
64 (ppc_elf_reloc_type_lookup): Likewise.
65 (ppc_elf_relocate_section): Likewise.
66 (ppc_elf_check_relocs): Reference count .got and .plt entires.
67 Handle new vtable relocs.
68 (ppc_elf_adjust_dynamic_symbol): Recognize unused .plt entries.
69 (ppc_elf_gc_mark_hook, ppc_elf_gc_sweep_hook): New.
70 (elf_backend_can_gc_sections): Define.
71
72 Fri Jun 26 10:48:23 1998 Jeffrey A Law (law@cygnus.com)
73
74 * archures.c (bfd_mach_mn10300): Define.
75 * elf-m10300.c: Include elf/mn10300.h
76 (elf_mn10300_mach): New function.
77 (_bfd_mn10300_elf_final_write_processing): Likewise.
78 (_bfd_mn10300_elf_object_p): Likewise.
79 (elf_backendfinal_write_processing): Define.
80 (elf_backend_object_p): Likewise.
81 start-sanitize-am33
82 * archures.c (bfd_mach_am33): Define.
83 * cpu-m10300.c (bfd_am33_arch): New arch info structure. Link it
84 into the NEXT field of bfd_mn10300_arch.
85 end-sanitize-am33
86
87 Thu Jun 25 18:31:08 1998 Nick Clifton <nickc@cygnus.com>
88
89 * elf32-v850.c (v850_elf_perform_relocation): Fix HI16_S
90 relocation.
91
92 Wed Jun 24 17:17:57 1998 Ian Lance Taylor <ian@cygnus.com>
93
94 * elflink.h (elf_bfd_final_link): Loop over input_bfds using the
95 link_next field, not the next field.
96
97 Sun Jun 21 19:38:39 1998 Ian Lance Taylor <ian@cygnus.com>
98
99 * elf.c (map_sections_to_segments): Check the section address
100 against the phdr size both with and without a modulo of
101 maxpagesize.
102
103 Fri Jun 19 17:08:18 1998 Ian Lance Taylor <ian@cygnus.com>
104
105 * elf32-mips.c (mips_elf_size_dynamic_sections): Only strip a
106 linker created empty input section if the output section has the
107 same name.
108
109 * elflink.h (elf_link_output_extsym): Print an error message if
110 _bfd_elf_section_from_bfd_section fails.
111
112 * elf.c (_bfd_elf_section_from_bfd_section): Call bfd_set_error on
113 failure.
114
115 Tue Jun 16 11:55:55 1998 Ian Lance Taylor <ian@cygnus.com>
116
117 * elf.c (copy_private_bfd_data): Improve handling of Solaris
118 native linker output. Avoid putting an empty section in more than
119 one segment.
120
121 Fri Jun 12 13:30:17 1998 Tom Tromey <tromey@cygnus.com>
122
123 * po/Make-in (all-yes): If maintainer mode, depend on .pot file.
124 ($(PACKAGE).pot): Unconditionally depend on POTFILES.
125
126 Fri Jun 12 13:34:02 1998 Doug Evans <devans@canuck.cygnus.com>
127
128 * elf.c (swap_out_syms): New arg relocatable_p.
129 Don't add section VMA to symbols for relocatable output.
130 (_bfd_elf_compute_section_file_positions): Update call to
131 swap_out_syms.
132
133 Mon Jun 8 15:20:57 1998 Nick Clifton <nickc@cygnus.com>
134
135 * elf32-v850.c (v850_elf_perform_relocation): Make comparisons
136 against 'addend' be signed rather than unsigned.
137
138 Sat Jun 6 00:31:21 1998 Nick Clifton <nickc@cygnus.com>
139
140 * elf32-m32r.c: Add prototyps for static functions.
141
142 * coff-arm.c: Add prototypes for static functions.
143
144 Fri Jun 5 17:21:51 1998 Nick Clifton <nickc@cygnus.com>
145
146 * elf.c (elf_sort_sections): Sort by LMA first then VMA, since the
147 LMA is used to order sections in a segment.
148
149 * elf32-v850.c: Add prototypes for static functions.
150 Change type of addend parameter to bfd_vma in various functions.
151
152 Fri Jun 5 18:09:58 1998 Ian Lance Taylor <ian@cygnus.com>
153
154 * aoutx.h (howto_table_ext): Change RELOC_BASE13 to use
155 complain_overflow_signed instead of complain_overflow_bitfield.
156
157 Fri Jun 5 15:11:11 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
158
159 * elf.c (elf_map_symbols): Don't add section VMA to symbol value
160 when comparing against 0.
161
162 Wed Jun 3 17:52:49 1998 Ian Lance Taylor <ian@cygnus.com>
163
164 * Makefile.am (config.status): New target.
165 * Makefile.in: Rebuild.
166
167 start-sanitize-sky
168 Wed Jun 3 11:39:57 1998 Doug Evans <devans@canuck.cygnus.com>
169
170 * elf32-mips.c (_bfd_mips_elf_fake_sections): Update to use
171 Elf32_Dvp_External_Overlay instead of 64 bit version.
172
173 end-sanitize-sky
174 Wed Jun 3 12:18:24 1998 Stan Cox <scox@equinox.cygnus.com>
175
176 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Give an
177 error if previous object endianness doesn't match current object.
178
179 Tue Jun 2 17:50:59 1998 Nick Clifton <nickc@cygnus.com>
180
181 * elf32-v850.c (v850_elf_print_private_bfd_data): Call
182 _bfd_elf_print_private)bfd_data ().
183
184 Tue Jun 2 15:29:35 1998 Ian Lance Taylor <ian@cygnus.com>
185
186 * elflink.h (elf_merge_symbol): Don't always set type_change_ok
187 and size_change_ok.
188 (elf_link_add_object_symbols): Set type_change_ok and
189 size_change_ok before calling elf_merge_symbol.
190
191 * elf32-mips.c (mips_elf_relocate_section): If we issue an
192 undefined symbol error, don't also issue an overflow error.
193
194 Tue Jun 2 13:51:00 1998 Geoff Keating <geoffk@ozemail.com.au>
195
196 * elf32-ppc.c (ppc_elf_relocate_section): The target of an
197 R_PPC_LOCAL24PC relocation should be local; if not, print an error
198 message instead of crashing.
199
200 Mon Jun 1 18:23:12 1998 Yuli Barcohen <yuli.barcohen@telrad.co.il>
201
202 * archures.c (bfd_mach_cpu32): Define.
203 (bfd_default_scan): Add case for 68060. Fix 68332 case to use
204 bfd_mach_cpu32.
205 * cpu-m68k.c (arch_info_struct): Add m68k:cpu32.
206 * ieee.c: Include <ctype.h>.
207 (ieee_object_p): Parse out process ID string to make it more
208 likely to be acceptable for bfd_scan_arch.
209 * bfd-in2.h: Rebuild.
210
211 Mon Jun 1 11:12:02 1998 Nick Clifton <nickc@cygnus.com>
212
213 * elf32-m32r.c (m32r_elf_print_private_bfd_data): Also call
214 _bfd_elf_print_private_bfd_data() so that the program header will
215 be displayed.
216
217 Mon Jun 1 12:14:28 1998 Ian Lance Taylor <ian@cygnus.com>
218
219 * peicode.h (coff_swap_sym_in): Check for C_SECTION rather than
220 0x68. Reindent. Add some comments.
221
222 start-sanitize-sky
223 Sun May 31 16:11:22 1998 Doug Evans <devans@canuck.cygnus.com>
224
225 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Set sh_link
226 field of .DVP.ovlytab to .DVP.ovlystrtab's section index.
227 (_bfd_mips_elf_section_from_shdr): Recognize SHT_DVP_OVERLAY_TABLE
228 and SHT_DVP_OVERLAY.
229 (_bfd_mips_elf_fake_sections): Ditto.
230
231 end-sanitize-sky
232 Fri May 29 09:58:08 1998 Nick Clifton <nickc@cygnus.com>
233
234 * elf.c (copy_private_bfd_data): Adjust physical address of
235 segment in output BFD to contain LMAs of its sections.
236
237 Tue May 26 19:37:47 1998 Stan Cox <scox@equinox.cygnus.com>
238
239 * elf32-sparc.c (_bfd_sparc_elf_howto_table, sparc_reloc_map,
240 elf32_sparc_relocate_section): Added R_SPARC_32LE for little
241 endian data 32 bit relocations.
242 (elf32_sparc_merge_private_bfd_data): Check if linking little
243 endian objects with big endian objects.
244 (elf32_sparc_object_p): Set bfd_mach_sparc_sparclite_le.
245 (elf32_sparc_final_write_processing): Set EF_SPARC_LEDATA in e_flags.
246 * libbfd.h (bfd_reloc_code_real_names): Added BFD_RELOC_SPARC_32LE.
247 * reloc.c: Same.
248 * cpu-sparc.c (arch_info_struct): Added sparc:sparclite_le
249 * archures.c (bfd_mach_sparc_sparclite_le): New.
250 * bfd-in2.h (BFD_RELOC_SPARC_32LE, bfd_mach_sparc_sparclite_le): New.
251
252 Thu May 21 16:59:28 1998 Nick Clifton <nickc@cygnus.com>
253
254 * peicode.h (add_data_entry): Fix precedence of operators in if ()
255 statement.
256
257 Tue May 19 18:41:19 1998 Ian Lance Taylor <ian@cygnus.com>
258
259 * bfd-in.h: Move over patch to bfd-in2.h.
260
261 * reloc.c (bfd_check_overflow): Add casts before shifts which may
262 not fit in 32 bits.
263 (_bfd_relocate_contents): Likewise.
264
265 Mon May 18 14:44:15 1998 Nick Clifton <nickc@cygnus.com>
266
267 * peicode.h (add_data_entry): If the section has no private data
268 then do not create a Data Dictionary entry for it.
269
270 Mon May 18 00:09:28 1998 Richard Henderson <rth@cygnus.com>
271
272 * elf64-alpha.c (elf64_alpha_relax_section): Set again on changes.
273 (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots,
274 elf64_alpha_size_got_sections): Rewrite, handling multiple got
275 subsections during relaxation more correctly.
276
277 Thu May 14 14:22:58 1998 Nick Clifton <nickc@cygnus.com>
278
279 * bfd-in2.h: Add new prototype: bfd_coff_set_symbol_class ().
280 Add extra argument to bfd_arm_process_before_allocation ().
281 * bfd-in.h: Reflect changes made in bfd-in2.h.
282 * coffgen.c (bfd_coff_set_symbol_class): New function. Set the
283 coff class of a BFD symbol.
284 * coff-arm.c: Add support for interworking between Thumb code and
285 non-interworking aware ARM code.
286
287 Sun May 10 22:33:59 1998 Jeffrey A Law (law@cygnus.com)
288
289 * po/Make-in (install-info): New target.
290
291 Thu May 7 17:40:56 1998 Ian Lance Taylor <ian@cygnus.com>
292
293 * filemode.c: Remove; not used.
294
295 If sysdep.h includes a header file, don't include it again:
296 * aix386-core.c: Don't include <stdio.h>, <stddef.h>, or
297 <errno.h>.
298 * aoutx.h: Don't include <string.h>. Use "sysdep.h" rather than
299 <sysdep.h>.
300 * archive.c: Don't include <string.h> or <errno.h>.
301 * evax-alpha.c; Don't include <stdio.h>.
302 * evax-egsd.c: Likewise.
303 * evax-etir.c: Likewise.
304 * evax-misc.c: Likewise.
305 * evax-emh.c: Likewise. Also, don't include <sys/types.h>.
306 * hppabsd-core.c: Don't include <stdio.h>, <sys/types.h>, or
307 <errno.h>.
308 * hpux-core.c: Likewise.
309 * netbsd-core.c: Likewise.
310 * som.c: Likewise.
311 * libbfd.c: Don't include <sys/types.h>.
312 * nlmcode.h: Don't include <string.h>.
313 * osf-core.c: Don't include <string.h> or <stdio.h>.
314 * ptrace-core.c: Don't include <stdio.h>, <sys/types.h>,
315 <errno.h>, or <unistd.h>.
316 * trad-core.c: Don't include <stdio.h> or <sys/types.h>.
317
318 Thu May 7 13:12:50 1998 Klaus Kaempf <kkaempf@progis.de>
319
320 * configure.com: If the version number can not be found in
321 configure.in, set it to "unknown" rather than "2.8.1".
322
323 Wed May 6 09:46:05 1998 Gavin Koch <gavin@cygnus.com>
324
325 * elf32-mips.c (elf_mips_mach): New.
326 (_bfd_mips_elf_object_p): Use elf_mips_mach.
327 (_bfd_mips_elf_final_write_processing): Use the names
328 of machines, rather than the numbers. Set both the ARCH
329 and MACH in e_flags. Handle a few more specific machines.
330 (_bfd_mips_elf_merge_private_bfd_data): Merge both
331 EF_MIPS_ARCH and EF_MIPS_MACH.
332
333 Tue May 5 21:01:53 1998 Richard Henderson <rth@cygnus.com>
334
335 * syms.c (bfd_is_local_label): Revert last change.
336 * srec.c (srec_write_symbols): Discard debugging symbols.
337
338 Tue May 5 23:36:06 1998 Ian Lance Taylor <ian@cygnus.com>
339
340 * som.c: Include <ctype.h>.
341 * som.h: Don't include sysdep.h.
342
343 Tue May 5 18:29:24 1998 Tom Tromey <tromey@cygnus.com>
344
345 * libbfd.h: Rebuilt.
346 * libbfd-in.h: Removed gettext includes and defines.
347 * sysdep.h: Moved gettext-related includes and defines here.
348
349 Tue May 5 16:47:54 1998 Richard Henderson <rth@cygnus.com>
350
351 * srec.c (srec_write_symbols): Use bfd_is_local_label rather than
352 an ad-hoc test. Kill bogus #if 0 code.
353 * syms.c (bfd_is_local_label): Consider BSF_DEBUGGING symbols local.
354
355 Mon May 4 16:10:33 1998 Ian Lance Taylor <ian@cygnus.com>
356
357 * sunos.c (sunos_check_dynamic_reloc): Don't use the PLT address
358 when generating a normal executable for a symbol defined in a
359 regular file. When copying a reloc into the output file, adjust
360 the addend for a PC relative reloc against a global symbol.
361
362 Mon May 4 10:08:18 1998 Tom Tromey <tromey@cygnus.com>
363
364 * libbfd.h: Rebuilt.
365 * libbfd-in.h (_): Define as dgettext.
366
367 Mon May 4 11:02:23 1998 Ian Lance Taylor <ian@cygnus.com>
368
369 * coff-arm.c (coff_arm_relocate_section): Cast to bfd_signed_vma,
370 not signed.
371 * peicode.h (pe_saved_coff_bfd_print_private_bfd_data): Use PARAMS
372 when declaring parameter types.
373 (pe_saved_coff_bfd_copy_private_bfd_data): Likewise.
374
375 Wed Apr 29 15:35:03 1998 Ian Lance Taylor <ian@cygnus.com>
376
377 * config.bfd: If we include any ELF targets in targ_defvec and/or
378 targ_selvecs, then add the generic ELF targets to targ_selvecs.
379 * elf32-gen.c (dummy): New static const variable.
380 (elf_generic_info_to_howto): New static function.
381 (elf_generic_info_to_howto_rel): New static function.
382 (elf_info_to_howto): Define as elf_generic_info_to_howto.
383 (elf_info_to_howto_rel): Define as elf_generic_info_to_howto_rel.
384 * elf64-gen.c: Same changes as elf32-gen.c.
385 * elfcode.h (elf_object_p): For the generic target, ignore a
386 failure of bfd_default_set_arch_mach. Fix indentation a bit.
387
388 Tue Apr 28 20:05:52 1998 Ian Lance Taylor <ian@cygnus.com>
389
390 * configure.in (WIN32LIBADD): Add -lintl on cygwin32.
391 * configure: Rebuild.
392
393 Tue Apr 28 12:16:57 1998 Jason Molenda (crash@bugshack.cygnus.com)
394
395 * config.bfd: Update OSR5/Unixware patterns.
396
397 Mon Apr 27 18:02:24 1998 Richard Henderson <rth@cygnus.com>
398
399 * elf.c (assign_file_positions_for_segments): Allow for holes
400 between sections added by a link script.
401
402 Mon Apr 27 11:49:55 1998 Ian Lance Taylor <ian@cygnus.com>
403
404 * configure.in: Change version number to 2.9.4
405 * configure: Rebuild.
406
407 Based on patch from H.J. Lu <hjl@gnu.org>:
408 * elf.c (bfd_elf_get_bfd_needed_list): New function.
409 * bfd-in.h (bfd_elf_get_bfd_needed_list): Declare.
410 * bfd-in2.h: Rebuild.
411
412 Sat Apr 25 20:07:53 1998 Richard Henderson <rth@cygnus.com>
413
414 * elf64-alpha.c (struct alpha_relax_info): Replace elfsym with other.
415 Change all users.
416
417 Sat Apr 25 18:29:07 1998 Richard Henderson <rth@cygnus.com>
418
419 * elf64-alpha.c (struct alpha_relax_info): Add tsec & elfsym members.
420 (elf64_alpha_relax_section): Fill them in.
421 (elf64_alpha_relax_opt_call): Implement more than a stub.
422 (elf64_alpha_add_symbol_hook): Don't set SEC_LOAD or default
423 alignment on .scommon.
424 (elf64_alpha_merge_gots): Merge use counts as well.
425
426 Sat Apr 25 14:07:29 1998 Richard Henderson <rth@cygnus.com>
427
428 * elf64-alpha.c (elf64_alpha_relax_section): Use the proper section
429 for calculating a local symbol's address.
430 (elf64_alpha_calc_got_offsets): Skip entries with 0 use count.
431 Set the .got's cooked size as well as the raw size.
432
433 Fri Apr 24 09:16:00 1998 Nick Clifton <nickc@cygnus.com>
434
435 * elf32-v850.c (v850_elf_print_private_bfd_data): Add
436 internationalisation of printed information.
437
438 * coff-arm.c (coff_arm_print_private_bfd_data): Add
439 internationalisation of printed information.
440
441 Fri Apr 24 12:09:18 1998 Ian Lance Taylor <ian@cygnus.com>
442
443 * syms.c (struct indexentry): Change directory_name, file_name,
444 and function_name fields to char *.
445 (struct stab_find_info): Change cached_file_name field to char *.
446
447 Thu Apr 23 08:13:04 1998 Nick Clifton <nickc@cygnus.com>
448
449 * peicode.h (dir_names): Add missing N_() macros to dir_names array.
450
451 Wed Apr 22 13:06:15 1998 Tom Tromey <tromey@cygnus.com>
452
453 * po/Make-in (MKINSTALLDIRS): Don't look in $(top_srcdir).
454
455 Wed Apr 22 17:48:48 1998 Ian Lance Taylor <ian@cygnus.com>
456
457 * Makefile.am (install-data-local): Make $(includedir).
458 * Makefile.in: Rebuild.
459
460 Wed Apr 22 13:06:15 1998 Tom Tromey <tromey@cygnus.com>
461
462 * libbfd-in.h: Use `gettext' and not `dgettext' for now.
463
464 Wed Apr 22 12:53:40 1998 Ian Lance Taylor <ian@cygnus.com>
465
466 * Makefile.am (INCLUDES): Add -I$(srcdir)/../intl -I../intl.
467 * Makefile.in: Rebuild.
468
469 * bfd-in2.h: Rebuild for Nick's changes.
470
471 Tue Apr 21 23:11:51 1998 Richard Henderson <rth@cygnus.com>
472
473 * archive.c (_bfd_generic_read_ar_hdr_mag): Fix lossage in last
474 change wrt length == max_namelen.
475
476 Tue Apr 21 21:19:36 1998 Tom Tromey <tromey@scribbles.cygnus.com>
477
478 * Many files: Added gettext invocations around user-visible
479 strings.
480 * libbfd-in.h: Added gettext includes and defines.
481 * acconfig.h (ENABLE_NLS, HAVE_CATGETS, HAVE_GETTEXT, HAVE_STPCPY,
482 HAVE_LC_MESSAGES): Define.
483 * configure.in: Call CY_GNU_GETTEXT. Create po/Makefile.in and
484 po/Makefile.
485 * Makefile.am (SUBDIRS): Added po.
486 (POTFILES): New macro.
487 (po/POTFILES.in): New target.
488 (SOURCE_HFILES): New macro.
489 (HFILES): Use it.
490 * po/Make-in, po/POTFILES.in, po/bfd.pot: New files.
491
492 Tue Apr 21 13:38:18 1998 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
493
494 * elfcore.h (bfd_prstatus): Copy core_prstatus from the first
495 NT_PRSTATUS note section encountered, it contains the status of
496 the currently executing thread when the core file was written.
497
498 Tue Apr 21 10:00:12 1998 Nick Clifton <nickc@cygnus.com>
499
500 * libcoff.h: Add extra parameter to
501 bfd_coff_link_output_has_begun overrideable function.
502 * cofflink.c: Pass extra parameter to
503 bfd_coff_link_output_has_begun function.
504 * bfd-in.h: Add prototypes for exported ARM interworking
505 functions.
506 * peicode.h: ARM specific code reorganised to conform to BFD
507 coding conventions.
508 * coffcode.h: ARM specific code reorganised to conform to BFD
509 coding conventions.
510 * coff-arm.c: Code reorganised to conform to the BFD coding
511 conventions. Global variables have been moved into an ARM
512 specific hash table structure and a new function:
513 bfd_arm_get_bfd_for_interworking() has been created which is
514 called from the linker scripts.
515
516 Tue Apr 21 00:11:51 1998 Richard Henderson <rth@cygnus.com>
517
518 * archive.c (_bfd_generic_read_ar_hdr_mag): Simplify end-of-name test.
519
520 * elf64-alpha.c (elf64_alpha_find_reloc_at_ofs): Renamed from
521 elf64_alpha_relax_find_reloc_ofs. Changed all callers.
522 (elf64_alpha_add_symbol_hook): Put small commons in .scommon not .sbss.
523 (elf64_alpha_size_got_sections): Don't merge .got sections twice.
524
525 Sat Apr 18 01:21:04 1998 Stan Cox <scox@cygnus.com>
526
527 * config.bfd: Added sparc86x support.
528
529 Fri Apr 17 22:29:04 1998 Ian Lance Taylor <ian@cygnus.com>
530
531 * elf32-mips.c (mips_elf_relocate_section): Do not complain about
532 an out of range pc-relative jump/call to an undefined weak symbol.
533
534 Thu Apr 16 13:49:00 1998 Richard Henderson <rth@cygnus.com>
535
536 * elf64-alpha.c (elf64_alpha_do_reloc_gpdisp): Do all gpdisp
537 comparisons signed.
538
539 Thu Apr 16 11:43:33 1998 Ian Lance Taylor <ian@cygnus.com>
540
541 * archive.c (bfd_generic_archive_p): If a slurp subroutine returns
542 an error other than bfd_error_system_call, set the error to
543 bfd_error_wrong_format.
544
545 * targets.c (bfd_target_vector) [SELECT_VECS not defined]: Add
546 bfd_elf32_powerpcle_vec.
547
548 * elf.c (copy_private_bfd_data): If all the p_paddr fields in the
549 program segments are zero, don't set p_paddr_valid.
550
551 Wed Apr 15 22:15:16 1998 Richard Henderson <rth@cygnus.com>
552
553 * elf64-alpha.c: Initial implementation of relaxation --
554 (struct alpha_elf_link_hash_entry): Add use_count member.
555 (elf64_alpha_check_relocs): Initialize and increment it.
556 (elf64_alpha_can_merge_gots): Check it when considering merging.
557 (elf64_alpha_merge_gots): Drop entries with zero use.
558 (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
559 (elf64_alpha_always_size_sections): Split out got sizing ...
560 (elf64_alpha_size_got_sections): ... here. New function.
561 (elf64_alpha_relax_find_reloc_ofs): New function.
562 (elf64_alpha_relax_with_lituse): Likewise.
563 (elf64_alpha_relax_without_lituse): Likewise.
564 (elf64_alpha_relax_opt_call): Likewise.
565 (elf64_alpha_relax_section): Likewise.
566 (elf64_alpha_add_symbol_hook): Likewise.
567 (elf64_alpha_howto_table): Implement GPRELHIGH/LOW & IMMED_GP_16.
568 (elf64_alpha_relocate_section): Likewise.
569 (bfd_elf64_bfd_relax_section): Define.
570 (elf_backend_add_symbol_hook): Likewise.
571
572 Wed Apr 15 16:08:46 1998 Richard Henderson <rth@cygnus.com>
573
574 * elf.c (prep_headers): Use new EM_SPARCV9 symbol.
575 * elf64-sparc.c (ELF_MACHINE_CODE): Likewise.
576 (ELF_MACHINE_ALT1): New. Set to EM_OLD_SPARC64.
577
578 Wed Apr 15 11:34:33 1998 Ian Lance Taylor <ian@cygnus.com>
579
580 * configure.in: Add -lkernel32 to WIN32LIBADD on cygwin32.
581 * configure: Rebuild.
582
583 Mon Apr 13 16:46:27 1998 Ian Lance Taylor <ian@cygnus.com>
584
585 * Makefile.am (libbfd_la_LIBADD): Add @WIN32LIBADD@.
586 (libbfd_la_LDFLAGS): Add @WIN32LDFLAGS@.
587 * configure.in: Define and substitute WIN32LDFLAGS and
588 WIN32LIBADD.
589 * aclocal.m4: Rebuild with new libtool.
590 * configure, Makefile.in: Rebuild.
591
592 Fri Apr 10 13:44:27 1998 Ian Lance Taylor <ian@cygnus.com>
593
594 * coffcode.h (coff_write_object_contents): Move a PE COMDAT symbol
595 before any other symbols in the same section.
596
597 Wed Apr 8 14:50:23 1998 Michael Meissner <meissner@cygnus.com>
598
599 * config.bfd (powerpc*-*-*): Remove PowerPC NT support from ELF
600 systems.
601
602 Tue Apr 7 16:25:31 1998 Gavin Romig-Koch <gavin@cygnus.com>
603
604 * dwarf2.c (comp_unit): Move it earlier in the source. Add
605 addr_size.
606 (read_address): Replace 'bdf*' argument with 'comp_unit*' argument.
607 Use addr_size for address size, rather than sizeof(bfd_vma).
608 (read_attribute): Replace bdf* argument with 'comp_unit*' argument.
609 Fix call to read_address.
610 (decode_line_info): Replace bdf* argument with 'comp_unit*' argument.
611 Scrap other unneeded arguments. Fix call to read_address.
612 (scan_unit_for_functions): Fix call to read_attribute.
613 (parse_comp_unit): We now handle more values for addr_size.
614 Set addr_size in unit. Fix call to read_attribute and
615 decode_line_info.
616
617 Tue Apr 7 15:44:47 1998 Gavin Romig-Koch <gavin@cygnus.com>
618
619 * dwarf2.c (parse_comp_unit): Drop use of unit->name when it is null.
620
621 Tue Apr 7 12:35:18 1998 Ian Lance Taylor <ian@cygnus.com>
622
623 * archures.c (bfd_default_scan): Add m68k cases back to default
624 switch, reverting patch of March 25, since IEEE support depends
625 upon them.
626
627 Mon Apr 6 14:06:40 1998 Ian Lance Taylor <ian@cygnus.com>
628
629 * Makefile.am (diststuff): New target.
630 * Makefile.in: Rebuild.
631
632 Sun Apr 5 16:21:44 1998 Jeffrey A Law (law@cygnus.com)
633
634 * som.c (som_bfd_ar_write_symbol_stuff): Fix computation of
635 som_offset when we have an extended name table.
636
637 Sun Apr 5 16:04:39 1998 H.J. Lu <hjl@gnu.org>
638
639 * Makefile.am (stamp-lib): Check that .libs/libbfd.a exists before
640 trying to copy it.
641 * Makefile.in: Rebuild.
642
643 Fri Apr 3 11:09:42 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
644
645 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Generate section
646 symbols when creating a shared library.
647 (elf_m68k_adjust_dynindx): New function, used by above code.
648 (elf_m68k_finish_dynamic_sections): Initialize the section
649 symbols.
650 (elf_m68k_relocate_section): Change abort to BFD_ASSERT.
651
652 Wed Apr 1 16:04:02 1998 Nick Clifton <nickc@cygnus.com>
653
654 * coff-arm.c (in_reloc_p): Use ARM_RVA32 in place of constant
655 value 11.
656
657 Wed Apr 1 13:36:58 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
658
659 * elf32-m68k.c (elf_m68k_relocate_section, case R_68K_PLT*O): Fix
660 assertion.
661
662 Tue Mar 31 00:12:12 1998 Jeffrey A Law (law@cygnus.com)
663
664 * elf-m10300.c (mn10300_elf_relax_section): Correctly handle
665 absolute symbols.
666
667 Mon Mar 30 12:46:15 1998 Ian Lance Taylor <ian@cygnus.com>
668
669 * configure.in: Set version to 2.9.1.
670 * configure: Rebuild.
671
672 * Branched binutils 2.9.
673
674 Mon Mar 30 12:20:50 1998 Brent Baccala <baccala@freesoft.org>
675
676 * syms.c (ENABLE_CACHING): Define.
677 (struct indexentry): Define.
678 (struct stab_cache): Remove.
679 (cmpindexentry): New static function.
680 (struct stab_find_info): Add new fields: indextable,
681 indextablesize, cached_indexentry, cached_offset, cached_stab, and
682 cached_file_name. Remove fields: file_cache, function_cache, and
683 line_cache.
684 (_bfd_stab_section_find_nearest_line): Rewrite to build a sorted
685 index table and search it.
686
687 Mon Mar 30 10:39:34 1998 Ian Lance Taylor <ian@cygnus.com>
688
689 * elf.c (_bfd_elf_copy_private_section_data): Call
690 copy_private_bfd_data once we've seen the last SEC_ALLOC section.
691
692 * cpu-mips.c: Remove trailing comma at end of enumeration list.
693
694 Sat Mar 28 16:33:02 1998 Ian Lance Taylor <ian@cygnus.com>
695
696 * coff-arm.c: Define all globally visible variables and functions
697 only when COFF_WITH_PE is not defined.
698 * configure.in (armpe_little_vec, armpe_big_vec): Add
699 coff-arm.lo.
700 * configure: Rebuild.
701
702 Fri Mar 27 16:06:02 1998 Ian Lance Taylor <ian@cygnus.com>
703
704 Fix some gcc -Wall warnings:
705 * aout-arm.c (MY(fix_pcrel_26)): Add casts to avoid warnings.
706 * archive.c (_bfd_generic_read_ar_hdr_mag): Likewise.
707 * archures.c (bfd_default_scan): Likewise.
708 * bfd.c (bfd_scan_vma): Likewise.
709 * binary.c (mangle_name): Likewise
710 * coff-arm.c (aoutarm_fix_pcrel_26): Likewise.
711 * coff-sh.c (sh_relocate_section): Likewise.
712 * coff-stgo32.c (create_go32_stub): Likewise.
713 * coffcode.h (coff_slurp_line_table): Likewise.
714 * ecoff.c (_bfd_ecoff_write_armap): Likewise.
715 * elf.c (_bfd_elf_make_section_from_shdr): Likewise.
716 (assign_file_positions_for_segments): Likewise.
717 * elf32-mips.c (mips_elf_relocate_section): Likewise.
718 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
719 * oasys.c (oasys_write_sections): Likewise.
720 * ppcboot.c (ppcboot_object_p): Likewise.
721 (mangle_name): Likewise.
722 * riscix.c (riscix_fix_pcrel_26): Likewise.
723 * srec.c (srec_scan): Likewise.
724 * stabs.c (_bfd_write_section_stabs): Likewise.
725 * sunos.c (sunos_add_dynamic_symbols): Likewise.
726 * aout-ns32k.c (_bfd_ns32k_relocate_contents): Add default case to
727 switch. Declare parameters for function pointers.
728 * archures.c (bfd_default_scan): Add braces to avoid ambiguous if
729 warning.
730 * elf.c (elf_sort_sections): Likewise.
731 * coff-arm.c (coff_thumb_pcrel_common): Initialize relocation.
732 Add default cases to switches.
733 (coff_arm_relocate_section): Remove unused local variables.
734 Always set rstat.
735 (coff_arm_bfd_set_private_flags): Change flag variable to type
736 flagword.
737 * coff-mips.c (mips_relocate_section): Initialize use_lo.
738 * coff-ppc.c (ppc_record_toc_entry): Change i to unsigned int.
739 (dump_toc): Change cat to const, and initialize it.
740 * coff-sh.c (sh_relax_delete_bytes): Initialize start and voff.
741 * elf32-sh.c (sh_elf_relax_delete_bytes): Likewise.
742 (sh_elf_relocate_section): Initialize r_symndx.
743 * coffcode.h (coff_compute_section_file_positions): Only declare
744 old_sofar if ALIGN_SECTIONS_IN_FILE.
745 (coff_write_object_contents): Initialize csym.
746 * coffgen.c (coff_pointerize_aux): Make type and class unsigned.
747 * cpu-ns32k.c (_bfd_ns32k_get_displacement): Add default case to
748 switch.
749 * dwarf2.c: Include libiberty.h.
750 (read_2_signed_bytes, read_4_signed_bytes): Comment out.
751 (decode_line_info): Remove unused local variables.
752 * elf32-m32r.c (m32r_elf_sda16_reloc): Likewise.
753 (m32r_elf_relocate_section): Likewise.
754 * elf32-v850.c (v850_elf_store_addend_in_insn): Likewise.
755 (v850_elf_reloc): Likewise.
756 * elf-bfd.h (elf_linker_section_t): Make alignment unsigned.
757 (struct elf_obj_tdata): Make cverdefs and cverrefs unsigned.
758 * elf.c (assign_file_positions_for_segments): Always set adjust.
759 start-sanitize-d30v
760 * elf32-d30v.c (bfd_elf_d30v_reloc): Initialize tmp_addr. Fully
761 parenthesize expression.
762 end-sanitize-d30v
763 * elf32-m32r.c (m32r_elf_relocate_section): Always initialize h.
764 (m32r_elf_object_p): Return a value.
765 (m32r_elf_print_private_bfd_data): Change fprintf format string.
766 * elf32-mips.c (mips_elf_final_link): Initialize last.
767 (mips_elf_finish_dynamic_sections): Initialize last and dindx.
768 * elf32-v850.c (v850_elf_object_p): Return a value.
769 (v850_elf_print_private_bfd_data): Change fprintf format string.
770 * elfcode.h (elf_slurp_symbol_table): Change symcount and i to
771 unsigned long.
772 * elflink.h (elf_link_add_object_symbols): Change vernum to
773 unsigned int, and initialize it. Change fprintf format string.
774 (NAME(bfd_elf,size_dynamic_sections)): Cast -1 to bfd_size_type
775 when setting or comparing to soname_indx.
776 (elf_create_pointer_linker_section): Change num_symbols to
777 unsigned int.
778 * libcoff-in.h (coff_data_type): Change flags to flagword.
779 * peicode.h (pe_print_idata): Initialize idx. Change j to
780 bfd_size_type. Initialize hint_member. Remove useless test to
781 time_stamp.
782 (pe_print_edata): Change num_functions and num_names in struct
783 EDT_type to unsigned long. Remove cast. Change fprintf format
784 string.
785 * ppcboot.c (ppcboot_object_p): Change i to size_t.
786 * reloc.c (bfd_get_reloc_size): Change return type to unsigned
787 int.
788 * reloc16.c (bfd_coff_reloc16_relax_section): Change shrinks to
789 int *. Update uses. Change j to long.
790 * bfd-in2.h, libcoff.h: Rebuild.
791
792 Fri Mar 27 10:10:46 1998 Catherine Moore <clm@cygnus.com>
793
794 * elf32-v850.c Remove definition of USE_REL.
795 (v850_elf_info_to_howto_rela): New function.
796 (v850_elf_perform_relocation): Renamed from
797 v850_elf_store_addend_in_insn. Removed replace argument.
798 (v850_elf_reloc): store the relocation in the addend field instead
799 of the insn.
800 (v850_elf_final_link_relocate): Now calls
801 v850_elf_perform_relocation.
802 (v850_elf_relocate_section): Remove code to generate REL
803 relocations.
804
805 Thu Mar 26 13:32:17 1998 Ian Lance Taylor <ian@cygnus.com>
806
807 * coffcode.h (coff_new_section_hook): Set the type and storage
808 class in the native symbol information allocated for a new section
809 symbol.
810
811 Thu Mar 26 10:13:41 1998 Nick Clifton <nickc@cygnus.com>
812
813 * peicode.h: Chain together calls to
814 coff_bfd_copy_private_bfd_data and
815 coff_bfd_print_private_bfd_data.
816
817 * coff-arm.c: Add prototypes for
818 coff_arm_bfd_print_private_bfd_data and
819 coff_arm_bfd_copy_private_bfd_data.
820
821 Wed Mar 25 15:45:55 1998 Nick Clifton <nickc@cygnus.com>
822
823 * coffcode.h (coff_mkobject_hook): Set private falgs even for a PE
824 build.
825
826 * peicode.h: Call arm-coff private data functions after handling
827 pe private data.
828
829 * coff-arm.c: Turn statics into globals so that they can be shared
830 both pe and pei backends.
831
832 Wed Mar 25 15:19:38 1998 Ian Lance Taylor <ian@cygnus.com>
833
834 * aoutf1.h (sunos_set_arch_mach): Use bfd_mach_m68* rather than
835 plain numbers.
836 (sunos_write_object_contents): Likewise.
837 * aoutx.h (NAME(aout,machine_type)): Likewise.
838 * coffcode.h (coff_set_arch_mach_hook): Likewise.
839
840 Wed Mar 25 13:59:24 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
841
842 * archures.c (bfd_mach_m68*): Add definitions for various m68k
843 variants.
844 (bfd_default_scan): Remove m68k special cases.
845 * bfd-in2.h: Rebuild.
846 * mipsbsd.c (MY(write_object_contents)): Use bfd_mach_m68* rather
847 than plain numbers.
848 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
849 * cpu-m68k.c (arch_info_struct): Likewise. Add entry for
850 m68k:68000.
851 (bfd_m68k_arch): Set mach field to zero to signal no explicit
852 selection, change printable_name to just "m68k" and make that the
853 default instead of m68k:68020.
854
855 * aout-tic30.c (NAME): Define this to avoid multiple definitions
856 from aoutx.h.
857 (MY_get_section_contents): Define as aout_32_get_section_contents
858 rather than NAME(aout,get_section_contents).
859
860 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Fix cast.
861
862 * evax-alpha.c (evax_set_arch_mach): Only accept bfd_arch_alpha
863 and call bfd_default_set_arch_mach to do the real work.
864
865 Wed Mar 25 10:41:35 1998 Richard Henderson <rth@cygnus.com>
866
867 * bout.c (BALX): Include return register g14 as part of the insn.
868 (BALX_MASK): New.
869 (calljx_callback): Use it.
870
871 Wed Mar 25 11:19:28 1998 Ian Lance Taylor <ian@cygnus.com>
872
873 * libbfd-in.h (BFD_ALIGN): Cast this parameter to bfd_vma.
874 * libbfd.h: Rebuild.
875
876 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Change
877 byte_count to unsigned int.
878 (mn10300_elf_relax_section): Initialize internal_relocs. Remove
879 unused local variables.
880
881 * evax-alpha.c (evax_close_and_cleanup): Remove unused local
882 variables er and er1.
883
884 * cpu-v850.c: Include <ctype.h>.
885 (scan): Case isdigit argument to unsigned char.
886
887 From Yan Meroth <YAN.MEROTH@st.com>:
888 * ihex.c (ihex_scan): Add extbase variable so that getting an
889 extended linear address record does not ignore any previous
890 extended address.
891 (ihex_write_object_contents): When writing out an extended linear
892 address record, zero out any previous extended address.
893
894 Tue Mar 24 16:09:43 1998 Manfred Hollstein <manfred@s-direktnet.de>
895
896 * ieee.c (do_one): Check section before dereferencing it.
897 (ieee_canonicalize_reloc): Likewise with src->relent.sym_ptr_ptr.
898 (ieee_generic_stat_arch_elt): Likewise with abfd->my_archive.
899
900 Mon Mar 23 18:51:47 1998 Joel Sherrill <joel@OARcorp.com>
901
902 * config.bfd: (sh*-*-rtems*): Switched from ELF to COFF.
903
904 Mon Mar 23 14:23:36 1998 Nick Clifton <nickc@cygnus.com>
905
906 * coff-arm.c: Add interworking functions to pe backends.
907
908 start-sanitize-r5900
909 Sun Mar 22 13:05:08 1998 Jeffrey A Law (law@cygnus.com)
910
911 * elf32-mips.c (R_MIPS15_S3): New relocation type.
912 (elf_mips_howto_table): Add R_MIPS15_S3.
913 (mips_reloc_map): Map BFD_RELOC_MIPS15_S3 to R_MIPS15_S3.
914 * reloc.c (BFD_RELOC_MIPS15_S3): New relocation type.
915 * bfd-in2.h, libbfd.h: Rebuilt.
916
917 end-sanitize-r5900
918 Fri Mar 20 18:47:20 1998 Ian Lance Taylor <ian@cygnus.com>
919
920 * configure.in: Use AM_DISABLE_SHARED.
921 * aclocal.m4, configure: Rebuild with libtool 1.2.
922
923 Fri Mar 20 11:25:41 1998 Nick Clifton <nickc@cygnus.com>
924
925 * coff-arm.c (coff_arm_relocate_section): Better error messages
926 when interowrking conflucts occur. Courtesy of Jonathan Walton
927 and Tony Thompson.
928 (aoutarm_std_reloc_howto): Fixed bitsize fields of rightshifted
929 relocations. Patch courtesy of Jonathan Walton and Tony
930 Thompson.
931
932 Fri Mar 20 02:26:43 1998 Richard Henderson <rth@cygnus.com>
933
934 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Revert
935 part of Feb 22 change controling when to override the existing
936 symbol with the .plt entry.
937
938 Wed Mar 18 09:26:25 1998 Nick Clifton <nickc@cygnus.com>
939
940 * config.bfd (targ_cpu): Add thumb-pe target.
941
942 * coffcode.h (OTHER_GLOBAL_CLASS): Support thumb external
943 functions in PE build.
944
945 Sun Mar 8 23:37:26 1998 Stan Cox <scox@equinox.cygnus.com>
946
947 * config.bfd (sparclite-*-elf*): Added.
948
949 start-sanitize-vr4320
950 Tue Mar 3 11:24:05 1998 Gavin Koch <gavin@cygnus.com>
951
952 * mips-cpu.c: Reorganize sanitization.
953
954 * archures.c, bfd-in2.h, mips-cpu.c : Added bfd_mach_mips4320.
955
956 end-sanitize-vr4320
957 Mon Feb 23 19:31:19 1998 Ian Lance Taylor <ian@cygnus.com>
958
959 * configure.in: Add elf.lo to elf shell variable.
960 * Makefile.am (BFD_LIBS): Remove elf.lo.
961 (BFD_LIBS_CFILES): Remove elf.c.
962 (BFD32_BACKENDS): Add elf.lo.
963 (BFD32_BACKENDS_CFILES): Add elf.c.
964 * configure, Makefile.in: Rebuild.
965
966 1998-02-23 15:53 Richard Henderson <rth@cygnus.com>
967
968 * elf32-i386.c (elf_i386_relocate_section): A pc-relative
969 relocation against a now-local symbol should not have a dynamic
970 relocation.
971
972 Mon Feb 23 16:17:08 1998 Ian Lance Taylor <ian@cygnus.com>
973
974 * peicode.h (coff_swap_filehdr_in): Don't set BFD flag HAS_SYMS in
975 COFF filehdr flags.
976 (pe_print_private_bfd_data): Print PE flags. From Mikey
977 <jeffdb@netzone.com>.
978
979 Sun Feb 22 20:39:00 1998 Richard Henderson <rth@cygnus.com>
980
981 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Don't create
982 a plt entry when we can determine that we authoritatively define
983 the symbol.
984
985 Sun Feb 22 20:33:05 1998 Richard Henderson <rth@cygnus.com>
986
987 * configure.in (COREFILE selection): Remove sparc-*-linux*. They
988 don't actually use trad-core, but a SunOS-style core file handled
989 by gdb directly.
990 * hosts/sparclinux.h: Remove.
991
992 start-sanitize-sky
993 Thu Feb 19 02:38:52 1998 Doug Evans <devans@charmed.cygnus.com>
994
995 * reloc.c (BFD_RELOC_MIPS_DVP_27_S4): New reloc type.
996 * elf32-mips.c (enum reloc_type): Add R_MIPS_DVP_27_S4.
997 (elf_mips_dvp_27_s4_howto): Describe it.
998 (bfd_elf32_bfd_reloc_type_lookup): Handle it.
999 (mips_info_to_how_rel): Handle it.
1000 (mips_elf_relocate_section): Handle it.
1001 * bfd-in2.h,libbfd.h: Regenerate.
1002
1003 end-sanitize-sky
1004 Wed Feb 18 15:31:06 1998 Ian Lance Taylor <ian@cygnus.com>
1005
1006 * peicode.h (pe_print_idata): If there is no .idata section, look
1007 for the import tables in some other section. Make the initial
1008 label line up better with the data. Print the import address
1009 table even if there is no import name table. If the import
1010 address table holds actual addresses, print them.
1011
1012 start-sanitize-sky
1013 Tue Feb 17 20:00:26 1998 Doug Evans <devans@canuck.cygnus.com>
1014
1015 * config.bfd (targ_archs): If mips64r5900-sky-elf, add bfd_dvp_arch.
1016
1017 end-sanitize-sky
1018 Tue Feb 17 12:58:34 1998 Ian Lance Taylor <ian@cygnus.com>
1019
1020 * libbfd.c (bfd_seek): If fseek fails, save errno around call to
1021 bfd_tell. If errno is EINVAL, set bfd_error_file_truncated, not
1022 bfd_error_system_call.
1023
1024 Fri Feb 13 13:11:33 1998 Ian Lance Taylor <ian@cygnus.com>
1025
1026 * Makefile.am (AUTOMAKE_OPTIONS): Define.
1027 * configure, Makefile.in, aclocal.m4: Rebuild with automake 1.2e.
1028
1029 From H.J. Lu <hjl@gnu.org>:
1030 * Makefile.am (libbfd_la_LDFLAGS): Define.
1031 * Makefile.in: Rebuild.
1032
1033 Thu Feb 12 17:31:11 1998 Ian Lance Taylor <ian@cygnus.com>
1034
1035 NetBSD patches from Gordon W. Ross <gwr@mc.com>:
1036 * netbsd.h (MACHTYPE_OK): Define.
1037 (MY(write_object_contents)): Use DEFAULT_ARCH and DEFAULT_MID when
1038 calling N_SET_MACHTYPE, rather than having a switch.
1039 * libaout.h (enum machine_type): Add M_PMAX_NETBSD, M_VAX_NETBSD,
1040 and M_ALPHA_NETBSD.
1041 * i386netbsd.c (MACHTYPE_OK): Don't define.
1042 (DEFAULT_MID): Define.
1043 * m68k4knetbsd.c (SEGMENT_SIZE): Don't define.
1044 (MACHTYPE_OK): Don't define.
1045 (DEFAULT_MID): Define.
1046 * m68knetbsd.c: (MACHTYPE_OK): Don't define.
1047 (DEFAULT_MID): Define.
1048 * ns32knetbsd.c (MACHTYPE_OK): Don't define.
1049 (DEFAULT_MID): Define.
1050 * sparcnetbsd.c (MACHTYPE_OK): Don't define.
1051 (DEFAULT_MID): Define.
1052
1053 NetBSD patches from Gordon W. Ross <gwr@mc.com>:
1054 * vaxnetbsd.c: New file.
1055 * netbsd-core.c: Clean up. Remove unused macros. Use netbsd
1056 rather than netbsd_core.
1057 * targets.c (vaxnetbsd_vec): Declare.
1058 (bfd_target_vector): Add vaxnetbsd_vec. If NETBSD_CORE is
1059 defined, add netbsd_core_vec.
1060 * configure.in: Set COREFILE for alpha*-*-netbsd* and
1061 powerpc-*-netbsd* to netbsd-core.lo. If COREFILE is
1062 netbsd-core.lo, set COREFLAG to -DNETBSD_CORE.
1063 * config.bfd (alpha*-*-netbsd*): New target.
1064 * Makefile.am: Rebuild dependencies.
1065 (BFD32_BACKENDS): Add vaxnetbsd.lo.
1066 (BFD32_BACKENDS_CFILES): Add vaxnetbsd.c.
1067 * configure, Makefile.in: Rebuild.
1068
1069 * configure.host: Remove the old shared library build stuff. We
1070 now use libtool instead.
1071
1072 Wed Feb 11 17:13:09 1998 Richard Henderson <rth@cygnus.com>
1073
1074 * tekhex.c (tekhex_write_object_contents): Call tekhex_init.
1075
1076 Tue Feb 10 19:23:28 1998 H.J. Lu <hjl@gnu.org>
1077
1078 * configure.in: Take stab-syms.lo out of sparclinux_vec list.
1079 * configure: Rebuild.
1080
1081 Tue Feb 10 15:16:38 1998 Nick Clifton <nickc@cygnus.com>
1082 start-sanitize-m32rx
1083 * elf32-m32r.c (m32r_elf_merge_private_bfd_data): Do not complain
1084 when merging m32r BFDs into m32rx BFDs.
1085 end-sanitize-m32rx
1086 * elf32-v850.c (remember_hi16s_reloc): New function.
1087 (find_remembered_hi16s_reloc): New function.
1088 (v850_elf_store_addend_in_insn): Use the above new functions to
1089 match up HI6S relocs with LO16 relocs.
1090
1091 start-sanitize-sky
1092 Tue Feb 10 13:25:14 1998 Doug Evans <devans@canuck.cygnus.com>
1093
1094 * archures.c (bfd_mach_dvp_{vif,gif}): Renamed from ..._{pke,gpuif}.
1095 (bfd_txvu_arch): Delete.
1096 * cpu-mips.c (arch_info_struct): dvp:{vif,gif} renamed from
1097 dvp:{pke,gpuif}.
1098 * bfd-in2.h: Regenerate.
1099
1100 end-sanitize-sky
1101 Tue Feb 10 15:01:39 1998 Ian Lance Taylor <ian@cygnus.com>
1102
1103 * configure.in: Change -linux* to -linux-gnu*.
1104 * config.bfd, configure.host: Likewise.
1105 * configure: Rebuild.
1106
1107 Mon Feb 9 19:40:59 1998 Nick Clifton <nickc@cygnus.com>
1108
1109 * elf32-v850.c (v850_elf_store_addend_in_insn): Fix another
1110 LO16/HI16S bug and improve comments about what is going on.
1111
1112 Sat Feb 7 15:27:03 1998 Ian Lance Taylor <ian@cygnus.com>
1113
1114 * configure, aclocal.m4: Rebuild with new libtool.
1115
1116 start-sanitize-v850e
1117 Fri Feb 6 14:48:20 1998 Nick Clifton <nickc@cygnus.com>
1118
1119 * elf32-v850.c (v850_elf_merge_private_bfd_data): Do not complain
1120 when merging v850 code into v850e/v850ea code. Do not initialise
1121 output flags if the input is the default architecture.
1122 end-sanitize-v850e
1123 Fri Feb 6 11:50:22 1998 Jeffrey A Law (law@cygnus.com)
1124
1125 start-sanitize-r5900
1126 * cpu-mips.c (arch_info_struct): Make r5900 pointer size 32bits.
1127 end-sanitize-r5900
1128 * elf32-mips.c (bfd_elf32_bfd_reloc_type_lookup): For BFD_RELOC_CTOR
1129 get the size from bfd_arch_bits_per_address instead of directly
1130 from the isa.
1131
1132 Thu Feb 5 14:21:34 1998 Michael Meissner <meissner@cygnus.com>
1133
1134 * libbfd-in.h (BFD_ALIGN): If rounding up would cause the address
1135 to wrap, just return all 1's bits instead.
1136 * libbfd.h: Regenerate.
1137
1138 Thu Feb 5 11:51:05 1998 Ian Lance Taylor <ian@cygnus.com>
1139
1140 * coff-i386.c (coff_pe_i386_relocate_section): New static function
1141 if COFF_WITH_PE.
1142 (coff_relocate_section): If COFF_WITH_PE, define as
1143 coff_pe_i386_relocate_section.
1144 * coffcode.h (coff_write_object_contents): If COFF_IMAGE_WITH_PE,
1145 skip empty sections, to match coff_write_object_contents.
1146
1147 * elf64-mips.c (mips_elf64_swap_reloca_out): Swap out r_addend,
1148 rather than swapping out r_offset twice. From Luke Deller
1149 <luked@cse.unsw.edu.au>.
1150
1151 Wed Feb 4 19:11:28 1998 Ian Lance Taylor <ian@cygnus.com>
1152
1153 * configure.in: Set libtool_enable_shared rather than
1154 libtool_shared. Remove diversion hack.
1155 * configure, Makefile.in, doc/Makefile.in, aclocal.m4: Rebuild
1156 with new libtool.
1157
1158 Wed Feb 4 16:10:21 1998 Brent Baccala <baccala@freesoft.org>
1159
1160 * syms.c (struct stab_cache): Define.
1161 (struct stab_find_info): Remove cached_offset, cached_stab,
1162 cached_str, and cached_stroff fields. Add file_cache,
1163 function_cache, and line_cache fields.
1164 (_bfd_stab_section_find_nearest_line): Use extensive caching to
1165 speed up searches.
1166
1167 Wed Feb 4 13:34:22 1998 Ian Lance Taylor <ian@cygnus.com>
1168
1169 * peicode.h (pe_print_idata): Check for import of ordinal rather
1170 than name.
1171 (pe_print_edata): If there is no .edata section, look for the
1172 export data in some other section.
1173
1174 Mon Feb 2 20:05:42 1998 Jason Molenda (crash@bugshack.cygnus.com)
1175
1176 * configure.in: Change version to 2.8.4.
1177 * configure: Regenerated.
1178
1179 Mon Feb 2 17:39:39 1998 Steve Haworth <steve@pm.cse.rmit.EDU.AU>
1180
1181 Add tms320c30 support:
1182 * cpu-tic30.c: New file.
1183 * aout-tic30.c: New file.
1184 * coff-tic30.c: New file.
1185 * archures.c (bfd_arch_tic30): Define.
1186 (bfd_tic30_arch): Declare.
1187 (bfd_archures_list): Add bfd_tic30_arch.
1188 * targets.c (bfd_target_vector): Add tic30_aout_vec and
1189 tic30_coff_vec.
1190 * reloc.c (BFD_RELOC_TIC30_LDP): Define.
1191 * coffcode.h (coff_set_arch_mach_hook): Add tic30 case.
1192 (coff_set_flags): Likewise.
1193 * config.bfd (tic30-*-*aout*, tic30-*-*coff*): New targets.
1194 * configure.in (tic30_aout_vec, tic30_coff_vec): New vectors.
1195 * Makefile.am: Rebuild dependencies.
1196 (ALL_MACHINES): Add cpu-tic30.lo.
1197 (ALL_MACHINES_CFILES): Add cpu-tic30.c.
1198 (BFD32_BACKENDS): Add aout-tic30.lo and coff-tic30.lo.
1199 (BFD32_BACKENDS_CFILES): Add aout-tic30.c and coff-tic30.c.
1200 * configure, Makefile.in, bfd-in2.h, libbfd.h: Rebuild.
1201
1202 Mon Feb 2 12:25:12 1998 Nick Clifton <nickc@cygnus.com>
1203
1204 * elf32-v850.c (v850_elf_store_addend_in_insn): Allow HI16_S reloc
1205 to lag behind LO16 reloc by a couple of instructions.
1206
1207 Mon Feb 2 14:09:46 1998 Ian Lance Taylor <ian@cygnus.com>
1208
1209 * Makefile.am ($(srcdir)/bfd-in2.h): Add dummy command to force
1210 make to reexamine the file timestamp.
1211 ($(srcdir)/libbfd.h, $(srcddir)/libcoff.h): Likewise.
1212
1213 * elf64-alpha.c (ELF_MAXPAGESIZE): Change to 0x10000 from
1214 0x100000.
1215
1216 start-sanitize-sky
1217 Fri Jan 30 17:48:17 1998 Doug Evans <devans@canuck.cygnus.com>
1218
1219 * elf32-mips.c (elf_mips_dvp_11_pcrel_howto): Set pcrel_offset=true
1220 and partial_inplace=false.
1221 (mips_elf_relocate_section): Recognize R_MIPS_DVP_11_PCREL.
1222
1223 end-sanitize-sky
1224 Fri Jan 30 19:07:07 1998 Geoff Keating <geoffk@ozemail.com.au>
1225
1226 * elf32-ppc.c (ppc_elf_create_dynamic_sections): New procedure
1227 to create .dynsbss and .rela.sbss sections.
1228 (ppc_elf_adjust_dynamic_symbol): Put space for small data to be
1229 copied from dynamic objects into .sbss.
1230 (ppc_elf_size_dynamic_sections): Strip .rela.sbss if we don't
1231 use it. Correct typo of .rela.sdata2.
1232 (ppc_elf_finish_dynamic_symbol): Generate reloc to where we
1233 put the data, which may now be in .sbss.
1234 (ppc_elf_relocate_section): A SDAREL16 reloc can be in dynsbss.
1235 (elf_backend_create_dynamic_sections): Define as
1236 ppc_elf_create_dynamic_sections.
1237
1238 * elf32-ppc.c (ppc_elf_check_relocs): Don't emit R_PPC_REL* relocs
1239 against _GLOBAL_OFFSET_TABLE_.
1240 (ppc_elf_relocate_section): Don't emit R_PPC_REL32 relocs in
1241 shared libraries which refer to local symbols. Make sure that the
1242 test for allocating space for a reloc in a shared object is the
1243 same as the test for emitting a reloc.
1244
1245 start-sanitize-sky
1246 Thu Jan 29 17:44:53 1998 Doug Evans <devans@canuck.cygnus.com>
1247
1248 * elf32-mips.c: Add dvp support.
1249
1250 end-sanitize-sky
1251 Thu Jan 29 15:55:35 1998 J.J. van der Heijden <J.J.vanderHeijden@student.utwente.nl>
1252
1253 * config.bfd (i[3456]-*-mingw32*): New target.
1254 * acinclude.m4 (BFD_BINARY_OPEN): Check for mingw32.
1255 * aclocal.m4, configure: Rebuild.
1256
1257 start-sanitize-sky
1258 Wed Jan 28 15:14:28 1997 Doug Evans <devans@canuck.cygnus.com>
1259
1260 * config.bfd, configure.in: Add dvp support.
1261 * configure: Regenerate.
1262 * aclocal.m4: Regenerate.
1263 * archures.c, reloc.c, cpu-mips.c: Add dvp support.
1264 * bfd-in2.h, libbfd.h, libcoff.h: Regenerate.
1265
1266 end-sanitize-sky
1267 Wed Jan 28 13:41:26 1998 Ian Lance Taylor <ian@cygnus.com>
1268
1269 * elf.c (_bfd_elf_close_and_cleanup): Only check the strtab if we
1270 have a bfd_object.
1271
1272 Tue Jan 27 21:43:55 1998 Richard Henderson <rth@cygnus.com>
1273
1274 Sparc v9 ABI compliant PLT:
1275 * elf64-sparc.c (PLT_HEADER_SIZE): V9 ABI uses 4 entries.
1276 (plt_templates, sparc64_elf_build_plt_entry): Delete.
1277 (LARGE_PLT_THRESHOLD): New define.
1278 (GOT_RESERVED_ENTRIES): V9 ABI only uses 1.
1279 (sparc64_elf_build_plt): New function.
1280 (sparc64_elf_plt_entry_offset): Likewise.
1281 (sparc64_elf_plt_ptr_offset): Likewise.
1282 (sparc64_elf_adjust_dynamic_symbol): Change h->plt_offset to
1283 contain the index for convenience. Skip the initial entries
1284 in .rela.plt.
1285 (sparc64_elf_size_dynamic_sections): Zero the allocated contents
1286 memory for the benefit of .rela.plt.
1287 (sparc64_elf_relocate_section): Call sparc64_elf_plt_entry_offset.
1288 (sparc64_elf_finish_dynamic_symbol): Kill template stuff. Use
1289 sparc64_elf_plt_entry_offset & sparc64_elf_plt_ptr_offset for reloc.
1290 (sparc64_elf_finish_dynamic_sections): DT_PLTGOT points to .plt.
1291 Call sparc64_elf_build_plt.
1292 (elf_backend_want_got_plt): No.
1293 (elf_backend_plt_readonly): No.
1294 (elf_backend_plt_alignment): 8.
1295
1296 * elf.c (_bfd_elf_close_and_cleanup): New function; free the shstrtab.
1297 * elf-bfd.h (_bfd_elf_close_and_cleanup): Declare it.
1298 * elfxx-target.h (bfd_elfNN_close_and_cleanup): Arrange for it
1299 to be called.
1300
1301 Tue Jan 27 21:45:15 1998 Jeffrey A Law (law@cygnus.com)
1302
1303 * archures.c (bfd_mach_mips*): Add definitions for various MIPS
1304 processors.
1305 * cpu-mips.c (arch_info_struct): Add mips variants.
1306 * bfd-in2.h: Rebuilt.
1307
1308 Tue Jan 27 15:06:04 1998 Nick Clifton <nickc@cygnus.com>
1309
1310 * coff-arm.c (coff_arm_relocate_section): Preserve the contents of
1311 t2a3_b_insn.
1312
1313 Tue Jan 27 12:47:27 1998 Robert Lipe <robertl@dgii.com>
1314
1315 * config.bfd (i[3456]86-sco3.2v5*): ELF now the default.
1316 (i[3456]86sco3.2v5*coff): New target.
1317
1318 Mon Jan 26 15:41:30 1998 Ian Lance Taylor <ian@cygnus.com>
1319
1320 * bfd-in2.h: Rebuild with changes to chew--tab expansion.
1321
1322 Thu Jan 22 21:26:48 1998 Richard Henderson <rth@cygnus.com>
1323
1324 * bfd.c (bfd_get_error_handler): Add orthogonal function.
1325 * bfd-in2.h: Regenerate.
1326
1327 Thu Jan 22 21:13:39 1998 Richard Henderson <rth@cygnus.com>
1328
1329 * tekhex.c (tekhex_write_object_contents): Check for no symbols.
1330
1331 Wed Jan 21 21:19:03 1998 Ian Lance Taylor <ian@cygnus.com>
1332
1333 * coff-i386.c (coff_i386_rtype_to_howto): If COFF_WITH_PE, don't
1334 adjust addend for an output common symbol (from Jimmy Blair
1335 <jimmyb@wrs.com>). If COFF_WITH_PE, adjust addend for PC relative
1336 defined symbol to counteract adjustment made in generic relocation
1337 code.
1338
1339 * dwarf2.c: Include sysdep.h, not stdio.h and stdlib.h.
1340
1341 Wed Jan 21 21:16:06 1998 Manfred Hollstein <manfred@s-direktnet.de>
1342
1343 * coff-m88k.c (GET_SCNDHR_NRELOC): Fix typo in macro name.
1344 (GET_SCNDHR_NLNNO): Likewise.
1345
1346 Mon Jan 19 12:49:52 1998 Ian Lance Taylor <ian@cygnus.com>
1347
1348 * cpu-sh.c (arch_info_struct): Correct next field of sh3e.
1349
1350 Wed Jan 14 17:23:27 1998 Nick Clifton <nickc@cygnus.com>
1351
1352 * elf32-m32r.c: Add macros to handle NOP insertion.
1353
1354 Wed Jan 14 16:15:22 1998 Richard Henderson <rth@cygnus.com>
1355
1356 * xcofflink.c (xcoff_mark_symbol): Don't mark the absolute section.
1357 (xcoff_mark): Likewise.
1358 (xcoff_build_ldsyms): Mark absolute symbols.
1359
1360 Wed Jan 14 16:03:11 1998 Richard Henderson <rth@cygnus.com>
1361
1362 * bout.c (b_out_write_object_contents): Sort symbols before output
1363 to keep {CALL,BAL}NAME symbols adjacent.
1364 (b_out_symbol_cmp): New function.
1365
1366 Tue Dec 30 12:45:18 1997 Ian Lance Taylor <ian@cygnus.com>
1367
1368 * elf32-sparc.c (elf32_sparc_check_relocs): If -Bsymbolic, don't
1369 allocate space for a PC relative reloc against a symbol which is
1370 defined in a regular file.
1371 (elf32_sparc_relocate_section): If -Bsymbolic, don't copy a PC
1372 relative reloc against a symbol which is defined in a regular
1373 file.
1374
1375 Mon Dec 29 18:02:28 1997 Ian Lance Taylor <ian@cygnus.com>
1376
1377 From Jonathan Stone <jonathan@DSG.Stanford.EDU>:
1378 * config.bfd (mips-dec-netbsd*): Add ECOFF vectors to
1379 targ_selvecs.
1380 (mips*el-*-netbsd*): Like mips-dec-netbsd*.
1381 (mips*-*-netbsd*): New target.
1382
1383 Mon Dec 29 17:13:28 1997 H.J. Lu (hjl@gnu.org)
1384
1385 * elflink.h (elf_link_assign_sym_version): Change error message
1386 from "undefined version name" to "undefined versioned symbol
1387 name".
1388
1389 Mon Dec 29 11:41:16 1997 Nick Clifton <nickc@cygnus.com>
1390
1391 * coff-arm.c (coff_arm_relocate_section): Fix typo from previous
1392 delta.
1393
1394 Tue Dec 23 17:01:10 1997 Ian Lance Taylor <ian@cygnus.com>
1395
1396 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Declare.
1397 * libbfd.h: Rebuild.
1398
1399 * peicode.h (coff_swap_scnhdr_out): Set .reloc section to be
1400 shared. Set stab* sections to be shared and read. Set .rsrc
1401 section to be read and shared.
1402
1403 Mon Dec 22 13:20:57 1997 Ian Lance Taylor <ian@cygnus.com>
1404
1405 * Makefile.am: Rebuild dependencies.
1406 (ALL_MACHINES_CFILES): Add dwarf2.lo.
1407 (ALL_MACHINES_CFILES): Add dwarf2.c.
1408 * Makefile.in: Rebuild.
1409
1410 * coff-arm.c: Don't include obstack.h.
1411
1412 Mon Dec 22 13:04:33 1997 Joel Sherrill <joel@oarcorp.com>
1413
1414 * config.bfd (i[3456]86*-go32-rtems*): Fix to be the same as
1415 i[3456]86-go32.
1416
1417 Thu Dec 18 16:01:25 1997 Doug Evans <devans@canuck.cygnus.com>
1418
1419 * configure: Regenerate to get @SHELL@ substituted.
1420
1421 Wed Dec 17 09:45:09 1997 Nick Clifton <nickc@cygnus.com>
1422
1423 * coff-arm.c (coff_arm_relocate_section): Only look at section
1424 owner if there is one.
1425
1426 * elf.c (assign_file_positions_for_segments): Fail if there is not
1427 enough room for the program headers.
1428
1429 Tue Dec 16 08:09:56 1997 Gavin Koch <gavin@cygnus.com>
1430
1431 * elf.c (_bfd_elf_find_nearest_line): Call
1432 _bfd_dwarf2_find_nearest_line first.
1433 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Same.
1434 * dwarf2.c: New file; implement _bfd_dwarf2_find_nearest_line.
1435
1436 Mon Dec 15 16:08:52 1997 Nick Clifton <nickc@cygnus.com>
1437
1438 start-sanitize-m32rx
1439 * elf32-m32r.c (m32r_elf_merge_private_bfd_data): Allow M32R
1440 object files to be merged into a M32RX executable.
1441
1442 * archures.c: Add bfd_mach_m32rx.
1443 end-sanitize-m32rx
1444 * archures.c: Add bfd_mach_m32r.
1445
1446 Mon Dec 15 16:11:22 1997 Fred Fish <fnf@cygnus.com>
1447
1448 * coffcode.h (ALIGN_SECTIONS_IN_FILE): Define if I960 not defined.
1449 (coff_compute_section_file_positions): Use ALIGN_SECTIONS_IN_FILE
1450 to decide when to align the file sections for paging.
1451 start-sanitize-tic80
1452 * coffcode.h (ALIGN_SECTIONS_IN_FILE): Undefine for TIC80COFF.
1453 end-sanitize-tic80
1454
1455 Mon Dec 15 15:01:15 1997 Nick Clifton <nickc@cygnus.com>
1456
1457 * elf32-m32r.c (m32r_elf_object_p): New Function.
1458 (m32r_elf_final_write_processing): New Function.
1459 (m32r_elf_set_private_flags): New Function.
1460 (m32r_elf_copy_private_bfd_data): New Function.
1461 (m32r_elf_merge_private_bfd_data): New Function.
1462 (m32r_elf_print_private_bfd_data): New Function.
1463 (elf_backend_object_p): Point to m32r_object_p.
1464 (elf_backend_final_write_processing): Point to
1465 m32r_elf_final_write_processing.
1466 (bfd_elf32_bfd_copy_private_bfd_data): Point to
1467 m32r_elf_copy_private_bfd_data.
1468 (bfd_elf32_bfd_merge_private_bfd_data): Point to
1469 m32r_elf_merge_private_bfd_data.
1470 (bfd_elf32_bfd_set_private_flags): Point to
1471 m32r_elf_set_private_bfd_data.
1472 (bfd_elf32_bfd_print_private_bfd_data): Point to
1473 m32r_elf_print_private_bfd_data.
1474
1475 start-sanitize-m32rx
1476 * cpu-m32r.c: Add m32rx cpu architecture.
1477 * bfd-in2.h (bfd_mach_m32rx): Add identifier for M32RX
1478 architecture machines.
1479 end-sanitize-m32rx
1480
1481 * bfd-in2.h (bfd_mach_m32r): Add identifier for M32R architecture
1482 machines.
1483
1484 Fri Dec 12 11:30:28 1997 Brendan Kehoe <brendan@canuck.cygnus.com>
1485
1486 * configure: Only build libbfd shared if --enable-shared's value
1487 was `yes', or was set to `*bfd*'.
1488 * aclocal.m4: Likewise.
1489 * NOTE: this really needs to be fixed in libtool/libtool.m4, the
1490 original source of this bit of code. It's not clear what the best fix
1491 would be, though.
1492
1493 Thu Dec 11 17:48:11 1997 Richard Henderson <rth@cygnus.com>
1494
1495 * linker.c (generic_link_add_symbol_list): Always init udata.p so
1496 that the generic relaxation code can function when input and output
1497 file formats are mismatched.
1498
1499 Thu Dec 11 01:02:18 1997 Ian Lance Taylor <ian@cygnus.com>
1500
1501 * coff-sh.c (bfd_coff_small_swap_table): Initialize new fields.
1502
1503 * elf.c (assign_file_positions_for_segments): For a loadable
1504 section, make sure that the load address is correct relative to
1505 the load address of the segment plus the size of the segment so
1506 far.
1507
1508 * coffcode.h (_coff_link_output_has_begun): Make static.
1509 (_coff_final_link_postscript): Likewise.
1510
1511 Wed Dec 10 23:37:11 1997 Ian Lance Taylor <ian@cygnus.com>
1512
1513 * elflink.h (elf_link_input_bfd): Handle a relocateable link in
1514 which a relocation refers to an indirect or warning symbol.
1515
1516 Wed Dec 10 11:15:55 1997 Nick Clifton <nickc@cygnus.com>
1517
1518 * coff-arm.c (bfd_arm_coff_final_link): Function deleted.
1519 (coff_arm_final_link_postscript): New function.
1520 (coff_arm_link_output_has_begun): New function.
1521
1522 * libcoff.h (struct bfd_coff_backend_data): Add new fields:
1523 _bfd_coff_link_output_has_begun and
1524 _bfd_coff_final_link_postscript. Add new macros:
1525 bfd_coff_link_output_has_begun() and
1526 bfd_coff_final_link_postscript().
1527
1528 * cofflink.c (_bfd_coff_final_link): Insert calls to
1529 bfd_coff_link_output_has_begun() and
1530 bfd_coff_final_link_postscript().
1531
1532 * coffcode.h: Add two new fields to bfd_coff_backend_data
1533 structure: _bfd_coff_link_output_has_begun and
1534 _bfd_coff_final_link_postscript. Add default initialisers for
1535 these fields. Add overridable aliases for the coff swap functions
1536 in the backend data structure.
1537
1538 * elf32-v850.c: Update with patches from the branch to fix
1539 HI16_S/LO16 reloc pairs.
1540
1541 start-sanitize-d30v
1542 Wed Dec 10 14:06:48 1997 Michael Meissner <meissner@cygnus.com>
1543
1544 * elf32-d30v.c (d30v_info_to_howto_rela): New function to support
1545 RELA relocations.
1546 (USE_REL): Don't define any more, switch to using RELA
1547 relocations.
1548 (elf_info_to_howto): Define as d30v_info_to_howto_rela.
1549
1550 end-sanitize-d30v
1551 Tue Dec 9 11:37:53 1997 Andrew Cagney <cagney@b1.cygnus.com>
1552
1553 * archures.c (bfd_mach_mips*): Define.
1554 (start-sanitize-vr5400):
1555 (vr5400, bfd_mach_vr5000): Define.
1556 (end-sanitize-vr5400):
1557 (bfd_default_scan): For 3000 and 4000 replace magic constant with
1558 macro.
1559
1560 * cpu-mips.c (N): Define.
1561 (bfd_mips_arch, arch_info_struct): Re-write using macro N, replace
1562 numbers with bfd_mach_mips* macros.
1563
1564 Fri Dec 5 11:13:46 1997 Nick Clifton <nickc@cygnus.com>
1565
1566 * elf32-v850.c (v850_elf_reloc, v850_elf_store_addend_in_insn,
1567 v850_elf_relocate_section): Fix reloc addend handling.
1568 (v850_elf_section_from_bfd_section, v850_elf_symbol_processing,
1569 v850_elf_add_symbol_hook, v850_elf_link_output_symbol_hook,
1570 v850_elf_section_from_shdr, v850_elf_fake_sections): New functions
1571 to create and handle special common sections.
1572 (v850_elf_final_link_relocate): Fix HI16 and HI16_S relocations
1573 which have data stored in the instructions.
1574
1575 Tue Dec 2 10:26:16 1997 Nick Clifton <nickc@cygnus.com>
1576
1577 * coff-arm.c (TARGET_UNDERSCORE): Revert back to '_'
1578 (USER_LABEL_PREFIX): Revert back to '_'
1579
1580 * config.bfd (targ_cpu): Add support for Thumb target.
1581
1582 Mon Dec 1 20:24:18 1997 J"orn Rennecke <amylaar@cygnus.co.uk>
1583
1584 * coff-sh.c (sh_coff_howtos): Add R_SH_SWITCH8 entry.
1585 (get_symbol_value): Handle R_SH_SWITCH8.
1586 (sh_relax_delete_bytes): Likewise.
1587
1588 Wed Nov 26 14:13:34 1997 Nick Clifton <nickc@cygnus.com>
1589
1590 * coff-arm.c (TARGET_UNDERSCORE): Changed to match definition in
1591 gcc/config/arm/semi.h
1592
1593 * coffcode.h (coff_slurp_symbol_table): Add ARM and Thumb symbol
1594 classes.
1595
1596 Sun Nov 23 16:02:58 1997 Andrew Cagney <cagney@b1.cygnus.com>
1597
1598 * freebsd.h (SWAP_MAGIC): Read magic number little and not big
1599 endian.
1600
1601 Wed Nov 26 09:30:37 1997 Nick Clifton <nickc@cygnus.com>
1602
1603 * coffcode.h (coff_mkobject_hook): Only set private flags for non
1604 PE ARM ports.
1605
1606 Tue Nov 25 15:33:23 1997 Richard Henderson <rth@cygnus.com>
1607
1608 * binary.c (binary_set_section_contents): Also ignore NEVER_LOAD
1609 sections.
1610
1611 Tue Nov 25 10:55:36 1997 Nick Clifton <nickc@cygnus.com>
1612
1613 * coff-arm.c (coff_arm_bfd_merge_private_bfd_data): Do not
1614 complain if inout and output formats differ.
1615
1616 Tue Nov 25 11:26:27 1997 Ian Lance Taylor <ian@cygnus.com>
1617
1618 * Makefile.am (BFD32_BACKENDS): Remove tekhex.lo.
1619 (BFD32_BACKENDS_CFILES): Remove tekhex.c.
1620 * Makefile.in: Rebuild.
1621 * aclocal.m4, configure, src/Makefile.in: Rebuild with current
1622 automake and autoconf.
1623
1624 * coff-arm.c (arm_allocate_interworking_sections): Fix typo
1625 (COFF_WITH_PR to COFF_WITH_PE).
1626
1627 Mon Nov 24 15:47:49 1997 Nick Clifton <nickc@cygnus.com>
1628
1629 * coff-arm.c: Make variables and some functions static, so that
1630 this file can be included in multiple object files.
1631 (coff_arm_bfd_final_link): Fix minor bug.
1632
1633 Sat Nov 22 15:16:00 1997 Nick Clifton <nickc@cygnus.com>
1634
1635 * coff-arm.c: Add support for PIC and APCS-FLOAT type binaries.
1636
1637 * coffcode.h: Add support for PIC and APCS-FLOAT type binaries.
1638
1639 Sat Nov 22 16:06:56 1997 Klaus Kaempf <kkaempf@progis.de>
1640
1641 * evax-emh.c (_bfd_evax_write_emh): Use alloca instead of strdup.
1642
1643 Sat Nov 22 12:29:30 1997 Ian Lance Taylor <ian@cygnus.com>
1644
1645 * sunos.c (sunos_add_one_symbol): When overriding a defined
1646 symbol, set it to undefined, not new.
1647
1648 * elf32-sh.c (sh_elf_relax_delete_bytes): Don't kill LABEL
1649 relocs.
1650
1651 Fri Nov 21 14:14:22 1997 Richard Henderson <rth@cygnus.com>
1652
1653 * coff-sh.c (sh_relax_section): Force sign extention of USES r_offset.
1654 (sh_relax_delete_bytes): Don't kill LABEL relocs.
1655
1656 Mon Nov 17 15:08:38 1997 Jeffrey A Law (law@cygnus.com)
1657
1658 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Fix typo.
1659 (mn10300_elf_relax_section): Likewise.
1660
1661 Sat Nov 15 15:36:07 1997 Fred Fish <fnf@cygnus.com>
1662
1663 * peicode.h (coff_swap_aouthdr_in): Cast second arg of
1664 bfd_h_get_* calls to "bfd_byte *".
1665
1666 Tue Nov 11 10:37:23 1997 Jeffrey A Law (law@cygnus.com)
1667
1668 * elf-m10300.c (elf32_mn10300_link_hash_entry): Add new field
1669 "movm_stack_size".
1670 (mn10300_elf_relax_section): Include stack space for register saves
1671 in the imm8 field of a "call" instruction.
1672 (compute_function_info): Determine how much stack is allocated by
1673 the movm instruction. Fix typo.
1674 (elf32_mn10300_link_hash_newfunc): Initialize movm_stack_size.
1675
1676 Mon Nov 10 14:32:40 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1677
1678 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't crash if
1679 a version dependency could not be found.
1680
1681 Tue Nov 4 12:05:56 1997 Klaus K"ampf <kkaempf@progis.de>
1682
1683 * configure.com: Get version info from configure.in
1684
1685 Fri Oct 24 11:15:58 1997 Jakub Jelinek <jj@sunsite.mff.cuni.cz>
1686
1687 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data):
1688 New function. Avoid mixing US1 and HAL R1 code.
1689 Set resulting memory ordering to the strongest one used.
1690 (sparc64_elf_object_p): Set bfd_mach correctly.
1691
1692 Thu Oct 23 14:09:33 1997 Richard Henderson <rth@cygnus.com>
1693
1694 * elf64-sparc.c (sparc64_elf_howto_table): Add UA64 & UA16.
1695 (sparc64_elf_check_relocs): Handle them.
1696 (sparc64_elf_relocate_section): Likewise. Before emitting a dyn reloc,
1697 check alignment and transmute R_SPARC_x<->R_SPARC_UAx.
1698
1699 Thu Oct 23 00:53:14 1997 Richard Henderson <rth@dot.cygnus.com>
1700
1701 * configure.in (sparc*-*-linux*): Use trad-core and ...
1702 * hosts/sparclinux.h: New file.
1703
1704 Thu Oct 23 00:25:29 1997 Richard Henderson <rth@dot.cygnus.com>
1705
1706 * config.bfd (sparc64-*-linux*): New target.
1707
1708 * elf-bfd.h (struct elf_backend_data): Add plt_alignment member.
1709 * elflink.c (_bfd_elf_create_got_section): Set .got alignment based
1710 on arch_size.
1711 (_bfd_elf_create_dynamic_sections): Likewise for .rel* sections.
1712 Set .plt alignment from new plt_alignment.
1713 * elflink.h (elf_link_create_dynamic_sections): Set version section
1714 alignment to LOG_FILE_ALIGN.
1715 * elfxx-target.h (elf_backend_plt_alignment): Provide default.
1716 (elfXX_bed): Init plt_alignment.
1717
1718 * elf64-sparc.c (sparc64_elf_check_relocs,
1719 sparc64_elf_adjust_dynamic_symbol, sparc64_elf_size_dynamic_sections,
1720 sparc64_elf_adjust_dynindx, sparc64_elf_finish_dynamic_symbol,
1721 sparc64_elf_finish_dynamic_sections): New functions.
1722 (sparc64_elf_howto_table): Fix a few name strings.
1723 (ELF_DYNAMIC_INTERPRETER): New definition.
1724 (sparc64_elf_relocate_section): Handle shared libraries.
1725
1726 * elf64-sparc.c (struct plt_template, plt_*_header, plt_*_entry,
1727 sparc64_elf_build_plt_entry, sparc64_elf_finish_dynamic_symbol):
1728 PLT definitions sparc64-linux originally choose. These will go
1729 away soon in favour of the official abi definitions.
1730
1731 Wed Oct 22 16:08:45 1997 Ian Lance Taylor <ian@cygnus.com>
1732
1733 * coff-sh.c (coff_small_object_p): New static function.
1734 (coff_small_new_section_hook): New static function.
1735 (bfd_coff_small_swap_table): New static const structure.
1736 (coff_small_close_and_cleanup): Define.
1737 (coff_small_bfd_free_cached_info): Define.
1738 (coff_small_get_section_contents): Define.
1739 (coff_small_get_section_contents_in_window): Define.
1740 (shcoff_small_vec): New static structure.
1741 (shlcoff_small_vec): New static structure.
1742 * targets.c (bfd_target_vector): Add shcoff_small_vec and
1743 shlcoff_small_vec.
1744 * config.bfd (sh-*-elf*): Add shcoff_small_vec and
1745 shlcoff_small_vec to targ_selvecs.
1746 (sh-*-*): Likewise.
1747 * configure.in: Add shcoff_small_vec and shlcoff_small_vec cases.
1748 * configure: Rebuild.
1749
1750 Mon Oct 20 15:01:27 1997 Klaus K"ampf <kkaempf@progis.de>
1751
1752 * evax-egsd.c: Weak symbols are global.
1753
1754 * evax-emh.c: Use proper casts.
1755
1756 * evax-egsd.c (_bfd_evax_write_egsd): Remove unneeded uname.
1757
1758 * evax-egsd.c: Section names and symbols have different
1759 length restrictions. Add length parameter to
1760 _bfd_evax_length_hash_symbol.
1761 * evax-etir.c: Likewise.
1762 * evax-misc.c (_bfd_evax_length_hash_symbol): Add length
1763 parameter.
1764 * evax.h (EOBJ_S_C_SECSIZ): Define.
1765
1766 * evax-alpha.c: Remove duplicate test.
1767
1768 * evax-emh.c: SYS$ functions are upper-case.
1769
1770 * evax-egsd.c: Create separate sections for common symbols.
1771 * evax-etir.c: Don't output common section.
1772 * evax.h: Bump up section count.
1773
1774 * configure.com: Use 64bit integers with DEC C.
1775
1776 * evax-egsd.c: Make section flags dec c compatible.
1777
1778 Mon Oct 20 09:38:31 1997 Jeffrey A Law (law@cygnus.com)
1779
1780 * som.c (normalize): Delete function.
1781 (som_bfd_ar_write_symbol_stuff): New parameter elength. All callers
1782 changed. Use passed in elength to determine size of the extended
1783 name table instead of computing it again.
1784
1785 Sun Oct 19 23:36:21 1997 Jim Wilson <wilson@cygnus.com>
1786
1787 * peicode.h (coff_swap_scnhdr_out): Use |= not = to set
1788 IMAGE_SCN_MEM_READ for an unrecognized section.
1789
1790 Sun Oct 19 21:04:56 1997 Jeffrey A Law (law@cygnus.com)
1791
1792 * som.c (som_bfd_ar_write_symbol_stuff): Account for trailing
1793 '/' in the extended name table.
1794
1795 Fri Oct 17 00:04:13 1997 Richard Henderson <rth@cygnus.com>
1796
1797 * elflink.h (elf_link_assign_sym_version): For explicitly versioned
1798 symbols, check globals list before matching on locals.
1799
1800 Thu Oct 16 08:17:06 1997 Michael Meissner <meissner@cygnus.com>
1801
1802 * peicode.h (coff_swap_scnhdr_out,pe_print_idata): Fix mangled
1803 patch.
1804
1805 Wed Oct 15 13:45:10 1997 Ian Lance Taylor <ian@cygnus.com>
1806
1807 * peicode.h (pe_mkobject_hook): Set DLL flag.
1808 (pe_bfd_copy_private_bfd_data): Copy DLL flag.
1809
1810 * peicode.h (coff_swap_scnhdr_out): Set IMAGE_SCN_MEM_DISCARDABLE
1811 for .stab* sections. Replace strlen of constant strings with
1812 number.
1813
1814 Tue Oct 14 15:42:45 1997 Richard Henderson <rth@cygnus.com>
1815
1816 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): New function to
1817 merge got and reloc entries from ind syms to their target.
1818 (elf64_alpha_always_size_sections): Call it.
1819 (elf64_alpha_check_relocs): Operate on the target of indirect symbols.
1820 (elf64_alpha_can_merge_gots): Likewise.
1821 (elf64_alpha_merge_gots): Likewise.
1822
1823 * elf64-alpha.c (elf64_alpha_relocate_section): Back out HJ's change,
1824 as it is insufficient to handle the relocation changes as well.
1825
1826 Mon Oct 13 23:10:08 1997 Richard Henderson <rth@cygnus.com>
1827
1828 * elf64-alpha.c (elf64_alpha_calc_dynrel_sizes): Allow for RELATIVE
1829 relocs for symbols in shlibs that have been forced local.
1830 (elf64_alpha_relocate_section): Output RELATIVEs in .got for same.
1831
1832 Mon Oct 13 21:24:04 1997 Richard Henderson <rth@cygnus.com>
1833
1834 * elf64-alpha.c (elf64_alpha_relocate_section): Use the
1835 got_enties of the default symbol for the default versioned
1836 symbol. Patch from hjl@gnu.ai.mit.edu, modified not to use
1837 alloca in the loop.
1838
1839 Mon Oct 13 17:37:37 1997 Nick Clifton <nickc@cygnus.com>
1840
1841 * elf32-v850.c (v850_elf_final_link_relocate): Only use the bottom
1842 24 bits of the PC when computing a PC relative relocation.
1843
1844 Fri Oct 10 16:01:30 1997 Nick Clifton <nickc@cygnus.com>
1845
1846 * elf32-v850.c (v850_elf_reloc, v850_elf_final_link_relocate):
1847 Correct value for maximum positive 22 bit PC relative relocation.
1848 (v850_elf_final_link_relocate): Prevent overflow from HI16_S and
1849 HI_16 relocations. Correct bit adjustment in TDA offsets.
1850
1851 Thu Oct 9 16:43:39 1997 Doug Evans <dje@canuck.cygnus.com>
1852
1853 * elf64-sparc.c (sparc_elf_{hix22,lox10}_reloc): New functions.
1854 (sparc64_elf_howto_table): Use them for HIX22,LOX10 relocs.
1855
1856 Wed Oct 8 11:38:45 1997 Richard Henderson <rth@cygnus.com>
1857
1858 * elfcore.h (bfd_prstatus): Pedanticly, alignment_power should
1859 be LOG_FILE_ALIGN.
1860
1861 Wed Oct 8 11:36:00 1997 Richard Henderson <rth@cygnus.com>
1862
1863 * config.bfd: Missed one alpha* change.
1864
1865 Tue Oct 7 13:00:17 1997 Doug Evans <dje@canuck.cygnus.com>
1866
1867 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove BFD64 support.
1868 * elf64-sparc.c (SPARC64_OLD_RELOCS): Undef.
1869 (MINUS_ONE): New macro.
1870 (sparc_elf_notsup_reloc): New function.
1871 (sparc64_elf_howto_table): Add entries for DISP64,PLT64,HIX22,LOX10,
1872 H44,M44,L44,REGISTER.
1873 (sparc_reloc_map): Likewise. Map BFD_RELOC_CTOR to R_SPARC_64.
1874 (init_insn_reloc): New function.
1875 (sparc_elf_wdisp16_reloc): Use it.
1876 (sparc64_elf_relocate_section): Add entries for OLO10,HIX22,LOX10.
1877
1878 Tue Oct 7 11:40:37 1997 Ian Lance Taylor <ian@cygnus.com>
1879
1880 * som.c (som_construct_extended_name_table): Remove static
1881 function, and define as macro instead.
1882
1883 Fri Oct 3 14:02:17 1997 Richard Henderson <rth@cygnus.com>
1884
1885 * config.bfd: Change alpha-*-* to alpha*-*-*; config.guess now
1886 recognizes alphaev5 etc.
1887 * configure.host: Likewise.
1888
1889 Fri Oct 3 11:23:47 1997 Ian Lance Taylor <ian@cygnus.com>
1890
1891 Make ld -s work on AIX:
1892 * xcofflink.c (xcoff_link_add_symbols): Don't create the .debug
1893 section if we are stripping.
1894 (bfd_xcoff_size_dynamic_sections): Don't set the .debug section
1895 size if we are stripping.
1896 (_bfd_xcoff_bfd_final_link): Don't set SEC_RELOC or rel_filepos,
1897 and don't write out relocs, if we are stripping.
1898 (xcoff_link_input_bfd): Don't set up reloc if we are stripping.
1899 (xcoff_write_global_symbol): Don't write out symbol or reloc if we
1900 are stripping.
1901
1902 * configure.in: Don't include elf.lo again for ELF targets; it's
1903 always in the library anyhow.
1904 * configure: Rebuild.
1905
1906 * bfd-in2.h: Rebuild.
1907
1908 * elf32-sparc.c (sparc_elf_wdisp16_reloc): Cast to bfd_byte *, not
1909 char *, when calling bfd_get_32 and bfd_put_32.
1910 * sunos.c (sunos_scan_dynamic_symbol): Cast contents to char *
1911 when calling strcpy.
1912
1913 Thu Oct 2 16:15:50 1997 Doug Evans <dje@canuck.cygnus.com>
1914
1915 * reloc.c (bfd_check_overflow): New function.
1916 (bfd_perform_relocation, bfd_install_relocation): Use it.
1917 (BFD_RELOC_SPARC_{DISP64,PLT64}): New relocs.
1918 (BFD_RELOC_SPARC_{HIX22,LOX10,H44,M44,L44,REGISTER}): New relocs.
1919 * bfd-in2.h: Regenerate.
1920 * libbfd.h: Regenerate.
1921
1922 Thu Oct 2 13:17:18 1997 Ian Lance Taylor <ian@cygnus.com>
1923
1924 * peicode.h (coff_swap_scnhdr_out): Set IMAGE_SCN_MEM_READ for an
1925 unrecognized section. From Jon Thackray <jont@harlequin.co.uk>.
1926
1927 Wed Oct 1 14:03:44 1997 Ian Lance Taylor <ian@cygnus.com>
1928
1929 * Makefile.am ($(BFD_H)): Change stmp-bfd.h to stmp-bfd-h.
1930 (stmp-bfd-h): Rename from stmp-bfd.h.
1931 (BFD_H_FILES, LIBBFD_H_FILES, LIBCOFF_H_FILES): New variables.
1932 ($(srcdir)/bfd-in2.h): Just depend upon stmp-bin2-h.
1933 (stmp-bin2-h): New target.
1934 ($(srcdir)/libbfd.h): Just depend upon stmp-lbfd-h.
1935 (stmp-lbfd-h): New target.
1936 ($(srcdir)/libcoff.h): Just depend upon stmp-lcoff-h.
1937 (stmp-lcoff-h): New target.
1938 (CLEANFILES): Change stmp-bfd.h to stmp-bfd-h. Add stmp-bin2.h,
1939 stmp-lbfd-h, and stmp-lcoff-h.
1940 * Makefile.in: Rebuild.
1941
1942 * configure.in: Use a diversion to set enable_shared before the
1943 arguments are parsed.
1944 * configure: Rebuild.
1945
1946 Tue Sep 30 14:18:32 1997 Doug Evans <dje@canuck.cygnus.com>
1947
1948 * elf32-sparc.c (_bfd_sparc_elf_howto_table): R_SPARC_GLOB_JMP
1949 renamed to R_SPARC_UNUSED_42.
1950 (sparc_reloc_map): Delete R_SPARC_GLOB_JMP entry.
1951 * elf64-sparc.c (_bfd_sparc_elf_howto_table): R_SPARC_GLOB_JMP
1952 renamed to R_SPARC_UNUSED_42.
1953 (sparc_reloc_map): Delete R_SPARC_GLOB_JMP entry.
1954 * reloc.c (BFD_RELOC_SPARC_GLOB_JMP): Delete.
1955 * bfd-in2.h: Regenerated.
1956 * libbfd.h: Regenerated.
1957
1958 Thu Sep 25 12:15:02 1997 Ian Lance Taylor <ian@cygnus.com>
1959
1960 * elflink.h (elf_merge_symbol): Don't check the hash creator until
1961 after we have set *sym_hash.
1962
1963 Wed Sep 24 16:52:28 1997 Joel Sherrill <joel@oarcorp.com>
1964
1965 * config.bfd (sh*-*-rtems*): New target, like sh-*-*elf*.
1966
1967 Wed Sep 24 11:27:23 1997 Ian Lance Taylor <ian@cygnus.com>
1968
1969 * Makefile.am (libbfd_a_SOURCES): Define.
1970 * Makefile.in: Rebuild.
1971
1972 * configure.in: Call AC_CHECK_TOOL before AM_PROG_LIBTOOL.
1973 * aclocal.m4: Rebuild with new libtool.
1974 * configure: Rebuild.
1975
1976 Tue Sep 23 19:03:13 1997 Ian Lance Taylor <ian@cygnus.com>
1977
1978 * elf.c (map_sections_to_segments): Even if we are not demand
1979 paged, don't put a loadable section after a nonloadable section.
1980 (assign_file_positions_for_segments): Increment the file offset
1981 for a section with contents, even if it is not loadable.
1982
1983 start-sanitize-v850e
1984 Sun Sep 21 11:03:24 1997 Nick Clifton <nickc@cygnus.com>
1985
1986 * elf32-v850.c (v850_elf_final_link_relocate): Add return code
1987 indicating that __ctbp could not be found.
1988
1989 end-sanitize-v850e
1990 Thu Sep 18 15:04:57 1997 Nick Clifton <nickc@cygnus.com>
1991
1992 * elf32-v850.c (v850_elf_check_relocs): Improve error message.
1993
1994 Wed Sep 17 09:54:51 1997 Nick Clifton <nickc@cygnus.com>
1995 start-sanitize-v850e
1996
1997 * elf32-v850.c (v850_elf_final_link_relocate, v850_elf_reloc,
1998 v850_elf_check_relocs, v850_elf_reloc_map, v850_elf_howto_table):
1999 Add support for the CALLT relocs.
2000
2001 * reloc.c (COMMENT): Add BFD_RELOC_V850_CALLT_6_7_OFFSET and
2002 BFD_RELOC_V850_CALLT_16_16_OFFSET.
2003 end-sanitize-v850e
2004
2005 * elf32-v850.c (v850_elf_final_link_relocate): Add checks to catch
2006 relocations against non-existant symbols.
2007
2008 Tue Sep 16 14:20:27 1997 Nick Clifton <nickc@cygnus.com>
2009
2010 * reloc.c: Add BFR_RELOC_V850_TDA_16_16_OFFSET.
2011
2012 * elf32-v850.c (v850_elf_reloc, v850_elf_final_link_relocate,
2013 v850_elf_howto_table, v850_elf_reloc_map): Add support for a 16
2014 bit reloc in the tiny data area.
2015
2016 start-sanitize-d30v
2017 Mon Sep 15 11:27:36 1997 Ken Raeburn <raeburn@cygnus.com>
2018
2019 Merged changes from Martin Hunt:
2020
2021 * elf32-d30v.c (bfd_elf_d30v_reloc): Change pc-relative relocs
2022 over 2^32 bytes to be absolute. Needed because D30V PC doesn't
2023 necessarily wrap.
2024
2025 * reloc.c, elf32-d30v.c (BFD_RELOC_D30V_9_PCREL,
2026 BFD_RELOC_D30V_9_PCREL_R): New relocs.
2027
2028 * elf32-d30v.c (bfd_elf_d30v_reloc_21): New function.
2029 Do 15 and 21 bit pc-relative relocations.
2030 * reloc.c (BFD_RELOC_D30V_15_PCREL_R, BFD_RELOC_D30V_21_PCREL_R):
2031 New relocations.
2032
2033 * elf32-d30v.c (bfd_elf_d30v_reloc): Addend needs to be
2034 added to the relocation, not or'd.
2035
2036 end-sanitize-d30v
2037 Wed Sep 10 15:17:25 1997 Nick Clifton <nickc@cygnus.com>
2038
2039 * elf32-v850.c (v850_elf_reloc): Remove spurious error message.
2040
2041 Wed Sep 10 11:17:50 1997 Andrew Cagney <cagney@b1.cygnus.com>
2042
2043 * archures.c (bfd_default_scan): Use strcasecmp.
2044 (bfd_default_scan): Test for match with arch_name + ":" +
2045 printable_name.
2046 (bfd_default_scan): Test for match with printable_name - ":".
2047 (bfd_default_scan): Delete w65, h8300, h8500, z8k, i960 special
2048 cases. Each implements their own scan function.
2049 (bfd_default_scan): Delete 386, 2900, 860, mips 2000, mips 4400
2050 special cases. Since info->mach == 0. The test mach == number
2051 fails.
2052 (bfd_arch_list): New function, return name of all the supported
2053 architectures.
2054
2055 Tue Sep 9 10:21:56 1997 Nick Clifton <nickc@cygnus.com>
2056
2057 * elf32-v850.c (v850_elf_print_private_bfd_data): Break after
2058 decoding architecture.
2059 (v850_elf_reloc): Do not complain if a R_V850_LO16 reloc has bit
2060 15 set.
2061
2062 Sun Sep 7 12:25:22 1997 H.J. Lu (hjl@gnu.ai.mit.edu)
2063
2064 * bfd/elf64-alpha.c (reloc_howto_type): Fix the howto table.
2065
2066 Thu Sep 4 09:44:10 1997 Ian Lance Taylor <ian@cygnus.com>
2067
2068 * Makefile.am: Rebuild dependencies.
2069 (ALL_MACHINES_CFILES): Add cpu-v850.c.
2070 (ALL_MACHINES_CFILES): Add elf32-v850.c.
2071 * Makefile.in: Rebuild.
2072
2073 * reloc.c: Remove extraneous commas from relocation entries.
2074 Remove BFD_RELOC_V850_16_PCREL.
2075 * bfd-in2.h: Rebuild.
2076
2077 * xcofflink.c (xcoff_link_add_symbols): Put XTY_CM/XMC_TD symbols
2078 in sections named .tocbss rather than .bss.
2079
2080 Wed Sep 3 11:23:23 1997 Nick Clifton <nickc@cygnus.com>
2081
2082 * libbfd.h, bfd-in2.h, elf32-v850.c: Removed
2083 BFD_RELOC_V850_16_PCREL.
2084
2085 Tue Sep 2 20:44:10 1997 Fred Fish <fnf@cygnus.com>
2086
2087 * cofflink.c (coff_link_check_ar_symbols): Handle C_SYSTEM syms
2088 the same as C_EXT syms.
2089 (coff_link_add_symbols): Ditto.
2090 (_bfd_coff_link_input_bfd): Ditto.
2091 (_bfd_coff_write_task_globals): Add save_global_to_static. Use
2092 it to preserve and restore state of global_to_static flag.
2093
2094 Tue Sep 2 17:45:22 1997 Nick Clifton <nickc@cygnus.com>
2095
2096 * elf32-v850.c (v850_elf_object_p): Set machine number based on
2097 bits in e_flags field rather than magic numbers.
2098 (v850_elf_final_write_processing, v850_elf_set_private_flags,
2099 v850_elf_copy_private_bfd_data, v850_elf_merge_private_bfd_data,
2100 v850_elf_print_private_bfd_data): New functions.
2101
2102 start-sanitize-v850e
2103 Tue Sep 2 17:43:49 1997 Nick Clifton <nickc@cygnus.com>
2104
2105 * elf.c (prep_headers): Remove V850E magic number.
2106 * elf.c (prep_headers): Remove V850EA magic number.
2107 end-sanitize-v850e
2108
2109 Tue Sep 2 17:35:05 1997 Doug Evans <dje@canuck.cygnus.com>
2110
2111 * cpu-arc.c (arc_get_mach): Properly scan defined mach entries.
2112
2113 Tue Sep 2 18:29:37 1997 Jeffrey A Law (law@cygnus.com)
2114
2115 * elf-m10200.c (mn10200_elf_final_link_relocate): PC relative
2116 instructions are relative to the next instruction, not the
2117 current instruction.
2118 (mn10200_elf_relax_section): Similarly.
2119
2120 Tue Sep 2 15:45:45 1997 Nick Clifton <nickc@cygnus.com>
2121
2122 * cpu-v850.c: Use a macro to construct bfd_arch_info_type
2123 entries.
2124
2125 * reloc.c, libbfd.h, bfd-in2.h, elf32-v850.c: Replace
2126 BFD_RELOC_V850_{SDA/TDA/ZDA}_OFFSET relocs with new bit pattern
2127 specific versions: BFD_RELOC_V850_{area}_{bits}_OFFSET.
2128
2129 Thu Aug 28 17:01:09 1997 Andrew Cagney <cagney@b1.cygnus.com>
2130
2131 * cpu-v850.c: Remove "plain" from v850 printable name.
2132 (scan): Use strcasecmp.
2133
2134 * archures.c (bfd_mach_v850): Define.
2135
2136 * cpu-sh.c (scan_mach): Compare with table instead of hardwired to
2137 just sh/SH, use strcasecmp.
2138 (arch_info_struct): Add entries for sh3 et.al.
2139
2140 * archures.c (bfd_mach_sh, ...): Define.
2141
2142 Wed Aug 27 17:33:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
2143
2144 * archures.c (bfd_archures_list): Always NULL terminate the list.
2145
2146 Tue Aug 26 17:26:51 1997 Ian Lance Taylor <ian@cygnus.com>
2147
2148 * Makefile.am: Rebuild dependencies.
2149 (ALL_MACHINES_CFILES): Add cpu-arc.c.
2150 (ALL_MACHINES_CFILES): Add elf32-arc.c.
2151 (elf32-arc.lo): Remove explicit dependency.
2152 * Makefile.in: Rebuild.
2153
2154 * acinclude.m4 (BFD_CC_FOR_BUILD): Set EXEEXT_FOR_BUILD.
2155 * doc/Makefile.am (MKDOC): Use EXEEXT_FOR_BUILD, not EXEEXT.
2156 * aclocal.m4, configure, Makefile.in, doc/Makefile.in: Rebuild.
2157
2158 Mon Aug 25 16:14:34 1997 Christopher Provenzano <proven@cygnus.com>
2159
2160 * configure: Rebuild with latest devo autoconf for NT support
2161
2162 Mon Aug 25 16:11:04 1997 Nick Clifton <nickc@cygnus.com>
2163
2164 * cpu-arm.c (compatible): If B is a default type, return A.
2165
2166 Mon Aug 25 15:35:46 1997 Nick Clifton <nickc@cygnus.com>
2167
2168 * cpu-v850.c (scan): New function.
2169 (arch_info_struct): New structure.
2170 (bfd_v850_arch): Add link into arch_info_structure.
2171
2172 * config.bfd (targ_cpu): All v850 variants use the bfd_arch_v850
2173 architecture.
2174
2175 * elf32-v850.c (v850_elf_object_p): New function.
2176
2177 start-sanitize-v850e
2178 * archures.c (bfd_mach_v850e): Machine value for v850e.
2179
2180 * bfd-in2.h (bfd_mach_v850e): Machine value for v850e.
2181
2182 * elf32-v850.c (ELF_MACHINE_CODE): Default to v850e machine
2183 number.
2184
2185 * elf.c (prep_headers): Add support for v850e machine number.
2186
2187 * archures.c (bfd_mach_v850ea): Machine value for v850ea.
2188
2189 * bfd-in2.h (bfd_mach_v850ea): Machine value for v850ea.
2190
2191 * elf32-v850.c (ELF_MACHINE_CODE): Default to v850ea machine
2192 number.
2193
2194 * elf.c (prep_headers): Add support for v850ea machine number.
2195 end-sanitize-v850e
2196
2197 Mon Aug 25 14:07:33 1997 Ian Lance Taylor <ian@cygnus.com>
2198
2199 * syms.c (_bfd_stab_section_find_nearest_line): Clear the
2200 cached_stab field if the offset prevents us from using the cache.
2201
2202 Mon Aug 25 12:08:13 1997 Ian Lance Taylor <ian@cygnus.com>
2203
2204 * aout-target.h (MY(vec)): Add SEC_CODE and SEC_DATA to section
2205 flags.
2206 * aout-arm.c (aout_arm_little_vec): Likewise.
2207 (aout_arm_big_vec): Likewise.
2208 * bout.c (b_out_vec_big_host): Likewise.
2209 (b_out_vec_little_host): Likewise.
2210 * mipsbsd.c (aout_mips_little_vec): Likewise.
2211 (aout_mips_big_vec): Likewise.
2212
2213 start-sanitize-tic80
2214 Tue Aug 19 10:09:10 1997 Fred Fish <fnf@cygnus.com>
2215
2216 * coff-tic80.c (COFF_ALIGN_IN_SFLAGS): Define to 1.
2217 * coffcode.h (styp_to_sec_flags): Ignore incoming STYP_INFO
2218 bit in s_flags if COFF_ALIGN_IN_S_FLAGS is defined.
2219
2220 end-sanitize-tic80
2221 Tue Aug 19 08:47:17 1997 Fred Fish <fnf@cygnus.com>
2222
2223 * coff-i960.c (COFF_ALIGN_IN_SECTION_HEADER): Define to 1.
2224 (GET_SCNHDR_ALIGN, PUT_SCNHDR_ALIGN): Define.
2225 * coff-m88k.c (GET_SCNHDR_NRELOC, GET_SCNHDR_NLNNO): Define.
2226 * coffcode.h (coff_set_alignment_hook): Conditionally compile in if
2227 COFF_ALIGN_IN_SECTION_HEADER is defined. Convert alignment to power
2228 of two for I960 only.
2229 * coffswap.h (GET_SCNHDR_NRELOC, PUT_SCNHDR_NRELOC, GET_SCNDHR_NLNNO,
2230 PUT_SCNHDR_NLNNO, GET_SCNHDR_FLAGS, PUT_SCNHDR_FLAGS): Provide
2231 default definitions.
2232 (coff_swap_scnhdr_in): Use GET_SCNHDR_FLAGS, GET_SCNHDR_NRELOC,
2233 GET_SCNHDR_NLNNO, and GET_SCNHDR_ALIGN.
2234 (coff_swap_scnhdr_out): Use PUT_SCNHDR_FLAGS, PUT_SCNHDR_ALIGN.
2235 start-sanitize-tic80
2236 * Makefile.in (coff-tic80.o): Depends upon coffswap.h.
2237 * coff-tic80.c (COFF_ALIGN_IN_SECTION_HEADER): Define to 1.
2238 (GET_SCNHDR_FLAGS, PUT_SCNHDR_FLAGS): Define
2239 *coffcode.h (coff_write_object_contents): Set alignment field in
2240 section header for TIC80COFF files.
2241 end-sanitize-tic80
2242
2243 Mon Aug 18 11:36:19 1997 Nick Clifton <nickc@cygnus.com>
2244
2245 * elf32-v850.c (v850_elf_howto_table, v850_elf_reloc_map,
2246 v850_elf_check_relocs, v850_elf_reloc,
2247 v850_elf_final_link_relocate): Add support for
2248 BFD_RELOC_V850_16_PCREL relocation.
2249
2250 * reloc.c (COMMENT): Add suuport for BFD_RELOC_V850_16_PCREL
2251 relocation.
2252
2253 * libbfd.h: Add support for BFD_RELOC_V850_16_PCREL relocation.
2254
2255 * bfd-in2.h: Add support for BFD_RELOC_V850_16_PCREL relocation.
2256
2257 start-sanitize-v850e
2258 Mon Aug 18 11:33:56 1997 Nick Clifton <nickc@cygnus.com>
2259
2260 * cpu-v850e: New file.
2261
2262 * elf.c (prep_headers): Add support for v850e target.
2263
2264 * bfd-in2.h (bfd_architecture): Add support for v850e target.
2265
2266 * config.bfd: Add support for v850e target.
2267
2268 * archures.c: Add support for v850e target.
2269
2270 Mon Aug 18 11:33:56 1997 Nick Clifton <nickc@cygnus.com>
2271
2272 * cpu-v850ea: New file.
2273
2274 * elf.c (prep_headers): Add support for v850ea target.
2275
2276 * bfd-in2.h (bfd_architecture): Add support for v850ea target.
2277
2278 * config.bfd: Add support for v850ea target.
2279
2280 * archures.c: Add support for v850ea target.
2281 end-sanitize-v850e
2282
2283 Fri Aug 15 12:01:28 1997 Ian Lance Taylor <ian@cygnus.com>
2284
2285 * coffgen.c (coff_find_nearest_line): Correctly handle the offset
2286 argument as section relative, rather than an absolute address.
2287 From Jan Hoogenraad <hoogenrd@natlab.research.philips.com>.
2288
2289 Fri Aug 15 04:58:02 1997 Doug Evans <dje@canuck.cygnus.com>
2290
2291 * config.bfd (arc-*-elf*): Add.
2292 * configure.in (bfd_elf32_{little,big}arc_vec): Add.
2293 * configure: Rebuild.
2294 * Makefile.am (ALL_MACHINES): Add cpu-arc.lo.
2295 (BFD32_BACKENDS): Add elf32-arc.lo.
2296 (cpu-arc.lo,elf32-arc.lo): Add rules for.
2297 * Makefile.in: Rebuild.
2298 * archures.c (architecture list): Add bfd_arch_arc.
2299 (bfd_archures_list): Add bfd_arc_arch.
2300 (bfd_mach_arc_base): Define.
2301 * reloc.c (BFD_RELOC_ARC_B22_PCREL,BFD_RELOC_ARC_B26): Add.
2302 * targets.c (bfd_elf32_{little,big}arc_vec): Declare.
2303 (bfd_target_vect): Add them.
2304 * bfd-in2.h, libbfd.h: Rebuild.
2305 * cpu-arc.c, elf32-arc.c: New files.
2306 * elf.c (pre_headers): Recognize bfd_arch_arc.
2307
2308 Tue Aug 12 11:45:18 1997 Ian Lance Taylor <ian@cygnus.com>
2309
2310 * aoutx.h (NAME(aout,final_link)): If no symbols, make sure the
2311 data section is correctly rounded to a page in the file.
2312
2313 Mon Aug 11 12:45:43 1997 Ian Lance Taylor <ian@cygnus.com>
2314
2315 * aoutx.h (NAME(aout,final_link)): Don't emit the string table if
2316 there are no symbols.
2317
2318 Sun Aug 10 14:45:56 1997 Ian Lance Taylor <ian@cygnus.com>
2319
2320 * coff-stgo32.c: Rename from coff-stubgo32.c to avoid old System V
2321 file system 14 character limit.
2322 * Makefile.am, configure.in: Corresponding changes.
2323 * Makefile.in, configure: Rebuild.
2324
2325 Fri Aug 8 18:34:36 1997 Ian Lance Taylor <ian@cygnus.com>
2326
2327 * Makefile.am: (ALL_MACHINES_CFILES): Add elf32-d10v.c.
2328 Rebuild dependencies.
2329 * Makefile.in: Rebuild.
2330
2331 Wed Aug 6 18:56:51 1997 Ian Lance Taylor <ian@cygnus.com>
2332
2333 * Makefile.am (docdir): Define.
2334 * Makefile.in: Rebuild.
2335
2336 Tue Aug 5 23:05:03 1997 Ian Lance Taylor <ian@cygnus.com>
2337
2338 * configure: Rebuild with autoconf 2.12.1.
2339
2340 Mon Aug 4 12:00:35 1997 Ian Lance Taylor <ian@cygnus.com>
2341
2342 * aclocal.m4, configure: Rebuild with new automake patches.
2343
2344 Sun Aug 3 08:15:12 1997 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
2345
2346 * rs6000-core.c (make_bfd_asection): New function to add a section
2347 to the core file bfd.
2348 (rs6000coff_core_p): Use make_bfd_asection to add the core file
2349 sections.
2350 Use BFD routines to seek, read and stat the core file.
2351 Handle .data sections from loaded objects and anonymously mmapped
2352 regions, these are available in AIX 4 core files.
2353
2354 Fri Aug 1 12:58:32 1997 Ian Lance Taylor <ian@cygnus.com>
2355
2356 * configure.in: Set enable_shared before AM_PROG_LIBTOOL.
2357 * acinclude.m4: Move acmacros.m4 in here. Remove AM_PROG_LIBTOOL
2358 copy; use a patches libtool instead.
2359 * acmacros.m4: Remove.
2360 * Makefile.in, aclocal.m4, configure: Rebuild.
2361
2362 Thu Jul 31 19:55:36 1997 Ian Lance Taylor <ian@cygnus.com>
2363
2364 * Makefile.am: New file, based on old Makefile.in.
2365 * acmacros.m4: New file, copied from old aclocal.m4.
2366 * acinclude.m4: New file.
2367 * configure.in: Call AM_PROG_LIBTOOL. Remove shared library
2368 handling; now handled by libtool. Replace AC_CONFIG_HEADER with
2369 AM_CONFIG_HEADER. Replace AC_PROG_INSTALL with AM_PROG_INSTALL.
2370 Call AM_MAINTAINER_MODE, AM_CYGWIN32, and AM_EXEEXT. Change all
2371 .o files to .lo. Remove stamp-h handling in AC_OUTPUT.
2372 * acconfig.h: Mention PACKAGE and VERSION.
2373 * stamp-h.in: New file.
2374 * dep-in.sed: Change .o to .lo.
2375 * Makefile.in: Now built with automake.
2376 * aclocal.m4: Now built with aclocal.
2377 * config.in, configure: Rebuild.
2378 * VERSION: Remove.
2379
2380 Thu Jul 31 12:09:20 1997 Geoff Keating <geoffk@ozemail.com.au>
2381
2382 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Don't set TEXTREL
2383 if there is only a relocation to a read-only but not allocatable
2384 section (like .stab).
2385 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
2386 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
2387 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
2388 * elf32-mips.c (mips_elf_size_dynamic_sections): Likewise.
2389 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
2390
2391 * elf32-ppc.c (ppc_elf_howto_raw): Correct various comments.
2392 (ppc_elf_create_linker_section): These sections are not
2393 created by the linker (that is, they are created by the user
2394 putting data in them). In particular, they can be the source
2395 and target of relocations.
2396 (ppc_elf_adjust_dynamic_symbol): Check postcondition of
2397 bfd_elf32_link_record_dynamic_symbol. Align 16-byte common
2398 objects (for instance, 'long double') to 16-byte boundaries.
2399 (ppc_elf_size_dynamic_sections): Make the code that generates
2400 section symbols exactly the same as for sparc, reducing the
2401 number of section symbols output.
2402 (ppc_elf_check_relocs): Check postcondition of
2403 bfd_elf32_link_record_dynamic_symbol. Make default case the
2404 same as corresponding code for sparc, fixing bug involving
2405 .rela.stabs.
2406 (ppc_elf_finish_dynamic_symbol): Fix case involving GOT symbols
2407 forced to be local because of versioning (by replicating
2408 corresponding change in sparc). Treat R_PPC_RELATIVE RELA relocs
2409 as usual in ELF, not as pseudo-REL relocs (as the sparc linker
2410 does).
2411 (ppc_elf_relocate_section): Add handy debugging code for when
2412 assertion fails. Add some more 'symbol made local because of
2413 versioning' cases.
2414
2415 * elf32-ppc.c (ppc_elf_relocate_section): Cope with addend when
2416 processing a GOT relocation as required by ABI.
2417
2418 Wed Jul 30 21:30:35 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2419
2420 * elflink.h (NAME(bfd_elf,record_link_assignment)): Remove any
2421 version info if this symbol came from a dynamic object.
2422 (elf_link_add_object_symbols): Set the version info of a symbol
2423 only if the object actually contains version definitions and
2424 defines this symbol.
2425
2426 Mon Jul 28 18:07:43 1997 Rob Savoye <rob@chinadoll.cygnus.com>
2427
2428 * aclocal.m4: Add CYGWIN and EXEEXT autoconf macros.
2429 * configure.in: Use CYGWIN and EXEEXT autoconf macro to look for
2430 win32 dependencies.
2431 * configure: Regenerated with autoconf 2.12.
2432 * doc/Makefile.in: Add $(EXEEXT) to chew executable.
2433
2434 Mon Jul 28 02:50:29 1997 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
2435
2436 * rs6000-core.c (rs6000coff_core_p): If CORE_TRUNC is set, print
2437 a warning rather than returning an error.
2438
2439 Sun Jul 27 19:54:14 1997 Felix Lee <flee@cygnus.com>
2440
2441 * coffswap.h (coff_swap_aux_in): add semicolon to make MSVC happy.
2442
2443 Fri Jul 25 14:50:08 1997 Felix Lee <flee@cygnus.com>
2444
2445 * cisco-core.c: define signals for wingdb.
2446
2447 Fri Jul 25 16:27:07 1997 Ian Lance Taylor <ian@cygnus.com>
2448
2449 * ecofflink.c (bfd_ecoff_debug_accumulate): Only merge files with
2450 the same number of aux entries.
2451
2452 Fri Jul 25 08:22:15 1997 Jeffrey A Law (law@cygnus.com)
2453
2454 * som.c (hppa_som_gen_reloc_type): Use R_DATA_EXPR for the
2455 difference of two symbols if the relocation size is 32 bits.
2456 (som_write_fixups): Handle R_DATA_EXPR.
2457
2458 Wed Jul 23 16:08:02 1997 Ian Lance Taylor <ian@cygnus.com>
2459
2460 * coff-i386.c (coff_i386_reloc): Don't offset a common symbol by
2461 its value if COFF_WITH_PE is defined.
2462
2463 Tue Jul 22 17:19:45 1997 Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>
2464
2465 * coff-stubgo32.c: New file.
2466 * go32stub.h: New file.
2467 * coff-i386.c: If COFF_GO32_EXE, include coff/go32exe.h.
2468 * coffswap.h (coff_swap_filehdr_in): Invoke
2469 COFF_ADJUST_FILEHDR_IN_PRE and COFF_ADJUST_FILEHDR_IN_POST if they
2470 are defined.
2471 (coff_swap_filehdr_out): Invoke COFF_ADJUST_FILEHDR_OUT_PRE and
2472 COFF_ADJUST_FILEHDR_OUT_POST if they are defined.
2473 (coff_swap_aux_in): Invoke COFF_ADJUST_AUX_IN_PRE and
2474 COFF_ADJUST_AUX_IN_POST if they are defined.
2475 (coff_swap_aux_out): Invoke COFF_ADJUST_AUX_OUT_PRE and
2476 COFF_ADJUST_AUX_OUT_POST if they are defined.
2477 (coff_swap_scnhdr_in): Invoke COFF_ADJUST_SCNHDR_IN_PRE and
2478 COFF_ADJUST_SCNHDR_IN_POST if they are defined.
2479 (coff_swap_scnhdr_out): Invoke COFF_ADJUST_SCNHDR_OUT_PRE and
2480 COFF_ADJUST_SCNHDR_OUT_POST if they are defined.
2481 * targets.c (go32stubbedcoff_vec): Declare.
2482 (bfd_target_vector): Add go32stubbedcoff_vec.
2483 * configure.in (go32coff_vec): New target vector.
2484 (go32stubbedcoff_vec): Likewise.
2485 * config.bfd (i[3456]86-*-msdosdjgpp*): New target.
2486 (i[3456]86-*-go32*): Change to be like new msdosdjgpp*.
2487 * Makefile.in: Rebuild dependencies.
2488 (BFD32_BACKENDS): Add coff-stubgo32.o.
2489 (BFD32_BACKENDS_CFILES): Add coff-stubgo32.c.
2490 (HFILES): Add go32stub.h.
2491
2492 Tue Jul 22 15:09:12 1997 Ian Lance Taylor <ian@cygnus.com>
2493
2494 * configure.in: Check for fdopen.
2495 * configure, config.in: Rebuild.
2496 * opncls.c (bfd_fdopenr): Check HAVE_FDOPEN rather than VMS or
2497 __GO32__. Reindent a bit.
2498
2499 Sun Jul 20 20:05:20 1997 Ian Lance Taylor <ian@cygnus.com>
2500
2501 * sunos.c (sunos_create_dynamic_sections): Set SEC_LINKER_CREATED
2502 flag for newly created sections.
2503 (sunos_add_dynamic_symbols): Don't discard newly created sections
2504 if shared library is dynobj.
2505
2506 Mon Jul 14 15:33:55 1997 Ian Lance Taylor <ian@cygnus.com>
2507
2508 * elf.c (map_sections_to_segments): When checking whether
2509 including a section in a segment would force us to skip a page,
2510 align the address of the next segment to avoid wraparound
2511 problems.
2512
2513 start-sanitize-tic80
2514 Tue Jul 8 12:11:29 1997 Fred Fish <fnf@cygnus.com>
2515
2516 * coffcode.h (coff_write_object_contents): Initialize
2517 target id field to TIC80_TARGET_ID.
2518 * coffswap.h (coff_swap_filehdr_out): Swap out target id field
2519 if used.
2520 (coff_swap_filehdr_in): Swap in target id field if used.
2521
2522 end-sanitize-tic80
2523 Mon Jul 7 16:41:20 1997 Ian Lance Taylor <ian@cygnus.com>
2524
2525 * coff-i386.c (coff_i386_is_local_label_name): New static function
2526 if TARGET_UNDERSCORE.
2527 (coff_bfd_is_local_label_name): Define if TARGET_UNDERSCORE.
2528 (i386coff_vec): Add SEC_CODE and SEC_DATA to section_flags.
2529
2530 Mon Jun 30 14:29:26 1997 Ian Lance Taylor <ian@cygnus.com>
2531
2532 * elf32-m68k.c (howto_table): Use complain_overflow_bitfield, not
2533 complain_overflow_signed, for 32 bit PC relative relocations.
2534
2535 Thu Jun 26 01:26:31 1997 Ian Lance Taylor <ian@cygnus.com>
2536
2537 * elflink.h (elf_link_add_object_symbols): When a version
2538 indirection symbol is overridden, make the original symbol point
2539 at the real overriding symbol.
2540
2541 * elf.c (bfd_elf_string_from_elf_section): Check for an invalid
2542 string index.
2543
2544 * elflink.h (elf_link_output_extsym): Use the right section for a
2545 common symbol.
2546 * elf32-mips.c (mips_elf_link_output_symbol_hook): If a common
2547 symbol was in .scommon, mark it as SHN_MIPS_SCOMMON.
2548
2549 Wed Jun 25 12:43:10 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
2550
2551 * elflink.h (elf_merge_symbols): Resolve indirect and warning
2552 symbols before checking for new symbols.
2553
2554 * elfcore.h (elf_corefile_note): Move out of HAVE_SYS_PROCFS_H.
2555
2556 Tue Jun 24 11:20:43 1997 Ian Lance Taylor <ian@cygnus.com>
2557
2558 * coffgen.c (coff_object_p): Read the f_opthdr bytes from the
2559 file, not aoutsz bytes (they are different in XCOFF .o files).
2560
2561 * xcofflink.c (xcoff_link_add_symbols): Permit symbols to be
2562 redefined by objects included from archives.
2563
2564 Mon Jun 23 18:03:27 1997 Ian Lance Taylor <ian@cygnus.com>
2565
2566 * elflink.h (elf_merge_symbol): In the case of a new defined
2567 symbol overriding an old defined symbol, return the hash table
2568 entry which we modify, even if it is the target of an
2569 indirection.
2570 (elf_link_add_object_symbols): If the real name of the symbol gets
2571 overridden, convert the versioned symbol into an indirect symbol
2572 to the real symbol.
2573
2574 * elflink.h (elf_merge_symbol): New static function, broken out of
2575 elf_link_add_object_symbols.
2576 (elf_link_add_object_symbols): Call it.
2577
2578 Sun Jun 22 19:40:57 1997 Ian Lance Taylor <ian@cygnus.com>
2579
2580 * coff-i386.c (i3coff_object_p): If COFF_IMAGE_WITH_PE, hack to
2581 handle case where COFF filehdr does not immediately follow PE
2582 header.
2583 * coffgen.c (coff_object_p): Remove useless seek to current
2584 location.
2585
2586 Wed Jun 18 19:03:38 1997 Ian Lance Taylor <ian@cygnus.com>
2587
2588 * linker.c (link_action): Change COMMON_ROW/indr to from CREF to
2589 REFC.
2590
2591 Tue Jun 17 11:55:02 1997 Ian Lance Taylor <ian@cygnus.com>
2592
2593 * cofflink.c (_bfd_coff_link_input_bfd): If stripping debugging
2594 symbols, skip N_ABS symbols with debugging storage classes.
2595
2596 Mon Jun 16 18:56:27 1997 Geoff Keating <geoffk@ozemail.com.au>
2597
2598 * elf32-ppc.c (ppc_elf_relocate_section): Don't emit R_PPC_REL*
2599 relocs in shared libraries which refer to local symbols. Cope
2600 with addend when processing a GOT relocation.
2601
2602 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Only create symbols
2603 for sections that the linker didn't create.
2604 (ppc_elf_finish_dynamic_sections): Only try to write out a section
2605 symbol if it was created in ppc_elf_size_dynamic_sections.
2606 (ppc_elf_relocate_section): Complain if we have to generate a reloc
2607 relative to a section for which we didn't output a symbol.
2608
2609 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Clean up. PLT
2610 relocs are 'rela' relocs, like everything else. .rela.plt is not
2611 a read-only section, so we don't have to special-case it.
2612
2613 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Entries in the
2614 .rela.bss section are (of course) 'rela' relocs not 'rel' relocs.
2615
2616 * elf32-ppc.c (ppc_elf_check_relocs): Initialise srelgot.
2617 (ppc_elf_relocate_section): @got offsets are 4 from start of the
2618 actual .got section.
2619 * elflink.c (_bfd_elf_create_got_section): The three reserved
2620 words start from the symbol '_GLOBAL_OFFSET_TABLE_'.
2621
2622 * elf32-ppc.c (ppc_elf_size_dynamic_sections): '.rela' is 5
2623 characters, not 4.
2624
2625 * elf32-ppc.c (ppc_elf_check_relocs): Use
2626 _bfd_elf_create_got_section to create the GOT rather than
2627 ppc_elf_create_linker_section. Create the '.rela.got' section
2628 ourselves.
2629 (ppc_elf_finish_dynamic_symbol): Set up GOT relocations when a
2630 symbol has a GOT entry.
2631 (ppc_elf_relocate_section): Record when a symbol is used through
2632 the GOT, and allocate space in the GOT for each such symbol.
2633 (ppc_elf_adjust_dynamic_symbol): Delete unused .got.plt stuff.
2634 (ppc_elf_create_linker_section): Delete unused LINKER_SECTION_GOT
2635 stuff.
2636
2637 * elf32-ppc.c (ppc_elf_howto_raw): GOT16_HA relocs should be
2638 treated in a similar way to ADDR16_HA relocs.
2639 (ppc_elf_relocate_section): PLTREL24 relocs do not get copied into
2640 shared objects; the linker must deal with them.
2641 (ppc_elf_create_linker_section): Stop setting
2642 _GLOBAL_OFFSET_TABLE_ to the wrong value; delete unused
2643 LINKER_SECTION_PLT stuff.
2644 (ppc_elf_check_relocs): Delete unused LINKER_SECTION_PLT stuff.
2645 (ppc_elf_finish_dynamic_sections): Use BFD calls to get GOT
2646 section, not ELF-specific calls.
2647 (elf_backend_plt_not_loaded): Set to 1.
2648 (elf_backend_got_symbol_offset): Set to 4.
2649 * elf-bfd.h (elf_backend_data): Add 'plt_not_loaded' member
2650 for when ld.so fills in the PLT; and 'got_symbol_offset' member.
2651 * elflink.c (_bfd_elf_create_dynamic_sections): Apply
2652 plt_not_loaded member.
2653 (_bfd_elf_create_got_section): Apply got_symbol_offset.
2654 * elfxx-target.h (elf_backend_plt_not_loaded): Set default to
2655 'loaded'.
2656 (elf_backend_G_O_T_offset): Set default to 0.
2657 (elfNN_bed): Set added fields.
2658
2659 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Was setting
2660 DT_RELENT in shared objects; should be DT_RELAENT.
2661
2662 * elf32-ppc.c (ppc_elf_relocate_section): Propagate
2663 R_PPC_ADDR16_HA relocs to shared objects. Cope with case where
2664 such a reloc (in a non-shared object) refers to a symbol that's
2665 not defined.
2666
2667 Mon Jun 16 14:42:14 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
2668
2669 * elfcode.h (put_signed_word): Define.
2670 (get_signed_word): Define.
2671 (elf_swap_reloca_in): Use get_signed_word for the r_addend field.
2672 (elf_swap_reloca_out): Use put_signed_word for the r_addend
2673 field.
2674 * elf32-m68k.c (elf_m68k_finish_dynamic_symbol): Use
2675 bfd_get_signed_32 to set the r_addend field.
2676 * elf64-mips.c (mips_elf64_swap_reloca_in): Use
2677 bfd_h_get_signed_64 to set the r_addend field.
2678
2679 Mon Jun 16 12:31:29 1997 Ian Lance Taylor <ian@cygnus.com>
2680
2681 * elf32-i386.c (elf_i386_relocate_section): When generating a
2682 shared library, do the relocation if the input section is not
2683 allocated in memory.
2684
2685 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Call
2686 elf_link_assign_sym_version before elf_adjust_dynamic_symbol.
2687 (elf_fix_symbol_flags): New static function, broken out of
2688 elf_adjust_dynamic_symbol.
2689 (elf_adjust_dynamic_symbol): Call elf_fix_symbol_flags.
2690 (elf_link_assign_sym_version): Likewise. Permit a symbol to be
2691 forced local even if NEEDS_PLT is set. When forcing a symbol to
2692 be local, clear NEEDS_PLT.
2693 (elf_link_output_extsym): Remove unused local bed.
2694
2695 Wed Jun 11 22:44:20 1997 Jeffrey A Law (law@cygnus.com)
2696
2697 * elf32-mn10300.c (elf32_mn10300_link_hash_entry): New structure
2698 for derived elf linker hash table entries. References to
2699 elf_link_hash_entry changed appropriately.
2700 (elf32_mn10300_link_hash_table): New structure for derived elf
2701 linker hash table.
2702 (elf32_mn10300_hash_table): Define.
2703 (elf32_mn10300_link_hash_traverse): Likewise.
2704 (elf32_mn10300_link_hash_newfunc): New function.
2705 (elf32_mn10300_link_hash_table_create): Likewise.
2706 (elf32_mn10300_finish_hash_table_entry): Likewise.
2707 (mn10300_elf_relax_section): Handle "call" -> "calls", removal
2708 of prologue code, and call:32->call:16 relaxing.
2709 (compute_function_info: New function.
2710 (bfd_elf32_bfd_ilink_hash_table_create): Define.
2711
2712 Wed Jun 11 00:00:07 1997 Ian Lance Taylor <ian@cygnus.com>
2713
2714 * elflink.h (elf_link_output_extsym): Call finish_dynamic_symbol
2715 for a symbol which is being forced to be local.
2716 * elf32-i386.c (elf_i386_relocate_section): Write out the
2717 relocation value for a GOT reloc for a symbol which is turning
2718 into a local symbol.
2719 (elf_i386_finish_dynamic_symbol): If a symbol is turning into a
2720 local symbol, write out a RELATIVE reloc rather than a GLOB_DAT
2721 reloc.
2722 * elf32-m68k.c, elf32-sparc.c: Corresponding changes.
2723
2724 * elf32-i386.c (elf_i386_relocate_section): Get the relocation
2725 value if the symbol is turning into a local symbol.
2726 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2727 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2728
2729 1997-06-10 22:58 Ulrich Drepper <drepper@cygnus.com>
2730
2731 * elflink.h (elf_link_add_object_symbols): Also read verneed
2732 information by calling `_bfd_elf_slurp_version_tables'.
2733 (elf_link_add_object_symbols): For undefined symbols look for
2734 version information in the verneed records.
2735 (elf_link_add_object_symbols): Use soname of shared object
2736 for verneed record if it is available.
2737
2738 Tue Jun 10 11:13:03 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
2739
2740 * cpu-arm.c: Add prototypes for compatible and scan.
2741 * cofflink.c: Add prototype for mark_relocs.
2742
2743 * archive.c (bfd_special_undocumented_glue): Change filename to
2744 const pointer. Add prototype.
2745
2746 Mon Jun 9 12:34:21 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2747
2748 * elflink.h (elf_link_add_object_symbols): Ignore relocations of
2749 sections that will be discarded.
2750
2751 1997-06-06 22:58 Ulrich Drepper <drepper@cygnus.com>
2752
2753 * elflink.h (elf_link_find_version_dependencies): When searching
2754 for known version symbol skip non-matching verdef records, not
2755 matching records.
2756
2757 Thu Jun 5 15:52:45 1997 Ian Lance Taylor <ian@cygnus.com>
2758
2759 * cofflink.c (_bfd_coff_generic_relocate_section): Write a long,
2760 not a bfd_vma, to the base file, to match how dlltool reads it.
2761
2762 Tue Jun 3 16:57:45 1997 Nick Clifton <nickc@cygnus.com>
2763
2764 * reloc.c: Add thumb relocations.
2765
2766 * bfd-in2.h: Add Thumb relocations.
2767
2768 * libbfd.h: Add Thumb relocations.
2769
2770 Mon Jun 2 10:41:52 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2771
2772 * cpu-m68k.c (arch_info_struct): Fix 68060 cpu name.
2773
2774 Fri May 30 12:46:27 1997 Ian Lance Taylor <ian@cygnus.com>
2775
2776 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Set dynindx
2777 for a section even if it is not loaded.
2778
2779 * cofflink.c (coff_link_add_symbols): If PE file, don't subtract
2780 section VMA.
2781 (_bfd_coff_link_input_bfd): Separate section VMA handling for
2782 input and output files.
2783 (_bfd_coff_generic_relocate_section): Check whether input file,
2784 not output file, is a PE file.
2785
2786 Wed May 28 15:48:43 1997 Nick Clifton <nickc@cygnus.com>
2787
2788 * coff-arm.c: (coff_arm_bfd_set_private_flags): Make static.
2789
2790 Wed May 28 16:16:04 1997 Ian Lance Taylor <ian@cygnus.com>
2791
2792 * coff-i386.c (coff_i386_reloc): Don't just exit if we see an
2793 R_IMAGEBASE reloc.
2794
2795 Wed May 28 09:48:43 1997 Nick Clifton <nickc@cygnus.com>
2796
2797 * cpu-arm.c (compatible): Add test for supersets of ARM
2798 architectures.
2799
2800 Tue May 27 19:42:03 1997 Bob Manson <manson@charmed.cygnus.com>
2801
2802 * cofflink.c (_bfd_coff_final_link): Initialize global_to_static
2803 member.
2804
2805 Tue May 27 14:34:08 1997 Nick Clifton <nickc@cygnus.com>
2806
2807 * coff-arm.c (coff_arm_bfd_set_private_flags): Make global. It is
2808 called directly by gas/config/tc-arm.c.
2809
2810 Tue May 27 15:58:53 1997 Richard Henderson <rth@tamu.edu>
2811
2812 * elf64-alpha.c (PLT_ENTRY_*): Use a new thread-safe format.
2813 (elf64_alpha_finish_dynamic_symbol): Fill it in properly.
2814
2815 Mon May 26 14:05:13 1997 Ian Lance Taylor <ian@cygnus.com>
2816
2817 * coff-ppc.c (coff_ppc_relocate_section): If PE file, don't add
2818 section VMA.
2819
2820 Mon May 26 10:57:48 1997 Fred Fish <fnf@cygnus.com>
2821
2822 * peicode.h (coff_bfd_print_private_bfd_data): #undef before #define.
2823 (coff_bfd_copy_private_bfd_data): Ditto.
2824 * coff-arm.c (coff_arm_bfd_merge_private_bfd_data): Make static.
2825 (coff_arm_bfd_print_private_bfd_data): Ditto.
2826 (coff_arm_bfd_set_private_flags): Ditto.
2827 (coff_arm_bfd_copy_private_bfd_data): Ditto.
2828
2829 Fri May 23 15:14:58 1997 Fred Fish <fnf@cygnus.com>
2830
2831 * libcoff-in.h (struct coff_final_link_info): Add boolean
2832 global_to_static member for support of task linking.
2833 (_bfd_coff_write_task_globals): Add prototype.
2834 * libcoff.h: Regenerate.
2835 * coffcode.h (coff_write_object_contents): Use #ifdef to
2836 check RS6000COFF_C, to be consistent with all other uses
2837 in this file.
2838 * cofflink.c (_bfd_coff_final_link): If doing task linking,
2839 call _bfd_coff_write_task_globals.
2840 (_bfd_coff_link_input_bfd): If doing task linking, convert
2841 global functions to static.
2842 (_bfd_coff_write_global_sym): If doing task linking, convert
2843 global variables to static.
2844 (_bfd_coff_write_task_globals): New function.
2845 start-sanitize-tic80
2846 * coff-tic80.c (TIC80COFF): Define this instead of just TIC80.
2847 (C_AUTOARG): #undef since it clashes with C_UEXT.
2848 (C_LASTENT): #undef since it clashes with C_STATLAB.
2849 * coffcode.h (coff_write_object_contents): Use TIC80COFF
2850 rather than TIC80.
2851 (coff_slurp_symbol_table): Use C_SYSTEM. Hide C_AUTOARG use
2852 when TIC80COFF defined (clashes with C_UEXT). Explicitly
2853 recognize C_UEXT, C_STATLAB, and C_EXTLAB as unsupported.
2854 end-sanitize-tic80
2855
2856 start-sanitize-tic80
2857 Fri May 23 12:38:24 1997 Ian Lance Taylor <ian@cygnus.com>
2858
2859 * coff-tic80.c (tic80_howto_table): Change overflow check for most
2860 PP relocations to complain_overflow_dont.
2861
2862 Thu May 22 20:22:14 1997 Ian Lance Taylor <ian@cygnus.com>
2863
2864 * coff-tic80.c (tic80_howto_table): Add PP relocations. Change
2865 name of R_RELLONG to "RELLONG". Set rightshift and complain for
2866 M_PPCR.
2867 (ppbase_reloc, glob15_reloc): New static functions.
2868 (glob16_reloc, local16_reloc): New static functions.
2869 (rtype2howto): Handle all relocation types.
2870 (coff_tic80_relocate_section): New static function.
2871 (coff_relocate_section): Define to coff_tic80_relocate_section.
2872 * Makefile.in (coff-tic80.o): Depends upon include/coff/tic80.h.
2873
2874 end-sanitize-tic80
2875 Wed May 21 17:15:50 1997 Ian Lance Taylor <ian@cygnus.com>
2876
2877 * coffcode.h (coff_slurp_symbol_table): If COFF_WITH_PE or
2878 COFF_IMAGE_WITH_PE, don't subtract the section VMA from the symbol
2879 value.
2880 * coffgen.c (fixup_symbol_value): Add abfd parameter. Change all
2881 callers. If PE file, don't add section VMA.
2882 (coff_write_alien_symbol): If PE file, don't add section VMA.
2883 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2884 (_bfd_coff_write_global_sym): Likewise.
2885 (_bfd_coff_generic_relocate_section): Likewise.
2886
2887 * peicode.h: Add & 0xffffffff when using ImageBase in case bfd_vma
2888 is 64 bits.
2889
2890 Wed May 21 09:58:10 1997 Nick Clifton <nickc@cygnus.com>
2891
2892 * cofflink.c (mark_relocs): Add new function to mark symbols which
2893 are used by relocations.
2894 (_bfd_coff_link_input_bfd): Add call to mark_relocs() and code to
2895 suppress the skipping of symbols that have thus been marked.
2896
2897 Tue May 20 18:45:26 1997 Ian Lance Taylor <ian@cygnus.com>
2898
2899 * coff-sh.c (sh_merge_private_data): New static function.
2900 (coff_bfd_merge_private_bfd_data): Define.
2901
2902 start-sanitize-tic80
2903 Mon May 19 14:46:00 1997 Mark Alexander <marka@cygnus.com>
2904
2905 * coff-tic80.c: Remove unnecessary #ifdefs.
2906 * config.bfd: Set targ_underscore to yes for tic80.
2907
2908 Mon May 19 14:26:36 1997 Mark Alexander <marka@cygnus.com>
2909
2910 * coff-tic80.c (NAMES_HAVE_UNDERSCORE): Define (fixes problem
2911 with unresolved external symbols in GDB).
2912
2913 end-sanitize-tic80
2914 Fri May 16 10:23:03 1997 Jeffrey A Law (law@cygnus.com)
2915
2916 * elf-m10300.c (elf32_mn10300_relax_section): Read in all
2917 the symbols associated with each BFD.
2918 (mn10300_elf_relax_delete_bytes): Don't adjust the same symbol
2919 more than once.
2920 * elf-m10200.c: Likewise.
2921 * elf32-m32r.c: Likewise.
2922 * elf32-sh.c: Likewise.
2923
2924 Fri May 16 12:10:52 1997 Ian Lance Taylor <ian@cygnus.com>
2925
2926 * elflink.h (elf_link_add_object_symbols): Don't decrease the
2927 alignment of a common symbol. If two symbols that look like
2928 common symbols are found in two shared libraries, and the size is
2929 different, use the larger size, and warn if --warn-common. If a
2930 common symbol overrides a definition in a shared library, set the
2931 size to the larger size, and warn if --warn-common.
2932
2933 Thu May 15 14:31:28 1997 Nick Clifton <nickc@cygnus.com>
2934
2935 * cpu-arm.c (compatible): Allow default machine to be polymorphed
2936 into any other machine type.
2937
2938 * coffcode.h (coff_set_flags): Initialise flags variable to 0.
2939
2940 * coff-arm.c (coff_arm_bfd_merge_private_bfd_data): When merging
2941 data into an unitialised destination set its machine type as well.
2942
2943 Thu May 15 16:40:20 1997 Ian Lance Taylor <ian@cygnus.com>
2944
2945 * elflink.h (elf_link_add_object_symbols): Force ELF symbol size
2946 to common symbol size. Consistently treat uninitialized symbols
2947 in shared objects as common symbols.
2948
2949 Fri May 9 10:15:27 1997 Nick Clifton <nickc@cygnus.com>
2950
2951 * archures.c (constants): Added new constants to identify the
2952 type of the ARM architecture: bfd_mach_arm_2, bfd_mach_arm_2a,
2953 bfd_mach_arm_3, bfd_mach_arm_3M, bfd_mach_arm_4 and bfd_mach_arm_4T.
2954
2955 * bfd-in2.h (constants): Added new constants to identify
2956 the type of the ARM architecture: bfd_mach_arm_2, bfd_mach_arm_2a,
2957 bfd_mach_arm_3, bfd_mach_arm_3M, bfd_mach_arm_4 and
2958 bfd_mach_arm_4T. This file is auto-magically generated from the
2959 archures.c file. This update is just to save work.
2960
2961 * coff-arm.c (coff_arm_bfd_merge_private_bfd_data,
2962 coff_arm_bfd_print_private_bfd_data,
2963 coff_arm_bfd_set_private_flags,
2964 coff_arm_bfd_copy_private_bfd_data): Added these new functions.
2965 (global): Macro redefinitions set up to use these new functions.
2966
2967 * coffcode.h (coff_mkobject_hook): Added call to
2968 coff_arm_bfd_set_private_flags().
2969 (coff_set_arch_mach_hook): Added code to set machine type based on
2970 bits stored in internal flags.
2971 (coff_set_flags): Added code to set the new bits in the flags
2972 field based on the machine number.
2973 (function definition macros): Made all function definition macros
2974 conditional so that they can be overridden by target specific
2975 files.
2976
2977 * cpu-arm.c (compatible): Added this function. (arch_info_struct):
2978 Structure extended to include new types, one each for ARMv2,
2979 ARMv2a, ARMv3, ARMv3M, ARMv4 and ARMv4T.
2980
2981 * libcoff-in.h (struct coff_tdata): Added flags field.
2982
2983 Fri May 9 17:40:02 1997 Ian Lance Taylor <ian@cygnus.com>
2984
2985 * config.bfd (i[3456]86-*-gnu*): Don't include Mach support.
2986
2987 * config.bfd: Change #if 0 around uses of host_aout_vec to #if
2988 HAVE_host_aout_vec.
2989
2990 Mon May 5 13:57:32 1997 Mike Meissner <meissner@cygnus.com>
2991
2992 * coffgen.c (coff_find_nearest_line): If there are no syments,
2993 just return false.
2994
2995 Mon May 5 18:18:45 1997 Philip Blundell <pjb27@cam.ac.uk>
2996
2997 * config.bfd: cope with '*-*-linux-gnuaout' targets.
2998
2999 Thu May 1 11:31:12 1997 Ian Lance Taylor <ian@cygnus.com>
3000
3001 * targmatch.sed: Add explicit \n characters to work around bug in
3002 HP/UX 10.20 sed program.
3003
3004 Wed Apr 30 12:27:03 1997 Ian Lance Taylor <ian@cygnus.com>
3005
3006 * elf.c (copy_private_bfd_data): Cast csecs to avoid sign
3007 extension problems.
3008
3009 Tue Apr 22 12:06:08 1997 Ian Lance Taylor <ian@cygnus.com>
3010
3011 * Makefile.in (do_maintainer_clean): Don't remove bfd-in2.h.
3012
3013 Mon Apr 21 11:21:31 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
3014
3015 * elf32-m68k.c: Follow the last changes in elf32-i386.c:
3016 (struct elf_m68k_pcrel_relocs_copied, struct
3017 elf_m68k_link_hash_entry, struct elf_m68k_link_hash_table,
3018 elf_m68k_link_hash_traverse, elf_m68k_hash_table,
3019 elf_m68k_link_hash_newfunc, elf_m68k_link_hash_table_create,
3020 elf_m68k_discard_copies, bfd_elf32_bfd_link_hash_table_create):
3021 New definitions.
3022 (elf_m68k_check_relocs): If linking with -Bsymbolic, don't copy
3023 PC relative relocs for a global symbol defined in a regular
3024 object, and count the number of PC relative relocs copied for any
3025 global symbol.
3026 (elf_m68k_size_dynamic_sections): If linking with -Bsymbolic,
3027 traverse with elf_m68k_discard_copies.
3028
3029 Sat Apr 19 22:50:14 1997 Ian Lance Taylor <ian@cygnus.com>
3030
3031 * elf32-i386.c (elf_i386_check_relocs): Only count PC relative
3032 relocs. From Jamie Lokier <jamie@rebellion.co.uk>.
3033
3034 * coffcode.h (coff_compute_section_file_positions): Force the
3035 potential last byte in the file to be written out when
3036 COFF_IMAGE_WITH_PE.
3037
3038 Thu Apr 17 13:46:56 1997 Per Fogelstrom <pefo@openbsd.org>
3039
3040 * configure.host (mips*-*-openbsd*): New host.
3041
3042 Thu Apr 17 11:10:54 1997 Ian Lance Taylor <ian@cygnus.com>
3043
3044 * elflink.h (elf_link_add_object_symbols): Only subtract the
3045 section VMA from the symbol value if this is a fully linked file.
3046
3047 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Define.
3048 (struct elf_i386_link_hash_entry): Define.
3049 (struct elf_i386_link_hash_table): Define.
3050 (elf_i386_link_hash_traverse): Define.
3051 (elf_i386_hash_table): Define.
3052 (elf_i386_link_hash_newfunc): New static function.
3053 (elf_i386_link_hash_table_create): New static function.
3054 (elf_i386_check_relocs): If linking with -Bsymbolic, don't copy
3055 PC relative relocs for a global symbol defined in a regular
3056 object, and count the number of PC relative relocs copied for any
3057 global symbol.
3058 (elf_i386_size_dynamic_sections): If linking with -Bsymbolic,
3059 traverse with elf_i386_discard_copies.
3060 (elf_i386_discard_copies): New static function.
3061 (bfd_elf32_bfd_link_hash_table_create): Define.
3062
3063 From Gordon W. Ross <gwr@mc.com>:
3064 * aoutf1.h (MY_entry_is_text_address): Define if not defined.
3065 (sunos4_aout_backend): Use MY_entry_is_text_address.
3066
3067 start-sanitize-d30v
3068 Wed Apr 16 12:43:32 1997 Martin Hunt <hunt@cygnus.com>
3069
3070 * elf32-d30v.c (elf_d30v_howto_table): Changed size of
3071 R_D30V_32_NORMAL to 2 (4 bytes).
3072
3073 end-sanitize-d30v
3074 Wed Apr 16 14:02:29 1997 Ian Lance Taylor <ian@cygnus.com>
3075
3076 From Gordon W. Ross <gwr@mc.com>:
3077 * netbsd.h (N_SHARED_LIB): Define.
3078 (SEGMENT_SIZE): Don't define.
3079 * m68knetbsd.c (SEGMENT_SIZE): Don't define (revert change of
3080 April 11).
3081 * sparcnetbsd.c (TARGET_PAGE_SIZE): Define as 0x2000.
3082 (SEGMENT_SIZE): Don't define.
3083
3084 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Set .rela.bss size
3085 to sizeof Rela structure, not sizeof Rel structure. From Gary
3086 Thomas <g.thomas@opengroup.org>.
3087
3088 Tue Apr 15 11:50:37 1997 Ian Lance Taylor <ian@cygnus.com>
3089
3090 * aout-target.h (MY(callback)): If entry_is_text_address, adjust
3091 whenever entry is larger than text address, but only by whole
3092 pages. From Gordon W. Ross <gwr@mc.com>.
3093
3094 * Makefile.in (install): Depend upon installdirs. Use
3095 mkinstalldirs to build $(oldincludedir).
3096 (installdirs): New target.
3097
3098 * elflink.h (elf_link_add_object_symbols): Don't call check_relocs
3099 if this is a debugging section which we are stripping.
3100
3101 Mon Apr 14 12:39:30 1997 Richard Henderson <rth@tamu.edu>
3102
3103 * elf64-alpha.c (elf64_alpha_object_p): Allocate the
3104 alpha-specific target data struct.
3105
3106 Mon Apr 14 11:45:46 1997 Ian Lance Taylor <ian@cygnus.com>
3107
3108 From Thomas Graichen <graichen@rzpd.de>:
3109 * Makefile.in: Always use $(SHELL) when running move-if-change.
3110 * configure.in: Use ${CONFIG_SHELL} when running $ac_config_sub.
3111 * configure: Rebuild.
3112
3113 Fri Apr 11 15:43:24 1997 Ian Lance Taylor <ian@cygnus.com>
3114
3115 * elfcode.h (elf_slurp_symbol_table): Only subtract the section
3116 VMA if this is an executable file or a shared object.
3117
3118 * targets.c (netbsd_core_vec): Declare. From Gordon W. Ross
3119 <gwr@mc.com>.
3120
3121 * libaout.h (struct aout_backend_data): Add entry_is_text_address
3122 field.
3123 * aout-target.h (SEGMENT_SIZE): Define to TARGET_PAGE_SIZE at the
3124 start of the file. Remove uses later on which switch using
3125 ifdef.
3126 (MY(callback)): Handle entry_is_text_address.
3127 (MY_entry_is_text_address): Define if not defined.
3128 (MY(backend_data)): Initialize new field.
3129 * aoutf1.h (sunos4_aout_backend): Likewise.
3130 * i386aout.c (MY(backend_data)): Likewise.
3131 * i386mach3.c (MY(backend_data)): Likewise.
3132 * mipsbsd.c (MY(backend_data)): Likewise.
3133 * sparclynx.c (sparclynx_aout_backend): Likewise.
3134 * netbsd.h (SEGMENT_SIZE): Define if not defined.
3135 (MY_entry_is_text_address): Define.
3136 * m68knetbsd.c (SEGMENT_SIZE): Define as 0x20000.
3137
3138 * xcofflink.c (bfd_xcoff_import_symbol): Handle importing a symbol
3139 whose name starts with `.'.
3140
3141 Fri Apr 11 11:57:15 1997 Niklas Hallqvist <niklas@appli.se>
3142
3143 * config.bfd: (i[3456]86-*-openbsd*, m68*-*-openbsd*,
3144 mips*el*-*-openbsd*, mips*-*-openbsd*, ns32k-*-openbsd*,
3145 powerpc-*-*bsd*, sparc-*-openbsd*): New targets.
3146 * configure.in (i[3456]86-*-openbsd*, mips*-*-openbsd*,
3147 m68*-*-openbsd*, ns32k-*-openbsd*, powerpc-*-*bsd*,
3148 sparc-*-openbsd*): New targets.
3149 * configure: Rebuild.
3150
3151 Tue Apr 8 18:09:29 1997 Jamie Lokier <jamie@rebellion.co.uk>
3152
3153 * stabs.c (struct stab_section_info): New field
3154 `cumulative_skips'.
3155 (_bfd_link_section_stabs): Fill the above array.
3156 (_bfd_stab_section_offset): Use `cumulative_skips' to
3157 speed up offset calculation.
3158
3159 Tue Apr 8 00:01:31 1997 Jeffrey A Law (law@cygnus.com)
3160
3161 * elf-mn10300.c (mn10300_elf_relax_section): Don't forget the
3162 addend for non pc-relative relocations.
3163
3164 * elf-m10300.c (bfd_elf32_mn10300_reloc): Remove prototype
3165 for non-existent function.
3166
3167 * elf-m10300.c (mn10300_elf_relax_section): New function.
3168 (mn10300_elf_relax_delete_bytes): Likewise.
3169 (mn10300_elf_symbol_address_p): Likewise.
3170 (mn10300_elf_get_relocated_section_contents): Likewise.
3171 (bfd_elf32_bfd_relax_section): Define.
3172 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
3173
3174 Mon Apr 7 16:47:09 1997 Ian Lance Taylor <ian@cygnus.com>
3175
3176 * configure.host: Set SHLIB_LIBS.
3177 * configure.in: Substitute SHLIB_LIBS.
3178 * configure: Rebuild.
3179 * Makefile.in (SHLIB_LIBS): New variable.
3180 ($(SHLIB)): Use $(SHLIB_LIBS).
3181
3182 Mon Apr 7 10:53:52 1997 Michael Snyder <msnyder@cleaver.cygnus.com>
3183
3184 * bfd-in.h bfd-in2.h: add bfd_section_lma macro to correspond
3185 with bfd_section_vma.
3186
3187 Fri Apr 4 11:37:15 1997 Ian Lance Taylor <ian@cygnus.com>
3188
3189 * configure.in: Update file names for bfd_elf32_mn10[23]00_vec.
3190 Correct CPU file names for mn10[23]00.
3191 * configure: Rebuild.
3192
3193 * bfd.c (bfd_record_phdr): Cast count to size_t before
3194 subtraction.
3195
3196 * coff-ppc.c (dump_toc): Add cast to avoid warning from SunOS cc.
3197 * coff-rs6000.c (xcoff_read_ar_hdr): Likewise.
3198 (xcoff_write_archive_contents): LIkewise.
3199 * elf32-mips.c (_bfd_mips_elf_set_section_contents): Likewise.
3200 (mips_elf_create_procedure_table): Likewise.
3201 * peicode.h (pe_print_idata): Likewise.
3202 (pe_print_edata, pe_print_pdata, pe_print_reloc): Likewise.
3203 * xcofflink.c (xcoff_get_section_contents): Likewise.
3204 (_bfd_xcoff_canonicalize_dynamic_symtab): Likewise.
3205 (xcoff_link_add_symbols): Likewise.
3206 (xcoff_link_add_symbols): Likewise.
3207
3208 * ppcboot.c (ppcboot_set_arch_mach): Make static.
3209 (ppcboot_bfd_print_private_bfd_data): Likewise.
3210
3211 * elf32-mips.c (elf_mips_ctor64_howto): Set complain_on_overflow
3212 to complain_overflow_signed.
3213
3214 Thu Apr 3 11:51:54 1997 Ian Lance Taylor <ian@cygnus.com>
3215
3216 * VERSION: Set to 2.8.1.
3217
3218 * Branched binutils 2.8.
3219
3220 * elf32-ppc.c (ppc_elf_check_relocs): Don't check SEC_ALLOC when
3221 deciding whether to copy a reloc into a shared object.
3222 (ppc_elf_relocate_section): Likewise. Relocate R_PPC_RELATIVE
3223 relocs in unallocated sections.
3224 * elf32-sparc.c (elf32_sparc_relocate_section): Relocate
3225 R_SPARC_RELATIVE relocs in unallocated sections.
3226
3227 Wed Apr 2 16:19:41 1997 Mike Meissner <meissner@cygnus.com>
3228
3229 * elf32-ppc.c (ppc_elf_check_relocs): Undo March 26 change and
3230 always create got section so that the _GLOBAL_OFFSET_TABLE_ label
3231 is always created.
3232
3233 Wed Apr 2 10:49:07 1997 Ian Lance Taylor <ian@cygnus.com>
3234
3235 * elflink.h (elf_link_add_object_symbols): Let a common symbol
3236 override an uninitialized symbol from a shared library with a
3237 smaller size.
3238
3239 * elf-m10200.c: Rename from elf32-mn10200.c.
3240 * elf-m10300.c: Rename from elf32-mn10300.c.
3241 * cpu-m10200.c: Rename from cpu-mn10200.c
3242 * cpu-m10300.c: Rename from cpu-mn10300.c
3243 * Makefile.in: Update accordingly.
3244
3245 * elf32-mips.c (elf_mips_ctor64_howto): New static variable.
3246 (elf_mips_isa): Move to earlier in file.
3247 (mips_reloc_map): Remove BFD_RELOC_CTOR entry.
3248 (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_CTOR
3249 specially.
3250
3251 * elf32-mips.c (mips16_jump_reloc): Print a warning rather than
3252 calling abort.
3253
3254 Tue Apr 1 16:18:05 1997 Klaus Kaempf <kkaempf@progis.de>
3255
3256 * configure.com: New file.
3257 * config.h-vms: Remove file.
3258 * makefile.vms: Update for new configure scheme.
3259
3260 Mon Mar 31 23:28:39 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
3261
3262 * libcoff-in.h (ppc_allocate_toc_section): Declare.
3263 (ppc_process_before_allocation): Declare.
3264 * libcoff.h: Rebuild.
3265
3266 * coffcode.h (coff_mkobject_hook): Declare if not a macro.
3267
3268 Mon Mar 31 16:29:50 1997 Joel Sherrill <joel@oarcorp.com>
3269
3270 * config.bfd (hppa*-*-rtems*): New target, like hppa-*-*elf*.
3271
3272 Mon Mar 31 16:11:35 1997 Ian Lance Taylor <ian@cygnus.com>
3273
3274 * coff-a29k.c (coff_a29k_relocate_section): Don't use symndx as a
3275 symbol index for a R_IHCONST reloc.
3276
3277 Mon Mar 31 15:40:59 1997 Philippe De Muyter <phdm@info.ucl.ac.be>
3278
3279 * targmatch.sed: Do not use \(\) recursively.
3280
3281 Fri Mar 28 14:44:08 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
3282
3283 * m68klinux.c (MACHTYPE_OK): Define.
3284 * i386linux.c (MACHTYPE_OK): Define.
3285
3286 Fri Mar 28 11:56:15 1997 Ian Lance Taylor <ian@cygnus.com>
3287
3288 From David S. Miller <davem@caip.rutgers.edu> and H.J. Lu
3289 <hjl@gnu.ai.mit.edu>:
3290 * sparclinux.c: New file.
3291 * bfd-in.h (bfd_sparclinux_size_dynamic_sections): Declare.
3292 * bfd-in2.h: Rebuild.
3293 * config.bfd (sparc-*-linuxaout*, sparc-*-linux*): New targets.
3294 * configure.in (sparclinux_vec): Add to list of vectors.
3295 * configure: Rebuild.
3296 * targets.c (sparclinux_vec): Declare.
3297 (bfd_target_vector): Add sparclinux_vec.
3298 * Makefile.in: Rebuild dependencies.
3299 (BFD32_BACKENDS): Add sparclinux.o.
3300 (BFD32_BACKENDS_CFILES): Add sparclinux.c.
3301
3302 * coff-mips.c (mips_ecoff_backend_data): Initialize new
3303 bfd_coff_backend_data field.
3304 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
3305
3306 * config.bfd: Add bfd_elf64_{big,little}mips_vec to targ_selvecs
3307 for mips*el*-*-linux* and mips*-*-linux*. From H.J. Lu
3308 <hjl@lucon.org> and Ralf Baechle <ralf@gnu.ai.mit.edu>.
3309
3310 * bfd.c: Include "libiberty.h".
3311 (strerror): Don't declare.
3312 (bfd_errmsg): Call xstrerror rather than strerror.
3313
3314 Thu Mar 27 12:55:42 1997 Ian Lance Taylor <ian@cygnus.com>
3315
3316 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Generate a COPY
3317 reloc even if the symbol is in the .bss section.
3318 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
3319 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
3320 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Likewise.
3321
3322 * coffcode.h (bfd_coff_backend_data): Add new field
3323 _bfd_coff_default_section_alignment_power.
3324 (bfd_coff_default_section_alignment_power): Define.
3325 (bfd_coff_std_swap_table): Initialize new field.
3326 * libcoff.h: Rebuild.
3327 * cofflink.c (coff_link_add_symbols): Limit alignment of a common
3328 symbol to the default section alignment.
3329
3330 * COPYING: Update FSF address.
3331
3332 start-sanitize-d30v
3333 Thu Mar 27 00:45:57 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
3334
3335 * elf32-d30v.c (elf_d30v_howto_table): Fix a typo in the
3336 21-bit absolute that made it act as a relative.
3337
3338 end-sanitize-d30v
3339 Wed Mar 26 14:50:20 1997 Ian Lance Taylor <ian@cygnus.com>
3340
3341 * elflink.c (_bfd_elf_create_linker_section): Don't set
3342 bss_section and rel_section from existing sections.
3343
3344 * elf32-ppc.c (ppc_elf_check_relocs): Only create the got section
3345 if it is needed.
3346
3347 Tue Mar 25 22:26:56 1997 Stu Grossman (grossman@critters.cygnus.com)
3348
3349 * aoutx.h (some_aout_object_p): Change executable test to fix
3350 problems with embedded a.out systems.
3351
3352 Tue Mar 25 14:35:37 1997 Ian Lance Taylor <ian@cygnus.com>
3353
3354 * stabs.c (_bfd_stab_section_offset): New function.
3355 * libbfd-in.h (_bfd_stab_section_offset): Declare.
3356 * libbfd.h: Rebuild.
3357 * elf32-i386.c (elf_i386_relocate_section): Adjust the offset of a
3358 stab reloc.
3359 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3360 * elf32-mips.c (mips_elf_relocate_section): Likewise.
3361 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3362 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3363 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
3364
3365 * stabs.c (_bfd_link_section_stabs): Copy over the first header
3366 symbol. Check for memory allocation failure of *psinfo.
3367 (_bfd_write_section_stabs): Add psinfo parameter. Change all
3368 callers. Set the value of the header symbol.
3369 * libbfd-in.h (_bfd_write_section_stabs): Update declaration.
3370 * libbfd.h: Rebuild.
3371
3372 start-sanitize-tic80
3373 Mon Mar 24 20:07:29 1997 Fred Fish <fnf@cygnus.com>
3374
3375 * coff-tic80.c (tic80_howto_table): Add R_ABS entry.
3376 (rtype2howto): Handle R_ABS reloc type. Also abort on unhandled
3377 reloc types, rather than silently failing to generate an output file.
3378
3379 end-sanitize-tic80
3380 Mon Mar 24 13:41:00 1997 Ian Lance Taylor <ian@cygnus.com>
3381
3382 * targmatch.sed: Use the hold space to put the #ifdef around the
3383 the string constant.
3384 * targets.c (UNSUPPORTED_TARGET): Don't define.
3385 (find_target): Don't check for UNSUPPORTED_TARGET.
3386 (bfd_set_default_target): Don't try to optimize by checking for
3387 default.
3388
3389 * Makefile.in: Rebuild dependencies.
3390 (ALL_MACHINES_CFILES): Add cpu-m32r.c.
3391 (BFD32_BACKENDS_CFILES): Add elf32-m32r.c.
3392 (elf32-m32r.o): Remove explicit target.
3393
3394 * config.bfd: Don't set targ_underscore for i[3456]86-*-gnu* or
3395 i[3456]86-*-linux*.
3396
3397 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Don't
3398 count section symbols for sections that were created by the
3399 linker, or are not allocatable or not loadable.
3400 (elf32_sparc_finish_dynamic_sections): Output output section
3401 symbols for section for which we made space for them.
3402
3403 Fri Mar 21 13:08:26 1997 Ian Lance Taylor <ian@cygnus.com>
3404
3405 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): If there is
3406 no .rela.plt section, don't output a DT_PLTGOT dynamic entry.
3407
3408 Fri Mar 21 12:36:46 1997 Doug Evans <dje@canuck.cygnus.com>
3409
3410 * elf32-m32r.c (m32r_elf_howto_table): Use special function for LO16.
3411 (m32r_hi16_list): New static local.
3412 (m32r_elf_hi16_reloc): Don't perform reloc, just queue it up.
3413 (m32r_elf_do_hi16_reloc): Delete.
3414 (m32r_elf_relocate_hi16): New function.
3415 (m32r_elf_lo16_reloc): New function.
3416 (m32r_elf_relocate_section): For HI16 relocs, scan for corresponding
3417 LO16 reloc.
3418
3419 Mon Mar 10 16:03:31 1997 Doug Evans <dje@seba.cygnus.com>
3420
3421 * elf32-m32r.c (m32r_elf_create_linker_section): Delete.
3422 (m32r_elf_add_symbol_hook): Rewrite _SDA_BASE_ support.
3423 (m32r_elf_final_sda_base): New function.
3424 (m32r_elf_relocate_section): Rewrite sdata support.
3425 (m32r_elf_finish_dynamic_sections): Delete.
3426
3427 Thu Mar 20 12:39:02 1997 Ian Lance Taylor <ian@cygnus.com>
3428
3429 Based on patches from Philippe De Muyter <phdm@info.ucl.ac.be>.
3430 * coff-svm68k.c: New file. Just defines some macros and includes
3431 coff-m68k.c.
3432 * coff-m68k.c: Add functions to handle common addends, moved in
3433 from cf-m68klynx.c. Control them using COFF_COMMON_ADDEND macro.
3434 Control whether relocs are visible using STATIC_RELOCS.
3435 * cf-m68klynx.c: Simplify greatly: just define macros to control
3436 coff-m68k.c.
3437 * coff-aux.c: Likewise. Just leave add_one_symbol routine.
3438 * targets. (m68ksysvcoff_vec): Declare.
3439 (bfd_target_vector): Add m68ksysvcoff_vec.
3440 * config.bfd (m68*-motorola-sysv*): New target.
3441 * configure.in (m68ksysvcoff_vec): New vector.
3442 * configure: Rebuild.
3443 * Makefile.in: Rebuild dependencies.
3444 (BFD32_BACKENDS): Add coff-svm68k.o.
3445 (BFD32_BACKENDS_CFILES): Add coff-svm68k.c.
3446
3447 * binary.c (binary_set_section_contents): Don't get misled if the
3448 first section is not loadable. From Matthew L. Martin
3449 <mlm@xedia.com>.
3450
3451 * elflink.h (elf_bfd_final_link): Set the value of a section
3452 symbol to the section address unless doing a relocateable link.
3453
3454 Tue Mar 18 23:03:17 1997 Richard Henderson <rth@tamu.edu>
3455
3456 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't create
3457 .plt entry if we've taken the function's address.
3458 (elf64_alpha_merge_gots): Merge collected flags info as well.
3459
3460 Tue Mar 18 22:40:09 1997 H.J. Lu <hjl@lucon.org>
3461
3462 * Many files: Add function prototypes.
3463 * cpu-m68k.c (bfd_default_scan_num_mach): Don't declare.
3464 * ecofflink.c: Include "libcoff.h" and "libecoff.h".
3465 * elf32-ppc.c (ppc_elf_fake_sections): Make static.
3466 * opncls.c (bfd_openstreamr): Change stream parameter to PTR.
3467 * peicode.h: Change several void * parameters to PTR.
3468 * srec.c (srec_get_symbol_info): Make static.
3469 * syms.c (bfd_symbol_is_absolute): Remove.
3470 * Makefile.in: Rebuild dependencies.
3471
3472 Tue Mar 18 12:58:08 1997 Ian Lance Taylor <ian@cygnus.com>
3473
3474 * elf32-m32r.c (m32r_elf_is_local_label_name): Remove.
3475 (bfd_elf32_bfd_is_local_label): Don't define.
3476
3477 * xcofflink.c (_bfd_xcoff_bfd_final_link): Call bfd_malloc rather
3478 than malloc.
3479
3480 Mon Mar 17 11:32:53 1997 Ian Lance Taylor <ian@cygnus.com>
3481
3482 * bfd-in.h: Don't include obstack.h.
3483 (struct bfd_hash_table): Change memory field to PTR.
3484 * bfd.c (struct _bfd): Change memory field to PTR.
3485 * bfd-in2.h: Rebuild.
3486 * libbfd-in.h (bfd_release): Declare as function, don't define as
3487 macro.
3488 * libbfd.h: Rebuild.
3489 * opncls.c: Include "objalloc.h" rather than "obstack.h". Use
3490 objalloc routines rather than obstack routines.
3491 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
3492 (getpagesize): Don't define.
3493 (_bfd_new_bfd): Don't set _bfd_chunksize.
3494 (bfd_openr): Free new bfd and objalloc on failure.
3495 (bfd_fdopenr, bfd_openstreamr, bfd_openw): Likewise.
3496 (bfd_alloc_size): Remove.
3497 (bfd_release): New function.
3498 * hash.c: Include "objalloc.h" rather than "obstack.h". Use
3499 objalloc routines rather than obstack routines.
3500 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
3501 * ecofflink.c: Include "objalloc.h" rather than "obstack.h". Use
3502 objalloc routines rather than obstack routines.
3503 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
3504 (struct accumulate): Change memory to struct objalloc *.
3505 * liboasys.h (oasys_data_type): Remove oasys_obstack field.
3506 * dep-in.sed: Don't remove obstack.h from dependency list.
3507 * Makefile.in: Rebuild dependencies.
3508 (BFD_H_DEPS): Remove obstack.h.
3509 (install): Don't install obstack.h.
3510 * Many files: Don't include "obstack.h".
3511 * VERSION: Bump.
3512
3513 * opncls.c (bfd_alloc_grow, bfd_alloc_finish): Remove.
3514 * libbfd-in.h (bfd_alloc_grow, bfd_alloc_finish): Don't declare.
3515 * libbfd.h: Rebuild.
3516 * ieee.c (ieee_archive_p): Rewrite to not use bfd_alloc_grow.
3517 * sunos.c (sunos_add_dynamic_symbols): Likewise.
3518 * srec.c (srec_scan): Rewrite to not use obstack_1grow.
3519
3520 * opncls.c (bfd_alloc): Rename from bfd_alloc_by_size_t. Remove
3521 old version of bfd_alloc.
3522 * libbfd-in.h (bfd_alloc_by_size_t): Don't declare.
3523 * libbfd.h: Rebuild.
3524 * Several files: Call bfd_alloc rather than bfd_alloc_by_size_t.
3525
3526 Sat Mar 15 15:24:18 1997 Ian Lance Taylor <ian@cygnus.com>
3527
3528 * elf32-mips.c (mips_elf_is_local_label_name): Accept the generic
3529 ELF local label syntax as well.
3530
3531 Sat Mar 15 10:16:42 1997 Fred Fish <fnf@cygnus.com>
3532
3533 * config.bfd (powerpc-*-beos*): New target.
3534 * configure.in (powerpc-*-beos*): Add case that explicitly
3535 does not set COREFILE for now. A future BeOS version is
3536 expected to support core files.
3537 * configure: Regenerate with autoconf.
3538
3539 Fri Mar 14 16:43:22 1997 Ian Lance Taylor <ian@cygnus.com>
3540
3541 * elf32-mips.c (mips_elf_check_relocs): Give an error if CALL16 is
3542 seen with a local symbol, rather than crashing.
3543
3544 * elfcode.h (elf_slurp_symbol_table): Don't try to read the
3545 version symbols if there aren't any.
3546
3547 start-sanitize-tic80
3548 Thu Mar 13 16:38:30 1997 Fred Fish <fnf@cygnus.com>
3549
3550 * coff-tic80.c (coff_rtype_to_howto): Define
3551 (coff_tic80_rtype_to_howto): Clone generic coff version and
3552 add code to handle the funky TI "internal relocations".
3553
3554 end-sanitize-tic80
3555 Thu Mar 13 14:08:53 1997 Ian Lance Taylor <ian@cygnus.com>
3556
3557 * elflink.h (elf_link_add_object_symbols): Don't warn about type
3558 or size changes because of a weak symbol.
3559
3560 * cisco-core.c (SIGEMT): Define if not defined.
3561
3562 Wed Mar 12 21:36:05 1997 Ian Lance Taylor <ian@cygnus.com>
3563
3564 * elflink.h (elf_link_add_object_symbols): Use extsymoff when
3565 setting ever. Sanity check the version number. Sort out copying
3566 flags and other information when adding an indirect symbol.
3567 (NAME(bfd_elf,size_dynamic_sections)): Preserve any dynamic
3568 symbols added by the backend. Clear the entire contents of the
3569 versym section.
3570 (elf_export_symbol): Ignore indirect symbols.
3571 (elf_link_output_extsym): Accept a section without an owner in an
3572 assert.
3573 * elfcode.h (elf_slurp_symbol_table): Add a sanity check on the
3574 version count. Correct the allocation of x_versymp.
3575
3576 * elf32-mips.c (mips_elf_add_symbol_hook): Don't set the owner of
3577 the magic sections used for SHN_MIPS_TEXT and SHN_MIPS_DATA.
3578 Don't return bfd_und_section_ptr when info->shared.
3579 (mips_elf_final_link): Set the alignment of .rtproc to 4, not 12.
3580 (mips_elf_create_dynamic_sections): Correct type: ^= for &=.
3581 (mips_elf_check_relocs): Resolve an indirect symbol in
3582 sym_hashes.
3583 (mips_elf_finish_dynamic_symbol): Don't change SHN_ABS into
3584 SHN_MIPS_TEXT or SHN_MIPS_DATA.
3585
3586 * elf.c (bfd_elf_print_symbol): Tweak version output slightly.
3587
3588 Tue Mar 11 01:38:36 1997 Ian Lance Taylor <ian@cygnus.com>
3589
3590 From Eric Youngdale <eric@andante.jic.com>:
3591 * elf-bfd.h (ELF_LINK_FORCED_LOCAL): Define.
3592 * elf.c (bfd_elf_print_symbol): Correct errors in last change.
3593 * elflink.h (elf_link_add_object_symbols): Handle cases in which a
3594 versioned symbol appears in both a regular and a shared object.
3595 (elf_link_assign_sym_version): Set ELF_LINK_FORCED_LOCAL when
3596 appropriate. Improve error message.
3597 (struct elf_outext_info): Rename from elf_finfo_failed. Change
3598 all uses. Add localsyms field.
3599 (elf_bfd_final_link): When generating a shared library, call
3600 elf_link_output_extsym to output all local symbols.
3601 (elf_link_output_extsym): Handle symbols which were forced to
3602 become local.
3603
3604 Sun Mar 9 23:08:49 1997 Ian Lance Taylor <ian@cygnus.com>
3605
3606 From Eric Youngdale <eric@andante.jic.com>:
3607 * elf-bfd.h (elf_symbol_type): Add version field.
3608 * elfcode.h (elf_slurp_symbol_table): Set version field.
3609 * elflink.h (elf_link_add_object_symbols): When creating an
3610 indirect symbol for a default version symbol, set DEF_DYNAMIC if
3611 appropriate. Set up an indirection from the nondefault version of
3612 the symbol as well.
3613 (NAME(bfd_elf,size_dynamic_sections)): Call
3614 elf_link_assign_sym_version before checking whether there are any
3615 versions. Always record the version name as a dynamic symbol.
3616 Initialize counters.
3617 (elf_link_assign_sym_version): After finding a version, see if a
3618 symbol should be forced to local scope. Create a new version
3619 definition if appropriate.
3620 (elf_link_output_extsym): Correct indirect symbol handling.
3621 * elf.c (bfd_elf_print_symbol): Print version information.
3622 (bfd_section_from_shdr): Turn version sections into BFD sections.
3623 (elf_fake_sections): Only copy cverdefs and cverrefs into sh_info
3624 if sh_info is not already set.
3625 (_bfd_elf_copy_private_section_data): Copy sh_info for version
3626 sections.
3627 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Tell
3628 _bfd_stringtab_add to copy the name into permanent memory if
3629 appropriate.
3630
3631 Fri Mar 7 11:55:31 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
3632
3633 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Fully parenthesize.
3634
3635 Fri Mar 7 10:37:30 1997 Ian Lance Taylor <ian@cygnus.com>
3636
3637 * coffcode.h (bfd_coff_backend_data): Change
3638 _bfd_coff_compute_section_file_positions to return a boolean
3639 value. Change all callers.
3640 (coff_compute_section_file_positions): Change return type to
3641 boolean. If the size of the last section changed, then output a
3642 zero byte at the end of the file.
3643 * libcoff.h: Rebuild.
3644
3645 * xcofflink.c (_bfd_xcoff_bfd_final_link): Always allocate space
3646 for at least 6 output symbols.
3647 (xcoff_write_global_symbol): When emitting TOC entry relocs, also
3648 emit a TC csect to represent the space they take up. For an XO
3649 symbol, just emit a reference, not a csect.
3650
3651 * Makefile.in ($(SHLINK)): Just use ln -s, not ln -sf, since
3652 Solaris doesn't like the combined options, and the -f is
3653 unnecessary.
3654 (stamp-tshlink, install): Likewise.
3655
3656 * elf32-mips.c (mips_elf_relocate_section): Correct R_MIPS16_26
3657 handling when little endian.
3658
3659 Thu Mar 6 13:51:51 1997 Jeffrey A Law (law@cygnus.com)
3660
3661 * elf32-mn10300.c (mn10300_elf_final_link_relocate): New function.
3662 (mn10300_elf_relocate_section): Likewise.
3663 (elf_backend_relocate_section): Define.
3664
3665 * elf32-mn10300.c (reloc_type): Remove PCREL{8,16,32}_{1,2}BYTE
3666 relocs. Replace them with generic PCREL_{8,16,32} relocs.
3667 (elf32_mn10300_howto_table): Likewise.
3668 (elf32_mn10300_reloc_map): Likewise.
3669 (bfd_elf32_mn10300_reloc): Delete unused function.
3670
3671 Thu Mar 6 12:19:59 1997 Fred Fish <fnf@cygnus.com>
3672
3673 start-sanitize-tic80
3674 * coff-tic80.c (rtype2howto): If passed a relocation type we don't
3675 understand, just set the howto field to NULL, and the caller will
3676 print an appropriate error message.
3677 end-sanitize-tic80
3678 * coffcode.h (coff_slurp_reloc_table): Pull duplicate declarations and
3679 code fragment out of both legs of #ifdef RELOC_PROCESSING ... #endif
3680 block. Use NULL for initializations of "ptr" rather than bare 0.
3681 * coff-h8300.c: Fix typo in comment.
3682 * coff-h8500.c: Ditto.
3683 * coff-w65.c: Ditto
3684 * coff-z8k.c: Ditto.
3685
3686 Wed Mar 5 13:59:09 1997 Doug Evans <dje@seba.cygnus.com>
3687
3688 * elf32-m32r.c (m32r_elf_do_10_pcrel_reloc): Fix overflow calc.
3689 (m32r_elf_relax_section, m32r_elf_relax_delete_bytes,
3690 m32r_elf_get_relocated_section_contents): First pass at relax support.
3691
3692 Mon Mar 3 13:27:09 1997 Ulrich Drepper <drepper@rtl.cygnus.com>
3693
3694 * elflink.h (elf_link_add_object_symbols): Use correct sh_size
3695 entry for reading verdef records.
3696 Use correct braces for computing increments of extverdaux and
3697 exteverdef record pointers.
3698
3699 start-sanitize-tic80
3700 Sun Mar 2 22:47:54 1997 Fred Fish <fnf@cygnus.com>
3701
3702 * coff-tic80.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set this to 2
3703 instead of 4.
3704
3705 end-sanitize-tic80
3706 Sun Mar 2 16:25:35 1997 Ian Lance Taylor <ian@cygnus.com>
3707
3708 * elflink.h (elf_link_find_version_dependencies): Check that
3709 DEF_REGULAR is not set as well as checking that DEF_DYNAMIC is
3710 set.
3711
3712 start-sanitize-tic80
3713 Fri Feb 28 16:52:40 1997 Fred Fish <fnf@cygnus.com>
3714
3715 * coffcode.h (coff_set_flags): Add case for TIC80_ARCH_MAGIC.
3716
3717 end-sanitize-tic80
3718 Fri Feb 28 15:06:45 1997 Ian Lance Taylor <ian@cygnus.com>
3719
3720 * targets.c (bfd_default_vector): Make non-const.
3721 (find_target): New static function, broken out of
3722 bfd_find_target.
3723 (bfd_set_default_target): New function.
3724 (bfd_find_target): Call find_target. When defaulting, use
3725 bfd_default_vector[0] if it is not NULL.
3726 * libbfd-in.h (bfd_default_vector): Adjust declaration.
3727 * bfd-in2.h, libbfd.h: Rebuild.
3728
3729 * syms.c (bfd_is_local_label): Return false if the symbol has no
3730 name.
3731 * coff-i960.c (coff_i960_is_local_label_name): New function.
3732 (coff_bfd_is_local_label_name): Define.
3733 * coff-m68k.c (m68k_coff_is_local_label_name): New function.
3734 (coff_bfd_is_local_label_name): Define.
3735 * coff-rs6000.c (xcoff_is_local_label_name): New function.
3736 (coff_bfd_is_local_label_name): Define.
3737 * elf.c (_bfd_elf_is_local_label_name): Treat symbols beginning
3738 with .. or _.L_ as local.
3739 * elf32-i386.c (elf_i386_is_local_label_name): New function.
3740 (bfd_elf32_bfd_is_local_label_name): Define.
3741 * evax-alpha.c (evax_bfd_is_local_label_name): Treat symbols
3742 beginning with $ as local.
3743
3744 Thu Feb 27 18:36:23 1997 Ian Lance Taylor <ian@cygnus.com>
3745
3746 * aoutx.h (aout_link_write_symbols): Use bfd_is_local_label_name
3747 rather than comparing against info->lprefix.
3748 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
3749 * elflink.h (elf_link_input_bfd): Likewise.
3750 * linker.c (_bfd_generic_link_output_symbols): Likewise.
3751 * xcofflink.c (xcoff_link_input_bfd): Likewise.
3752
3753 * elfxx-target.h (bfd_elfNN_bfd_is_local_label_name): Define as
3754 _bfd_elf_is_local_label_name if not already defined.
3755 * elf.c (_bfd_elf_is_local_label_name): New function.
3756 * elf-bfd.h (_bfd_elf_is_local_label_name): Declare.
3757
3758 * coff-m88k.c (coff_bfd_is_local_label_name): Define.
3759 (m88k_is_local_label_name): New static function.
3760
3761 * coffcode.h (coff_bfd_is_local_label_name): Define as
3762 _bfd_coff_is_local_label_name if not already defined.
3763 * coffgen.c (_bfd_coff_is_local_label_name): New function.
3764 * libcoff-in.h (_bfd_coff_is_local_label_name): Declare.
3765 * libcoff.h: Rebuild.
3766
3767 * targets.c (BFD_JUMP_TABLE_SYMBOLS): Change _bfd_is_local_label
3768 to _bfd_is_local_label_name.
3769 (bfd_target): Likewise.
3770 * syms.c (bfd_is_local_label): Define as function, not macro.
3771 (bfd_is_local_name): Define.
3772 * libbfd.c (bfd_generic_is_local_label_name): Rename from
3773 bfd_generic_is_local_label, and take a string rather than a
3774 symbol.
3775 * libbfd-in.h (_bfd_nosymbols_bfd_is_local_label): Don't define.
3776 (_bfd_nosymbols_bfd_is_local_label_name): Define.
3777 (bfd_generic_is_local_label): Don't declare.
3778 (bfd_generic_is_local_label_name): Declare.
3779 * bfd-in2.h, libbfd.h: Rebuild.
3780 * All backends: Change local_label to local_label_name.
3781
3782 * elf32-mips.c (struct mips_got_info): Add assigned_gotno field.
3783 (mips_elf_relocate_got_local): Change return type to boolean.
3784 Don't assume that the first zero entry is unassigned; instead, use
3785 assigned_gotno.
3786 (mips_elf_relocate_section): Check return value of
3787 mips_elf_relocate_got_local.
3788 (mips_elf_create_got_section): Initialize assigned_gotno field.
3789
3790 start-sanitize-d30v
3791 Wed Feb 26 15:19:51 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
3792
3793 * elf32-d30v.c (bfd_elf_d30v_reloc): Add code to do 32-bit
3794 relocations.
3795
3796 end-sanitize-d30v
3797 Wed Feb 26 13:33:03 1997 Ian Lance Taylor <ian@cygnus.com>
3798
3799 * elflink.h (elf_link_input_bfd): Don't skip symbols from sections
3800 that have no contents merely because linker_mark is not set.
3801
3802 Tue Feb 25 18:51:35 1997 Stan Shebs <shebs@andros.cygnus.com>
3803
3804 * config.bfd (mips*-*-lnews*): New target.
3805 * coff-mips.c (mips_relocate_section): Make assert compare
3806 content byteorder instead of header byteorder.
3807 (ecoff_biglittle_vec): New BFD, big-endian headers, little-endian
3808 data.
3809 * targets.c (bfd_target_vector): Add ecoff_biglittle_vec.
3810 * configure.in (ecoff_biglittle_vec): Add case.
3811 * configure: Update.
3812
3813 Tue Feb 25 00:32:49 1997 Ian Lance Taylor <ian@cygnus.com>
3814
3815 * elf.c (elf_fake_sections): Use SHT_NOTE for any section whose
3816 name begins with ".note".
3817 (map_sections_to_segments): Add a PT_NOTE segment for any loadable
3818 section whose name begins with ".note".
3819 (get_program_header_size): Corresponding change.
3820
3821 * elf32-mips.c (mips_elf_relocate_section): Check for misaligned
3822 jal and for jal overflow.
3823
3824 Mon Feb 24 17:53:14 1997 Ian Lance Taylor <ian@cygnus.com>
3825
3826 From Eric Youngdale <eric@andante.jic.com>:
3827 * elflink.h (elf_link_add_archive_symbols): If a default symbol is
3828 not found, try looking it up again without the version name.
3829 (elf_link_add_object_symbols): Always link against the dynamic
3830 symbol table of a dynamic object. When linking against a dynamic
3831 object, include version strings in symbol names, and set up
3832 version information. Add indirect symbols for default versions.
3833 (elf_link_create_dynamic_sections): Add special version sections.
3834 (struct elf_assign_sym_version_info): Define.
3835 (struct elf_find_verdep_info): Define.
3836 (NAME(bfd_elf,size_dynamic_sections)): Add verdefs parameter. Set
3837 up version sections.
3838 (elf_adjust_dynamic_symbol): Ignore indirect symbols.
3839 (elf_link_find_version_dependencies): New static function.
3840 (elf_link_assign_sym_version): New static function.
3841 (elf_link_renumber_dynsyms): New static function.
3842 (struct elf_final_link_info): Add symver_sec field.
3843 (elf_bfd_final_link): Initialize finfo.symver_sec. Don't count
3844 local symbols of a dynamic object. Handle DT_VER* constants.
3845 (elf_link_output_extsym): Simplify BFD_ASSERT checking for a
3846 dynamic object. Skip indirect symbols from ELF objects. Remove
3847 the version name before choosing a hash bucket. Write out the
3848 version information if appropriate.
3849 (elf_link_input_bfd): Check for DYNAMIC, not ET_DYN.
3850 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
3851 (bfd_elf64_size_dynamic_sections): Likewise.
3852 * bfd-in2.h: Rebuild.
3853 * elf-bfd.h (struct elf_link_hash_entry): Add verinfo field.
3854 Change elf_link_hash_flags to unsigned short.
3855 (ELF_LINK_HIDDEN): Define.
3856 (struct elf_obj_tdata): Add fields dynversym_hdr, dynverref_hdr,
3857 dynverdef_hdr, dynversym_section, dynverdef_section,
3858 dynverref_section, cverdefs, cverrefs, verdef, verref.
3859 (elf_dynversym, elf_dynverdef, elf_dynverref): Define.
3860 (_bfd_elf_swap_verdef_in, _bfd_elf_swap_verdef_out): Declare.
3861 (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Declare.
3862 (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Declare.
3863 (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Declare.
3864 (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Declare.
3865 (_bfd_elf_slurp_version_tables): Declare.
3866 * elf.c (_bfd_elf_swap_verdef_in): New function.
3867 (_bfd_elf_swap_verdef_out): Likewise.
3868 (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Likewise.
3869 (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Likewise.
3870 (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Likewise.
3871 (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Likewise.
3872 (_bfd_elf_print_private_bfd_data): Add DT_VER* constants. Print
3873 version information if there is any.
3874 (_bfd_elf_link_hash_newfunc): Initialize verinfo field.
3875 (bfd_section_from_shdr): Handle SHT_GNU_ver* section types.
3876 (elf_fake_sections): Handle .gnu.version* section names.
3877 (assign_section_numbers): Handle SHT_GNU_ver* section types.
3878 (_bfd_elf_slurp_version_tables): New function.
3879 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't include
3880 version name in string entered in dynamic hash table.
3881 * elfcode.h: Include fnmatch.h.
3882 * elf32-i386.c (elf_i386_relocate_section): Handle a dynamic
3883 symbol which was forced to become local.
3884 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3885 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3886 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3887 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
3888
3889 Fri Feb 21 16:15:18 1997 Jeffrey A Law (law@cygnus.com)
3890
3891 * elf32-mn10200.c (mn10200_elf_final_link_relocate): Simplify
3892 somewhat.
3893 (mn10200_elf_relax_section): Correctly compute a symbol's value
3894 when the symbol is local, but not in the same section as we are
3895 relaxing. Implement abs24 -> abs16, imm24 -> imm16 and d24 -> d16
3896 relaxing.
3897
3898 Fri Feb 21 13:55:14 1997 Doug Evans <dje@seba.cygnus.com>
3899
3900 * elf32-m32r.c: Rewrite to use ELF backend linker.
3901 Store lower 16 bits of addend in R_M32R_HI16_[SU]LO insns.
3902 Add small data area support (R_M32R_SDA16).
3903 * reloc.c: Document BFD_RELOC_M32R_SDA16.
3904 * bfd-in2.h,libbfd.h: Regenerated.
3905
3906 Thu Feb 20 23:50:31 1997 Jeffrey A Law (law@cygnus.com)
3907
3908 * elf32-mn10200.c (mn10200_elf_relax_section): New function.
3909 (mn10200_elf_relax_delete_bytes): Likewise.
3910 (mn10200_elf_symbol_address_p): Likewise.
3911 (mn10200_elf_get_relocated_section_contents): Likewise.
3912 (bfd_elf32_bfd_relax_section): Define.
3913 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
3914
3915 * elf32-mn10200.c (mn10200_elf_final_link_relocate): New function.
3916 (mn10200_elf_relocate_section): Likewise.
3917 (elf_backend_relocate_section): Define.
3918
3919 start-sanitize-d30v
3920 Tue Feb 18 17:22:59 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
3921
3922 * Makefile.in, archures.c, config.bfd, configure.in, elf.c,
3923 reloc.c, targets.c: New target, elf-*-D30V.
3924
3925 * bfd-in2.h, configure, libbfd.h: Rebuilt.
3926
3927 * cpu-d30v.c, elf32-d30v.c: New files.
3928
3929 end-sanitize-d30v
3930 Tue Feb 18 15:31:48 1997 Fred Fish <fnf@cygnus.com>
3931
3932 * reloc.c (struct reloc_howto_struct): Fix typo in comment.
3933 * bfd-in2.h: Regenerated.
3934 start-sanitize-tic80
3935 * coff-tic80.c (RTYPE2HOWTO): Replace abort with real function.
3936 (rtype2howto): Add function.
3937 (tic80_howto_table): Add.
3938 end-sanitize-tic80
3939
3940 Tue Feb 18 11:41:00 1996 Dawn Perchik <dawn@cygnus.com>
3941
3942 * sysdep.h: Don't define errno in MSVC if error.h is included.
3943
3944 Tue Feb 18 10:04:13 1997 Jeffrey A Law (law@cygnus.com)
3945
3946 * elf32-v850.c (v850_elf_relocate_section): Make sure r_symndx
3947 is initialized before it is used.
3948
3949 Mon Feb 17 11:28:40 1997 Ian Lance Taylor <ian@cygnus.com>
3950
3951 * hp300hpux.c (convert_sym_type): Don't convert a secondary common
3952 symbol into a weak undefined symbol; leave it as a common symbol.
3953
3954 Fri Feb 14 19:08:03 1997 Ian Lance Taylor <ian@cygnus.com>
3955
3956 * elflink.h (elf_link_add_object_symbols): Don't issue a warning
3957 about a symbol defined in a dynamic object if it has already been
3958 defined in a regular object.
3959
3960 Thu Feb 13 20:53:22 1997 Klaus Kaempf (kkaempf@progis.de)
3961
3962 * makefile.vms: Add gcc flags to allow compiling with current gcc
3963 snapshot
3964 (targmatch.h): New dependency.
3965
3966 * reloc.c (BFD_RELOC_ALPHA_CODEADDR): New relocation for
3967 openVMS/Alpha.
3968 * evax.h (ALPHA_R_CODEADDR): New relocation.
3969 * evax-alpha.c (ALPHA_R_CODEADDR): 64 bit procedure relocation for
3970 openVMS/Alpha.
3971 * evax-etir.c (ALPHA_R_CODEADDR): Output object code for this
3972 relocation.
3973 * bfd-in2.h, libbfd.h: Rebuild.
3974
3975 Restrict symbol length to 64 bytes, case preserving:
3976 * evax-emh.c (_bfd_evax_write_emh): Remove case hacking.
3977 * evax-misc.c (_bfd_evax_case_hack_symbol): Remove.
3978 (_bfd_evax_length_hash_symbol): Added.
3979 * evax-etir.c (_bfd_evax_write_etir): Call
3980 _bfd_evax_length_hash_symbol before output of symbol.
3981 * evax-egsd.c (_bfd_evax_write_egsd): Likewise.
3982 * evax.h (flag_hash_long_names, flag_show_after_trunc): Remove.
3983
3984 * evax-emh.c: Output filename to object file without path.
3985
3986 * evax-egsd.c: New sections for local and global commons.
3987
3988 * evax-alpha.c, evax-emh.c, evax-egsd.c, evax-etir.c,
3989 evax-misc.c, evax.h: Remove 8 bit characters from copyright
3990 notices. Replace AXP with Alpha.
3991
3992 Wed Feb 12 18:10:30 1997 Ian Lance Taylor <ian@cygnus.com>
3993
3994 * sunos.c (sunos_create_dynamic_sections): We need the dynamic
3995 sections if we are creating a shared library.
3996
3997 Tue Feb 11 15:45:43 1997 Doug Evans <dje@canuck.cygnus.com>
3998
3999 * configure.host (i386-windows): Don't set host64=true.
4000
4001 Tue Feb 11 15:27:32 1997 Ian Lance Taylor <ian@cygnus.com>
4002
4003 * elf32-mips.c (reloc_type): Add R_MIPS16_GPREL.
4004 (elf_mips16_gprel_howto): New static variable.
4005 (mips16_gprel_reloc): New static function.
4006 (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_GPREL.
4007 (mips_info_to_howto_rel): Handle R_MIPS16_GPREL.
4008 (mips_elf_relocate_section): Handle R_MIPS16_GPREL.
4009 * reloc.c (BFD_RELOC_MIPS16_GPREL): Define.
4010 * bfd-in2.h, libbfd.h: Rebuild.
4011
4012 Mon Feb 10 23:25:00 1997 Doug Evans <dje@seba.cygnus.com>
4013
4014 * elf32-m32r.c (elf_m32r_howto_table): Change partial_inplace to true
4015 for R_M32R_{16,32,24,HI16_ULO,HI16_SLO,LO16}.
4016
4017 start-sanitize-r5900
4018 Fri Feb 7 16:20:17 1997 Gavin Koch <gavin@cygnus.com>
4019
4020 * config.bfd: add r5900
4021
4022 end-sanitize-r5900
4023 Fri Feb 7 12:39:11 1997 Ian Lance Taylor <ian@cygnus.com>
4024
4025 * elflink.h (elf_link_input_bfd): If we've discarded a section,
4026 the output section will be the absolute section; don't print an
4027 assertion message for that case when doing a relocateable link.
4028
4029 Thu Feb 6 16:55:43 1997 Ian Lance Taylor <ian@cygnus.com>
4030
4031 * elf32-mips.c (FN_STUB, CALL_STUB, CALL_FP_STUB): Define.
4032 (struct mips_elf_link_hash_entry): Add new fields fn_stub,
4033 need_fn_sub, call_stub, and call_fp_stub.
4034 (struct mips_elf_link_hash_table): Add field mips16_stubs_seen.
4035 (mips_elf_link_hash_newfunc): Initialize new fields.
4036 (mips_elf_link_hash_table_create): Likewise.
4037 (mips_elf_relocate_section): Redirect relocations to use mips16
4038 stubs when appropriate.
4039 (mips_elf_check_relocs): Attach stub sections to the appropriate
4040 symbol. Set need_fn_stub when appropriate.
4041 (mips_elf_always_size_sections): New static function.
4042 (mips_elf_check_mips16_stubs): New static function.
4043 (elf_backend_always_size_sections): Define.
4044 * elf-bfd.h (struct elf_obj_tdata): Add local_stubs field.
4045
4046 * elflink.h (elf_link_input_bfd): Discard local symbols that are
4047 attached to sections which are not being included in the link.
4048
4049 Wed Feb 5 13:20:17 1997 Ian Lance Taylor <ian@cygnus.com>
4050
4051 * cofflink.c (_bfd_coff_generic_relocate_section): Ignore the
4052 symbol value when computing the addend for a pc_relative
4053 pcrel_offset reloc.
4054
4055 Mon Feb 3 11:54:06 1997 Ian Lance Taylor <ian@cygnus.com>
4056
4057 * cofflink.c (_bfd_coff_generic_relocate_section): If doing a
4058 relocateable link, just skip pc_relative pcrel_offset relocs.
4059 * coff-arm.c (coff_arm_rtype_to_howto): Return a different howto
4060 structure for an ARM26 reloc which can be resolved.
4061 (coff_arm_adjust_symndx): Only convert ARM26 to ARM26D if the
4062 reloc can be resolved.
4063
4064 * coff-h8300.c (h8300_reloc16_extra_cases): Correct off by one
4065 error in overflow check for R_RELBYTE.
4066
4067 Fri Jan 31 14:07:27 1997 Ian Lance Taylor <ian@cygnus.com>
4068
4069 * ieee.c (ieee_slurp_section_data): Pick up the start address.
4070 From Mark Rasin <mark.rasin@telrad.co.il>.
4071
4072 * aoutx.h (aout_link_write_symbols): Don't apply discard_l to
4073 debugging symbols.
4074
4075 Wed Jan 29 00:00:49 1997 Jeffrey A Law (law@cygnus.com)
4076
4077 * elf32-mn10200.c (reloc_type): Add 16bit pc-relative reloc.
4078 (elf_mn10200_howto_table): Likewise.
4079 (mn10200_reloc_map): Likewise.
4080
4081 Mon Jan 27 12:07:35 1997 Doug Evans <dje@seba.cygnus.com>
4082
4083 * reloc.c: Add relocs BFD_RELOC_M32R_{HI16_[US]LO,LO16}.
4084 * bfd-in2.h, libbfd.h: Regenerated.
4085 * elf32-m32r.c: Add support for them.
4086
4087 Mon Jan 27 12:25:02 1997 Ian Lance Taylor <ian@cygnus.com>
4088
4089 * aout-arm.c (MY_swap_std_reloc_in): Remove unused r_length.
4090 * elf32-ppc.c (ppc_elf_check_relocs): Remove unused plt.
4091 * elf32-v850.c (v850_elf_final_link_relocate): Remove used
4092 r_format and r_pcrel. Always return a value.
4093 * riscix.c (MY_final_link_callback): Define to dummy value.
4094
4095 * elf32-i386.c (elf_i386_size_dynamic_sections): When checking for
4096 relocations against the text segment, look up the output name of
4097 the reloc section.
4098 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
4099 * elf32-mips.c (mips_elf_size_dynamic_sections): Likewise.
4100 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
4101 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
4102 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
4103
4104 start-sanitize-tic80
4105 Wed Jan 22 15:40:28 1997 Fred Fish <fnf@cygnus.com>
4106
4107 * coff-tic80.c (tic80coff_vec): Use correct data put/get
4108 routines for little endian data.
4109 * coffcode.h (coff_write_object_contents): Set magic to
4110 TIC80_ARCH_MAGIC for TIc80.
4111
4112 Tue Jan 21 12:32:43 1997 Fred Fish <fnf@cygnus.com>
4113
4114 * coff-tic80.c (tic80coff_vec): Change to little endian data
4115 as the default.
4116
4117 end-sanitize-tic80
4118 Thu Jan 16 17:45:57 1997 Ian Lance Taylor <ian@cygnus.com>
4119
4120 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Change type of
4121 auxiliary_filters parameter to be const char * const *. Accept a
4122 NULL terminated array.
4123 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
4124 (bfd_elf32_size_dynamic_sections): Update declaration.
4125 * bfd-in2.h: Rebuild.
4126
4127 Wed Jan 15 11:21:32 1997 Ian Lance Taylor <ian@cygnus.com>
4128
4129 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Treat a
4130 NOTYPE symbol in a text section as a FUNC symbol.
4131
4132 * coffcode.h (coff_compute_section_file_positions): Force
4133 relocbase to be aligned to COFF_DEFAULT_SECTION_ALIGNMENT_POWER.
4134
4135 Tue Jan 14 08:46:33 1997 Doug Evans <dje@canuck.cygnus.com>
4136
4137 * libaout.h (machine_type): Reserve several values for sparclet.
4138
4139 start-sanitize-tic80
4140 Mon Jan 13 22:39:08 1997 Michael Meissner <meissner@tiktok.cygnus.com>
4141
4142 * config.bfd (tic80-*-*): Don't require 'coff'.
4143
4144 end-sanitize-tic80
4145 Mon Jan 13 19:36:25 1997 Michael Meissner <meissner@tiktok.cygnus.com>
4146
4147 * elf32-v850.c (v850_elf_howto_table): Set the special_function
4148 table to v850_elf_reloc for all non-standard relocations.
4149 (v850_elf_check_relocs): Add check for h being non-null.
4150 (v850_elf_reloc): Add R_V850_ZDA_OFFSET support. Use switch
4151 statement instead of multiple ifs.
4152 (v850_elf_relocate_section): Fix up error message, don't just call
4153 abort.
4154
4155 Mon Jan 6 13:28:35 1997 Jeffrey A Law (law@cygnus.com)
4156
4157 * elf32-mn10200.c (elf_mn10200_howto): Don't ever set partial-inplace.
4158 Use bfd_elf_generic_reloc as special function for all relocs.
4159 (bfd_elf32_mn10200_reloc): Remove unnecessary function.
4160
4161 * elf32-mn10200.c (elf_mn10200_howto): Set pcrel_offset for
4162 24bit pc-relative reloc.
4163
4164 start-sanitize-tic80
4165 Fri Jan 3 16:33:00 1997 Fred Fish <fnf@cygnus.com>
4166
4167 * Makefile.in (coff-tic80.o): Add coffcode.h to dependency list.
4168 * coff-tic80.c (tic80coff_vec): Data byte order is big endian and
4169 header byte order is little endian. Use correct bfd_get and
4170 bfd_put routines for little endian headers.
4171 * coffcode.h (coff_set_arch_mach_hook): Set arch to
4172 bfd_arch_tic80 for TIC80_ARCH_MAGIC number.
4173
4174 end-sanitize-tic80
4175 Fri Jan 3 16:54:08 1997 Jeffrey A Law (law@cygnus.com)
4176
4177 * reloc.c: Add BFD_RELOC_24.
4178 * elf32-mn10200.c (enum reloc_type): Add 24bit and pcrel relocs.
4179 (elf_mn10200_howto, mn10200_reloc_map): Corresponding changes.
4180 * bfd-in2.h, libbfd.h: Rebuilt.
4181
4182 Fri Jan 3 16:58:31 1997 Richard Henderson <rth@tamu.edu>
4183
4184 elf64-alpha multiple .got rewrite:
4185
4186 * elf-bfd.h (struct elf_backend_data): Add always_size_sections entry.
4187 (bfd_elf*_mkobject): Don't define here ...
4188 * elfxx-target.h: ... but rather here. Default always_size_sections
4189 hook to NULL.
4190 * elf.c (elf_mkobject): Rename to bfd_elf_mkobject, since that was
4191 what the #defines in elf-bfd.h transmuted it to anyway.
4192
4193 * section.c: Add SEC_LINKER_CREATED flag.
4194 * bfd-in2.h: Rebuild.
4195 * elf32-i386.c (elf_i386_check_relocs): Add SEC_LINKER_CREATED to
4196 relocation section flags.
4197 (elf_i386_size_dynamic_sections): Use SEC_LINKER_CREATED instead of
4198 SEC_IN_MEMORY to recognize generated bits.
4199 * elf32-m68k.c (elf_m68k_check_relocs, elf_m68k_size_dynamic_sections):
4200 Likewise.
4201 * elf32-mips.c (mips_elf_final_link, mips_elf_create_dynamic_sections,
4202 mips_elf_create_compact_rel_section, mips_elf_create_got_section,
4203 mips_elf_check_relocs, mips_elf_size_dynamic_sections): Likewise.
4204 * elf32-ppc.c (ppc_elf_create_linker_section,
4205 ppc_elf_size_dynamic_sections): Likewise.
4206 * elf32-sparc.c (elf32_sparc_check_relocs,
4207 elf32_sparc_size_dynamic_sections): Likewise.
4208 * elflink.c (_bfd_elf_create_got_section): Add SEC_LINKER_CREATED to
4209 section flags.
4210 (_bfd_elf_create_dynamic_sections): Likewise.
4211 (_bfd_elf_make_linker_section_rela): Likewise.
4212 * elflink.h (elf_link_create_dynamic_sections): Likewise.
4213 (bfd_elf,size_dynamic_sections): Call the always_size_sections hook.
4214 (elf_bfd_final_link): Use SEC_LINKER_CREATED instead of SEC_IN_MEMORY
4215 to identify generated bits.
4216 (elf_link_input_bfd): Likewise.
4217
4218 * elf64-alpha.c: Rewrite everything touching relocations.
4219
4220 Fri Jan 3 11:42:53 1997 Michael Meissner <meissner@tiktok.cygnus.com>
4221
4222 * elf32-v850.c (all functions and static variables): Go through
4223 and regularize names to be of the form v850_elf_<xxx>.
4224 (toplevel): Include <elf/v850.h>.
4225 (enum reloc_type): Move to include/elf/v850.h.
4226 (v850_elf_check_relocs): For common variables, if the variable is
4227 referenced by a R_V850_{SDA,ZDA,TDA} relocation, put the variable
4228 into the appropriate section.
4229 (elf_backend_check_relocs): Define.
4230
4231 Tue Dec 31 15:15:28 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4232
4233 * elf32-v850.c (elf_v850_howto_table): Fix some spacing.
4234
4235 Tue Dec 31 14:44:50 1996 Ian Lance Taylor <ian@cygnus.com>
4236
4237 * config.bfd (mips*el-*-linux*): New target.
4238 (mips*-*-linux*): New target.
4239
4240 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Clean up.
4241 Return a useful value.
4242
4243 * Makefile.in (ALL_CFLAGS): Add -D_GNU_SOURCE.
4244
4245 * configure.in: Check ac_cv_func_mmap_fixed_mapped, not
4246 ac_cv_func_mmap.
4247 * configure: Rebuild.
4248 * configure.host: Use ac_cv_func_mmap_fixed_mapped instead of
4249 ac_cv_func_mmap in bfd/configure.host.
4250
4251 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Add
4252 filter_shlib and auxiliary_filter_shlib parameters.
4253 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_AUXILIARY and
4254 DT_FILTER.
4255 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
4256 (bfd_elf64_size_dynamic_sections): Likewise.
4257 * bfd-in2.h: Rebuild.
4258
4259 Mon Dec 30 18:48:52 1996 Ian Lance Taylor <ian@cygnus.com>
4260
4261 * xcofflink.c (xcoff_build_ldsyms): When exporting all defined
4262 symbols, don't export a symbol which is defined by an object in an
4263 archive which contains shared objects.
4264
4265 start-sanitize-tic80
4266 Mon Dec 30 16:12:58 1996 Fred Fish <fnf@cygnus.com>
4267
4268 * archures.c (enum bfd_architecture): Add bfd_arch_tic80
4269 for TI TMS320c80 (MVP).
4270 (bfd_archures_list): Add bfd_tic80_arch.
4271 * bfd-in2.h: Regenerate by running "make headers".
4272
4273 Sun Dec 29 16:18:52 1996 Fred Fish <fnf@cygnus.com>
4274
4275 * cpu-tic80.c (bfd_tic80_arch): Add struct.
4276 * configure.in (case $vec): Correct typo, "tb" not "tp".
4277 Also add cofflink.o for tic80coff_vec.
4278 * configure: Regenerate with autoconf.
4279
4280 end-sanitize-tic80
4281 Mon Dec 30 11:54:56 1996 Ian Lance Taylor <ian@cygnus.com>
4282
4283 * libbfd.c: Patch up the mmap code so that it is only built if BFD
4284 is configured with --with-mmap.
4285
4286 start-sanitize-tic80
4287 Sun Dec 29 10:48:57 1996 Fred Fish <fnf@cygnus.com>
4288
4289 * Makefile.in (BFD32_BACKENDS): Add coff-tic80.o
4290 (ALL_MACHINES): Add cpu-tic80.o
4291 (cpu-tic80.o, coff-tic80.o): Add dependencies.
4292 * coff-tic80.c: Add skeleton, cloned from another coff config.
4293 * coffcode.h (coff_write_object_contents): Set magic to TIC80MAGIC
4294 for TIc80.
4295
4296 end-sanitize-tic80
4297 Fri Dec 27 20:56:41 1996 Fred Fish <fnf@cygnus.com>
4298
4299 * TODO: Correct a misspelling.
4300 start-sanitize-tic80
4301 * coff-tic80.c: New file for TI TMS320C80 (MVP).
4302 * cpu-tic80.c: New file for TI TMS320C80 (MVP).
4303 * configure.in (case $vec): Add tic80coff_vec entry.
4304 * configure: Regenerate with autoconf.
4305 * archures.c (bfd_tic80_arch): Declare.
4306 * bfd-in2.h (enum bfd_architecture): Add bfd_arch_tic80.
4307 * config.bfd (case ${targ}): Add tic80*-*-coff* target.
4308 * targets.c (tic80coff_vec): Add decl as extern bfd_target.
4309 (bfd_target_vector): Add tic80coff_vec entry.
4310 end-sanitize-tic80
4311
4312 Fri Dec 27 11:48:12 1996 H.J. Lu <hjl@lucon.org>
4313
4314 * elflink.h (elf_buckets): Add some more values for larger
4315 binaries.
4316
4317 Thu Dec 26 18:36:54 1996 Ian Lance Taylor <ian@cygnus.com>
4318
4319 * Makefile.in (install): Move subdir_do out of conditional. From
4320 Fred Fish <fnf@cygnus.com>.
4321
4322 Wed Dec 18 10:04:30 1996 Jeffrey A Law (law@cygnus.com)
4323
4324 * elf32-mn10200.c (enum reloc_type): Enable basic 8, 16, and
4325 32 bit relocs.
4326 (elf_mn10200_howto_table): Likewise.
4327 (mn10200_reloc_map): Likewise.
4328
4329 Tue Dec 17 11:09:36 1996 Ian Lance Taylor <ian@cygnus.com>
4330
4331 * elf32-mips.c (mips_elf_add_symbol_hook): Add 1 to the value of a
4332 mips16 symbol during the link.
4333 (mips_elf_finish_dynamic_symbol): Subtract 1 from the value of a
4334 mips16 symbol.
4335 (mips_elf_link_output_symbol_hook): New static function.
4336 (elf_backend_link_output_symbol_hook): Define.
4337
4338 * elf.c (bfd_elf_print_symbol): Print the st_other field if it is
4339 not zero.
4340
4341 Mon Dec 16 14:38:39 1996 Ian Lance Taylor <ian@cygnus.com>
4342
4343 * elf.c (bfd_section_from_shdr): Don't check for reloc sections
4344 against SEC_DEBUGGING sections here (revert patch of December 5).
4345 * elfcode.h (elf_object_p): Check for them here, instead.
4346
4347 Sun Dec 15 14:46:06 1996 Ian Lance Taylor <ian@cygnus.com>
4348
4349 * elfcode.h (elf_slurp_reloc_table): Add dynamic parameter.
4350 * elf.c (_bfd_elf_canonicalize_reloc): Pass new argument to
4351 slurp_reloc_table.
4352 (_bfd_elf_get_dynamic_reloc_upper_bound): New function.
4353 (_bfd_elf_canonicalize_dynamic_reloc): New function.
4354 * elf-bfd.h (struct elf_size_info): Update declaration of
4355 slurp_reloc_table.
4356 (_bfd_elf_get_dynamic_reloc_upper_bound): Declare.
4357 (_bfd_elf_canonicalize_dynamic_reloc): Declare.
4358 * elfxx-target.h: Use new dynamic reloc routines by default.
4359 * elf64-mips.c (mips_elf64_slurp_reloc_table): Add dynamic
4360 parameter.
4361
4362 Fri Dec 13 13:18:49 1996 Dan Wilder <dan@gasboy.com>
4363
4364 * coffcode.h (coff_set_flags): Use MC68KBCSMAGIC for bfd_arch_m68k
4365 if NAMES_HAVE_UNDERSCORE is defined.
4366
4367 Fri Dec 13 11:13:23 1996 Doug Evans <dje@canuck.cygnus.com>
4368
4369 * libaout.h (enum machine_type): Change M_SPARCLET from 142 to 131.
4370
4371 Thu Dec 12 15:07:20 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4372
4373 * elf32-ppc.c (ppc_elf_check_relocs): Move R_PPC_PLTREL24 into the
4374 supported relocs.
4375
4376 Thu Dec 12 14:55:41 1996 Ian Lance Taylor <ian@cygnus.com>
4377
4378 * elflink.h (elf_link_add_object_symbols): Only add a weak
4379 symbol if the real definition is in the dynamic symbol table.
4380 After finding the real definition, then, if it is dynamic, add the
4381 weak symbol to the dynamic symbol table.
4382
4383 * coff-aux.c (coff_m68k_aux_link_add_one_symbol): Make static.
4384
4385 * ppcboot.c (ppcboot_set_arch_mach): Don't define; it's a
4386 function.
4387 (ppcboot_bfd_print_private_bfd_data): Don't take the address of an
4388 array.
4389
4390 Tue Dec 10 23:23:52 1996 Jeffrey A Law (law@cygnus.com)
4391
4392 * elf32-mn10300.c (reloc_type): Remove big endian mn10300 reloc
4393 variants.
4394 (elf32_mn10300_howto_table, mn10300_reloc_map): Likewise.
4395 (bfd_elf32_mn10300_reloc): Write data in little endian format.
4396 * reloc.c: Remove mn10300 big endian relocs.
4397 * bfd-in2.h, libbfd.h: Rebuilt.
4398
4399 * elf32-mn10200.c: Update from elf32-mn10300.c.
4400
4401 Fri Dec 6 15:18:05 1996 Jeffrey A Law (law@cygnus.com)
4402
4403 * elf32-mn10300.c (elf_symbol_leading_char): Define.
4404
4405 * elf32-mn10300.c: Add some comments.
4406
4407 Fri Dec 6 17:16:43 1996 Ian Lance Taylor <ian@cygnus.com>
4408
4409 * ihex.c (ihex_scan): Always initialize buf before jumping to
4410 error_return.
4411 (ihex_read_section): Likewise.
4412
4413 Thu Dec 5 22:29:18 1996 Jeffrey A Law (law@cygnus.com)
4414
4415 * elf32-mn10300.c (elf_mn10300_howto_table): Don't set partial-
4416 inplace for most relocs.
4417
4418 Thu Dec 5 13:24:46 1996 Ian Lance Taylor <ian@cygnus.com>
4419
4420 * elflink.h (elf_link_add_object_symbols): Calling check_relocs
4421 even if SEC_ALLOC is not set.
4422 * elf32-i386.c (elf_i386_check_relocs): Don't check SEC_ALLOC
4423 when deciding whether to copy a reloc into a shared object.
4424 (elf_i386_relocate_section): Likewise.
4425 * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
4426 (elf32_sparc_relocate_section): Likewise.
4427 * elf32-i386.c (elf_i386_check_relocs): Don't set SEC_ALLOC in a
4428 reloc section if it is not set in the source section.
4429 * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
4430 * elf.c (bfd_section_from_shdr): Mark a reloc section associated
4431 with a SEC_DEBUGGING section as SEC_DEBUGGING.
4432
4433 Wed Dec 4 14:18:13 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4434
4435 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): #if 0 code that
4436 expects a .got.plt until we actually create it.
4437
4438 Mon Dec 2 12:13:51 1996 Ian Lance Taylor <ian@cygnus.com>
4439
4440 * cofflink.c (_bfd_coff_generic_relocate_section): Print an error
4441 message for bfd_reloc_outofrange, rather than aborting. From
4442 Philippe De Muyter <phdm@info.ucl.ac.be>.
4443
4444 * cofflink.c (_bfd_coff_final_link): If there aren't any relocs in
4445 a relocateable link, don't try to process them. From Heinz Wrobel
4446 <wrobel@lpr.e-technik.tu-muenchen.de>.
4447
4448 Mon Dec 2 00:39:24 1996 Jeffrey A Law (law@cygnus.com)
4449
4450 * elf32-mn10300.c (mn10300_info_howto): Renamed from
4451 mn10300_info_howto_rel. Tweak reloc argument to be an
4452 Elf32_Internal_Rela.
4453 (USE_RELA): Define instead of USE_REL.
4454 (elf_info_to_howto, elf_info_howto_rel): Corresponding changes.
4455
4456 Sun Dec 1 00:18:59 1996 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
4457
4458 * configure.in, configure: Handle mips*-sgi-irix6*.
4459 * irix-core.c (irix_core_core_file_p): Accept CORE_MAGICN32
4460 core files.
4461
4462 Wed Nov 27 12:10:25 1996 Ian Lance Taylor <ian@cygnus.com>
4463
4464 * elf32-i386.c (elf_i386_relocate_section): Warn about a
4465 relocation against a symbol defined in a section with no output
4466 section.
4467
4468 Tue Nov 26 11:07:31 1996 Ian Lance Taylor <ian@cygnus.com>
4469
4470 * aclocal.m4 (BFD_CC_FOR_BUILD): Don't require AC_C_CROSS.
4471 * configure, config.in: Rebuild with autoconf 2.12.
4472
4473 * elf-bfd.h (struct elf_link_hash_entry): Add other field.
4474 * elf.c (_bfd_elf_link_hash_newfunc): Initialize other field.
4475 (swap_out_syms): Set st_other from existing st_other field.
4476 * elflink.h (elf_link_add_object_symbols): Store st_other in hash
4477 table other field.
4478 (elf_link_output_extsym): Set the other field from the global hash
4479 table entry.
4480 * elf32-mips.c (enum reloc_type): Add R_MIPS16_26.
4481 (elf_mips16_jump_howto): New static variable.
4482 (mips16_jump_reloc): New static function.
4483 (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_JMP.
4484 (mips_info_to_howto_rel): Handle R_MIPS16_26.
4485 (mips_elf_relocate_section): Handle R_MIPS16_26. Handle R_MIPS_26
4486 to a mips16 symbol.
4487 * reloc.c (BFD_RELOC_MIPS16_JMP): Add to list of relocs.
4488 * bfd-in2.h, libbfd.h: Rebuild.
4489 * cpu-mips.c (arch_info_struct): Add mips:16 entry.
4490
4491 Mon Nov 25 11:23:32 1996 Ian Lance Taylor <ian@cygnus.com>
4492
4493 * configure.host: Use long long for mips-sgi-irix6*.
4494
4495 * coffswap.h (coff_swap_scnhdr_out): Make line number overflow
4496 only a warning. From Philippe De Muyter <phdemuyt@ulb.ac.be>.
4497
4498 Mon Nov 25 08:52:29 1996 Jeffrey A Law (law@cygnus.com)
4499
4500 * elf32-mn10300.c (bfd_elf32_mn10300_reloc): New function.
4501 (enum reloc_type): Add more reloc types.
4502 (elf32_mn10300_howto_table): Update for new reloc types.
4503 (elf32_mn10300_reloc_map): Update for new reloc types.
4504 * reloc.c: Add some new relocs for the mn10300 series.
4505 * bfd-in2.h, libbfd.h: Rebuilt.
4506
4507 Sat Nov 23 13:26:18 1996 Jeffrey A Law (law@cygnus.com)
4508
4509 * som.c (setup_sections): Don't lose for a space which has
4510 no data, but some symbols.
4511
4512 Fri Nov 22 11:32:13 1996 Ian Lance Taylor <ian@cygnus.com>
4513
4514 * sunos.c (struct sunos_link_hash_table): Add got_needed field.
4515 (sunos_link_hash_table_create): Initialize got_needed.
4516 (sunos_create_dynamic_sections): Only set .got section size if it
4517 is not already set. Set got_needed.
4518 (bfd_sunos_size_dynamic_sections): Check got_needed. Only set
4519 sdynptr, and only handle dynamic sections, if dynamic sections are
4520 needed.
4521 (sunos_scan_std_relocs): Pass false to create_dynamic_sections.
4522 Initialize .got section.
4523 (sunos_scan_ext_relocs): Likewise.
4524 (sunos_write_dynamic_symbol): Set up PLT entry even if this is not
4525 a dynamic symbol.
4526 (sunos_finish_dynamic_link): Check got_needed. Only set up
4527 dynamic linking information if needed.
4528
4529 Thu Nov 21 10:31:31 1996 Rob Savoye (rob@cygnus.com)
4530
4531 * config.bfd: Added VersaDOS format to the Ericsson configuration.
4532
4533 Wed Nov 20 16:31:31 1996 Jeffrey A Law (law@cygnus.com)
4534
4535 * elf32-mn10300.c: Rough cut at relocs for the mn10300.
4536
4537 Wed Nov 13 08:12:38 1996 Jeffrey A Law (law@cygnus.com)
4538
4539 * Makefile.in (elf32-d10v.o): Don't depend on elf/d10v.h
4540 anymore.
4541
4542 Tue Nov 12 13:30:00 1996 Dawn Perchik <dawn@cygnus.com>
4543
4544 * filemode.c: Include sysdep.h.
4545 * ihex.c: Add casts to eliminate compiler warnings.
4546 * sunos.c: Add casts to eliminate compiler warnings.
4547
4548 Mon Nov 11 10:37:02 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4549
4550 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Create .got.plt
4551 section.
4552 (ppc_elf_check_relocs): Add support for R_PPC_LOCAL24PC. Make
4553 appropriate relocations in the .so file if shared.
4554 (ppc_elf_relocate_section): Ditto.
4555
4556 Tue Oct 29 15:03:02 1996 Doug Evans <dje@canuck.cygnus.com>
4557
4558 * elf32-m32r.c (elf_m32r_howto_table, R_M32R_24): Use
4559 complain_overflow_unsigned.
4560
4561 Tue Oct 29 12:53:46 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
4562
4563 * elf32-d10v.c (elf_d10v_howto_table): Don't complain on
4564 overflows for R_D10V_16 and R_D10V_18.
4565
4566 Tue Oct 29 13:23:53 1996 Ian Lance Taylor <ian@cygnus.com>
4567
4568 * ieee.c (ieee_write_section_part): Use LMA rather than VMA.
4569 (do_with_relocs): Likewise.
4570 (do_as_repeat): Likewise.
4571 (copy_expression): Likewise.
4572
4573 Fri Oct 25 16:56:40 1996 Ian Lance Taylor <ian@cygnus.com>
4574
4575 * ieee.c (ieee_write_external_part): Correctly record whether
4576 there is an external part.
4577
4578 Thu Oct 24 14:32:52 1996 Jeffrey A Law (law@cygnus.com)
4579
4580 * elf32-v850.c (elf32_v850_bfd_final_link_relocate): Correctly
4581 handle tda offsets for sld.w and sst.w instructions.
4582 Fix alignment check in sld.w and sst.w tda reloc handling.
4583
4584 Thu Oct 24 09:08:47 1996 Stu Grossman (grossman@critters.cygnus.com)
4585
4586 * aclocal.m4, configure: Set USE_BINARY_FOPEN for *-*-windows.
4587
4588 Wed Oct 23 00:53:16 1996 Jeffrey A Law (law@cygnus.com)
4589
4590 * elf32-v850.c: Add comments about assumptions about
4591 char, short & long sizes.
4592 (elf32_v850_bfd_final_link_relocate): Fix sign extension
4593 problems for several relocs.
4594
4595 * elf32-v850.c (elf32_v850_howto_table): Fix typo in
4596 R_V850_SDA_OFFSET entry.
4597
4598 Wed Oct 23 00:20:34 1996 Ian Lance Taylor <ian@cygnus.com>
4599
4600 * xcofflink.c (bfd_xcoff_import_symbol): Don't allocate ldsym.
4601 Store import file index in ldindx.
4602 (xcoff_build_ldsyms): Assume that ldsym was not previously
4603 allocated. For an imported symbol, copy ldindx into l_ifile.
4604
4605 Tue Oct 22 19:20:38 1996 Jeffrey A Law (law@cygnus.com)
4606
4607 * elf32-v850.c (elf_v850_howto_table): Fix ordering of
4608 R_V850_ZDA_OFFSET and R_V850_TDA_OFFSET. Fix various
4609 fields in R_V850_TDA_OFFSET.
4610 (elf32_v850_bfd_final_link_relocate): Tweak pc-relative
4611 relocs to work more like other relocs. Handle R_V850_TDA_OFFSET
4612 relocations.
4613
4614 * elf32-v850.c: Include bfdlink.h.
4615 (bfd_elf32_v850_reloc): Return an error if we get a reloc
4616 we can't handle.
4617 (elf32_v850_bfd_final_link_relocate): New function.
4618 (v850_elf_relocation_section): Likewise.
4619 (elf_backend_relocate_section): Define.
4620
4621 Tue Oct 22 17:22:43 1996 Ian Lance Taylor <ian@cygnus.com>
4622
4623 * binary.c (binary_set_section_contents): Ignore sections which
4624 don't have SEC_LOAD and SEC_ALLOC set.
4625
4626 Mon Oct 21 12:13:05 1996 Jeffrey A Law (law@cygnus.com)
4627
4628 * linker.c (_bfd_generic_final_link): Avoid losing static
4629 symbols in the .bss section.
4630
4631 Mon Oct 21 10:54:58 1996 Ian Lance Taylor <ian@cygnus.com>
4632
4633 * elf32-mips.c (elf_mips_howto_table): Describe R_MIPS_64.
4634 (mips32_64bit_reloc): New static function.
4635 (mips_reloc_map): Add entry for BFD_RELOC_64.
4636 (mips_elf_relocate_section): Handle R_MIPS_64.
4637
4638 * linker.c (default_indirect_link_order): Print an error message
4639 when attempting to do a relocateable link with different object
4640 file formats, rather than calling abort.
4641
4642 Thu Oct 17 10:43:29 1996 Doug Evans <dje@canuck.cygnus.com>
4643
4644 * reloc.c (m32r relocs): Rename them.
4645 * bfd-in2.h, libbfd.h: Regenerated.
4646 * elf32-m32r.c: Update.
4647 (m32r_elf_10_pcrel_reloc): New function.
4648 (elf_m32r_howto_table, R_M32R_10_PCREL entry): Use it.
4649 (elf_m32r_howto_table, R_M32R_24 entry): Fix {src,dst}_masks.
4650
4651 Wed Oct 16 11:24:35 1996 Jeffrey A Law (law@cygnus.com)
4652
4653 * linker.c (_bfd_generic_final_link): Set "linker_mark" for
4654 all sections that will be included in the output file.
4655 (_bfd_generic_link_output_symbols): Discard symbols in sections
4656 which are being discarded.
4657 * elf32-v850.c (enum reloc_type): Add R_V850_SDA_OFFSET,
4658 R_V850_TDA_OFFSET and R_V850_ZDA_OFFSET.
4659 (elf_v850_howto_table): Corresponding changes.
4660 (elf_v850_reloc_map): Corresponding changes.
4661 * reloc.c: Add additional V850 relocations.
4662 * bfd-in2.h, libbfd.h: Rebuilt.
4663
4664 * elf32-v850.c (bfd_elf32_v850_reloc): Mask out bits we
4665 no longer want in pc-relative relocs.
4666
4667 Tue Oct 15 22:17:37 1996 Jeffrey A Law (law@cygnus.com)
4668
4669 * elf32-v850.c (bfd_elf32_v850_reloc): Don't silently
4670 accept a reloc against an undefined sybmol!
4671
4672 Tue Oct 15 16:17:28 1996 Stu Grossman (grossman@critters.cygnus.com)
4673
4674 * elf32-v850.c: Define elf_symbol_leading_char to be '_'.
4675
4676 Tue Oct 15 12:40:41 1996 Ian Lance Taylor <ian@cygnus.com>
4677
4678 * VERSION: Bump for new relocation.
4679
4680 * hosts/i386bsd.h: If NBPG is not defined, define it as
4681 PAGE_SIZE, for recent versions of FreeBSD.
4682
4683 Mon Oct 14 12:37:26 1996 Ian Lance Taylor <ian@cygnus.com>
4684
4685 * configure.host: Use `long long' as the 64 bit type on a Solaris
4686 host, since both gcc and the SunPRO compilers support it.
4687
4688 Mon Oct 14 11:17:24 1996 Richard Henderson <rth@tamu.edu>
4689
4690 * reloc.c: Create a new BFD_RELOC_ALPHA_ELF_LITERAL. It was a
4691 mistake to have reused the ECOFF LITERAL for ELF since they have
4692 different semantics.
4693 * elf64-alpha.c (elf_reloc_map): Map from ELF_LITERAL.
4694 * bfd-in2.h, libbfd.h: Rebuild.
4695
4696 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Trap .got
4697 section overflow.
4698
4699 * elf64-alpha.c (elf64_alpha_relocate_section): Do not emit a
4700 dynamic relocation for an undefweak symbol when we are building
4701 a static executable.
4702
4703 Thu Oct 10 11:15:06 1996 Stan Shebs <shebs@andros.cygnus.com>
4704
4705 * mpw-make.sed (config.bfd, targmatch.sed): Edit references to
4706 point explicitly to srcdir.
4707 (targmatch.h): Edit references to point explicitly to objdir.
4708
4709 Thu Oct 10 14:14:23 1996 Ian Lance Taylor <ian@cygnus.com>
4710
4711 * config.bfd: When setting targ_cpu, don't get confused by
4712 linux-gnu.
4713
4714 Tue Oct 8 08:51:19 1996 Stu Grossman (grossman@critters.cygnus.com)
4715
4716 * configure.host: Add support for windows host (a build done
4717 under the Microsoft build environment).
4718
4719 Tue Oct 8 11:40:16 1996 Ian Lance Taylor <ian@cygnus.com>
4720
4721 * elflink.h (elf_link_add_object_symbols): If a symbol is a weak
4722 definition in a dynamic object, add it to the dynamic symbol table
4723 if any dynamic object mentions it. Reverts part of last patch.
4724
4725 * sunos.c (struct sunos_link_hash_table): Add got_base field.
4726 (sunos_link_hash_table_create): Initialize got_base.
4727 (bfd_sunos_size_dynamic_sections): If the .got section is more
4728 than 0x1000 bytes, set __GLOBAL_OFFSET_TABLE_ and got_base to
4729 0x1000.
4730 (sunos_check_dynamic_reloc): Subtract got_base from a base
4731 relative relocation.
4732
4733 * elf32-mips.c (elf_mips_isa): New static function.
4734 (_bfd_mips_elf_merge_private_bfd_data): Don't warn about linking
4735 -mips1 and -mips2 code together, or -mips3 and -mips4 code.
4736
4737 Mon Oct 7 11:44:17 1996 Ian Lance Taylor <ian@cygnus.com>
4738
4739 * archive.c (do_slurp_coff_armap): Only treat archive as little
4740 endian for i960 COFF.
4741
4742 Fri Oct 4 13:49:01 1996 Ian Lance Taylor <ian@cygnus.com>
4743
4744 * coffcode.h (coff_compute_section_file_positions): Adjust sofar
4745 by the change in size of the section when EXEC_P is not set.
4746
4747 * coff-m68k.c (coff_rtype_to_howto): Define if not defined.
4748 (m68kcoff_rtype_to_howto): New static function.
4749 * cf-m68klynx.c (coff_m68k_lynx_rtype_to_howto): Add the section
4750 VMA to the addend for a PC relative reloc.
4751
4752 * dep-in.sed: Rework backslash loop a bit to avoid bug in sed on
4753 HP/UX 10.20.
4754 * Makefile.in: Rebuild dependencies.
4755
4756 * dep-in.sed: Remove ../bfd/sysdep.h, since it will appear when
4757 som.h is included.
4758
4759 Fri Oct 4 11:41:39 1996 Jeffrey A Law (law@cygnus.com)
4760
4761 * Makefile.in: Remove explicit dependencies for mn10200 and
4762 mn10300 files.
4763 (ALL_MACHINE_CFILES): Add cpu-mn10200.c and cpu-mn10300.c.
4764 (BFD32_BACKENDS_CFILES): Add elf32-mn10200.c and elf32-mn10300.c
4765 (dependencies): Rebuilt.
4766
4767 Thu Oct 3 16:57:51 1996 Ian Lance Taylor <ian@cygnus.com>
4768
4769 * cofflink.c (coff_link_add_symbols): Set obj_coff_keep_syms
4770 during this function.
4771
4772 * elflink.c (_bfd_elf_create_linker_section): Only use an existing
4773 section if the flags are compatible.
4774
4775 * configure.in: Add havevecs, and put it in tdefaults.
4776 * mpw-config.in: Likewise.
4777 * configure: Rebuild.
4778 * targmatch.sed: New file; a sed script to build targmatch.h from
4779 config.bfd.
4780 * config.bfd: Add #if, #endif, and comments for targmatch.h.
4781 * targets.c: Include "fnmatch.h".
4782 (struct targmatch): Define.
4783 (bfd_target_match): Define by including targmatch.h.
4784 (bfd_find_target): If the target is not found by name, search for
4785 it as a configuration triplet.
4786 * Makefile.in: Rebuild dependencies.
4787 (BFD32_BACKENDS): Add aout-arm.o, aout-sparcle.o, hp300bsd.o,
4788 i386dynix.o, m68k4knetbsd.o, and riscix.o.
4789 (BFD32_BACKENDS_CFILES): Add aout-arm.c, aout-sparcle.c,
4790 hp300bsd.c, i386dynix.c, m68k4knetbsd.c, and riscix.c.
4791 (HFILES): Add targmatch.h. Also, alphabetize and reindent.
4792 (CFILES): Remove i386dynix.c and hp300bsd.c.
4793 (targmatch.h): New target.
4794 (do_clean): Remove targmatch.h.
4795
4796 * configure.in: Add BFD_NEED_DECLARATION(getenv).
4797 * acconfig.h: Add NEED_DECLARATION_GETENV.
4798 * configure, config.in: Rebuild.
4799 * sysdep.h: If NEED_DECLARATION_GETENV, declare getenv.
4800 * aout-adobe.c (aout_adobe_object_p): Don't declare getenv.
4801
4802 Thu Oct 3 09:29:09 1996 Jeffrey A Law (law@cygnus.com)
4803
4804 * cpu-mn10x00.c, elf32-mn10x00: Removed.
4805 * cpu-mn10200.c, cpu-mn10300.c: New files.
4806 * elf32-mn10200.c, elf32-mn10300.c: New files.
4807 * Makefile.in: Break mn10x00 support into two separate
4808 configurations, mn10200 and mn10300.
4809 * archures.c, config.bfd, configure.in, elf.c, targets.c: Likewise.
4810 * bfd-in2.h, configure: Rebuilt.
4811
4812 Thu Oct 3 15:38:19 1996 Jason Molenda (crash@godzilla.cygnus.co.jp)
4813
4814 * Makefile.in (do_clean): Move config.log to do_distclean.
4815
4816 Wed Oct 2 21:40:55 1996 Jeffrey A Law (law@cygnus.com)
4817
4818 * cpu-mn10x00.c, elf32-mn10x00.c: New files.
4819 * Makefile.in (ALL_MACHINES): Add cpu-mn10x00.o.
4820 (BFD32_BACKENDS): Similarly for elf32-mn10x00.o.
4821 (elf32-mn10x00.o): Add dependencies.
4822 * archures.c (enum bfd_architecture): Add bfd_arch_mn10x00.
4823 (bfd_mn10x00_arch): Declare.
4824 (bfd_archures_list): Add bfd_mn10x00_arch.
4825 * config.bfd: Add mn10x00-*-*.
4826 * configure.in: Add bfd_elf32_mn10x00_vec.
4827 * elf.c (prep_headers): Handle bfd_arch_mn10x00.
4828 * targets.c (bfd_elf32_mn10x00_vec): Declare.
4829 (bfd_target_vector): Add bfd_elf32_mn10x00_vec.
4830 * bfd-in2.h, configure: Rebuilt.
4831
4832 Wed Oct 2 15:46:45 1996 Klaus Kaempf <kkaempf@progis.de>
4833
4834 openVMS/Alpha: Provide filename and case_hack flags via
4835 symbol table from gas.
4836 Add case_hack code for symbol output from vax/vms.
4837 * evax-alpha.c (evax_initialize): Remove filename handling,
4838 filename is provided via symbol table.
4839 (evax_get_symtab): Use local symbol count when setting up table.
4840 * evax-egsd.c (_bfd_evax_slurp_egsd): Print correct name when
4841 debugging.
4842 (_bfd_evax_write_egsd): Skip file name symbol.
4843 * evax-emh.c (get_vms_time_string): Local function now.
4844 (_bfd_evax_write_emh): Extract source filename and case_hack flags
4845 from symbol table.
4846 * evax_write_etir (_bfd_evax_write_etir): Pass all symbol names
4847 through _bfd_evax_case_hack_symbol.
4848 * evax-misc.c (hash_string, _bfd_evax_case_hack_symbol): New
4849 functions.
4850 (_bfd_evax_basename): Removed.
4851 (_bfd_get_vms_time_string): Moved to evax-emh.c.
4852 * evax.h (evax_private_data_struct): Remove filename.
4853 (flag_hash_long_names, flag_show_after_trunc,
4854 flag_no_hash_mixed_case, vms_name_mapping): New flags for
4855 vms_case_hack.
4856
4857 Wed Oct 2 12:02:02 1996 Ian Lance Taylor <ian@cygnus.com>
4858
4859 * freebsd.h (N_GET_MAGIC_NET): Don't use ntohl.
4860 (N_GETMID_NET, N_GETFLAG_NET): Likewise.
4861 (NO_SWAP_MAGIC): Don't define.
4862 (SWAP_MAGIC): Define.
4863
4864 * cofflink.c (_bfd_coff_link_input_bfd): Don't crash if there is
4865 no hash table entry for a global symbol.
4866
4867 Tue Oct 1 16:14:22 1996 Joel Sherrill <joel@oarcorp.com>
4868
4869 * config.bfd (mips*-*-rtems*): New target, like mips*-*-elf*.
4870
4871 Tue Oct 1 12:31:39 1996 Ian Lance Taylor <ian@cygnus.com>
4872
4873 * cofflink.c (coff_link_add_symbols): Don't override a meaningful
4874 symbol type with T_NULL. Warn if symbol type changes. Based on
4875 patch from Philippe De Muyter <phdm@info.ucl.ac.be>.
4876
4877 * elflink.h (elf_link_add_object_symbols): Only put a symbol from
4878 a dynamic object in the dynamic symbol table if it is referenced
4879 or defined by a regular object.
4880
4881 Fri Sep 27 18:41:07 1996 Stu Grossman (grossman@critters.cygnus.com)
4882
4883 * elf32-v850.c (bfd_elf32_v850_is_local_label): New function to
4884 remove dwarf local labels. Shrinks binaries by a factor of 3!
4885
4886 Mon Sep 23 13:33:00 1996 Ian Lance Taylor <ian@cygnus.com>
4887
4888 * elf32-ppc.c (ppc_elf_add_symbol_hook): Create the .sbss section
4889 by hand, rather than by calling bfd_make_section.
4890
4891 Mon Sep 23 09:23:41 1996 Doug Evans <dje@seba.cygnus.com>
4892
4893 * reloc.c: Rename m32r relocs.
4894 * bfd-in2.h, libbfd.h: Rebuilt.
4895 * elf32-m32r.c: Update.
4896
4897 Fri Sep 20 11:43:43 1996 Ian Lance Taylor <ian@cygnus.com>
4898
4899 * aoutx.h (aout_link_input_section_ext): When doing a relocateable
4900 link, adjust the symbol index of a base relative reloc. Don't
4901 change the addend of a PC relative reloc if pcrel_offset is set.
4902 * sunos.c (bfd_sunos_size_dynamic_sections): Don't do anything for
4903 a relocateable link.
4904
4905 * reloc.c (bfd_perform_relocation): Apply the relocation even if
4906 it is zero, in case src_mask matters.
4907 (bfd_install_relocation): Likewise.
4908
4909 Thu Sep 19 11:03:06 1996 Ian Lance Taylor <ian@cygnus.com>
4910
4911 * xcofflink.c (xcoff_link_add_symbols): Always initialize
4912 keep_syms.
4913 (_bfd_xcoff_bfd_final_link): Don't set target_index
4914 to an uninitialized value.
4915
4916 Tue Sep 17 14:18:31 1996 Ian Lance Taylor <ian@cygnus.com>
4917
4918 * coffcode.h (coff_slurp_line_table): Warn about illegal symbol
4919 indices, rather than crashing.
4920 (coff_slurp_reloc_table): Likewise. Check whether the howto field
4921 is NULL.
4922 * coff-sh.c (sh_relocate_section): Check for an illegal symbol
4923 index.
4924
4925 Mon Sep 16 12:39:36 1996 Ian Lance Taylor <ian@cygnus.com>
4926
4927 * coff-arm.c (aoutarm_std_reloc_howto): Change dst_mask for ARM26D
4928 reloc to 0.
4929 (coff_arm_adjust_symndx): New static function.
4930 (coff_adjust_symndx): Define.
4931
4932 * srec.c (srec_scan): Accept multiple symbols on a single line.
4933 From Pascal Martin <pmartin@alsys.com>.
4934
4935 * README: New file.
4936
4937 Fri Sep 13 14:32:42 1996 Doug Evans <dje@canuck.cygnus.com>
4938
4939 * aoutf1.h (MY_bfd_merge_private_bfd_data): Define.
4940 (sunos_merge_private_bfd_data): New function.
4941
4942 Fri Sep 13 15:50:57 1996 Ian Lance Taylor <ian@cygnus.com>
4943
4944 * bfd.c (bfd_copy_private_bfd_data): Switch on output BFD rather
4945 than input BFD.
4946 (bfd_merge_private_bfd_data): Likewise.
4947 * section.c (bfd_copy_private_section_data): Likewise.
4948 * syms.c (bfd_copy_private_symbol_data): Likewise.
4949 * bfd-in2.h: Rebuild.
4950 * aout-target.h (MY_bfd_copy_private_section_data): Check that
4951 both BFD's are the right flavour.
4952 * ecoff.c (_bfd_ecoff_bfd_copy_private_bfd_data): Likewise.
4953 * elf.c (_bfd_elf_copy_private_symbol_data): Likewise.
4954 * elf32-mips.c (_bfd_mips_elf_copy_private_bfd_data): Likewise.
4955 (_bfd_mips_elf_merge_private_bfd_data): Likewise.
4956 * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Likewise.
4957 (ppc_elf_merge_private_bfd_data): Likewise.
4958 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Likewise.
4959 * peicode.h (pe_bfd_copy_private_section_data): Likewise.
4960
4961 * elf32-hppa.c (elf_hppa_howto_table): Fill in some fields for
4962 R_PARISC_DIR32, so that _bfd_stab_section_find_nearest_line passes
4963 its sanity check.
4964
4965 Thu Sep 12 11:45:57 1996 Doug Evans <dje@seba.cygnus.com>
4966
4967 * reloc.c: Add m32r relocs.
4968 * bfd-in2.h, libbfd.h: Rebuilt.
4969 * cpu-m32r.c,elf32-m32r.c: New files.
4970
4971 Thu Sep 12 11:10:05 1996 Ian Lance Taylor <ian@cygnus.com>
4972
4973 * ieee.c (ieee_vec): Set symbol_leading_char field to '_'.
4974
4975 Wed Sep 11 11:57:56 1996 Ian Lance Taylor <ian@cygnus.com>
4976
4977 * tekhex.c (first_phase): Change type parameter from char to int.
4978 (out): Likewise.
4979 (pass_over): Change func to expect int, not char.
4980
4981 * elf.c (assign_file_positions_for_segments): Test SEC_ALLOC
4982 rather than SEC_LOAD when aligning the file offset for the first
4983 section in a segment.
4984
4985 Tue Sep 10 16:18:30 1996 Fred Fish <fnf@cygnus.com>
4986
4987 * syms.c (coff_section_type): Make arg const.
4988 * irix-core.c (irix_core_core_file_p): Remove extraneous extra arg
4989 to make_bfd_asection().
4990 * elf-bfd.h (bfd_section_from_phdr): Add prototype.
4991 * elfcode.h (bfd_section_from_phdr): Remove prototype.
4992 (_bfd_elf_stringtab_init): Remove prototype.
4993
4994 * netbsd-core.c (swap_abort): Add prototype.
4995 * aix386-core.c (swap_abort): Ditto & make static
4996 * hpux-core.c (swap_abort): Ditto & make static.
4997 * irix-core.c (swap_abort): Ditto & make static.
4998 * ptrace-core.c (swap_abort): Ditto & make static.
4999 * trad-core.c (swap_abort): Ditto & make static.
5000 * coffswap.h (coff_swap_reloc_in): Ditto.
5001 (coff_swap_reloc_out): Ditto.
5002 (coff_swap_filehdr_in): Ditto.
5003 (coff_swap_filehdr_out): Ditto.
5004 (coff_swap_sym_in): Ditto.
5005 (coff_swap_sym_out): Ditto.
5006 (coff_swap_aux_in): Ditto.
5007 (coff_swap_aux_out): Ditto.
5008 (coff_swap_lineno_in): Ditto.
5009 (coff_swap_lineno_out): Ditto.
5010 (coff_swap_aouthdr_in): Ditto.
5011 (coff_swap_aouthdr_out): Ditto.
5012 (coff_swap_scnhdr_in): Ditto.
5013 (coff_swap_scnhdr_out): Ditto.
5014 * ihex.c (ihex_sizeof_headers): Ditto.
5015 * tekhex.c (getsym): Ditto.
5016 (find_chunk): Ditto & make static.
5017 (insert_byte): Ditto.
5018 (first_phase): Ditto.
5019 (pass_over): Ditto.
5020 (tekhex_get_symtab): Ditto & make static.
5021 (tekhex_get_symtab_upper_bound): Ditto & make static.
5022 (tekhex_mkobject): Ditto.
5023 (tekhex_object_p): Ditto.
5024 (move_section_contents): Ditto.
5025 (tekhex_get_section_contents): Ditto.
5026 (tekhex_set_arch_mach): Ditto & make static.
5027 (tekhex_set_section_contents): Ditto.
5028 (writevalue): Ditto.
5029 (writesym): Ditto.
5030 (out): Ditto.
5031 (tekhex_write_object_contents): Ditto.
5032 (tekhex_sizeof_headers): Ditto.
5033 (tekhex_make_empty_symbol): Ditto.
5034 (tekhex_get_symbol_info): Ditto.
5035 (tekhex_print_symbol): Ditto.
5036 * irix-core.c (make_bfd_asection): Ditto.
5037 (irix_core_core_file_p): Ditto.
5038 (irix_core_core_file_failing_command): Ditto.
5039 (irix_core_core_file_failing_signal): Ditto.
5040 (irix_core_core_file_matches_executable_p): Ditto.
5041 (irix_core_make_empty_symbol): Ditto.
5042 * coff-mips.c (mips_bfd_reloc_type_lookup): Ditto.
5043 * srec.c (srec_new_symbol): Ditto.
5044 (srec_get_section_contents): Ditto.
5045 (srec_set_arch_mach): Ditto.
5046 (srec_set_section_contents): Ditto.
5047 (internal_srec_write_object_contents): Ditto.
5048 (srec_write_object_contents): Ditto.
5049 (symbolsrec_write_object_contents): Ditto.
5050 (srec_sizeof_headers): Ditto.
5051 (srec_make_empty_symbol): Ditto.
5052 (srec_get_symtab_upper_bound): Ditto.
5053 (srec_get_symtab): Ditto.
5054 (srec_print_symbol): Ditto and make static.
5055 * elf.c (elf_read): Ditto
5056 (assign_section_numbers): Ditto.
5057 (elf_fake_sections): Ditto.
5058 (sym_is_global): Ditto.
5059 (elf_map_symbols): Ditto.
5060 (get_program_header_size): Ditto.
5061 * coffgen.c (make_a_section_from_file): Ditto.
5062 (coff_real_object_p): Ditto.
5063 (fixup_symbol_value): Ditto.
5064 (build_debug_section): Ditto.
5065 (copy_name): Ditto.
5066 * syms.c (coff_section_type): Ditto.
5067
5068 Mon Sep 9 22:36:01 1996 Jeffrey A Law (law@cygnus.com)
5069
5070 * bfd-in2.h: Rebuilt after m32r changes.
5071
5072 Mon Sep 9 12:31:22 1996 Doug Evans <dje@canuck.cygnus.com>
5073
5074 * config.bfd,configure.in,configure: Add m32r support.
5075 * Makefile.in,archures.c,elf.c,targets.c: Likewise.
5076 * config.bfd: Keep target list alphabetically sorted.
5077
5078 Mon Sep 9 11:48:41 1996 Jeffrey A Law (law@cygnus.com)
5079
5080 * elf32-v850.c (bfd_elf32_v850_reloc, case R_V850_HI16): Don't forget
5081 to add in the constant part found in the instruction itself.
5082 (case R_V850_HI16_S): Likewise.
5083
5084 Fri Sep 6 17:04:39 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
5085
5086 * elf32-d10v.c (elf_d10v_howto_table): Modify the size of R_D10V_16
5087 and R_D10V_18 to be 1 (word).
5088
5089 Thu Sep 5 15:23:08 1996 Ian Lance Taylor <ian@cygnus.com>
5090
5091 * stabs.c (_bfd_link_section_stabs): If the output_section field
5092 of either section is bfd_abs_section, then the linker is
5093 discarding the section and we should not optimize it.
5094
5095 Tue Sep 3 12:16:20 1996 Doug Evans <dje@canuck.cygnus.com>
5096
5097 * Makefile.in (aout-sparcle.o): New target.
5098 * aoutf1.h (TARGET_IS_BIG_ENDIAN_P): Don't define if little endian.
5099 * config.bfd (sparclet-*-aout*): Add case.
5100 * configure.in (sparcle_aout_vec): Add case.
5101 * configure: Regenerated.
5102 * targets.c (sparcle_aout_vec): Declare.
5103 (bfd_target_vector): Add sparcle_aout_vec.
5104 * aout-sparcle.c: New file.
5105
5106 Tue Sep 3 00:57:02 1996 Jeffrey A Law (law@cygnus.com)
5107
5108 * elf32-v850.c (bfd_elf32_v850_reloc): Fix handling of
5109 low order sign bit propogation for R_V850_HI16_S.
5110
5111 * elf32-v850.c (bfd_elf32_v850_reloc): New function for
5112 handling V850 specific relocs.
5113 (elf_v850_howto_table): Use the new function for some
5114 relocations. Twiddle masks & shifts for some relocs.
5115 Set partial_inplace where needed.
5116
5117 Mon Sep 2 12:12:34 1996 Ian Lance Taylor <ian@cygnus.com>
5118
5119 * cpu-mips.c: Add an explicit mips:3000 entry, and change the
5120 default architecture to a machine number of 0.
5121 * elf32-mips.c (_bfd_mips_elf_object_p): Set the machine number
5122 for E_MIPS_ARCH_1.
5123 (_bfd_mips_elf_merge_private_bfd_data): If the machine number of
5124 the output BFD is the default, set it from the first input BFD.
5125
5126 Sun Sep 1 18:38:01 1996 Jeffrey A Law (law@cygnus.com)
5127
5128 * elf32-v850.c (elf_v850_howto_table): All the 16bit relocs
5129 insert at bitpos zero. The HI16 relocs are shifted right
5130 by 16 bits. Fix src_mask for all relocs.
5131 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME): Define. The V850 is
5132 little endian!
5133 (TARGET_BIG_SYM, TARGET_BIG_NAME): Remove. The V850 is little
5134 endian!
5135
5136 Sun Sep 1 15:41:08 1996 Ian Lance Taylor <ian@cygnus.com>
5137
5138 * rs6000-core.c (rs6000coff_core_file_matches_executable_p):
5139 Rewrite to use BFD file read routines and to avoid using a fixed
5140 length for the file name.
5141
5142 Sat Aug 31 10:22:25 1996 Jeffrey A Law (law@cygnus.com)
5143
5144 * elf32-v850.c (enum reloc_type): Add R_V850_{32,16,8}.
5145 (elf_v850_howto_table): Add support for R_V850_{32,16,8}.
5146 (v850_reloc_map): Add translation from BFD_RELOC_{32,16,8}
5147 to R_V850_{32,16,8}.
5148
5149 Fri Aug 30 18:06:04 1996 J.T. Conklin <jtc@hippo.cygnus.com>
5150
5151 * elf32-v850.c (reloc_type): Add R_V850_HI16_S.
5152 (elf_v850_howto_table): Add info for HI16_S reloc.
5153 (v850_reloc_map): Add HI_16_S reloc.
5154 * reloc.c: Define BFD_RELOC_V850_* relocs.
5155
5156 Fri Aug 30 11:49:19 1996 Ian Lance Taylor <ian@cygnus.com>
5157
5158 Add SH ELF support.
5159 * elf32-sh.c: New file.
5160 * elf.c (prep_headers): Handle bfd_arch_sh.
5161 * elfcode.h (write_relocs): Handle absolute symbol.
5162 * elf-bfd.h (_bfd_elf32_link_read_relocs): Declare.
5163 (_bfd_elf64_link_read_relocs): Declare.
5164 * elflink.h (NAME(_bfd_elf,link_read_relocs)): Rename from
5165 elf_link_read_relocs. Make globally visible. Change all
5166 callers.
5167 (elf_link_input_bfd): Get external symbols from cache in
5168 symtab_hdr->contents. Get contents from cache in
5169 elf_section_data.
5170 * elfxx-target.h (bfD_elfNN_bfd_relax_section): Only define if not
5171 already defined.
5172 * reloc.c: Define BFD_RELOC_SH_* relocs.
5173 * libbfd-in.h (_bfd_sh_align_load_span): Declare.
5174 * coff-sh.c (sh_insns_conflict): Fix a return value.
5175 (_bfd_sh_align_load_span): New globally visible function, broken
5176 out of sh_align_load.
5177 (sh_align_load): Call _bfd_sh_align_load_span.
5178 (sh_swap_insns): Change relocs parameter to PTR.
5179 * bfd-in2.h, libbfd.h: Rebuild.
5180 * targets.c (bfd_elf32_sh_vec): Declare.
5181 (bfd_elf32_shl_vec): Declare.
5182 * config.bfd (sh-*-elf*): New target.
5183 * configure.in (bfd_elf32_sh_vec): New target vector.
5184 (bfd_elf32_shl_vec): New target vector.
5185 * configure: Rebuild.
5186 * Makefile.in: Rebuild dependencies.
5187 (BFD32_BACKENDS): Add elf32-sh.o.
5188 (BFD32_BACKENDS_CFILES): Add elf32-sh.c.
5189
5190 * elf.c (map_sections_to_segments): Check that LMA does not skip a
5191 page before checking D_PAGED.
5192
5193 * ihex.c (ihex_scan): Removed unnecessary extbase variable.
5194 (ihex_write_object_contents): Remove extbase; always use segbase
5195 instead.
5196
5197 Thu Aug 29 16:52:17 1996 Michael Meissner <meissner@tiktok.cygnus.com>
5198
5199 * configure.in (i[345]86-*-*): Recognize i686 for pentium pro.
5200 * configure.host (i[345]86-*-*): Ditto.
5201 * config.bfd (i[345]86-*-*): Ditto.
5202 * configure: Regenerate.
5203
5204 * config.bfd (i[3456]86-*-dgux*): Recognize as a synonym for x86
5205 elf.
5206
5207 Tue Aug 27 09:18:18 1996 Jeffrey A Law (law@cygnus.com)
5208
5209 * elf32-hppa.c (hppa_elf_gen_reloc_type): Add new argument.
5210 * elf32-hppa.h (hppa_elf_gen_reloc_type): Update prototype.
5211 * som.c (hppa_som_gen_reloc_type): Add new argument. If
5212 we encounter an R_DATA_ONE_SYMBOL reloc against a symbol that
5213 will have an ST_CODE type, change the symbol's type to ST_DATA.
5214 * som.c (hppa_som_gen_reloc_type): Update prototype.
5215
5216 Tue Aug 27 00:12:22 1996 Ian Lance Taylor <ian@cygnus.com>
5217
5218 * elf32-mips.c (mips_elf_check_relocs): Set dynobj if needed for
5219 R_MIPS_32 and R_MIPS_REL32. Set sgot and g as soon as possible.
5220 (mips_elf_size_dynamic_sections): Don't require .got to exist.
5221 (mips_elf_finish_dynamic_sections): Likewise.
5222
5223 Thu Aug 22 10:54:38 1996 Ian Lance Taylor <ian@cygnus.com>
5224
5225 * configure.host (HLDENV): New variable to set. Set it for
5226 *-*-sysv4*, since those linkers may not support -R but they always
5227 support LD_RUN_PATH.
5228
5229 * libieee.h (NSECTIONS): Don't define.
5230 (ieee_data_struct): Change section_table to asection **. Add
5231 section_table_size.
5232 * ieee.c (get_section_entry): If the table isn't big enough, make
5233 it bigger.
5234 (ieee_slurp_sections): Remove assertion about number of sections.
5235 (ieee_object_p): Adjust initialization of ieee to match changes to
5236 the structure.
5237
5238 * xcofflink.c (xcoff_mark): Don't copy relocs for undefined
5239 symbols merely because we are generating a shared library.
5240 (xcoff_build_ldsyms): Don't set up global linkage code for an
5241 undefined symbol merely because we are generating a shared
5242 library.
5243
5244 Tue Aug 20 15:06:05 1996 J.T. Conklin <jtc@hippo.cygnus.com>
5245
5246 * Makefile.in (ALL_MACHINES): Add cpu-v850.o.
5247 (BFD32_BACKENDS) Add elf32-v850.o.
5248 * archures.c: Add bfd_v850_arch.
5249 * bfd-in2.h: Add bfd_v850_arch.
5250 * config.bfd (v850-*-*): New target.
5251 * configure: (bfd_elf32_v850_vec) New vector.
5252 * configure.in: (bfd_elf32_v850_vec) New vector.
5253 * cpu-v850.c: New file.
5254 * elf.c (prep_headers): Added case bfd_arch_v850.
5255 * elf32-v850.c: New file.
5256 * targets.c (bfd_elf32_v850_vec): New vector.
5257
5258 Fri Aug 16 16:25:35 1996 Ian Lance Taylor <ian@cygnus.com>
5259
5260 * xcofflink.c (xcoff_link_add_dynamic_symbols): Create and define
5261 a function code symbol for an XMC_XO symbol.
5262
5263 Thu Aug 15 12:33:29 1996 Stan Shebs <shebs@andros.cygnus.com>
5264
5265 * mpw-config.in: Update editing of autoconf vars to reflect
5266 Jul 18 configure.in change.
5267 * mpw-make.sed: Update editing of include pathnames to be
5268 more general, add @DASH_C_FLAG@ to explicit compile rule edit.
5269
5270 Thu Aug 15 10:35:13 1996 Richard Henderson <rth@tamu.edu>
5271
5272 * elf64-alpha.c (elf64_alpha_output_extsym): The section from
5273 which to offset to get the .plt entry address is ".plt".
5274
5275 Thu Aug 15 16:40:30 1996 James G. Smith <jsmith@cygnus.co.uk>
5276
5277 * reloc.c: (BFD_RELOC_ARM_THUMB_ADD, BFD_RELOC_ARM_THUMB_IMM,
5278 BFD_RELOC_ARM_THUMB_SHIFT, BFD_RELOC_ARM_THUMB_OFFSET):
5279 Added, for internal use by the ARM gas.
5280 * libbfd.h: Rebuilt
5281 * bfd-in2.h: Rebuilt
5282
5283 Wed Aug 14 17:02:09 1996 Richard Henderson <rth@tamu.edu>
5284
5285 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Correct typo
5286 in section dynidx start.
5287
5288 Tue Aug 13 14:35:38 1996 Ian Lance Taylor <ian@cygnus.com>
5289
5290 * elf.c (_bfd_elf_make_section_from_shdr): Treat sections whose
5291 name begins with .gnu.linkonce as SEC_LINK_ONCE. This is an
5292 optimization for g++.
5293
5294 Tue Aug 13 17:04:40 1996 Michael Meissner <meissner@tiktok.cygnus.com>
5295
5296 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): If one module has
5297 the -mrelocatable-lib bit set and the other doesn't, clear the
5298 -mrelocatable-lib bit in the header.
5299
5300 Sat Aug 10 22:59:17 1996 Ian Lance Taylor <ian@cygnus.com>
5301
5302 * elflink.h (elf_link_add_object_symbols): Do not resolve a common
5303 symbol against a STT_FUNC symbol in a shared library.
5304
5305 Fri Aug 9 12:44:57 1996 Ian Lance Taylor <ian@cygnus.com>
5306
5307 * xcofflink.c (xcoff_link_add_dynamic_symbols): If a descriptor
5308 symbol is found, automatically define the corresponding function
5309 code.
5310
5311 * cofflink.c (coff_link_add_symbols): Only set (*sym_hash)->numaux
5312 if sym.n_numaux is not zero.
5313 (_bfd_coff_link_input_bfd): Permit the symbol and the hash table
5314 entry to disagree about the number of aux entries if the symbol
5315 has zero.
5316
5317 * elf32-mips.c (mips_elf_check_relocs): Create the .rel.dyn
5318 section if it might be needed, not just if info->shared.
5319 (mips_elf_adjust_dynamic_symbol): Make room for a null element at
5320 the start of .rel.dyn if we are going to use it.
5321 (mips_elf_finish_dynamic_sections): Only clear the first element
5322 of .rel.dyn if the size is greater than zero.
5323
5324 Thu Aug 8 16:24:55 1996 Ian Lance Taylor <ian@cygnus.com>
5325
5326 * xcofflink.c (xcoff_link_input_bfd): If we already called the
5327 undefined_symbol callback for a symbol, then don't issue any more
5328 warnings about loader relocs.
5329 (_bfd_ppc_xcoff_relocate_section): Don't do any further processing
5330 after calling the undefined_symbol callback.
5331
5332 * xcofflink.c (XCOFF_MULTIPLY_DEFINED): Define.
5333 (xcoff_link_add_symbols): Permit multiple definitions of a symbol
5334 as the AIX linker seems to do.
5335
5336 Thu Aug 8 12:21:56 1996 Klaus Kaempf <kkaempf@progis.de>
5337
5338 * evax-alpha.c (evax_alpha_vec): Corrected flags, cleanup.
5339 (evax_initialize): Remove evax_reloc_table.
5340 (evax_close_and_cleanup): Ditto.
5341 (reloc_nil): Ditto.
5342 (alpha_howto_table): Remove ALPHA_R_SWREL32 and ALPHA_R_SWREL64
5343 entries.
5344 (evax_bfd_reloc_type_lookup): Ditto.
5345 * evax-egsd.c (_bfd_evax_slurp_egsd): Add a few casts; set
5346 cooked_size == raw_size.
5347 * evax-emh.c (_bfd_evax_register_filename): Remove.
5348 * evax-etir.c (etir_stc): Allow ETIR_S_C_STC_xx commands.
5349 * evax-misc.c (add_new_contents): Malloc section at full size.
5350 (_bfd_save_evax_section): Memcpy section contents directly.
5351 * evax.h (ALPHA_R_SWREL32, ALPHA_R_SWREL64): Remove.
5352 (evax_reloc_table): Remove.
5353
5354 * hosts/alphavms.h (O_ACCMODE): Define if needed.
5355
5356 * makefile.vms: Add better support for DEC C compilation
5357 Add evax.h dependencies
5358
5359 * reloc.c (bfd_get_reloc_size): Add case for 16 byte reloc.
5360 (BFD_RELOC_SWREL32,BFD_RELOC_SWREL64): Remove.
5361 (BFD_RELOC_ALPHA_BASEREG): Remove.
5362 * bfd-in2.h, libbfd.h: Rebuild.
5363
5364 Thu Aug 8 08:17:32 1996 Stu Grossman (grossman@critters.cygnus.com)
5365
5366 * archive.c (bsd_write_armap): Ifdef around calls to getuid and
5367 getgid if _WIN32 is defined.
5368 * opncls.c (bfd_fdopenr): Remove unnecessary WINGDB ifdef.
5369
5370 Wed Aug 7 23:19:00 1996 Stu Grossman (grossman@critters.cygnus.com)
5371
5372 * aoutx.h bfd-in.h bfd-in2.h opncls.c riscix.c som.c targets.c:
5373 Change NO_FLAGS to BFD_NO_FLAGS to avoid conflict with an HPUX
5374 include file.
5375 * libbfd.c: Create dummy getpagesize() macro if HAVE_GETPAGESIZE
5376 isn't defined.
5377
5378 Wed Aug 7 14:11:44 1996 Philippe De Muyter <phdm@info.ucl.ac.be>
5379
5380 * configure.in: Call BFD_NEEDED_DECLARATION on strstr and
5381 realloc.
5382 * acconfig.h (NEED_DECLARATION_STRSTR): New macro.
5383 (NEED_DECLARATION_REALLOC): New macro.
5384 * configure, config.in: Rebuild.
5385 * sysdep.h (strstr): Declare if NEED_DECLARATION_STRSTR.
5386 (realloc): Declare if NEED_DECLARATION_REALLOC.
5387
5388 * aclocal.m4 (BFD_NEED_DECLARATION): Include <string.h> or
5389 <strings.h> if they exist.
5390
5391 * ieee.c (ieee_set_section_contents): Cast bfd_alloc return.
5392
5393 Wed Aug 7 12:12:03 1996 Ian Lance Taylor <ian@cygnus.com>
5394
5395 * cpu-i386.c (i8086_arch): Architecture info for the i8086.
5396
5397 Based on patches from Eric Valette <valette@crf.canon.fr>:
5398 * elf32-i386.c (enum reloc_type): Add FIRST_INVALID_RELOC,
5399 LAST_INVALID_RELOC, R_386_16, R_386_PC16, R_386_8, R_386_PC8.
5400 (elf_howto_table): Add entries for new relocs.
5401 (elf_i386_reloc_type_lookup): Handle new relocs.
5402 (elf_i386_info_to_howto): Just call abort.
5403 (elf_i386_info_to_howto_rel): Check that the reloc type is valid.
5404 (elf_i386_relocate_section): Likewise.
5405
5406 Tue Aug 6 12:54:56 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
5407
5408 * elf32-d10v.c (elf_d10v_howto_table): Added R_D10V_32.
5409
5410 Mon Aug 5 13:42:41 1996 Ian Lance Taylor <ian@cygnus.com>
5411
5412 * elf.c (_bfd_elf_make_section_from_shdr): For a loadable section,
5413 only get the LMA from the phdr if they are in the same part of the
5414 file.
5415
5416 * elf.c (map_sections_to_segments): Rewrite tests for starting a
5417 new segment to make them more comprehensible. If the relationship
5418 between the LMA and the VMA changed, start a new segment. Don't
5419 check dynsec when deciding whether to start a new segment for a
5420 writeable section; -N will now handle this.
5421
5422 Thu Aug 1 22:43:08 1996 Jeffrey A Law (law@cygnus.com)
5423
5424 * libhppa.h: Remove "esel" changes. Not the right approach.
5425 * som.c: Corresponding changes.
5426 (som_bfd_derive_misc_symbol_info): Use ST_DATA for symbols
5427 which don't have a SOM symbol type associated with them.
5428 Reverses a 1994 change.
5429
5430 Wed Jul 31 15:50:55 1996 Ian Lance Taylor <ian@cygnus.com>
5431
5432 Make ld -N more reasonable for ELF:
5433 * elf.c (map_sections_to_segments): If D_PAGED is not set, set
5434 phdr_in_section to false, and always use a single load segment.
5435 (elf_sort_sections): Sort sections by LMA after VMA.
5436 (assign_file_positions_for_segments): If D_PAGED is not set, don't
5437 align to maxpagesize.
5438 (assign_file_positions_except_relocs): Likewise.
5439 * elfcode.h (elf_object_p): If a section is loaded but not page
5440 aligned, clear D_PAGED.
5441
5442 Wed Jul 31 15:00:12 1996 James G. Smith <jsmith@cygnus.co.uk>
5443
5444 * reloc.c: (BFD_RELOC_ARM_OFFSETIMM8, BFD_RELOC_ARM_HWLITERAL):
5445 Added, for internal use by the ARM gas.
5446 * libbfd.h: Rebuilt
5447 * bfd-in2.h: Rebuilt
5448
5449 Tue Jul 30 14:14:57 1996 Jeffrey A Law (law@cygnus.com)
5450
5451 * libhppa.h (R_HPPA_ESEL): New field selector.
5452 (e_esel): Similarly.
5453 * som.c (hppa_som_gen_reloc_type): If we encounter an e_esel,
5454 then generate R_COMP2 (PUSH_SYM), R_DATA_EXPR fixup stream.
5455 (som_write_fixups): Handle R_DATA_EXPR just like R_CODE_EXPR.
5456
5457 Tue Jul 30 13:31:27 1996 Ian Lance Taylor <ian@cygnus.com>
5458
5459 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Do the regular
5460 archive search before looking for stripped dynamic objects.
5461
5462 Fri Jul 26 17:51:39 1996 Ian Lance Taylor <ian@cygnus.com>
5463
5464 * xcofflink.c (xcoff_build_ldsyms): Make exporting an undefined
5465 symbol a warning rather than an error.
5466
5467 Wed Jul 24 12:02:53 1996 Ian Lance Taylor <ian@cygnus.com>
5468
5469 * elf.c (assign_file_positions_for_segments): Track the virtual
5470 memory position separately from the file position, and use it to
5471 compute the alignment adjustment.
5472
5473 Tue Jul 23 10:43:31 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
5474
5475 * elf32-d10v.c (elf_d10v_howto_table): Changed all relocs to "long"
5476 and fixed mask on R_D10V_10_PCREL_L.
5477
5478 Mon Jul 22 15:30:30 1996 Ian Lance Taylor <ian@cygnus.com>
5479
5480 * elf64-mips.c: Include "aout/ar.h".
5481 (mips_elf64_slurp_armap): New static function.
5482 (mips_elf64_write_armap): New static function.
5483 (bfd_elf64_archive_*): Define.
5484 * elfxx-target.h (bfd_elfNN_archive_p): Define if not defined.
5485 Use instead of bfd_generic_archive_p.
5486 (bfd_elfNN_write_archive_contents): Define if not defined. Use
5487 instead of _bfd_write_archive_contents.
5488 (bfd_elfNN_mkdarchive): Define if not defined. Use instead of
5489 _bfd_generic_mkarchive.
5490 (TARGET_BIG_SYM): If bfd_elfNN_archive_functions is defined, use
5491 bfd_elfNN_archive in BFD_JUMP_TABLE_ARCHIVE rather than
5492 _bfd_archive_coff.
5493 (TARGET_LITTLE_SYM): Likewise.
5494 * archive.c (bfd_slurp_armap): Check for and reject an archive map
5495 name of /SYM64/.
5496 * Makefile.in: Rebuild dependencies.
5497
5498 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Handle
5499 SHT_MIPS_LIBLIST, SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and
5500 SHT_MIPS_EVENTS sections.
5501 (_bfd_mips_elf_section_from_shdr): Handle SHT_MIPS_IFACE,
5502 SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and SHT_MIPS_EVENTS
5503 sections.
5504 (_bfd_mips_elf_fake_sections): Likewise.
5505
5506 * libecoff.h (ecoff_data_type): Add rdata_in_text field.
5507 * ecoff.c (ecoff_compute_section_file_positions): Copy
5508 rdata_in_text from backend info to tdata. Clear it if any data
5509 section comes before .rdata.
5510 (_bfd_ecoff_write_object_contents): Use rdata_in_text field in
5511 tdata rather than backend info.
5512
5513 Fri Jul 19 18:15:51 1996 Ian Lance Taylor <ian@cygnus.com>
5514
5515 * configure.in: Fix test for whether a compiler has a 64 bit
5516 type. From Jim Wilson <wilson@cygnus.com>.
5517
5518 Thu Jul 18 15:39:10 1996 Ian Lance Taylor <ian@cygnus.com>
5519
5520 * configure.host (mips-sgi-irix6*): New host.
5521
5522 * configure.in: Set and substitute VERSION, BFD_HOST_64BIT_LONG
5523 (replacing HOST_64BITLONG), BFD_HOST_64_BIT_DEFINED,
5524 BFD_HOST_64_BIT, and BFD_HOST_U_64_BIT. Add bfd-in2.h:bfd-in2.h
5525 to AC_OUTPUT call.
5526 * configure: Rebuild.
5527 * bfd-in.h (BFD_ARCH_SIZE): Define as @wordsize@, not @WORDSIZE@.
5528 (BFD_HOST_64_BIT): Define conditionally.
5529 (BFD_HOST_U_64_BIT): Define when BFD_HOST_64_BIT is defined.
5530 (bfd_vma): Typedef as BFD_HOST_U_64_BIT.
5531 (symvalue, bfd_size_type): Likewise.
5532 * bfd-in2.h: Rebuild.
5533 * Makefile.in (do_clean): Remove bfd-tmp.h.
5534 (do_distclean): Remove bfd-in3.h.
5535 (stmp-bfd.h): Just do copy-if-change bfd-in3.h bfd.h.
5536 (bfd-in3.h): New target.
5537
5538 * config.bfd (sparc-*-sysv4*): Don't build sunos_big_vec. From
5539 Andrew Gierth <ANDREWG@microlise.co.uk>.
5540
5541 * configure.host: Set INSTALL_SHLIB.
5542 * configure.in: Call AC_SUBST (INSTALL_SHLIB).
5543 * configure: Rebuild.
5544 * Makefile.in (install): Use @INSTALL_SHLIB@.
5545
5546 * config.bfd (mips*-*-irix6*): New target.
5547 * configure.host: Handle Irix 6 shared library like Irix 5.
5548
5549 * xcofflink.c (xcoff_link_add_symbols): Don't check an XMC_TD
5550 symbol for a magic name.
5551 (xcoff_link_input_bfd): Don't change the reloc symbol for an
5552 XMC_TD symbol.
5553 (_bfd_ppc_xcoff_relocate_section): Don't get the TOC offset for an
5554 XMC_TD symbol.
5555
5556 Thu Jul 18 11:36:31 1996 Stan Shebs <shebs@andros.cygnus.com>
5557
5558 * mpw-config.in: Add ELF support to mips config, create the
5559 elf32-target.h file in the object dir.
5560 * mpw-make.sed: Edit elfXX-target.h refs at beginnings of lines.
5561
5562 Wed Jul 17 18:02:32 1996 Kim Knuttila <krk@cygnus.com>
5563
5564 * coff-ppc.c: Redid debug scheme - numerous fprintf's gone.
5565 Also removed most abort calls, in favor of using bfd reporting.
5566
5567 Wed Jul 17 14:51:52 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
5568
5569 * Makefile.in (ALL_MACHINES): Add cpu-d10v.o.
5570 (BFD32_BACKENDS) Add elf32-d10v.o.
5571 * archures.c: Add bfd_d10v_arch.
5572 * bfd-in2.h: Add bfd_d10v_arch.
5573 * config.bfd (d10v-*-*): New target.
5574 * configure: (bfd_elf32_d10v_vec) New vector.
5575 * configure.in: (bfd_elf32_d10v_vec) New vector.
5576 * cpu-d10v.c: New file.
5577 * elf.c (prep_headers): Added case bfd_arch_d10v.
5578 * elf32-d10v.c: New file.
5579 * libbfd.h: Rebuild.
5580 * reloc.c (BFD_RELOC_D10V_10_PCREL_R, BFD_RELOC_D10V_10_PCREL_L,
5581 BFD_RELOC_D10V_18, BFD_RELOC_D10V_18_PCREL): Define.
5582 * targets.c (bfd_elf32_d10v_vec): New vector.
5583
5584 Wed Jul 17 10:58:55 1996 Kim Knuttila <krk@cygnus.com>
5585
5586 * coff-ppc.c (coff_ppc_relocate_section): Removed bogus fprintf
5587
5588 Tue Jul 16 23:49:02 1996 Stu Grossman (grossman@critters.cygnus.com)
5589
5590 * archures.c bfd-in2.h: Add bfd_mach_i386_i386 and
5591 bfd_mach_i386_i8086 machine types.
5592
5593 Wed Jul 10 12:42:56 1996 Ian Lance Taylor <ian@cygnus.com>
5594
5595 * ecoff.c (_bfd_ecoff_new_section_hook): Set SEC_CODE for _INIT
5596 and _FINI sections.
5597
5598 Wed Jul 10 11:18:21 1996 Richard Henderson <rth@tamu.edu>
5599
5600 * coffcode.h (coff_set_section_contents): A/UX does not require
5601 special handling of the _LIB section.
5602
5603 Tue Jul 9 15:52:20 1996 Jeffrey A Law (law@cygnus.com)
5604
5605 * coff-h8300.c (h8300_reloc16_extra_cases): Use the correct
5606 value for R_RELBYTE.
5607
5608 * reloc16.c (bfd_coff_reloc16_relax_section): Only "shrinks"
5609 array if one was allocated.
5610
5611 Tue Jul 9 12:21:54 1996 Ian Lance Taylor <ian@cygnus.com>
5612
5613 From Kazumoto Kojima <kkojima@kk.info.kanagawa-u.ac.jp>:
5614 * elf32-mips.c (struct mips_elf_link_hash_table): Add new fields
5615 use_rld_obj_head and rld_value.
5616 (mips_elf_link_hash_table_create): Initialize new fields.
5617 (mips_elf_add_symbol_hook): Mark __rld_obj_head symbol as
5618 dynamic.
5619 (mips_elf_create_dynamic_sections): Create .rld_map section. If
5620 __rld_obj_head symbol not seen, create an __rld_map symbol.
5621 (mips_elf_size_dynamic_sections): Make space in .rld_map section.
5622 Create a DT_MIPS_RLD_MAP entry rather than a DT_DEBUG entry.
5623 (mips_elf_finish_dynamic_symbol): Save value of __rld_map or
5624 __rld_obj_head symbol.
5625 (mips_elf_finish_dynamic_sections): Handle DT_MIPS_RLD_MAP.
5626
5627 Mon Jul 8 16:18:03 1996 Ian Lance Taylor <ian@cygnus.com>
5628
5629 * elf32-mips.c (mips_reloc_map): Remove BFD_RELOC_32_PCREL entry.
5630
5631 * elf32-ppc.c (ppc_elf_howto_raw): For R_PPC_ADDR16_HA, use
5632 ppc_elf_addr16_ha_reloc.
5633 (ppc_elf_addr16_ha_reloc): New static function.
5634
5635 * coff-mips.c (struct mips_hi): Define.
5636 (mips_refhi_list): New static variable.
5637 (mips_refhi_addr, mips_refhi_addend): Remove.
5638 (mips_refhi_reloc): Maintain a list of unmatched REFHI relocs.
5639 (mips_reflo_reloc): Process mips_refhi_list.
5640 (mips_relhi_list): New static variable.
5641 (mips_relhi_addr, mips_relhi_addend): Remove.
5642 (mips_relhi_reloc): Maintain a list of unmatched RELHI relocs.
5643 (mips_rello_reloc): Process mips_relhi_list.
5644 (mips_relocate_section): Permit an arbitrary number of REFHI or
5645 RELHI relocs before the associated REFLO or RELLO reloc.
5646
5647 Fri Jul 5 19:27:49 1996 Ian Lance Taylor <ian@cygnus.com>
5648
5649 * aout-target.h (MY(callback)): Set reloc_count fields.
5650
5651 Thu Jul 4 12:00:37 1996 Ian Lance Taylor <ian@cygnus.com>
5652
5653 * sunos.c (sunos_add_dynamic_symbols): Don't create dynamic
5654 sections unless this is a SunOS link.
5655
5656 * VERSION: Set to 2.7.1.
5657
5658 * Released binutils 2.7.
5659
5660 Wed Jul 3 14:59:47 1996 Ian Lance Taylor <ian@cygnus.com>
5661
5662 * i386aout.c: Include "aout/aout64.h".
5663 (i386aout_write_object_contents): New static function.
5664 (MY_write_object_contents): Define.
5665
5666 * netbsd.h (MY(write_object_contents)): Make sure that
5667 adjust_sizes_and_vmas is called before fiddling with the magic
5668 number.
5669
5670 Tue Jul 2 23:30:39 1996 Ian Lance Taylor <ian@cygnus.com>
5671
5672 * stabs.c (_bfd_link_section_stabs): Fix casts of psinfo.
5673
5674 Sun Jun 30 13:34:33 1996 Ian Lance Taylor <ian@cygnus.com>
5675
5676 * libbfd-in.h (itos, stoi): Don't define.
5677 * libbfd.h: Rebuild.
5678 * i386lynx.c (KEEPIT): Define as udata.i.
5679 (NAME(lynx,swap_std_reloc_out)): Don't use stoi.
5680 (NAME(lynx,swap_ext_reloc_out)): Likewise.
5681 * riscix.c (riscix_swap_std_reloc_out): Use udata.i rather than
5682 flags. Don't use stoi.
5683
5684 * elf32-mips.c (ELF_MAGPAGESIZE): Change definition to 0x1000.
5685
5686 * elf.c (map_sections_to_segments): Don't start a new segment for
5687 a writable section if it's on the same page as the previous
5688 segment. Reset the writable variable for a readonly section.
5689
5690 Sat Jun 29 16:18:51 1996 Kim Knuttila <krk@cygnus.com>
5691
5692 * peicode.h (coff_swap_aouthdr_in): Missing initializations of
5693 first_thunk_address, thunk_size, and import_table_size.
5694 * peicode.h: Improved some diagnostics regarding edata sections.
5695
5696 * coff-ppc.c (coff_ppc_relocate_section): Earlier error check
5697 on IMGLUE relocs.
5698 (coff_ppc_relocate_section): Improved diagnostic for large TOCDEFN's.
5699 (TARGET_LITTLE_SYM): Added missing D_PAGED.
5700
5701 Fri Jun 28 13:48:45 1996 Ian Lance Taylor <ian@cygnus.com>
5702
5703 * xcofflink.c (xcoff_link_check_ar_symbols): An undefined symbol
5704 with XCOFF_DEF_DYNAMIC set is really defined.
5705 (xcoff_link_check_dynamic_ar_symbols): Likewise.
5706 (xcoff_link_add_symbols): Only create special sections if using an
5707 XCOFF hash table.
5708
5709 * reloc.c (bfd_perform_relocation): Handle xcoff-powermac like
5710 aixcoff-rs6000.
5711 (bfd_install_relocation): Likewise.
5712
5713 Fri Jun 28 11:17:00 1996 Richard Henderson <rth@tamu.edu>
5714
5715 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add flags
5716 field.
5717 (ALPHA_ELF_LINK_HASH_LU_ADDR): Define.
5718 (ALPHA_ELF_LINK_HASH_LU_MEM): Define.
5719 (ALPHA_ELF_LINK_HASH_LU_FUNC): Define.
5720 (elf64_alpha_link_hash_newfunc): Initialize flags field.
5721 (elf64_alpha_check_relocs): Record types of LITUSE entries that
5722 are found for LITERAL relocs.
5723 (elf64_alpha_adjust_dynamic_symbol): If a symbol has its address
5724 taken, we cannot generate a .plt entry for the symbol.
5725
5726 Thu Jun 27 11:24:29 1996 Ian Lance Taylor <ian@cygnus.com>
5727
5728 * configure.in: Add AC_ISC_POSIX, and check for setitimer and
5729 sysconf functions (for gprof).
5730 * configure, config.in: Rebuild.
5731
5732 Wed Jun 26 16:29:02 1996 Ian Lance Taylor <ian@cygnus.com>
5733
5734 * ecoff.c (_bfd_ecoff_archive_p): Check the first object file in
5735 an archive if it has a map. If the object file has the wrong
5736 xvec, reject it.
5737
5738 * coff-alpha.c (alpha_adjust_reloc_in): Set the addend for a
5739 BRADDR, SREL16, SREL32, or SREL64 reloc against an external
5740 symbol.
5741 (alpha_relocate_section): Likewise.
5742
5743 * coffswap.h (coff_swap_reloc_out): Use RELSZ, not sizeof.
5744 (coff_swap_filehdr_out): Use FILHSZ, not sizeof.
5745 (coff_swap_sym_out): Use SYMESZ, not sizeof.
5746 (coff_swap_aux_out): Use AUXESZ, not sizeof.
5747 (coff_swap_lineno_out): Use LINESZ, not sizeof.
5748 (coff_swap_aouthdr_out): Use AOUTSZ, not sizeof.
5749 (coff_swap_scnhdr_out): Use SCNHSZ, not sizeof.
5750 * peicode.h: Corresponding changes.
5751
5752 Tue Jun 25 15:28:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
5753
5754 * elflink.h (elf_create_pointer_linker_section): Comment out code
5755 dealing with making GOT pointers negative of the GOT symbol for
5756 now.
5757
5758 Tue Jun 25 11:41:24 1996 Richard Henderson <rth@tamu.edu>
5759
5760 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't
5761 increment the .rela.plt size until after we're done creating the
5762 .plt entry.
5763 (elf64_alpha_finish_dynamic_symbol): Change .plt entry to load the
5764 .rela.plt offset directly rather than calculating it.
5765
5766 Mon Jun 24 17:15:10 1996 Jason Molenda (crash@godzilla.cygnus.co.jp)
5767
5768 * Makefile.in, (bindir, libdir, datadir, mandir, infodir, includedir):
5769 Use autoconf-set values.
5770 * doc/Makefile.in (bindir, libdir, datadir, mandir, infodir,
5771 includedir, INSTALL, INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set
5772 values.
5773 (docdir): Deleted.
5774 * configure.in (AC_PREREQ): autoconf v2.5 or higher.
5775 * configure: Rebuilt.
5776
5777 Mon Jun 24 22:50:35 1996 Jeffrey A Law (law@cygnus.com)
5778
5779 * som.c (som_write_fixups): Fix typo in R_END_TRY for exception
5780 handling code > 1k away.
5781
5782 Mon Jun 24 18:41:06 1996 Michael Meissner <meissner@tiktok.cygnus.com>
5783
5784 * elflink.h (elf_create_pointer_linker_section): If DEBUG is
5785 defined, output whenever the symbol is updated.
5786
5787 Mon Jun 24 17:58:12 1996 Jouke Numan <jnuman@bazis.nl>
5788
5789 * elf.c (elf_fake_sections): Don't set sh_addr of a non SEC_ALLOC
5790 section to 0 if user_set_vma is set.
5791 * elflink.h (elf_bfd_final_link): Likewise.
5792
5793 Sun Jun 23 20:42:51 1996 Doug Evans <dje@canuck.cygnus.com>
5794
5795 Partially undo patch of Jun 20.
5796 * coffcode.h (coff_set_alignment_hook): Use COFF_IMAGE_WITH_PE.
5797 (coff_compute_section_file_positions): Likewise.
5798 (coff_write_object_contents): Likewise. Re-add deleted code, but
5799 use #ifdef COFF_WITH_PE, not COFF_OBJ_WITH_PE.
5800 * peicode.h (pe_bfd_copy_private_bfd_data): Re-add #ifdef.
5801
5802 Fri Jun 21 17:38:15 1996 Joel Sherrill <joel@merlin.gcs.redstone.army.mil>
5803
5804 * config.bfd: Add support for *-*-rtems* configurations.
5805
5806 Fri Jun 21 15:19:59 1996 Ian Lance Taylor <ian@cygnus.com>
5807
5808 * elf.c (prep_headers): Add bfd_arch_alpha case.
5809
5810 Fri Jun 21 12:35:27 1996 Richard Henderson <rth@tamu.edu>
5811
5812 * elf64-alpha.c: New file.
5813 * config.bfd (alpha-*-linuxecoff*): New target.
5814 (alpha-*-linux*, alpha-*-elf*): New targets.
5815 * configure.in (bfd_elf64_alpha_vec): New vector.
5816 * configure: Rebuild.
5817 * targets.c (bfd_elf64_alpha_vec): Declare.
5818 (bfd_target_vector): Add bfd_elf64_alpha_vec if BFD64.
5819 * reloc.c (BFD_RELOC_ALPHA_GPDISP): Define.
5820 * bfd-in2.h, libbfd.h: Rebuild.
5821 * Makefile.in: Rebuild dependencies.
5822 (BFD64_BACKENDS): Add elf64-alpha.o.
5823 (BFD64_BACKENDS_CFILES): Add elf64-alpha.c.
5824
5825 Thu Jun 20 18:14:25 1996 Ian Lance Taylor <ian@cygnus.com>
5826
5827 * ecoff.c (ecoff_armap_hash): If hlog is 0, just return 0, rather
5828 than relying on a right shift of 32.
5829
5830 Thu Jun 20 11:00:57 1996 Doug Evans <dje@canuck.cygnus.com>
5831
5832 * coffcode.h (coff_set_alignment_hook): Change COFF_IMAGE_WITH_PE
5833 ifdef to COFF_WITH_PE.
5834 (coff_compute_section_file_positions): Likewise.
5835 (coff_write_object_contents): Likewise. Delete COFF_OBJ_WITH_PE.
5836 * pe-{arm,i386,ppc}.c (COFF_OBJ_WITH_PE): Delete.
5837 * peicode.h (pe_bfd_copy_private_bfd_data): Delete ifdef
5838 COFF_IMAGE_WITH_PE, always include.
5839
5840 * peicode.h (coff_swap_scnhdr_out): ".drectve" doesn't have trailing 0.
5841
5842 Wed Jun 19 11:37:52 1996 Ian Lance Taylor <ian@cygnus.com>
5843
5844 * elf.c (map_sections_to_segments): Fix up the test for -Ttext to
5845 approximate the correct answer if SIZEOF_HEADERS was not used.
5846
5847 * binary.c (binary_set_section_contents): Set section file
5848 position based on LMA rather than VMA.
5849
5850 Wed Jun 19 11:19:25 1996 Manfred Hollstein KS/EIC5 60/3/142 #40283 <manfred@lts.sel.alcatel.de>
5851
5852 * linker.c (_bfd_generic_link_output_symbols): Don't output any
5853 symbols if info->strip == strip_all.
5854
5855 Tue Jun 18 15:17:36 1996 Jeffrey A. Law <law@rtl.cygnus.com>
5856
5857 * coff-h8300.c: Remove #if 0 code.
5858 (compatable): Don't allow mixing/matching of different architectures.
5859
5860 * archures.c (bfd_mach_h8300s): Add.
5861 * bfd-in2.h: Rebuilt.
5862 * coff-h8300.c (funcvec_hash_newfunc): Handle H8/S too.
5863 (BADMAG): Likewise.
5864 (h8300_reloc16_estimate): Likewise.
5865 (h8300_reloc16_extra_cases): Likewise.
5866 (h8300_bfd_link_add_symbols): Likewise.
5867 * coffcode.h (coff_set_arch_mach_hook): Likewise.
5868 (coff_set_flags): Likewise.
5869 * cpu-h8300.c (h8300_scan): Likewise.
5870 Add H8/S to bfd_h8300_arch list.
5871
5872 Tue Jun 18 14:42:58 1996 Klaus Kaempf <kkaempf@progis.de>
5873
5874 Added support for Alpha OpenVMS:
5875 * evax.h, evax-alpha.c, evax-egsd.c, evax-emh.c: New files.
5876 * evax-etir.c, evax-misc.c, hosts/alphavms.h: New files.
5877 * config.h-vms, makefile.vms: New files.
5878 * config.bfd (alpha-*-*vms*): New target.
5879 * configure.in (evax_alpha_vec): New target vector.
5880 * configure: Rebuild.
5881 * reloc.c (BFD_RELOC_SWREL32, BFD_RELOC_SWREL64): Define.
5882 (BFD_RELOC_ALPHA_LINKAGE, BFD_RELOC_ALPHA_BASEREG): Define.
5883 * targets.c (bfd_target_evax_flavour): Define.
5884 (evax_alpha_vec): Declare.
5885 (bfd_target_vector): Add ecoffalpha_little_vec and evax_alpha_vec
5886 if BFD64 is defined.
5887 * bfd-in2.h, libbfd.h: Rebuild.
5888 * Makefile.in: Rebuild dependencies.
5889 (BFD64_BACKENDS): Add evax-alpha.o, evax-egsd.o, evax-etir.o,
5890 evax-emh.o, and evax-misc.o.
5891 (BFD64_BACKENDS_CFILES): Add evax-alpha.c, evax-egsd.c,
5892 evax-etir.c, evax-emh.c, and evax-misc.c.
5893 (HFILES): Add evax.h.
5894
5895 Tue Jun 18 13:54:18 1996 Ian Lance Taylor <ian@cygnus.com>
5896
5897 * coff-h8300.c (h8300_reloc16_extra_cases): Make name a const
5898 pointer.
5899 (h8300_bfd_link_add_symbols): Likewise.
5900
5901 Mon Jun 17 10:06:50 1996 Jeffrey A. Law <law@rtl.cygnus.com>
5902
5903 * som.h (R_HPPA_BEGIN_TRY, R_HPPA_END_TRY): Define.
5904 * som.c (som_write_fixups): Handle R_BEGIN_TRY and R_END_TRY.
5905
5906 Mon Jun 17 12:49:11 1996 Ian Lance Taylor <ian@cygnus.com>
5907
5908 * elf32-mips.c (mips_elf_relocate_section): Don't create a reloc
5909 for R_MIPS_REL32 and R_MIPS_32 relocs if no dynamic sections were
5910 created.
5911 (mips_elf_check_relocs): Only create .rel.dyn for R_MIPS_REL32 and
5912 R_MIPS_32 relocs if creating a shared library.
5913
5914 Thu Jun 13 20:14:51 1996 Doug Evans <dje@canuck.cygnus.com>
5915
5916 * peicode.h (add_data_entry): Use pei_section_data rather than
5917 _cooked_size. Corresponds to May 13 change in coffcode.h.
5918
5919 Thu Jun 13 10:23:40 1996 Ian Lance Taylor <ian@cygnus.com>
5920
5921 * cofflink.c (_bfd_coff_final_link): Handle long section names.
5922 * coffcode.h (coff_write_object_contents): If there are long
5923 section names, always set the f_symptr field, even if there are no
5924 symbols.
5925 * peicode.h (coff_swap_filehdr_in): Don't clear the f_symptr field
5926 if there are no symbols.
5927
5928 * coffgen.c (make_a_section_from_file): Check return value of
5929 _bfd_coff_read_string_table.
5930 (coff_real_object_p): Check return value of
5931 make_a_section_from_file.
5932 (_bfd_coff_read_string_table): Check that there are some symbols
5933 before trying to read the string table size.
5934
5935 Wed Jun 12 11:16:37 1996 Ian Lance Taylor <ian@cygnus.com>
5936
5937 * xcofflink.c (xcoff_link_add_symbols): When considering whether
5938 to replace a symbol in a dynamic object with a symbol from another
5939 dynamic object, do the replacement if the existing symbol is
5940 global linkage code.
5941
5942 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Check explicitly
5943 for _ptrgl, and treat it as global linkage code.
5944
5945 * aoutx.h (NAME(aout,find_nearest_line)): Notice if we find a
5946 filename or N_SO symbol past the offset, and use it to indicate
5947 that there is no line number or function when appropriate.
5948
5949 Tue Jun 11 15:24:48 1996 Ian Lance Taylor <ian@cygnus.com>
5950
5951 * xcofflink.c (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR for a
5952 common symbol defined by the linker. Don't export function code
5953 even if export_defineds is set.
5954
5955 Mon Jun 10 11:57:27 1996 Jeffrey A Law (law@cygnus.com)
5956
5957 * coff-h8300.c (howto_table): Add new entries for R_BCC_INV
5958 and R_JMP_DEL.
5959 (rtype2howto): Handle R_BCC_INV and R_JMP_DEL.
5960 (h8300_symbol_address_p): New function.
5961 (h8300_reloc16_estimate): Eliminate jumps made unnecessary by
5962 relaxing.
5963
5964 Sun Jun 9 16:30:20 1996 Jeffrey A Law (law@cygnus.com)
5965
5966 * coff-h8300.c (h8300_reloc16_estimate): Fix many minor spacing
5967 problems.
5968 (h8300_reloc16_estimate, cases R_JMP1, R_JMP2): Adjust "dot"
5969 correctly for the two variants. Allow relaxing if the target
5970 is 128 bytes away since after relaxation it'll be 126 bytes away.
5971 (h8300_reloc16_estimate, case R_PCRWORD): Correctly adjust
5972 "dot" and "value". Allow relaxing if the target is 128 bytes
5973 away since after relaxation it'll be 126 bytes away.
5974 * reloc16.c (bfd_coff_reloc16_relax_section): Keep relaxing
5975 the given section until nothing changes.
5976
5977 Thu Jun 6 15:24:45 1996 Richard Henderson <rth@tamu.edu>
5978
5979 * ecoff.c (_bfd_ecoff_new_section_hook): Remove the _PDATA
5980 alignment hack--we can get the lnnoptr info another way without
5981 suddenly increasing the alignment requirements. Set the flags for
5982 the _PDATA section.
5983 (ecoff_compute_section_file_positions): Do so.
5984
5985 Thu Jun 6 11:24:37 1996 Ian Lance Taylor <ian@cygnus.com>
5986
5987 * ieee.c (ieee_write_object_contents): Put a timestamp in the file
5988 to keep the HP emulator database happy.
5989
5990 * config.bfd: Recognize powerpc-*-linux* and powerpcle-*-linux*.
5991 From Kevin Buettner <kev@primenet.com>.
5992
5993 Wed Jun 5 15:16:04 1996 Ian Lance Taylor <ian@cygnus.com>
5994
5995 * aoutx.h (translate_to_native_sym_flags): Don't try to print the
5996 name of a NULL section.
5997
5998 Tue Jun 4 18:53:58 1996 Ian Lance Taylor <ian@cygnus.com>
5999
6000 * linker.c (_bfd_generic_link_add_one_symbol): If notice_all is
6001 set, always call the notice callback.
6002
6003 * VERSION: Increment for bfdlink.h change.
6004
6005 Mon Jun 3 11:01:53 1996 Ian Lance Taylor <ian@cygnus.com>
6006
6007 * coff-sh.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set to 4.
6008 (sh_relax_delete_bytes): Correct handling of differently sized
6009 trailing alignment reloc.
6010
6011 * bfd-in.h: Use #error if BFD_HOST_64_BIT can not be defined.
6012 * bfd-in2.h: Rebuild.
6013 * configure.in: Warn if there is no known 64 bit type.
6014 * configure: Rebuild.
6015
6016 * Makefile.in: Rebuild dependencies.
6017 (BFD32_BACKENDS): Add ppcboot.o.
6018 (BFD32_BACKENDS_CFILES): Add ppcboot.c.
6019
6020 * elf32-mips.c (mips_elf_size_dynamic_sections): Initialize c.
6021 From Per Fogelstrom <per.fogelstrom@mailbox200.swipnet.se>.
6022
6023 Sat Jun 1 21:49:58 1996 Ian Lance Taylor <ian@cygnus.com>
6024
6025 * elf64-mips.c (bfd_mips_elf64_swap_reginfo_in)
6026 (bfd_mips_elf64_swap_reginfo_out): Move from here...
6027 * elf32-mips.c (bfd_mips_elf64_swap_reginfo_in)
6028 (bfd_mips_elf64_swap_reginfo_out): ...to here.
6029
6030 Fri May 31 13:51:28 1996 Ian Lance Taylor <ian@cygnus.com>
6031
6032 * elf64-mips.c: Improve reloc special_functions and handling of
6033 SHT_MIPS_OPTIONS section.
6034 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Rename from
6035 mips_elf_hi16_reloc and make globally visible.
6036 (_bfd_mips_elf_lo16_reloc): Rename from mips_elf_lo16_reloc and
6037 make globally visible.
6038 (_bfd_mips_elf_got16_reloc): Rename from mips_elf_got16_reloc and
6039 make globally visible.
6040 (_bfd_mips_elf_gprel16_reloc): Rename from mips_elf_gprel16_reloc
6041 and make globally visible.
6042 (gprel16_with_gp): Check howto->src_mask before using value in
6043 insn.
6044 (_bfd_mips_elf_gprel32_reloc): Rename from mips_elf_gprel32_reloc
6045 and make globally visible.
6046 (gprel32_with_gp): Check howto->src_mask before fetching value.
6047 (bfd_mips_elf_swap_options_in): New function.
6048 (bfd_mips_elf_swap_options_out): New function.
6049 (_bfd_mips_elf_set_private_flags): Rename from
6050 mips_elf_set_private_flags and make globally visible.
6051 (_bfd_mips_elf_copy_private_bfd_data): Rename from
6052 mips_elf_copy_private_bfd_data and make globally visible.
6053 (_bfd_mips_elf_merge_private_bfd_data): Rename from
6054 mips_elf_merge_private_bfd_data and make globally visible.
6055 (_bfd_mips_elf_section_from_shdr): Accept .MIPS.options as a name
6056 for a SHT_MIPS_OPTIONS section.
6057 (mips_elf32_section_from_shdr): Handle SHT_MIPS_OPTIONS section.
6058 (_bfd_mips_elf_fake_sections): Consider .MIPS.options to be the
6059 name of a SHT_MIPS_OPTIONS section.
6060 (_bfd_mips_elf_set_section_contents): New function.
6061 (mips_elf32_section_processing): Set the GP value in a
6062 SHT_MIPS_OPTIONS section.
6063 (_bfd_mips_elf_find_nearest_line): Rename from
6064 mips_elf_find_nearest_line and make globally visible.
6065 (bfd_elf32_set_section_contents): Define.
6066 * elf-bfd.h (_bfd_mips_elf_hi16_reloc): Declare.
6067 (_bfd_mips_elf_lo16_reloc): Declare.
6068 (_bfd_mips_elf_gprel16_reloc): Declare.
6069 (_bfd_mips_elf_got16_reloc): Declare.
6070 (_bfd_mips_elf_gprel32_reloc): Declare.
6071 (_bfd_mips_elf_set_private_flags): Declare.
6072 (_bfd_mips_elf_copy_private_bfd_data): Declare.
6073 (_bfd_mips_elf_merge_private_bfd_data): Declare.
6074 (_bfd_mips_elf_find_nearest_line): Declare.
6075 (_bfd_mips_elf_set_section_contents): Declare.
6076
6077 * elf32-hppa.c (elf32_hppa_info_to_howto): Rename from
6078 elf_info_to_howto.
6079 (elf_info_to_howto): Define.
6080 * elf32-sparc.c (elf32_sparc_info_to_howto): Rename from
6081 elf_info_to_howto.
6082 (elf_info_to_howto): Define.
6083 * elf64-sparc.c (sparc64_elf_info_to_howto): Rename from
6084 elf_info_to_howto.
6085 (elf_info_to_howto): Define.
6086
6087 * coff-w65.c (h8300_reloc16_estimate): Rename R_MOVB[12] to
6088 R_MOV16B[12], to match change in coff/internal.h.
6089
6090 Thu May 30 12:38:49 1996 Ian Lance Taylor <ian@cygnus.com>
6091
6092 * elf64-mips.c: Extensive additions to provide better support for
6093 writing files and for gas.
6094 * elf32-mips.c (_bfd_mips_elf_object_p): New function, broken out
6095 of mips_elf_object_p.
6096 (mips_elf32_object_p): Rename from mips_elf_object_p; call
6097 _bfd_mips_elf_object_p.
6098 (_bfd_mips_elf_final_write_processing): Rename from
6099 mips_elf_final_write_processing and make globally visible.
6100 (_bfd_mips_elf_fake_sections): Rename from
6101 mips_elf_fake_sections and make globally visible.
6102 (_bfd_mips_elf_section_from_bfd_section): Rename from
6103 mips_elf_section_from_bfd_section and make globally visible.
6104 (_bfd_mips_elf_section_processing): New function, broken out of
6105 mips_elf_section_processing.
6106 (mips_elf32_section_processing): Rename from
6107 mips_elf_section_processing; call
6108 _bfd_mips_elf_section_processing.
6109 (_bfd_mips_elf_symbol_processing): Rename from
6110 mips_elf_symbol_processing and make globally visible.
6111 (_bfd_mips_elf_read_ecoff_info): Rename from
6112 mips_elf_read_ecoff_info and make globally visible.
6113 (mips_elf32_ecoff_debug_swap): Rename from
6114 mips_elf_ecoff_debug_swap.
6115 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Use asymbol rather than
6116 struct symbol_cache_entry.
6117 (_bfd_elf_validate_reloc): New function, moved in from
6118 elfcode.h:validate_reloc.
6119 * elfcode.h (validate_reloc): Remove; moved into elf.c and renamed
6120 to _bfd_elf_validate_reloc. Change all callers.
6121 * elf-bfd.h (bfd_section_from_shdr): Declare.
6122 (_bfd_elf_symbol_from_bfd_symbol): Declare.
6123 (_bfd_elf_validate_reloc): Declare.
6124 (_bfd_mips_elf_object_p): Declare.
6125 (_bfd_mips_elf_fake_sections): Declare.
6126 (_bfd_mips_elf_section_from_bfd_section): Declare.
6127 (_bfd_mips_elf_section_processing): Declare.
6128 (_bfd_mips_elf_symbol_processing): Declare.
6129 (_bfd_mips_elf_read_ecoff_info): Declare.
6130 (_bfd_mips_elf_final_write_processing): Declare.
6131 * elfxx-target.h (bfd_elfNN_get_reloc_upper_bound): Don't define
6132 if already defined.
6133
6134 * elf32-mips.c (mips_elf_object_p): Handle E_MIPS_ARCH_4.
6135 (mips_elf_final_write_processing): Likewise.
6136
6137 Wed May 29 16:15:29 1996 Ian Lance Taylor <ian@cygnus.com>
6138
6139 64-bit MIPS ELF ABI objdump support:
6140 * elf64-mips.c: New file.
6141 * Makefile.in: Rebuild dependencies.
6142 (BFD64_BACKENDS): Add elf64-mips.o.
6143 (BFD64_BACKENDS_CFILES): Add elf64-mips.c.
6144 * config.bfd (mips*el-*-elf*) Add bfd_elf64_bigmips_vec and
6145 bfd_elf64_littlemips_vec to targ_selvecs.
6146 (mips*-*-elf*): Likewise.
6147 * confingure.in: Add bfd_elf64_bigmips_vec and
6148 bfd_elf64_littlemips_vec to vector switch.
6149 * configure: Rebuild.
6150 * elf32-mips.c (_bfd_mips_elf_section_from_shdr): New function,
6151 broken out of mips_elf_section_from_shdr.
6152 (mips_elf32_section_from_shdr): Rename from
6153 mips_elf_section_from_shdr. Call new function.
6154 (elf_backend_section_from_shdr): Update name of renamed function.
6155 * elf-bfd.h (struct elf_size_info): Change second parameter of
6156 write_out_phdrs to be const. Likewise for second parameter of
6157 swap_symbol_out.
6158 (struct bfd_elf_section_data): Add rel_hdr2 field.
6159 (bfd_elf32_swap_symbol_in): Change second parameter to be const.
6160 (bfd_elf32_swap_symbol_out): Likewise.
6161 (bfd_elf32_swap_reloc_in): Likewise.
6162 (bfd_elf32_swap_reloc_out): Likewise.
6163 (bfd_elf32_swap_reloca_in): Likewise.
6164 (bfd_elf32_swap_reloca_out): Likewise.
6165 (bfd_elf32_swap_phdr_in): Likewise.
6166 (bfd_elf32_swap_phdr_out): Likewise.
6167 (bfd_elf32_swap_dyn_in): Likewise.
6168 (bfd_elf32_swap_dyn_out): Likewise.
6169 (bfd_elf32_slurp_symbol_table): Declare.
6170 (bfd_elf32_write_shdrs_and_ehdr): Declare.
6171 (bfd_elf32_write_out_phdrs): Declare.
6172 (bfd_elf64_swap_symbol_in): Change second parameter to be const.
6173 (bfd_elf64_swap_symbol_out): Likewise.
6174 (bfd_elf64_swap_reloc_in): Likewise.
6175 (bfd_elf64_swap_reloc_out): Likewise.
6176 (bfd_elf64_swap_reloca_in): Likewise.
6177 (bfd_elf64_swap_reloca_out): Likewise.
6178 (bfd_elf64_swap_phdr_in): Likewise.
6179 (bfd_elf64_swap_phdr_out): Likewise.
6180 (bfd_elf64_swap_dyn_in): Likewise.
6181 (bfd_elf64_swap_dyn_out): Likewise.
6182 (bfd_elf64_slurp_symbol_table): Declare.
6183 (bfd_elf64_write_shdrs_and_ehdr): Declare.
6184 (bfd_elf64_write_out_phdrs): Declare.
6185 (_bfd_mips_elf_section_from_shdr): Declare.
6186 * elf.c (bfd_section_from_shdr): Remove assertion requiring
6187 SHT_REL/SHT_RELA to match use_rela_p. If there is already a reloc
6188 section for the section, add the new one to rel_hdr2. Increment
6189 reloc_count rather than setting it.
6190 * elfcode.h (elf_slurp_symbol_table): Define name as macro.
6191 Remove static declaration.
6192 (elf_write_shdrs_and_ehdr): Define name as macro.
6193 (elf_write_out_phdrs): Likewise.
6194 (elf_swap_ehdr_in, elf_swap_ehdr_out): Declare.
6195 (elf_swap_shdr_in, elf_swap_shdr_out): Declare.
6196 (elf_swap_symbol_in): Change second parameter to be const.
6197 (elf_swap_symbol_out): Likewise.
6198 (elf_swap_ehdr_in, elf_swap_ehdr_out): Likewise.
6199 (elf_swap_shdr_in, elf_swap_shdr_out): Likewise.
6200 (elf_swap_phdr_in, elf_swap_phdr_out): Likewise.
6201 (elf_swap_reloc_in, elf_swap_reloc_out): Likewise.
6202 (elf_swap_reloca_in, elf_swap_reloca_out): Likewise.
6203 (elf_write_out_phdrs): Rename from write_out_phdrs. Change second
6204 parameter to be const. Make non-static.
6205 (elf_write_shdrs_and_ehdr): Rename from write_shdrs_and_ehdr.
6206 Make non-static.
6207 (elf_slurp_symbol_table): Make non-static.
6208 (NAME(_bfd_elf,size_info)): Update names of renamed functions.
6209 * elfxx-target.h (elf_info_to_howto): Define if not defined.
6210 (elf_backend_size_info): Likewise.
6211 (elfNN_bed): Use elf_backend_size_info.
6212 * targets.c (bfd_elf64_bigmips_vec): Declare.
6213 (bfd_elf64_littlemips_vec): Declare.
6214 (bfd_target_vector): Add bfd_elf64_bigmips_vec and
6215 bfd_elf64_littlemips_vec if BFD64 is defined.
6216
6217 * libbfd.c (bfd_get_file_window): Add cast to fprintf argument.
6218
6219 Tue May 28 11:42:08 1996 Ian Lance Taylor <ian@cygnus.com>
6220
6221 * coff-sh.c (sh_relax_delete_bytes): Insert nop instructions, not
6222 zeroes, in alignment holes.
6223
6224 * configure: Rebuild with autoconf 2.10.
6225
6226 * aoutx.h (NAME(aout,find_nearest_line)): Make room for the
6227 potential leading underscore in the allocated buffer.
6228
6229 Fri May 24 14:28:38 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6230
6231 * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not put small common
6232 symbols into .sbss if this is a relocatable link.
6233
6234 Thu May 23 12:26:24 1996 Ian Lance Taylor <ian@cygnus.com>
6235
6236 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Warn about
6237 undefined symbols when creating a shared library.
6238
6239 Fri May 17 13:54:15 1996 Ian Lance Taylor <ian@cygnus.com>
6240
6241 * coff-sh.c: Add a bunch of new code and static const arrays to
6242 support aligning loads and stores on four byte memory boundaries.
6243 Also:
6244 (sh_coff_howtos): Add entries for R_SH_CODE, R_SH_DATA and
6245 R_SH_LABEL.
6246 (sh_relax_section): Look for R_SH_CODE relocs. If we find one,
6247 call sh_align_loads.
6248 (sh_relax_delete_bytes): Don't mark R_SH_CODE or R_SH_DATA relocs
6249 as unused.
6250
6251 Thu May 16 16:34:13 1996 Ian Lance Taylor <ian@cygnus.com>
6252
6253 * cache.c (bfd_open_file): Unlink the file before opening it for
6254 write. From Marty Leisner <leisner@sdsp.mc.xerox.com>.
6255
6256 * opncls.c (bfd_fdopenr): Set opened_once.
6257
6258 Tue May 14 12:35:32 1996 Ian Lance Taylor <ian@cygnus.com>
6259
6260 * som.c (som_slurp_reloc_table): Clear external_relocs cache after
6261 freeing it.
6262
6263 * libbfd.c: Remove #ifdef FILE_OFFSET_IS_CHAR_INDEX, and compile
6264 the code unconditionally.
6265
6266 Mon May 13 19:51:37 1996 Ian Lance Taylor <ian@cygnus.com>
6267
6268 * libcoff-in.h (struct pei_section_tdata): Define structure.
6269 (pei_section_data): Define macro.
6270 * libcoff.h: Rebuild.
6271 * coffcode.h (coff_set_alignment_hook): If COFF_IMAGE_WITH_PE,
6272 store s_paddr field in pei_section_data.
6273 (coff_compute_section_file_positions): Use pei_section_data rather
6274 than _cooked_size, and don't overwrite an existing value.
6275 (coff_write_object_contents): If COFF_OBJ_WITH_PE, set s_paddr to
6276 0. If COFF_IMAGE_WITH_PE, set s_paddr to pei_section_data.
6277 * peicode.h (coff_bfd_copy_private_section_data): Define if
6278 COFF_IMAGE_WITH_PE.
6279 (pe_bfd_copy_private_section_data): New static function if
6280 COFF_IMAGE_WITH_PE.
6281
6282 Wed May 8 16:10:38 1996 Ian Lance Taylor <ian@cygnus.com>
6283
6284 * srec.c (srec_set_arch_mach): Write as a function rather than a
6285 macro definition.
6286
6287 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): If an archive has
6288 no map, just check each member in turn to see whether it is
6289 required.
6290
6291 Wed May 8 09:17:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6292
6293 * ppcboot.c (ppcboot_object_p): Check for type 0x41 in partition
6294 table. Call BFD_ASSERT to validate header size, instead of
6295 calling fatal.
6296 (ppcboot_bfd_print_private_bfd_data): Put quotes around partition
6297 name.
6298
6299 Tue May 7 16:10:19 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6300
6301 * ppcboot.c: New target for looking at PPCbug boot records.
6302
6303 * config{ure.in,.bfd}: Add support for ppcboot target.
6304 * targets.c: Ditto.
6305 * configure: Regenerate.
6306
6307 Tue May 7 11:15:19 1996 Jeffrey A Law (law@cygnus.com)
6308
6309 * coff-h8300.c (howto_table): Update names to match recent
6310 changes to include/coff/internal.h. Fix minor errors in the
6311 existing relocs. Add R_MOVL1 and R_MOVL2.
6312 (rtype2howto): Similarly.
6313 (h8300_reloc16_estimate): Rewrite to simplify, fix bugs in the
6314 existing relaxing code and peform more relaxing.
6315 (h8300_reloc16_extra_cases): Likewise.
6316
6317 Mon May 6 18:24:09 1996 Jeffrey A Law (law@cygnus.com)
6318
6319 * reloc16.c (bfd_coff_reloc16_get_value): Handle common
6320 symbols correctly.
6321
6322 Sat May 4 05:08:45 1996 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
6323
6324 * elfcode.h (elf_object_p): Reject generic ELF target if
6325 e_machine matches an alternate machine code in a specific backend.
6326
6327 * netbsd-core.c (netbsd_core_vec): Remove initializer for
6328 obsolete align_power_min field.
6329
6330 Fri May 3 13:07:35 1996 Jeffrey A Law (law@cygnus.com)
6331
6332 * coff-h8300.c (reloc_howto_type): Add howto entry for
6333 R_PCRWORD_B.
6334 (rtype2howto): Handle R_PCRWORD_B.
6335 (h8300_reloc16_extra_cases): Handle R_PCRWORD_B.
6336 (h8300_reloc_16_estimate): Likewise. Try to turn a 16bit
6337 pc-relative branch (R_PCRWORD) into an 8bit pc-relative
6338 branch (R_PCWORD_B).
6339
6340 Fri May 3 10:47:41 1996 Ian Lance Taylor <ian@cygnus.com>
6341
6342 * aoutx.h (translate_from_native_sym_flags): Set the section for
6343 BSF_CONSTRUCTOR symbols.
6344
6345 * cofflink.c (_bfd_coff_link_input_bfd): Correct setting of
6346 last_bf_index.
6347
6348 Wed May 1 18:39:32 1996 Doug Evans <dje@canuck.cygnus.com>
6349
6350 * coffcode.h (coff_write_object_contents): In comdat section lookup,
6351 stop looking when section is found.
6352
6353 Wed May 1 14:17:57 1996 Ian Lance Taylor <ian@cygnus.com>
6354
6355 * coffcode.h (STRING_SIZE_SIZE): Define.
6356 (styp_to_sec_flags): Handle long symbol names when looking for the
6357 section symbol.
6358 (bfd_coff_backend_data): Add _bfd_coff_long_section_names field.
6359 (bfd_coff_long_section_names): Define.
6360 (coff_write_object_contents): Handle long section names.
6361 (bfd_coff_std_swap_table): Initialize new field.
6362 * libcoff.h: Rebuild.
6363 * coffgen.c (make_a_section_from_file): Handle long section
6364 names.
6365 (coff_write_symbols): Handle long section names.
6366 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
6367 * coff-mips.c (mips_ecoff_backend_data): Likewise.
6368 * pe-arm.c (COFF_LONG_SECTION_NAMES): Define.
6369 * pei-arm.c (COFF_LONG_SECTION_NAMES): Define.
6370 * pe-i386.c (COFF_LONG_SECTION_NAMES): Define.
6371 * pei-i386.c (COFF_LONG_SECTION_NAMES): Define.
6372 * pe-ppc.c (COFF_LONG_SECTION_NAMES): Define.
6373 * pei-ppc.c (COFF_LONG_SECTION_NAMES): Define.
6374
6375 * bout.c (b_out_callback): Set lma of sections.
6376 (b_out_bfd_get_relocated_section_contents): Rename in_abfd
6377 parameter to output_bfd. Used input_bfd instead of output_bfd in
6378 several places.
6379
6380 Tue Apr 30 17:56:39 1996 Ian Lance Taylor <ian@cygnus.com>
6381
6382 * aoutx.h (translate_from_native_sym_flags): Don't create
6383 SEC_CONSTRUCTOR sections.
6384 * ecoff.c (ecoff_set_symbol_info): Likewise.
6385
6386 * elf32-mips.c (mips_elf_copy_private_bfd_data): Copy elf_gp.
6387 From Don Bowman <bowman@waterloo.hp.com>.
6388
6389 Tue Apr 30 17:06:32 1996 Doug Evans <dje@canuck.cygnus.com>
6390
6391 * coff-arm.c (armcoff_little_vec): If COFF_WITH_PE is defined, add
6392 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
6393
6394 Mon Apr 29 13:15:17 1996 Ian Lance Taylor <ian@cygnus.com>
6395
6396 * elf32-mips.c (struct mips_elf_link_hash_entry): Add
6397 mips_32_relocs field.
6398 (mips_elf_link_hash_newfunc): Initialize mips_32_relocs field.
6399 (mips_elf_relocate_section): Copy R_MIPS_REL32 and R_MIPS_32
6400 relocs against a global symbol which is not defined in a regular
6401 file.
6402 (mips_elf_check_relocs): For a R_MIPS_REL32 or R_MIPS_32 reloc
6403 against a global symbol, increment mips_32_relocs.
6404 (mips_elf_adjust_dynamic_symbol): If mips_32_relocs is set, and
6405 the symbol is not defined in a regular file, make room in the
6406 .rel.dyn section.
6407
6408 Fri Apr 26 18:00:37 1996 Ian Lance Taylor <ian@cygnus.com>
6409
6410 * ecoff.c (ecoff_compute_section_file_positions): Track the real
6411 file position and the virtual file position separately. Set
6412 filepos information bsaed on the real file position.
6413 (_bfd_ecoff_set_section_contents): Handle .lib sections like the
6414 Jan 23 change to coffcode.h.
6415
6416 * som.c (som_slurp_symbol_table): Set the symbol count to the
6417 number of BFD symbols created.
6418
6419 Fri Apr 26 12:34:29 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6420
6421 * elf32-ppc.c (ppc_elf_check_relocs): Forward relocations to the
6422 output file if linking shared objects. Loop to check all relocs,
6423 rather than returning false on first error.
6424
6425 Thu Apr 25 13:25:12 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6426
6427 * elf32-ppc.c (ppc_elf_create_linker_section): Add PLT case.
6428 (ppc_elf_additional_program_headers): If .interp section, bump #
6429 of program headers by 1.
6430 (ppc_elf_adjust_dynamic_symbol): Flesh out support.
6431 (ppc_elf_size_dynamic_sections): Add support for .plt section.
6432 (ppc_elf_check_relocs): Print out filename in debug code. Enable
6433 PLT support.
6434 (ppc_elf_finish_dynamic_symbol): Add support for PLT's, beef up
6435 debug output.
6436 (ppc_elf_relocate_section): If the output section isn't defined,
6437 don't abort, just give an error message.
6438
6439 * elflink.c (_bfd_elf_create_dynamic_sections): If the section
6440 being created is .sdata or .sdata2, don't make the symbol dynamic.
6441
6442 Wed Apr 24 14:04:07 1996 Ian Lance Taylor <ian@cygnus.com>
6443
6444 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through the
6445 members of an archive for dynamic objects with no symbols, and
6446 pass them directly to check_archive_element.
6447 (xcoff_link_check_ar_symbols): Pass dynamic objects to
6448 xcoff_link_check_dynamic_ar_symbols.
6449 (xcoff_link_check_dynamic_ar_symbols): New static function.
6450
6451 * coff-rs6000.c (rs6000coff_vec): Change BFD_JUMP_TABLE_DYNAMIC
6452 from _bfd_nodynamic to _bfd_xcoff.
6453 * libcoff-in.h (_bfd_xcoff_get_dynamic_symtab_upper_bound):
6454 Declare.
6455 (_bfd_xcoff_canonicalize_dynamic_symtab): Declare.
6456 (_bfd_xcoff_get_dynamic_reloc_upper_bound): Declare.
6457 (_bfd_xcoff_canonicalize_dynamic_reloc): Declare.
6458 * libcoff.h: Rebuild.
6459 * xcofflink.c (xcoff_swap_ldrel_in): New static function.
6460 (xcoff_get_section_contents): New static function.
6461 (_bfd_xcoff_get_dynamic_symtab_upper_bound): New function.
6462 (_bfd_xcoff_canonicalize_dynamic_symtab): New function.
6463 (_bfd_xcoff_get_dynamic_reloc_upper_bound): New function.
6464 (xcoff_dynamic_reloc): New static variable.
6465 (_bfd_xcoff_canonicalize_dynamic_reloc): New function.
6466 (xcoff_link_add_dynamic_symbols): Use xcoff_get_section_contents.
6467
6468 Tue Apr 23 12:48:42 1996 Ian Lance Taylor <ian@cygnus.com>
6469
6470 * coff-sparc.c (bfd_coff_generic_reloc): Return bfd_reloc_ok even
6471 if reloc_entry->addend is not 0.
6472 (CALC_ADDEND): Just set the addend to reloc.r_offset.
6473
6474 Mon Apr 22 18:29:01 1996 Doug Evans <dje@canuck.cygnus.com>
6475
6476 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Fix spelling of
6477 R_SPARC_GLOB_JMP.
6478 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
6479 Add entries for R_SPARC_[56].
6480 (sparc_reloc_map): Add entries for R_SPARC_[56].
6481
6482 Mon Apr 22 15:07:24 1996 Ian Lance Taylor <ian@cygnus.com>
6483
6484 Optimize linking of stabs in sections as used in ELF and COFF.
6485 * stabs.c: New file.
6486 * libbfd-in.h (_bfd_link_section_stabs): Declare.
6487 (_bfd_write_section_stabs): Declare.
6488 (_bfd_write_stab_strings): Declare.
6489 * libbfd.h: Rebuild.
6490 * libcoff-in.h (struct coff_section_tdata): Add stab_info field.
6491 (struct coff_link_hash_table): Add stab_info field.
6492 * libcoff.h: Rebuild.
6493 * cofflink.c (_bfd_coff_link_hash_table_init): Initialize
6494 stab_info field.
6495 (coff_link_add_symbols): Call _bfd_link_section_stabs if
6496 appropriate.
6497 (_bfd_coff_final_link): Write out stab strings hash table.
6498 (_bfd_coff_link_input_bfd): Handle optimized stabs sections.
6499 * coff-ppc.c (ppc_bfd_coff_final_link): Write out stab strings
6500 hash table.
6501 * elf-bfd.h (struct elf_link_hash_table): Add stab_info field.
6502 (struct bfd_elf_section_data): Add stab_info field.
6503 * elf.c (_bfd_elf_link_hash_table_init): Initialize stab_info
6504 field.
6505 * elflink.h (elf_link_add_object_symbols): If appropriate, call
6506 _bfd_link_section_stabs.
6507 (elf_bfd_final_link): Write out stab strings hash table.
6508 (elf_link_input_bfd): Handle optimized stabs sections.
6509 * reloc.c (_bfd_final_link_relocate): Check address against
6510 _raw_size rather than _cooked_size.
6511 * Makefile.in: Rebuild dependencies.
6512 (BFD_LIBS): Add stabs.o
6513 (BFD_LIBS_CFILES): Add stabs.c.
6514
6515 * VERSION: Increment for bfdlink.h change.
6516
6517 * coffgen.c (coff_renumber_symbols): Correct handling of
6518 BSF_NOT_AT_END common symbols.
6519
6520 Fri Apr 19 19:21:56 1996 Ian Lance Taylor <ian@cygnus.com>
6521
6522 * coff-ppc.c (record_toc): Add cast to avoid warning.
6523 (ppc_allocate_toc_section): Likewise.
6524 (coff_ppc_relocate_section): Remove ANSI C string concatenation.
6525 (ppc_coff_reloc_type_lookup): Remove unreached code.
6526 * coffcode.h (coff_write_object_contents): Don't take the address
6527 of an array.
6528 * peicode.h (pe_print_idata): Add casts to avoid warning.
6529 (pe_print_edata): Likewise.
6530 (pe_print_reloc): Remove ANSI C string concatenation.
6531
6532 Thu Apr 18 18:51:18 1996 Ian Lance Taylor <ian@cygnus.com>
6533
6534 * libcoff-in.h (struct coff_final_link_info): Add last_bf_index
6535 and last_bf fields.
6536 * libcoff.h: Rebuild.
6537 * coffswap.h (coff_swap_aux_in): Swap endndx field for C_FCN
6538 symbols.
6539 (coff_swap_aux_out): Likewise.
6540 * peicode.h (coff_swap_aux_in): Likewise.
6541 (coff_swap_aux_out): Likewise.
6542 * coffgen.c (coff_pointerize_aux): Check endndx field for C_FCN
6543 symbols.
6544 * cofflink.c (_bfd_coff_final_link): Initialize last_bf_index
6545 field.
6546 (_bfd_coff_link_input_bfd): Check endndx field for C_FCN symbols.
6547 Fix up .bf endndx link fields.
6548 * coff-ppc.c (ppc_bfd_coff_final_link): Initialize last_bf_index
6549 field.
6550 * xcofflink.c (xcoff_link_input_bfd): Check endndx field for C_FCN
6551 symbols.
6552
6553 Wed Apr 17 12:08:24 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6554
6555 * pe{,i}-ppc.c (PPC_PE): Define instead of PPC, so that compiling
6556 on Solaris PowerPC systems doesn't get confused.
6557
6558 * ccffcode.h (coff_write_object_contents): Use #ifdef PPC_PE, not
6559 #ifdef PPC.
6560
6561 * elfcore.h (bfd_prstatus, bfd_fpregset): Add thread argument.
6562 (elf_corefile_note): If HAVE_SYS_PROCFS_H is not defined, don't
6563 update did_reg and did_reg2.
6564
6565 Wed Apr 17 13:07:37 1996 Ian Lance Taylor <ian@cygnus.com>
6566
6567 * xcofflink.c (xcoff_link_input_bfd): Check for TOC overflow.
6568
6569 * linker.c (_bfd_generic_link_add_one_symbol): When calling the
6570 callback routines, pass h->root.string rather than name, in case
6571 copy is true and name is transient.
6572
6573 Tue Apr 16 16:36:38 1996 Stu Grossman (grossman@lisa.cygnus.com)
6574
6575 * elfcore.h: Add support for core files with multiple threads.
6576 (Primarily for Solaris.)
6577
6578 Tue Apr 16 13:44:08 1996 Ian Lance Taylor <ian@cygnus.com>
6579
6580 * aoutx.h (NAME(aout,squirt_out_relocs)): Don't do anything if
6581 section->orelocation is NULL.
6582
6583 * coffgen.c (bfd_coff_get_syment): New function.
6584 (bfd_coff_get_auxent): New function.
6585 * bfd-in.h (bfd_coff_get_syment): Declare.
6586 (bfd_coff_get_auxent): Declare.
6587 * bfd-in2.h: Rebuild.
6588
6589 Mon Apr 15 19:06:59 1996 Ian Lance Taylor <ian@cygnus.com>
6590
6591 * elf32-mips.c (struct mips_hi16): Define.
6592 (mips_hi16_addr, mips_hi16_addend): Remove.
6593 (mips_hi16_list): New static variable.
6594 (mips_elf_hi16_reloc): Maintain a list of unmatched HI16 relocs.
6595 (mips_elf_lo16_reloc): Process mips_hi16_list.
6596 (mips_elf_relocate_section): Permit an arbitrary number of HI16
6597 relocs before the associated LO16 reloc.
6598
6599 Wed Apr 10 00:23:53 1996 Ian Lance Taylor <ian@cygnus.com>
6600
6601 * versados.c (versados_scan): Check bfd_alloc return value.
6602 (versados_object_p): Check all bfd_read return values. Require
6603 that lang field be less than 10, to avoid confusion with Intel Hex
6604 files.
6605
6606 * libaout.h (WRITE_HEADERS): Write out the relocs even if there
6607 aren't any symbols.
6608 * aoutx.h (NAME(aout,swap_std_reloc_out)): Set r_index to N_ABS,
6609 not 0, for an absolute symbol.
6610 (NAME(aout,swap_ext_reloc_out)): Likewise.
6611
6612 * ihex.c (ihex_scan): Accept a length of 4 for record type 5.
6613 (ihex_write_object_contents): For a large start address, output
6614 the full 32 bit address in record type 5.
6615
6616 * ieee.c (ieee_write_byte): Change second parameter from bfd_byte
6617 to int to avoid promotion problems in prototype.
6618
6619 Tue Apr 9 11:44:21 1996 Ian Lance Taylor <ian@cygnus.com>
6620
6621 * configure.host: Use ${srcdir} when looking for picfrag.
6622
6623 * configure.host: Switch on ${libdir}, not $(libdir). From
6624 alan@spri.levels.unisa.edu.au (Alan Modra).
6625
6626 * aoutx.h (aout_link_add_symbols): Always call add_dynamic_symbols
6627 entry point, not just for DYNAMIC objects.
6628 * sunos.c (sunos_add_dynamic_symbols): Always call
6629 sunos_create_dynamic_sections. If called with a non DYNAMIC
6630 object, don't do anything else.
6631 (sunos_add_one_symbol): Don't call sunos_create_dynamic_sections.
6632
6633 Mon Apr 8 12:09:36 1996 Ian Lance Taylor <ian@cygnus.com>
6634
6635 * configure.in: Permit --enable-shared to specify a list of
6636 directories.
6637 * configure: Rebuild.
6638
6639 * configure.host: Set HLDFLAGS and SHLIB_CFLAGS for *-dec-osf*
6640 host when configuring with --enable-shard.
6641
6642 Fri Apr 5 12:24:13 1996 Ian Lance Taylor <ian@cygnus.com>
6643
6644 * config.bfd: Add i[345]86-*-freebsdelf* target; from John Polstra
6645 <jdp@polstra.com>.
6646
6647 * linker.c (link_action): For WARN_ROW/warn, use MWARN, not CYCLE,
6648 to avoid crashing in bfd_hash_replace.
6649
6650 * sysdep.h: Use #ifdef, not #if.
6651
6652 Thu Apr 4 23:32:23 1996 Ian Lance Taylor <ian@cygnus.com>
6653
6654 * config.in: Rebuild.
6655
6656 Thu Apr 4 18:49:09 1996 Fred Fish <fnf@cygnus.com>
6657
6658 * configure.in (mips-sony-bsd*): Fix typo in AC_DEFINE.
6659 (AC_CHECK_HEADERS): Check for sys/time.h
6660 (AC_HEADER_TIME): Add macro.
6661 * configure: Rebuild.
6662 * sysdep.h: Use TIME_WITH_SYS_TIME and HAVE_SYS_TIME_H
6663 to control what combination of <time> and <sys/time.h>
6664 get included.
6665
6666 Tue Apr 2 13:11:53 1996 Doug Evans <dje@canuck.cygnus.com>
6667
6668 * aoutf1.h (sunos_32_set_arch_mach): Handle M_SPARCLET.
6669 (aout_32_sunos4_write_object_contents): Likewise.
6670 * aoutx.h (NAME(aout,machine_type)): Handle
6671 bfd_mach_sparc_{sparclet,sparclite}.
6672 * archures.c (bfd_mach_sparc_{sparclet,sparclite}): Define.
6673 (bfd_mach_sparc_v9_p): Update.
6674 * cpu-sparc.c (arch_info_struct): Add entries for sparclet,sparclite.
6675 * libaout.h (enum machine_type): Add M_SPARCLET.
6676 * sunos.c (MACHTYPE_OK): Define.
6677 * bfd-in2.h: Regenerated.
6678
6679 Tue Apr 2 00:33:18 1996 Ian Lance Taylor <ian@cygnus.com>
6680
6681 * elf-bfd.h (struct elf_link_hash_table): Add hgot field.
6682 * elf.c (_bfd_elf_link_hash_table_init): Initialize hgot field.
6683 * elflink.c (_bfd_elf_create_got_section): Store the
6684 _GLOBAL_OFFSET_TABLE_ hash table entry in the hgot field.
6685 * elf32-sparc.c (elf32_sparc_check_relocs): If the size of the
6686 global offset table goes over 0x1000, set the value of
6687 _GLOBAL_OFFSET_TABLE_ to 0x1000 into the section.
6688 (elf32_sparc_relocate_section): Subtract the offset of
6689 _GLOBAL_OFFSET_TABLE_ when handling GOT relocations.
6690
6691 * elfcode.h: Don't include <string.h>.
6692
6693 Mon Apr 1 10:39:24 1996 Jeffrey A Law (law@cygnus.com)
6694
6695 * linker.c (_bfd_generic_link_hash_newfunc): Renamed from
6696 generic_link_hash_newfunc. All references changed.
6697 * genlink.h (_bfd_generic_link_hash_newfunc): Declaration
6698 moved here from libbfd-in.h.
6699 * libbfd-in.h: Corresponding changes.
6700 * libbfd.h: Regenerated.
6701
6702 Mon Apr 1 12:35:36 1996 Ian Lance Taylor <ian@cygnus.com>
6703
6704 * aoutx.h (aout_link_input_section_std): When reporting an
6705 overflow error, use the name of the symbol in the hash table if
6706 available.
6707 (aout_link_input_section_ext): Likewise.
6708
6709 * elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
6710 defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
6711
6712 Sun Mar 31 01:58:41 1996 steve chamberlain <sac@slash.cygnus.com>
6713
6714 * peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
6715 * coffcode.h (coff_compute_section_file_positions): Likewise.
6716 (coff_write_object_contents): Likewise.
6717
6718 Fri Mar 29 12:44:36 1996 Ian Lance Taylor <ian@cygnus.com>
6719
6720 * section.c (SEC_LINK_ONCE): Define.
6721 (SEC_LINK_DUPLICATES): Define.
6722 (SEC_LINK_DUPLICATES_DISCARD): Define.
6723 (SEC_LINK_DUPLICATES_ONE_ONLY): Define.
6724 (SEC_LINK_DUPLICATES_SAME_SIZE): Define.
6725 (SEC_LINK_DUPLICATES_SAME_CONTENTS): Define.
6726 * bfd-in2.h: Rebuild.
6727 * coffcode.h (sec_to_styp_flags): If COFF_WITH_PE, turn
6728 SEC_LINK_ONCE into IMAGE_SCN_LNK_COMDAT.
6729 (styp_to_sec_flags): If COFF_WITH_PE, turn IMAGE_SCN_LNK_REMOVE
6730 into SEC_EXCLUDE. If IMAGE_SCN_LNK_COMDAT is set, set
6731 SEC_LINK_ONCE, and look through the symbol table for the setting
6732 for SEC_LINK_DUPLICATES.
6733 (coff_write_object_contents): If COFF_WITH_PE, if SEC_LINK_ONCE is
6734 set for a section, find the section symbol in the symbol table,
6735 and set the aux entry based on SEC_LINK_DUPLICATES.
6736 * coffgen.c (coff_print_symbol): Add a space before "checksum".
6737 * coff-arm.c (armcoff_big_vec): If COFF_WITH_PE is defined, add
6738 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
6739 * coff-i386.c (i386coff_vec): Likewise.
6740 * coff-ppc.c (TARGET_LITTLE_SYM, TARGET_BIG_SYM): Likewise.
6741
6742 * VERSION: Bump to 2.6.1.
6743 * Makefile.in (stamp-h): Depend upon VERSION.
6744
6745 Thu Mar 28 23:48:49 1996 Jeffrey A Law (law@cygnus.com)
6746
6747 * libbfd-in.h (generic_link_hash_newfunc): Add declaration.
6748 * libbfd.h: Rebuilt.
6749 * linker.c (generic_link_hash_newfunc): No longer static.
6750 * coffcode.h (coff_bfd_link_hash_create): Allow specific targets
6751 to override.
6752 * coff-h8300.c: Add two derived hash tables and their associated
6753 funtions and #defines for use by the h8300 linker.
6754 (h8300_reloc16_extra_cases, case R_MEM_INDIRECT): Create entries in
6755 the function vector as needed. Place the address of the function
6756 vector entry in the location specified by the R_MEM_INDIRECT reloc.
6757 Rewrite the vectors section contents as necessary.
6758 (h8300_bfd_link_add_symbols): New function for the h8300 linker.
6759 (coff_bfd_link_add_symbols): Define to use h8300 specific version.
6760 (coff_bfd_link_hash_table_create): Likewise.
6761
6762 Thu Mar 28 17:44:08 1996 Ian Lance Taylor <ian@cygnus.com>
6763
6764 * libhppa.h: If gcc 2.7 or higher, declare all the functions with
6765 __attribute__ ((__unused__)) so that -Wall doesn't warn about
6766 them.
6767 (hppa_rebuild_insn): Pass pointer to correct type to
6768 low_sign_unext and dis_assemble_21.
6769
6770 Thu Mar 28 11:00:36 1996 Doug Evans <dje@canuck.cygnus.com>
6771
6772 * config.bfd (sparc64-{sysv4*,solaris2*}): Delete.
6773 Stick with sparc-*-{sysv4*,solaris2*}.
6774
6775 Wed Mar 27 10:43:34 1996 Ian Lance Taylor <ian@cygnus.com>
6776
6777 * peicode.h (coff_swap_aux_in): Swap in extra PE x_scn fields.
6778 (coff_swap_aux_out): Swap out extra PE x_scn fields.
6779 * coffswap.h (coff_swap_aux_in): Zero out extra PE x_scn fields.
6780 * coffgen.c (coff_print_symbol): If any of the extra PE x_scn
6781 fields is non-zero, print them.
6782
6783 * coff-ppc.c (ppc_record_toc_entry): Put inside COFF_IMAGE_WITH_PE
6784 ifdef. Remove unused variables.
6785 (ppc_record_data_in_toc_entry): Ifdef out. Removed unused
6786 variables.
6787 (ppc_mark_symbol_as_glue): Put inside COFF_IMAGE_WITH_PE ifdef.
6788 (get_symbol_value): Ifdef out.
6789 (pe_ppc_reloc): Ifdef out. Remove unused variables.
6790 (coff_ppc_relocate_section): Remove unused variables. Make
6791 fprintf strings and argument types correspond. Put before_addr in
6792 DEBUG_RELOC ifdef.
6793 (dump_toc): Make fprintf strings and argument types correspond.
6794 (ppc_process_before_allocation): Remove unused variables. Always
6795 return a value.
6796 (ppc_reflo_reloc): Ifdef out.
6797 (ppc_addr32nb_reloc): Ifdef out.
6798 (ppc_coff_rtype2howto): Make fprintf strings and argument types
6799 correspond.
6800 (coff_ppc_rtype_to_howto): Likewise.
6801 (ppc_coff_swap_sym_in_hook): Remove unused variables.
6802
6803 * peicode.h (pe_print_idata): Move otherwise unused variables into
6804 the #ifdef where they are used. Always return a value.
6805 (pe_print_edata): Make fprintf strings and argument types
6806 correspond. Always return a value.
6807 (pe_print_pdata): Removed unused variable addr_value. Always
6808 return a value.
6809 (pe_print_reloc): Remove unused variable onaline. Make fprintf
6810 strings and argument types correspond. Always return a value.
6811
6812 * elf32-ppc.c (ppc_elf_fake_sections): Return true.
6813 (ppc_elf_finish_dynamic_symbol): Move definition of unused
6814 variable rela inside #if 0 section where it is used.
6815
6816 * ns32k.h: New file.
6817 * cpu-ns32k.h: Include ns32k.h. Rename externally visible
6818 functions to start with _bfd_.
6819 * aout-ns32k.c: Include ns32k.h. Change references to renamed
6820 functions in cpu-ns32k.h.
6821 * Makefile.in: Rebuild dependencies.
6822 (HFILES): Add ns32k.h.
6823
6824 * section.c (struct sec): Add linker_mark field. Change
6825 user_set_vma and reloc_done to be single bit fields.
6826 (STD_SECTION): Update accordingly.
6827 * bfd-in2.h: Rebuild.
6828 * aoutx.h (NAME(aout,final_link)): Mark sections included in the
6829 link.
6830 (aout_link_input_bfd): Don't link unmarked sections.
6831 * cofflink.c (_bfd_coff_final_link): Mark sections included in the
6832 link.
6833 (_bfd_coff_link_input_bfd): Don't link unmarked sections.
6834 * coff-ppc.c (ppc_bfd_coff_final_link): Mark sections included in
6835 the link.
6836 * elflink.h (elf_bfd_final_link): Mark sections included in the
6837 link.
6838 (elf_link_input_bfd): Don't link unmarked sections.
6839 * xcofflink.c (_bfd_xcoff_bfd_final_link): Mark sections included
6840 in the link.
6841 (xcoff_link_input_bfd): Don't link unmarked sections.
6842
6843 * coffswap.h (coff_swap_scnhdr_out): Include section name in
6844 overflow error messages.
6845
6846 Tue Mar 26 15:46:18 1996 Ian Lance Taylor <ian@cygnus.com>
6847
6848 * bfd.c (_bfd_default_error_handler): If _bfd_error_program_name
6849 is not set, print "BFD: " before the error message.
6850
6851 * configure.in: Use AC_CHECK_TOOL to find ar and ranlib. From
6852 Miles Bader <miles@gnu.ai.mit.edu>.
6853 * configure: Rebuild.
6854
6855 Fri Mar 22 12:17:00 1996 Ian Lance Taylor <ian@cygnus.com>
6856
6857 * xcofflink.c (xcoff_link_input_bfd): Fix scan for C_BINCL/C_EINCL
6858 symbols.
6859
6860 * config.bfd: Add ieee_vec to targ_selvecs for i960 targets and
6861 m68k-aout, m68k-coff, and m68k-elf targets.
6862
6863 Fri Mar 22 11:33:44 1996 Martin Anantharaman <martin@goofy.imech.uni-duisburg.de>
6864
6865 * ieee.c: Changed #ifdef KEEPMINUSPCININST to #if KEEPMINUSPCININST.
6866 (ieee_generic_stat_arch_elt): Restructured to prevent
6867 ieee_object_p from being called repeatedly.
6868
6869 Thu Mar 21 11:00:47 1996 steve chamberlain <sac@slash.cygnus.com>
6870
6871 * coffcode.h (coff_write_object_contents): Allocate
6872 buffers large enough for any FILEHDR or AOUTHDR.
6873
6874 Thu Mar 21 16:28:17 1996 David Mosberger-Tang <davidm@azstarnet.com>
6875
6876 * ecofflink.c (lookup_line): New static function, renamed and
6877 slighly changed from old _bfd_ecoff_locate_line.
6878 (_bfd_ecoff_locate_line): Cache line number information. Use
6879 lookup_line for actual lookup.
6880
6881 Thu Mar 21 14:59:11 1996 Michael Meissner <meissner@tiktok.cygnus.com>
6882
6883 * peicode.h (pe_print_pdata): Warn if the .pdata section is not a
6884 multiple of 20 bytes.
6885
6886 Thu Mar 21 13:54:40 1996 Ian Lance Taylor <ian@cygnus.com>
6887
6888 * ecoff.c (_bfd_ecoff_find_nearest_line): Use bfd_zalloc to
6889 allocate ecoff_find_line, and don't initialize by hand.
6890 * elf32-mips.c (mips_elf_find_nearest_line): Use bfd_zalloc for
6891 mips_elf_find_line, and don't call memset.
6892
6893 * coffcode.h (coff_compute_section_file_positions): If not
6894 producing a final executable, don't consider sofar when aligning
6895 the section to the correct size.
6896
6897 Wed Mar 20 16:53:12 1996 Ian Lance Taylor <ian@cygnus.com>
6898
6899 * coffcode.h (coff_add_missing_symbols): Ifdef out.
6900 (coff_write_object_contents): Don't call coff_add_missing_symbols.
6901 * coffgen.c (coff_section_symbol): Ifdef out.
6902
6903 Mon Mar 18 12:54:41 1996 Ian Lance Taylor <ian@cygnus.com>
6904
6905 * elf32-mips.c (mips_elf_gprel32_reloc): Initialize gp if
6906 output_bfd is not NULL.
6907
6908 Thu Mar 14 17:12:06 1996 Doug Evans <dje@charmed.cygnus.com>
6909
6910 * coffgen.c (coff_get_normalized_symtab): Call bfd_zalloc instead
6911 of bfd_alloc (fixes fix_line not being initialized).
6912 Delete zeroing of fix_{value,tag,end,scnlen} fields.
6913
6914 Thu Mar 14 16:06:06 1996 Jeffrey A Law (law@cygnus.com)
6915
6916 * coffcode.h: Allow specific backends to override the
6917 bfd_link_add_symbols routine.
6918
6919 * coff-h8300.c: Include genlink.h.
6920 (howto_table): Add R_MEM_INDIRECT.
6921 (rtype2howto): Support R_MEM_INDIRECT.
6922 (h8300_reloc16_extra_cases): Handle R_MEM_INDIRECT like R_RELBYTE
6923 for now.
6924
6925 Tue Mar 12 12:41:17 1996 David Mosberger-Tang <davidm@koala.azstarnet.com>
6926
6927 * coff-alpha.c (alpha_relocate_section): Use
6928 info->callbacks_warning, rather than _bfd_error_handler, for
6929 "multiple gp" warning.
6930
6931 Tue Mar 12 12:10:55 1996 Ian Lance Taylor <ian@cygnus.com>
6932
6933 * linker.c (bfd_wrapped_link_hash_lookup): New function.
6934 (_bfd_generic_link_add_one_symbol): Remove BFD_ASSERT on hash
6935 table string. Use bfd_wrapped_link_hash_lookup.
6936 (_bfd_generic_link_write_global_symbol): Remove BFD_ASSERT on hash
6937 table string.
6938 * aoutx.h (aout_link_write_symbols): Use the name from the hash
6939 table, if any, when writing out symbols.
6940 (aout_link_input_section_std): Use the name from the hash table,
6941 if any, when reporting undefined symbols.
6942 (aout_link_input_section_ext): Likewise.
6943 (aout_link_reloc_link_order): Use bfd_wrapped_link_hash_lookup.
6944 * bout.c (get_value): Likewise.
6945 * cofflink.c (_bfd_coff_reloc_link_order): Likewise.
6946 * ecoff.c (ecoff_reloc_link_order): Likewise.
6947 * elflink.h (elf_link_add_object_symbols): Likewise.
6948 (elf_reloc_link_order): Likewise.
6949 * linker.c (_bfd_generic_link_output_symbols): Likewise.
6950 (_bfd_generic_reloc_link_order): Likewise.
6951 (default_indirect_link_order): Likewise.
6952 * reloc16.c (bfd_coff_reloc16_get_value): Likewise.
6953 * sunos.c (sunos_add_one_symbol): Likewise.
6954 * xcofflink.c (xcoff_link_add_symbols): Likewise.
6955 (bfd_xcoff_link_count_reloc): Likewise.
6956 (xcoff_reloc_link_order): Likewise.
6957
6958 * ecoffswap.h (ecoff_swap_fdr_in): If ECOFF_64, turn 0xffffffff
6959 into -1 for intern->rss.
6960
6961 * configure: Rebuild with autoconf 2.8.
6962
6963 Mon Mar 11 12:28:31 1996 Ian Lance Taylor <ian@cygnus.com>
6964
6965 * stab-syms.c (__define_stab_duplicate): Define.
6966 (bfd_get_stab_name): Rename from aout_stab_name. Rewrite to use a
6967 switch.
6968 * bfd-in.h (bfd_get_stab_name): Declare.
6969 * bfd-in2.h: Rebuild.
6970 * Makefile.in: Rebuild dependencies.
6971 (BFD_LIBS): Add stab-syms.o.
6972 (BFD_LIBS_CFILES): Add stab-syms.c.
6973 (BFD32_BACKENDS): Remove stab-syms.o.
6974 (BFD32_BACKENDS_CFILES): Remove stab-syms.c.
6975 * configure.in: Don't list stab-syms.o in bfd_backends.
6976 * configure: Rebuild.
6977 * libaout.h (aout_stab_name): Don't declare.
6978 * aoutx.h (NAME(aout,get_symbol_info)): Call bfd_get_stab_name,
6979 not aout_stab_name.
6980
6981 Fri Mar 8 11:26:20 1996 Ian Lance Taylor <ian@cygnus.com>
6982
6983 * elf.c (assign_file_positions_for_segments): Adjust file offset
6984 for section alignment even if SEC_LOAD is not set.
6985
6986 Tue Mar 5 12:02:23 1996 Ian Lance Taylor <ian@cygnus.com>
6987
6988 * configure.in: Don't set SHLIB or SHLINK to an empty string,
6989 since they appear as targets in Makefile.in.
6990 * configure: Rebuild.
6991
6992 * sunos.c (sunos_scan_ext_relocs): If not making a shared library,
6993 don't fiddle with a symbol which is not defined anywhere.
6994
6995 Mon Mar 4 12:49:16 1996 Ian Lance Taylor <ian@cygnus.com>
6996
6997 * xcofflink.c (xcoff_mark): Treat undefined imported symbols as
6998 though they are defined in a shared library.
6999 (xcoff_build_ldsyms): Likewise.
7000
7001 * coffgen.c (coff_find_nearest_line): Don't look at the line
7002 numbers for the section if section->lineno is NULL.
7003
7004 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Print a useful error
7005 message rather than calling BFD_ASSERT.
7006 * elfcode.h (write_relocs): Check return value of
7007 _bfd_elf_symbol_from_bfd_symbol.
7008
7009 Fri Mar 1 09:42:59 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7010
7011 * elf32-ppc.c (ppc_elf_add_symbol_hook): Don't set SEC_LOAD flag
7012 for .sbss section.
7013
7014 Wed Feb 28 11:25:47 1996 Jeffrey A Law (law@cygnus.com)
7015
7016 * libhppa.h (hppa_reloc_field_selector_type): Add R_HPPA_NLSEL
7017 and R_HPPA_NLRSEL.
7018 (e_nsel, e_nlsel, e_nlrsel): Undefine. Add to
7019 hppa_reloc_field_selector_type_alt.
7020 (hppa_field_adjust): Handle e_nlsel, e_nlrsel. Fix e_nsel handling.
7021 * som.c (hppa_som_gen_reloc_type): Handle N', NL' NLR' field
7022 selectors.
7023 (som_write_fixups): Finish handling of R_N0SEL and R_N1SEL.
7024
7025 Wed Feb 28 11:00:24 1996 Ian Lance Taylor <ian@cygnus.com>
7026
7027 * elf.c (assign_file_positions_for_segments): Adjust the segment
7028 memory size for the alignment of a SEC_ALLOC section, not just a
7029 SEC_LOAD section.
7030
7031 Tue Feb 27 14:17:31 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
7032
7033 * m68klinux.c: New file.
7034 * hosts/m68klinux.h: New file.
7035 * config.bfd (m68*-*-linuxaout*, m68*-*-linux*): New targets.
7036 * configure.in (m68*-*-linux*): New native host.
7037 (m68klinux_vec): New vector.
7038 * configure: Rebuild.
7039 * targets.c (m68klinux_vec): Declare.
7040 * i386linux.c (bfd_i386linux_size_dynamic_sections): Renamed from
7041 bfd_linux_size_dynmic_sections to avoid clash with m68klinux.c.
7042 * bfd-in.h (bfd_i386linux_size_dynamic_sections): Rename
7043 declaration from bfd_linux_size_dynamic_sections.
7044 (bfd_m68klinux_size_dynamic_sections): Declare.
7045 * bfd-in2.h: Rebuild.
7046 * Makefile.in: Rebuild dependencies.
7047 (BFD32_BACKENDS): Add m68klinux.o.
7048 (BFD32_BACKENDS_CFILES): Add m68klinux.c.
7049
7050 Tue Feb 27 11:31:34 1996 Jeffrey A Law (law@cygnus.com)
7051
7052 * libhppa.h (pa_arch): Add pa20.
7053 (hppa_reloc_field_selector_type): Add R_HPPA_NSEL.
7054 (e_nsel): Undefine. Add to hppa_reloc_field_selector_type_alt.
7055 (hppa_field_adjust): Handle e_nsel.
7056 * som.c: Provide default definitions for many new relocs found only
7057 in hpux10 include files.
7058 (som_fixup_formats): Add several new relocs from hpux10.
7059 (som_hppa_howto_table): Add hpux10 relocs.
7060 (som_write_fixups): Handle R_N0SEL and R_N1SEL hpux10 relocs.
7061
7062 Mon Feb 26 12:52:48 1996 Stan Shebs <shebs@andros.cygnus.com>
7063
7064 * mpw-make.sed: Edit out recent shared library support, and
7065 rules to rebuild .h files using doc/chew.
7066
7067 Mon Feb 26 14:48:39 1996 David Mosberger-Tang <davidm@AZStarNet.com>
7068
7069 * ecoff.c (ecoff_compute_section_file_positions): Adjust the file
7070 size even of sections with no contents.
7071
7072 Mon Feb 26 14:01:13 1996 Ian Lance Taylor <ian@cygnus.com>
7073
7074 * cofflink.c (_bfd_coff_link_input_bfd): When merging, skip names
7075 starting with '$' the way we skip names starting with '.'. When
7076 updating x_endndx, don't be fooled by an index which has been
7077 merged.
7078
7079 * cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
7080 struct/union/enum type with no elements.
7081
7082 Sat Feb 24 11:38:58 1996 Ian Lance Taylor <ian@cygnus.com>
7083
7084 * bfd.c (bfd_errmsg): Handle a NULL return from strerror.
7085
7086 * archive.c (bfd_generic_archive_p): If the first file in the
7087 archive can not be recognized as an object, don't assume that this
7088 is the wrong format.
7089
7090 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
7091 format is not bfd_object.
7092 (bfd_elf_get_dt_soname): Likewise.
7093
7094 Wed Feb 21 13:58:04 1996 Ian Lance Taylor <ian@cygnus.com>
7095
7096 * coff-sh.c (sh_relax_delete_bytes): Correct range of R_SH_USES
7097 reloc.
7098
7099 Tue Feb 20 16:22:44 1996 J.T. Conklin <jtc@rtl.cygnus.com>
7100
7101 * bfd.c (tdata): Add netbsd_core_data.
7102 * bfd-in2.h: Regenerated.
7103
7104 Tue Feb 20 16:50:02 1996 Ian Lance Taylor <ian@cygnus.com>
7105
7106 * sunos.c (SUNOS_CONSTRUCTOR): Define.
7107 (sunos_add_one_symbol): Don't let a symbol from a dynamic object
7108 override a constructor symbol. Set SUNOS_CONSTRUCTOR when
7109 appropriate.
7110
7111 * bout.c (b_out_squirt_out_relocs): Use udata.i rather than flags
7112 to get the symbol index, matching 14 Jul 95 change.
7113
7114 Tue Feb 20 08:26:27 1996 Fred Fish <fnf@phydeaux.cygnus.com>
7115
7116 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents):
7117 Remove duplicate definition of gp.
7118
7119 Mon Feb 19 12:37:41 1996 Ian Lance Taylor <ian@cygnus.com>
7120
7121 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Don't
7122 assume that we can set the GP value and then get the same value,
7123 since it won't be true if the output file is neither ELF nor
7124 ECOFF.
7125 * coff-mips.c (mips_adjust_reloc_in): Don't bother to use
7126 _bfd_get_gp_value here.
7127 (mips_gprel_reloc): Don't assume we can set and get the GP value.
7128 * elf32-mips.c (mips_elf_hi16_reloc): Get gp value from
7129 mips_elf_final_gp.
7130 (mips_elf_lo16_reloc): Likewise.
7131 (mips_elf_final_gp): Add pgp parameter. Set it to the GP value.
7132 Don't require that the BFD be ELF.
7133 (mips_elf_gprel16_reloc): Get gp value from mips_elf_final_gp.
7134 (mips_elf_gprel32_reloc): Likewise.
7135 (mips_elf_relocate_section): Don't assume we can set and get the
7136 GP value.
7137 (mips_elf_finish_dynamic_symbol): Don't bother to use
7138 _bfd_get_gp_value here.
7139
7140 * elf32-mips.c (mips_elf_create_procedure_table): Initialize sv.
7141 Don't change epdr between malloc and free. Be careful not to free
7142 NULL pointers. Zero out the first RPDR.
7143
7144 * configure.host: On Linux, only pass -rpath option if $(libdir)
7145 is neither /lib nor /usr/lib. From Alan Modra
7146 <alan@mullet.Levels.UniSA.Edu.Au>.
7147
7148 * elf-bfd.h (struct elf_obj_tdata): Rename dt_needed_name to
7149 dt_name.
7150 (elf_dt_name): Rename from elf_dt_needed_name.
7151 * elf.c (bfd_elf_set_dt_needed_name): Use elf_dt_name, not
7152 elf_dt_needed_name.
7153 (bfd_elf_get_dt_soname): New function.
7154 * elflink.h (elf_link_add_object_symbols): Use elf_dt_name, not
7155 elf_dt_needed_name. Save the SONAME back in elf_dt_name.
7156 * bfd-in.h (bfd_elf_get_dt_soname): Declare.
7157 * bfd-in2.h: Rebuild.
7158
7159 Mon Feb 19 02:50:23 1996 Doug Evans <dje@charmed.cygnus.com>
7160
7161 * elf32-sparc.c (elf32_sparc_reloc_type_lookup): Renamed from
7162 _bfd_sparc_elf_reloc_type_lookup.
7163 (bfd_elf32_bfd_reloc_type_lookup): Update.
7164 * elf64-sparc.c (SPARC64_OLD_RELOCS): Define.
7165 (sparc64_elf_howto_table): Define.
7166 (sparc_reloc_map): Define.
7167 (sparc64_elf_reloc_type_lookup): New function.
7168 (sparc_elf_wdisp16_reloc): New function.
7169 (elf_info_to_howto): Use sparc64_elf_howto_table.
7170 (sparc64_elf_relocate_section): Likewise.
7171 (bfd_elf64_bfd_reloc_type_lookup): Update.
7172
7173 Sun Feb 18 15:02:25 1996 Ian Lance Taylor <ian@cygnus.com>
7174
7175 * configure.host: Check for 'do not mix' from native linker before
7176 trying to use -rpath.
7177
7178 Fri Feb 16 12:46:18 1996 Ian Lance Taylor <ian@cygnus.com>
7179
7180 * bfd.c (_bfd_get_gp_value): New function.
7181 (_bfd_set_gp_value): New function.
7182 * libbfd-in.h (_bfd_get_gp_value): Declare.
7183 (_bfd_set_gp_value): Declare.
7184 * libbfd.h: Rebuild.
7185 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
7186 _bfd_get_gp_value and _bfd_set_gp_value rather than referring
7187 directly to the fields in the tdata information.
7188 (alpha_relocate_section): Likewise.
7189 * coff-mips.c (mips_adjust_reloc_in): Likewise.
7190 (mips_gprel_reloc): Likewise.
7191 (mips_relocate_section): Likewise.
7192 * elf32-mips.c (mips_elf_hi16_reloc): Likewise.
7193 (mips_elf_lo16_reloc): Likewise.
7194 (mips_elf_final_gp): Likewise.
7195 (mips_elf_gprel16_reloc): Likewise.
7196 (mips_elf_gprel32_reloc): Likewise.
7197 (mips_elf_relocate_section): Likewise.
7198 (mips_elf_finish_dynamic_symbol): Likewise.
7199
7200 * bout.c (b_out_set_arch_mach): Recognize bfd_mach_i960_jx.
7201
7202 Thu Feb 15 11:29:13 1996 Ian Lance Taylor <ian@cygnus.com>
7203
7204 * configure.in: Call AC_PROG_CC before configure.host.
7205 * configure: Rebuild.
7206 * configure.host: Don't set information which autoconf should
7207 figure out, namely CC, CFLAGS, LDFLAGS, AR, and RANLIB.
7208
7209 * configure.host: Remove go32 and win32 host information, since it
7210 should no longer be needed.
7211
7212 * elf.c (map_sections_to_segments): If we have a .dynamic section,
7213 then start a new segment rather than put a writable section in a
7214 readonly segment.
7215
7216 * configure.host: Set RPATH_ENVVAR.
7217
7218 * Makefile.in: Rebuild dependencies.
7219
7220 * elflink.c (_bfd_elf_create_linker_section): Remove unused
7221 zero_section variable.
7222
7223 Thu Feb 15 10:39:17 1996 H.J. Lu <hjl@zoom.com>
7224
7225 * Makefile.in ($(srcdir)/bfd-in2.h): Rename target from bfd-in2.h.
7226 ($(srcdir)/libbfd.h): Rename from libbfd.h.
7227 ($(srcdir)/libcoff.h): Rename from libcoff.h.
7228
7229 Wed Feb 14 16:29:07 1996 Martin Anantharaman <martin@mail.imech.uni-duisburg.de>
7230
7231 * ieee.c (ieee_write_expression): Only use an R variable for a
7232 local symbol. Don't output a zero offset. Handle a zero address.
7233 (SRC_MASK, PCREL_OFFSET): Define based on KEEPMINUSPCININST.
7234 (rel32_howto, rel16_howto, rel8_howto): Use SRC_MASK and
7235 PCREL_OFFSET.
7236 (parse_expression): Don't try to handle multiple occurrences of a
7237 P variable. Handle I variables differently from X variables. Fix
7238 the order of minus expressions.
7239 (ieee_slurp_external_symbols): Generate an I variable for an NN
7240 record. Fix handling of ATI and ATX records.
7241 (ieee_slurp_sections): Only set minimal section attributes.
7242 Adjust them later, based on the section contents.
7243 (ieee_object_p): Read in the file until just after the ME record.
7244 Call ieee_slurp_section_data to set the section flags.
7245 (do_one): Add iterations parameter. Only repeat the first load
7246 item. Set the section and file reloc flags.
7247 (ieee_slurp_section_data): Set section flags. Pass iterations to
7248 do_one.
7249 (ieee_canonicalize_reloc): Handle I variables.
7250 (do_with_relocs): Only emit relocation size when necessary.
7251 Increase MAXRUN to 127. Change ov to be assigned, and take
7252 src_mask and pcrel_offset into account.
7253 (ieee_write_data_part): Skip sections that are not loaded.
7254 (ieee_write_external_part): Don't output optional last entry of WX
7255 records.
7256 (ieee_write_me_part): Make setting of me_record neater.
7257 (ieee_generic_stat_arch_elt): Get the size of an archive element.
7258
7259 * syms.c (stt): Add entries for zerovars, vars, and code.
7260
7261 * elfcode.h (validate_reloc): New static function.
7262 (write_relocs): Call validate_reloc for non ELF relocs.
7263
7264 * elfxx-target.h (elf_symbol_leading_char): Define if not defined.
7265 (TARGET_BIG_SYM): Use elf_symbol_leading_char.
7266 (TARGET_LITTLE_SYM): Likewise.
7267
7268 * config.bfd (m68*-*-psos*): New target.
7269
7270 Tue Feb 13 15:56:22 1996 Bryan Ford <baford@snake.cs.utah.edu>
7271
7272 * i386msdos.c: Remove some #if 0 code.
7273 (msdos_write_object_contents): Don't include empty sections in the
7274 size computation, regardless of their address.
7275
7276 Tue Feb 13 15:36:37 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7277
7278 * elf32-ppc.c (ppc_elf_relocate_section): Don't segfault if dynboj
7279 is NULL, ie, the -r switch is used.
7280
7281 Tue Feb 13 14:35:15 1996 Ian Lance Taylor <ian@cygnus.com>
7282
7283 * reloc.c (BFD_RELOC_MIPS_GOT_HI16): Define.
7284 (BFD_RELOC_MIPS_GOT_LO16): Define.
7285 (BFD_RELOC_MIPS_CALL_HI16, BFD_RELOC_MIPS_CALL_LO16): Define.
7286 * bfd-in2.h, libbfd.h: Rebuild.
7287 * elf32-mips.c (mips_reloc_map): Map new relocs.
7288
7289 * configure.host: Set HDLFLAGS for *-*-hpux with --enable-shared.
7290
7291 * Makefile.in ($(SHLINK)): Check ts against $(SHLIB), not
7292 $(SHLINK).
7293
7294 * ieee.c (get_symbol): Set the section to bfd_abs_section.
7295 (do_with_relocs): If EXEC_P is set and there are no relocs, use a
7296 simple number for the section address, rather than an expression.
7297 Limit the number of bytes between relocs to MAXRUN.
7298 (ieee_write_me_part): Set me_record to the file offset after the
7299 start address.
7300 (ieee_write_processor): New static function.
7301 (ieee_write_object_contents): Use ieee_write_processor.
7302
7303 Fri Feb 9 10:53:00 1996 Ian Lance Taylor <ian@cygnus.com>
7304
7305 * configure.host: Use ${CC-gcc} when testing for -rpath on SunOS.
7306
7307 * coff-aux.c: Change include of aux.h to aux-coff.h.
7308
7309 Thu Feb 8 14:01:03 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
7310
7311 * elf32-m68k.c (elf_m68k_relocate_section): For a R_68K_RELATIVE
7312 relocation put the addend both in the reloc entry and the data.
7313 (elf_m68k_finish_dynamic_symbol): Likewise. Mask out marker in
7314 GOT offset value.
7315
7316 * elf32-m68k.c (elf_m68k_relocate_section): If -Bsymbolic, resolve
7317 a R_68K_PCxx reloc against a defined global symbol directly.
7318 (elf_m68k_check_relocs): Don't count such a reloc.
7319
7320 * elf32-m68k.c (elf_m68k_check_relocs): Don't record a symbol with
7321 a PLTxx reloc as dynamic. Disallow PLTxxO reloc against a local
7322 symbol for now, otherwise always record the symbol as dynamic.
7323 (elf_m68k_adjust_dynamic_symbol): If a symbol with a PLTxx reloc
7324 is not referenced by a dynamic object, and we are not making a
7325 shared object, then don't make a PLT entry. If we do make a PLT
7326 entry, make sure the symbol has been recorded as dynamic.
7327
7328 Wed Feb 7 13:56:06 1996 Ian Lance Taylor <ian@cygnus.com>
7329
7330 * configure.host: When making a shared library, set HLDFLAGS to
7331 pass an appropriate -rpath option. Use the make variable SONAME
7332 as the shared library soname, rather than computing it here. On
7333 SunOS, build stamp-tshlink in place of $(SHLINK).
7334 * Makefile.in (SONAME): New variable.
7335 ($(SHLINK)): Make a link to the transformed name, as well.
7336 (stamp-tshlink): New target.
7337 (install): Skip stamp-tshlink during install.
7338
7339 Wed Feb 7 13:37:39 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7340
7341 * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not assume that the
7342 linker sections have been set up yet.
7343
7344 * elf.c (make_mapping): Add an additional argument to suppress
7345 making the first section include the program headers.
7346 (map_sections_to_segments): If the user used -Ttext such that the
7347 program headers are on a different page, do not set the flags
7348 saying that this section includes the program headers.
7349
7350 Tue Feb 6 14:04:49 1996 J.T. Conklin <jtc@rtl.cygnus.com>
7351
7352 * configure.in (*-*-netbsd*): Set COREFILE to netbsd-core.c.
7353 don't define TRAD_HEADER.
7354 * configure: Rebuild.
7355
7356 * netbsd-core.c: New file, support for NetBSD core files.
7357 * hosts/*nbsd.h: Removed.
7358
7359 Tue Feb 6 11:47:49 1996 Doug Evans <dje@charmed.cygnus.com>
7360
7361 * reloc.c (BFD_RELOC_SPARC_[567]): New reloc types.
7362 (BFD_RELOC_SPARC_LO7 reloc type): Deleted.
7363 * libbfd.h, bfd-in2.h: Regenerated.
7364 * elf32-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Renamed from
7365 bfd_elf32_bfd_reloc_type_lookup.
7366 (reloc_type{,_names}): Deleted.
7367 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
7368 Add sparc64 relocs.
7369 (sparc_reloc_map): Add sparc64 relocs.
7370 (sparc_elf_notsupported_reloc): New static function.
7371 (sparc_elf_wdisp16_reloc): New static function.
7372 (elf32_sparc_check_relocs): Handle R_SPARC_WDISP{16,19}.
7373 (elf32_sparc_relocate_section): Likewise.
7374 (bfd_elf32_bfd_reloc_type_lookup): Define.
7375 * elf64-sparc.c (sparc64_elf_wdisp16_reloc): Deleted.
7376 (reloc_type{,_names}): Deleted.
7377 (elf_sparc_howto_table): Deleted.
7378 (sparc_reloc_map): Deleted.
7379 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
7380 (bfd_elf64_bfd_reloc_type_lookup): Change from function to #define.
7381
7382 Tue Feb 6 12:12:22 1996 Ian Lance Taylor <ian@cygnus.com>
7383
7384 * configure.host: Make SHLIB_CFLAGS include $(PICFLAG) on a
7385 *-*-hpux* host.
7386
7387 * Makefile.in (program_transform_name): New variable.
7388 (install): Transform library name before installing it.
7389
7390 Mon Feb 5 10:38:27 1996 Ian Lance Taylor <ian@cygnus.com>
7391
7392 * archures.c (bfd_mach_i960_hx): Define.
7393 * bfd-in2.h: Rebuild.
7394 * cpu-i960.c (scan_960_mach): Accept machine "hx".
7395 (MATRIX): Expand entries for HX.
7396 (arch_info_struct): Add i960:hx entry.
7397 * bout.c (b_out_set_arch_mach): Handle bfd_mach_i960_hx.
7398 * coffcode.h (coff_set_arch_mach_hook): Handle F_I960HX.
7399 (coff_set_flags): Handle bfd_mach_i960_hx.
7400
7401 Support for building as a shared library, based on patches from
7402 Alan Modra <alan@spri.levels.unisa.edu.au>:
7403 * configure.in: Add AC_ARG_ENABLE for shared and commonbfdlib.
7404 New substitutions: ALLLIBS, PICFLAG, SHLIB, SHLIB_CC,
7405 SHLIB_CFLAGS, COMMON_SHLIB, PICLIST, SHLINK.
7406 * configure: Rebuild.
7407 * configure.host: If --enable-shared, adjust shared library stuff
7408 based on the host. If the host is SunOS, and the linker supports
7409 -rpath, set HLDFLAGS to use it.
7410 * Makefile.in (ALLLIBS): New variable.
7411 (PICFLAG, SHLIB, SHLIB_CC, SHLIB_CFLAGS): New variables.
7412 (COMMON_SHLIB, SHLINK): New variables.
7413 (.c.o): If PICFLAG is set, compile twice, once PIC, once normal.
7414 (STAGESTUFF): Remove variable.
7415 (all): Depend upon $(ALLLIBS) and @PICLIST@ rather than
7416 $(TARGETLIB).
7417 (stamp-ofiles): New target, like old ofiles target, but build
7418 using a temporary file and move-if-change, and touch stamp-ofiles
7419 when done.
7420 (ofiles): Just depend upon stamp-ofiles.
7421 (stamp-piclist, piclist): New targets.
7422 ($(SHLIB), $(SHLINK)): New targets.
7423 (targets.o, archures.o): Build twice if PICFLAG is set.
7424 (do_mostlyclean): Remove pic/*.o.
7425 (do_clean): Remove stamp-ofiles, $(SHLIB), $(SHLINK), piclist, and
7426 stamp-piclist.
7427 (do_distclean): Remove pic and stamp-picdir.
7428 (install): Install shared libraries.
7429 ($(OFILES)): Depend upon stamp-picdir.
7430 (stamp-picdir): New target.
7431
7432 * libcoff-in.h: Add comment reminding people that libcoff.h is a
7433 generated file.
7434 * libcoff.h: Rebuild.
7435
7436 * elflink.h (elf_adjust_dynamic_symbol): Don't try to get the
7437 flavour of a section with no owner.
7438
7439 * elf32-mips.c (mips_elf_create_dynamic_sections): Clear
7440 ELF_LINK_NON_ELF flag.
7441 (mips_elf_create_got_section): Likewise.
7442
7443 * elf.c: Revert last change, since it breaks dynamic linking.
7444 * elf-bfd.h (struct elf_backend_data): Remove want_hdr_in_seg
7445 field.
7446 * elf32-mips.c (elf_backend_want_hdr_in_seg): Don't define.
7447 * elfxx-target.h (elf_backend_want_hdr_in_seg): Don't define.
7448 (elfNN_bed): Don't initialize want_hdr_in_seg field.
7449
7450 Sun Feb 4 20:45:13 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7451
7452 * elf.c (assign_file_positions_for_segments): If the backend does
7453 not want the elf header or the program headers in the address
7454 space, do not include them in the calculations.
7455
7456 * elf32-ppc.c (ppc_elf_additional_program_headers): New hook
7457 function to determine if we need additional program headers.
7458 (ppc_elf_modify_segment_map): Define as a NOP function for now.
7459 (ppc_elf_create_linker_section): .sdata2 is a read-only section.
7460
7461 Sat Feb 3 23:00:03 1996 Ian Lance Taylor <ian@cygnus.com>
7462
7463 * coffcode.h: Move today's libcoff.h change into coffcode.h.
7464
7465 Sat Feb 3 15:43:44 1996 Fred Fish <fnf@cygnus.com>
7466
7467 * libcoff.h (bfd_coff_link_add_one_symbol): Combine macro args
7468 back into one line. Some compilers (sunos 4.1.3 for example)
7469 won't accept args split across more than one line.
7470
7471 Fri Feb 2 11:42:15 1996 Steve Chamberlain <sac@slash.cygnus.com>
7472
7473 * aclocal.m4 (BFD_BINARY_FOPEN): Understand cygwin32.
7474 * configure: Regenerate.
7475
7476 Fri Feb 2 12:12:16 1996 Jeffrey A Law (law@cygnus.com)
7477
7478 * elf32-hppa.c (elf32_hppa_backend_symbol_table_processing): Don't
7479 try to do arithmetic on a void *, cast it to a unsigned char * first.
7480
7481 Thu Feb 1 16:04:06 1996 Ian Lance Taylor <ian@cygnus.com>
7482
7483 * elf-bfd.h (ELF_LINK_NON_ELF): Define.
7484 * elf.c (_bfd_elf_link_hash_newfunc): Set elf_link_hash_flags to
7485 ELF_LINK_NON_ELF.
7486 * elflink.h (elf_link_add_object_symbols): Reset ELF_LINK_NON_ELF
7487 flag for a newly defined symbol.
7488 (NAME(bfd_elf,record_link_assignment)): Likewise.
7489 (elf_adjust_dynamic_symbol): If ELF_LINK_NON_ELF is set, try to
7490 set the DEF or REF_REGULAR flags correctly.
7491
7492 * Makefile.in (bfd-in2.h): Make bfd.h, not protos, in docdir.
7493 (libbfd.h, libcoff.h): Corresponding change.
7494
7495 * elf32-i386.c (elf_i386_check_relocs): Don't record a symbol with
7496 a PLT32 reloc as dynamic.
7497 (elf_i386_adjust_dynamic_symbol): If a symbol with a PLT32 reloc
7498 is not referenced by a dynamic object, and we are not making a
7499 shared object, then don't make a PLT entry. If we do make a PLT
7500 entry, make sure the symbol has been recorded as dynamic.
7501
7502 Wed Jan 31 17:23:32 1996 Steve Chamberlain <sac@slash.cygnus.com>
7503
7504 * coff-i386.c (coff_i386_reloc_type_lookup): Add BFD_RELOC_32_PCREL.
7505 * config.bfd (i[345]86-*-win32): Becomes i[345]86-*-cygwin32.
7506 (powerpcle-*-cygwin32): New.
7507 * peicode.h (add_data_entry): Get address from vma.
7508
7509 Wed Jan 31 16:23:57 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7510
7511 * elflink.c (_bfd_elf_create_linker_section): If the symbol
7512 attached to the section has already been created as an undefined
7513 symbol, treat it as if it hasn't been created yet.
7514
7515 Wed Jan 31 16:16:53 1996 Ian Lance Taylor <ian@cygnus.com>
7516
7517 * elflink.h (elf_bfd_final_link): Don't output initial dummy
7518 symbol or section symbols if stripping all symbols and this is not
7519 a relocateable link. Don't output the symbol string table if
7520 there are no symbols.
7521 (elf_link_flush_output_syms): Don't do anything if there are no
7522 symbols to flush.
7523
7524 Wed Jan 31 12:55:49 1996 Richard Henderson <rth@tamu.edu>
7525
7526 * coff-aux.c: New file.
7527 * hosts/m68kaux.h: New file.
7528 * config.bfd (m68*-apple-aux*): New target.
7529 * configure.in (m68*-apple-aux*): New native host.
7530 (m68kaux_coff_vec): New vector.
7531 * configure: Rebuild.
7532 * targets.c (m68kaux_coff_vec): Declare.
7533 * coffcode.h (bfd_coff_backend_data): Add field
7534 _bfd_coff_link_add_one_symbol.
7535 (bfd_coff_link_add_one_symbol): Define.
7536 (compare_arelent_ptr): New static function if TARG_AUX.
7537 (coff_write_relocs): If TARG_AUX, sort the relocs.
7538 (coff_write_object_contents): Set A/UX aouthdr magic number.
7539 (coff_link_add_one_symbol): Define if not defined.
7540 (bfd_coff_std_swap_table): Initialize new field.
7541 * libcoff.h: Rebuild.
7542 * cofflink.c (coff_link_add_symbols): Call
7543 bfd_coff_link_add_one_symbol rather than
7544 _bfd_generic_link_add_one_symbol.
7545 * coff-m68k.c (COFF_PAGE_SIZE): Don't define if already defined.
7546 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
7547 * coff-mips.c (mips_ecoff_backend_data): Likewise.
7548 * Makefile.in: Rebuild dependencies.
7549 (BFD32_BACKENDS): Add coff-aux.o.
7550 (BFD32_BACKENDS_CFILES): Add coff-aux.c.
7551
7552 Wed Jan 31 11:37:46 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
7553
7554 * elf32-m68k.c (elf_m68k_relocate_section): Fix R_68K_GOT*
7555 relocation; ignore addend with R_68K_{GOT,PLT}*O relocation.
7556
7557 Tue Jan 30 12:09:04 1996 Ian Lance Taylor <ian@cygnus.com>
7558
7559 * Makefile.in (do_maintainer_clean): Remove $(srcdir)/bfd-in2.h,
7560 $(srcdir)/libbfd.h and $(srcdir)/libcoff.h.
7561 (maintainer-clean): Warn about deleting special files.
7562 (bfd-in2.h, libbfd.h, libcoff.h): New targets.
7563
7564 * elf32-hppa.c (elf32_hppa_relocate_section): Handle indirect and
7565 warning symbols correctly.
7566 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7567 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7568 * elf32-mips.c (mips_elf_relocate_section): Likewise.
7569 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7570 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7571 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7572
7573 * syms.c (_bfd_stab_section_find_nearest_line): Add casts to avoid
7574 warnings.
7575
7576 Mon Jan 29 14:27:24 1996 Kim Knuttila <krk@cygnus.com>
7577
7578 * libcoff-in.h: aligned newly exported names with bfd naming
7579 conventions. Removed an erroneous define of POWERPC_LE_PE.
7580 * libcoff.h: Rebuild.
7581 * cofflink.c, coff-ppc.c: the above function name changes
7582
7583 Mon Jan 29 13:06:28 1996 Ian Lance Taylor <ian@cygnus.com>
7584
7585 From Basim Kadhim <kadhim@spock.cs.colorado.edu>:
7586 * ecoff.c (struct extsym_info): Define.
7587 (_bfd_ecoff_bfd_final_link): Pass a pointer to struct extsym_info
7588 to ecoff_link_write_external.
7589 (ecoff_link_write_external): Accept a struct extsym_info pointer.
7590 Strip symbols when appropriate.
7591
7592 Based on patches from Ronald F. Guilmette <rfg@monkeys.com>:
7593 * syms.c (BSF_OBJECT): Define.
7594 (bfd_print_symbol_vandf): Print 'O' for BSF_OBJECT.
7595 * bfd-in2.h: Rebuild.
7596 * elfcode.h (elf_slurp_symbol_table): Set BSF_OBJECT for an
7597 STT_OBJECT symbol.
7598 * elf.c (swap_out_syms): Only set type to STT_OBJECT if BSF_OBJECT
7599 is set.
7600
7601 * elf32-i386.c (elf_i386_relocate_section): If -Bsymbolic, when
7602 copying relocs into a shared object, treat a defined global symbol
7603 as a local symbol.
7604 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7605 * elf32-mips.c (mips_elf_relocate_section): Likewise.
7606 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7607
7608 * elflink.h (elf_link_add_object_symbols): Only set weakdef to a
7609 real defined symbol, not to a weak defined symbol.
7610
7611 Mon Jan 29 11:34:36 1996 Kim Knuttila <krk@cygnus.com>
7612
7613 * cofflink.c: removed the POWERPC_LE_PE hack, promoted some types
7614 and made a few static functions externs.
7615
7616 * coff-ppc.c (ppc_bfd_coff_final_link): new function, replaces the
7617 POWERPC_LE_PE hack in cofflink.
7618
7619 * libcoff-in.h: promoted the following from cofflink.c to allow
7620 _bfd_coff_final_link to be overridden - STRING_SIZE_SIZE,
7621 coff_debug_merge_element, struct coff_debug_merge_type,
7622 coff_debug_merge_hash_entry, coff_debug_merge_hash_table,
7623 coff_debug_merge_hash_table_init, coff_debug_merge_hash_table_free,
7624 coff_debug_merge_hash_lookup, coff_link_section_info,
7625 coff_final_link_info, coff_debug_merge_hash_newfunc,
7626 coff_write_global_sym, coff_link_input_bfd, coff_reloc_link_order.
7627
7628 * libcoff.h: re-gen'd
7629
7630 Fri Jan 26 18:33:35 1996 Ian Lance Taylor <ian@cygnus.com>
7631
7632 * syms.c: Include "bfdlink.h".
7633 (struct stab_find_info): Define.
7634 (_bfd_stab_section_find_nearest_line): New function.
7635 * libbfd-in.h (_bfd_stab_section_find_nearest_line): Declare.
7636 * libbfd.h: Rebuild.
7637 * elf-bfd.h (struct elf_obj_tdata): Add line_info field.
7638 * elf.c (_bfd_elf_find_nearest_line): Try calling
7639 _bfd_stab_section_find_nearest_line before searching the ELF
7640 symbol table. Find the closest STT_FUNC symbol, not the last one.
7641 * libcoff-in.h (coff_data_type): Add line_info field.
7642 * libcoff.h: Rebuild.
7643 * coffgen.c (coff_find_nearest_line): Try calling
7644 _bfd_stab_section_find_nearest_line before searching the COFF
7645 symbol table.
7646 * Makefile.in: Rebuild dependencies.
7647
7648 Fri Jan 26 16:11:19 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7649
7650 * elf32-ppc.c (R_PPC_EMB_SDA21 relocations): Make relocation size
7651 4 bytes, so we get the correct value when updating the register
7652 field in little endian mode.
7653
7654 Thu Jan 25 12:14:16 1996 Ian Lance Taylor <ian@cygnus.com>
7655
7656 * libcoff-in.h (struct xcoff_tdata): Remove toc_section and
7657 entry_section fields. Add sntoc and snentry fields.
7658 * libcoff.h: Rebuild.
7659 * coffcode.h (coff_mkobject_hook): Initialize sntoc and snentry,
7660 not toc_section and entry_section (the COFF file does not have any
7661 sections at this point).
7662 (coff_write_object_contents): Set o_snentry and o_sntoc from
7663 snentry and sntoc rather than entry_section and toc_section.
7664 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy sntoc and
7665 snentry, not toc_section and entry_section.
7666 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Don't set
7667 entry_section from hentry.
7668 (xcoff_link_input_bfd): If a defined symbol has XCOFF_ENTRY set,
7669 set snenty.
7670 (xcoff_link_input_bfd): Set sntoc, not toc_section.
7671 (xcoff_write_global_symbol): Get toc_section from sntoc, rather
7672 than using toc_section directly.
7673
7674 * archures.c: Add missing `.' in enum bfd_architecture.
7675 * bfd-in2.h: Rebuild.
7676
7677 * config.bfd (i[345]86-*-sco*elf*): Use bfd_elf32_i386_vec. From
7678 Robert Lipe <robertl@arnet.com>.
7679
7680 Thu Jan 25 12:08:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7681
7682 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Add .rela.sdata{,2}
7683 to sections we allocate. Use bfd_zalloc to allocate initialial
7684 sections, not bfd_alloc.
7685 (ppc_elf_check_relocs): Remove BFD_ASSERTs for !shared from
7686 SDA{,2}I16 relocations.
7687 (ppc_elf_add_symbol_hook): Use the value of -G nn to determine
7688 whether to put something in .sbss or not.
7689 (ppc_elf_relocate_section): Add support for more relocations. Add
7690 in sec->output_offset where appropriate. Make error messages
7691 include the symbol name.
7692
7693 * elflink.c (_bfd_elf_create_linker_section): Lookup symbol before
7694 trying to add it to the symbol table, so _GLOBAL_OFFSET_TABLE_
7695 doesn't get redefined messages if -shared.
7696
7697 * elflink.h (elf_create_pointer_linker_section) Only bump RELA
7698 section if the rel_section field has been set up.
7699
7700 Wed Jan 24 20:40:26 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7701
7702 * elf32-ppc.c (ppc_elf_relocate_section): Fix typo in eabi
7703 relocations.
7704
7705 Wed Jan 24 10:38:34 1996 Doug Evans <dje@charmed.cygnus.com>
7706
7707 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Delete checking
7708 of flags, only flags used are controlled by mach number. Bump up
7709 output file mach number to highest of input file mach numbers.
7710 (elf32_sparc_object_p): Watch for EF_SPARC_SUN_US1.
7711 (elf32_sparc_final_write_processing): Set EF_SPARC_SUN_US1 if v8plusa.
7712
7713 * config.bfd (sparc64-*-{sysv4*,solaris2*}): Comment out
7714 bfd_elf64_sparc_vec support.
7715
7716 Tue Jan 23 14:33:05 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7717
7718 * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Don't complain if
7719 the embedded bit is set on some objects and not on others. Just
7720 or it together.
7721 (ppc_elf_relocate_section): Implement R_PPC_EMB_{SDA21,RELSDA}
7722 relocations.
7723
7724 Tue Jan 23 14:22:45 1996 Ian Lance Taylor <ian@cygnus.com>
7725
7726 * coffcode.h (coff_new_section_hook): Don't try to align the
7727 .stabstr section.
7728
7729 * coffcode.h (coff_set_section_contents): Fix the handling of the
7730 .lib section to work even if the entire section contents are
7731 written at once. From Gvran Uddeborg <gvran@uddeborg.pp.se> and
7732 Robert Lipe <robertl@arnet.com>.
7733
7734 Mon Jan 22 18:45:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7735
7736 * elflink.h (elf_finish_pointer_linker_section): Don't allocate
7737 memory here for contents.
7738
7739 * elf32-ppc.c (ppc_elf_relocate_section): Bump up _SDA_BASE_ and
7740 _SDA2_BASE_ by 32768.
7741 (ppc_elf_size_dynamic_sections): #if out PLT code which we haven't
7742 started using. Allocate contents for .sdata and .sdata2 sections
7743 also.
7744 (ppc_elf_check_relocs): Use bfd_get_section_name in debug message,
7745 rather than _name.
7746 (ppc_elf_finish_dynamic_symbol): Remove code that attempted to
7747 size _SDA{,2}_BASE_.
7748 (ppc_elf_relocate_section): Change how sdata{,2} relocations are
7749 done.
7750
7751 Mon Jan 22 08:52:04 1996 Doug Evans <dje@charmed.cygnus.com>
7752
7753 * elflink.h (elf_finish_pointer_linker_section): Fix typo.
7754
7755 * archures.c (bfd_mach_sparc_v9): Renamed from bfd_mach_sparc64.
7756 (bfd_mach_sparc_{v8plus,v8plusa}): Define.
7757 (bfd_mach_sparc_v9a): Define.
7758 (bfd_mach_sparc_v9_p): Define.
7759 * bfd-in2.h: Regenerated.
7760 * aoutx.h (aout,machine_type): bfd_mach_sparc64 renamed to
7761 bfd_mach_sparc_v9.
7762 * elf64-sparc.c (sparc64_elf_object_p): Likewise.
7763 * config.bfd (sparc64-*-sysv4*,sparc64-*-solaris2*): Set targ_defvec
7764 to bfd_elf32_sparc_vec.
7765 * cpu-sparc.c (arch_info_struct): Renamed from sparc_arch_info.
7766 Add v8plus{,a} support.
7767 Add v9a support.
7768 (sparc_compatible): New function.
7769 * elf32-sparc.h: #include "elf/sparc.h".
7770 (elf32_sparc_merge_private_bfd_data, elf32_sparc_object_p,
7771 elf32_sparc_final_write_processing): New functions.
7772 (bfd_elf32_bfd_merge_private_bfd_data, elf_backend_object_p,
7773 elf_backend_final_write_processing): Define.
7774
7775 Mon Jan 22 11:21:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7776
7777 * elf-bfd.h (struct elf_link_hash_entry): Add
7778 linker_section_pointer field.
7779 (enum elf_linker_section_enum): Enumeration for new way of
7780 creating linker dynamic sections and symbols.
7781 (elf_linker_section{,_pointers}): New structures for creating
7782 dynamic sections and symbols.
7783 (elf_obj_tdata): Add linker_section_pointers and linker_section
7784 fields.
7785 (elf_local_ptr_offsets,elf_linker_section): New accessor macros.
7786 (_bfd_elf_create_linker_section): New declarations.
7787 (_bfd_elf_find_pointer_linker_section): Ditto.
7788 (bfd_elf{32,64}_{create,finish}_pointer_linker_section): Ditto.
7789 (_bfd_elf_make_linker_section_rela): Ditto.
7790
7791 * elf.c (_bfd_elf_link_hash_newfunc): Initialize new fields.
7792
7793 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Delete.
7794 (ppc_elf_create_linker_section): New function to create the
7795 sections .got, .sdata, and .sdata2.
7796 (ppc_elf_size_dynamic_sections): Zap .rela.{sdata,sdata2} if
7797 needed.
7798 (ppc_elf_check_relocs): Support more of the eabi relocations.
7799 (ppc_elf_relocate_section): Ditto.
7800 (ppc_elf_finish_dynamic_symbols): Adjust _SDA{,2}_BASE_ by 32768
7801 if the .sdata{,2} + .sbss{,2} section size is > 32k.
7802
7803 * elflink.h (elf_create_pointer_linker_section): New function to
7804 create initialized pointers in dynamic linker sections.
7805 (elf_finish_pointer_linker_section): Actually intialize the
7806 pointers created above.
7807
7808 * elfcode.h (bfd_elf{32,64}_create_pointer_linker_section): New
7809 macros to provide both 32 and 64 bit versions of
7810 elf_create_pointer_linker_section.
7811 (bfd_elf{32,64}_finish_pointer_linker_section): New macros to
7812 provide both 32 and 64 bit versions of
7813 elf_finish_pointer_linker_section.
7814
7815 * elflink.c (_bfd_elf_create_linker_section): New function to
7816 create a linker section.
7817 (_bfd_elf_find_pointer_linker_section): Find a unique pointer to a
7818 given address in the linker pointer offsets created for a given
7819 symbol.
7820 (_bfd_elf_make_linker_section_rela): Make a RELA section
7821 corresponding to the generated linker section.
7822
7823 Sat Jan 20 08:36:10 1996 Doug Evans <dje@canuck.cygnus.com>
7824
7825 * elf32-sparc.c (ELF_MACHINE_ALT1): Define.
7826
7827 Thu Jan 18 18:25:34 1996 Kim Knuttila <krk@cygnus.com>
7828
7829 * coff-ppc.c (coff_ppc_relocate_section): changed TOCDEFN relocs.
7830 (coff_ppc_relocate_section): Handle special values for gcc built dlls.
7831 (dump_toc): fix diagnosing code to identify out-of-toc-bounds entries.
7832 Also begin the toc at 4 as an eye catcher ('31313131' marks the first
7833 toc entry in an objdump) for now.
7834 (ppc_do_last, ppc_get_last): New function - needed to save processing
7835 the toc owner to the end.
7836 (ppc_coff_swap_sym_in_hook): Removed an incorrect hack for doing the
7837 toc owner last.
7838
7839 * cofflink.c (_bfd_coff_final_link): Added a new hack to keep the
7840 toc owner from being done till last. Must define POWERPC_LE_PC
7841 to enable it.
7842
7843 * coffcode.h (coff_set_alignment_hook): alignment setting for .stab
7844
7845 * peicode.h (coff_swap_scnhdr_out): set section flags for stab/str
7846 to INFO.
7847 (coff_swap_aouthdr_out): Removed a non-working hack for computing the
7848 SizeOfImage for PowerPC. Ignore the size of the .junk section.
7849
7850 Thu Jan 18 17:42:12 1996 Ian Lance Taylor <ian@cygnus.com>
7851
7852 * elfcore.h: Include <signal.h> before <sys/procfs.h>.
7853
7854 Wed Jan 17 12:40:14 1996 Ian Lance Taylor <ian@cygnus.com>
7855
7856 * cpu-powerpc.c (arch_info_struct): Change last entry to not point
7857 back to first.
7858 (bfd_powerpc_arch): Point at first entry in arch_info_struct.
7859
7860 Tue Jan 16 15:10:49 1996 Ian Lance Taylor <ian@cygnus.com>
7861
7862 * elf.c (assign_file_positions_for_segments): Don't increment file
7863 offset for a segment which contains no loadable sections.
7864
7865 Mon Jan 15 17:46:27 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7866
7867 * reloc.c: Add new PowerPC relocations.
7868 * {bfd-in2,libbfd}.h: Regenerate.
7869
7870 * elf32-ppc.c (ppc_elf_howto_raw): Add more PPC relocations.
7871 (ppc_elf_reloc_type_lookup): Lookup new relocations.
7872
7873 Mon Jan 15 14:29:44 1996 Ian Lance Taylor <ian@cygnus.com>
7874
7875 * aoutx.h (howto_table_ext): Fix RELOC_BASE10 and RELOC_BASE22
7876 entries.
7877
7878 * sunos.c (sunos_scan_ext_relocs): Don't fail assert if
7879 info->shared.
7880
7881 * coffgen.c (coff_find_nearest_line): Don't try to cache
7882 information in sections that are not owned by a BFD. From Richard
7883 Henderson <richard@atheist.tamu.edu>.
7884
7885 * elf32-mips.c: Numerous changes to dynamic linking code, mostly
7886 from Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>.
7887 * elflink.h (elf_link_output_extsym): Remove special check for
7888 _rld_new_interface.
7889
7890 * ecoffswap.h: Add prototypes for static functions.
7891
7892 Sun Jan 14 21:36:08 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7893
7894 * elf32-ppc.c (ppc_elf_{unsupported,std}_reloc): Remove functions.
7895 (ppc_elf_howto_raw): Remove ppc_elf_{unsupported,std}_reloc
7896 references.
7897 (ppc_elf_relocate_section): No longer allow .sdata/.sbss sections
7898 to satisfy a TOC16 relocation. Rewrite unsupported relocation
7899 support. Begin support for R_PPC_SDA{2,}REL.
7900
7901 Sat Jan 13 09:36:52 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7902
7903 * elf32-ppc.c (ppc_elf_create_dynamic_sections): New function to
7904 create the .got and .got.neg sections.
7905 (ppc_elf_size_dynamic_sections): Call it.
7906 (ppc_elf_check_relocs): Call it.
7907 (ppc_elf_size_dynamic_sections): Support .got.neg, just like .got.
7908 (ppc_elf_check_relocs): Add error messages for relocations we
7909 don't yet support. Do not include R_PPC_SDAREL16 like a GOT
7910 relocation.
7911
7912 Fri Jan 12 15:27:59 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7913
7914 * elf32-ppc.c (ppc_elf_fake_sections): Define, and handle the new
7915 section flags for V.4 and eabi.
7916
7917 Fri Jan 12 13:59:16 1996 Ian Lance Taylor <ian@cygnus.com>
7918
7919 * elf.c (assign_file_positions_for_segments): If a segment
7920 contains no sections, don't mark it as readable.
7921
7922 * elf-bfd.h (_bfd_elf_section_from_bfd_section): Declare.
7923 * elfcode.h (_bfd_elf_section_from_bfd_section): Don't declare.
7924
7925 * elf.c (_bfd_elf_print_private_bfd_data): Dump contents of
7926 dynamic section, if there is one.
7927 * elf-bfd.h (struct elf_size_info): Add swap_dyn_in field.
7928 (bfd_elf32_swap_dyn_in): Change type of second parameter to PTR.
7929 (bfd_elf64_swap_dyn_in): Likewise.
7930 * elfcode.h (elf_swap_dyn_in): Change type of second parameter to
7931 PTR.
7932 (NAME(_bfd_elf,size_info)): Initialize swap_dyn_in field.
7933
7934 * elf32-i386.c (elf_i386_size_dynamic_sections): Don't create a
7935 DT_TEXTREL entry because of .rel.plt. From Martin Pirker
7936 <pirker@eiunix.tuwien.ac.at>.
7937
7938 Thu Jan 11 17:06:14 1996 Michael Meissner <meissner@tiktok.cygnus.com>
7939
7940 * section.c (SEC_{EXCLUDE,SORT_ENTRIES}): New section flags for
7941 PowerPC V.4 and eabi.
7942 * bfd-in2.h: Regenerate.
7943 * libfd.h: Regenerate.
7944
7945 * elfxx-target.h (TARGET_{BIG,LITTLE}_SYM): Add new flags.
7946
7947 * elf32-ppc.c (ppc_elf_section_from_shdr): Support SHT_ORDERED
7948 section type and SHF_EXCLUDE section flag, turning them into the
7949 appropriate bfd section flag.
7950
7951 Thu Jan 11 11:23:30 1996 Ian Lance Taylor <ian@cygnus.com>
7952
7953 * xcofflink.c (xcoff_link_add_symbols): Create the special
7954 sections if we see a DYNAMIC object, in case that is the only
7955 XCOFF input object we see.
7956
7957 * elf32-mips.c: Extensive changes for a start at dynamic linking
7958 support, from Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>.
7959
7960 * elf-bfd.h (struct elf_backend_data): Add type_change_ok field.
7961 (struct elf_backend_data): Remove
7962 elf_backend_create_program_headers field. Add
7963 elf_backend_additional_program_headers and
7964 elf_backend_modify_segment_map fields.
7965 * elfxx-target.h (elf_backend_type_change_ok): Define if not
7966 defined.
7967 (elf_backend_additional_program_headers): Likewise.
7968 (elf_backend_modify_segment_map): Likewise.
7969 (elf_backend_create_program_headers): Don't define.
7970 (elfNN_bed): Change to account for field changes.
7971 * elf.c (assign_file_positions_for_segments): Call new
7972 modify_segment_map backend function. Don't call old
7973 create_program_headers backend function.
7974 (get_program_header_size): Call additional_program_headers rather
7975 than create_program_headers.
7976 * elflink.h (elf_link_add_object_symbols): Initialize
7977 type_change_ok from new backend field.
7978 (elf_link_output_extsym): Don't warn if _rld_new_interface is
7979 defined.
7980 (elf_reloc_link_order): Treat a reloc against a defined symbol as
7981 a reloc against the appropriate section.
7982
7983 * elf-bfd.h (struct bfd_elf_section_data): Add tdata field.
7984 (struct elf_obj_tdata): Rename ppc_flags_init field to flags_init.
7985 (elf_flags_init): Rename from elf_ppc_flags_init.
7986 * elf32-ppc.c (ppc_elf_set_private_flags): Use elf_flags_init, not
7987 elf_ppc_flags_init.
7988 (ppc_elf_copy_private_bfd_data): Likewise.
7989 (ppc_elf_merge_private_bfd_data): Likewise.
7990
7991 * elf32-m68k.c (howto_table): Change src_mask to 0 for all
7992 relocation entries.
7993
7994 Tue Jan 9 15:22:53 1996 David Mosberger-Tang <davidm@azstarnet.com>
7995
7996 * coff-alpha.c (alpha_relocate_section): During final link, allow
7997 output .lita section to be bigger than 64k by adjusting gp value
7998 on a per-input section basis.
7999 * libecoff.h (struct ecoff_tdata): Add issued_multiple_gp_warning
8000 field.
8001 (struct ecoff_section_tdata): Add gp field.
8002
8003 Tue Jan 9 12:00:36 1996 Ian Lance Taylor <ian@cygnus.com>
8004
8005 Handle Alpha ECOFF changes in OSF/1 3.2.
8006 * libecoff.h (struct ecoff_backend_data): Add get_elt_at_filepos
8007 field.
8008 * coff-alpha.c: Include "aout/ar.h".
8009 (alpha_ecoff_get_relocated_section_contents): Don't require an
8010 ALPHA_R_IGNORE reloc after an ALPHA_R_GPDISP reloc, since OSF/1
8011 3.2 doesn't generate one.
8012 (alpha_relocate_section): Likewise.
8013 (alpha_ecoff_slurp_armap): Define.
8014 (alpha_ecoff_slurp_extended_name_table): Define.
8015 (alpha_ecoff_construct_extended_name_table): Define.
8016 (alpha_ecoff_truncate_arname): Define.
8017 (alpha_ecoff_write_armap): Define.
8018 (alpha_ecoff_generic_stat_arch_elt): Define.
8019 (alpha_ecoff_update_armap_timestamp): Define.
8020 (ARFZMAG): Define.
8021 (alpha_ecoff_read_ar_hdr): New static function.
8022 (alpha_ecoff_get_elt_at_filepos): New static function.
8023 (alpha_ecoff_openr_next_archived_file): New static function.
8024 (alpha_ecoff_get_elt_at_index): New static function.
8025 (alpha_ecoff_backend_data): Initialize get_elt_at_filepos field.
8026 (ecoffalpha_little_vec): Change BFD_JUMP_TABLE_ARCHIVE from
8027 _bfd_ecoff to alpha_ecoff.
8028 * ecoff.c (ecoff_link_add_archive_symbols): Use get_elt_at_filepos
8029 field from backend structure, rather than always calling
8030 _bfd_get_elt_at_filepos.
8031 * coff-mips.c (mips_ecoff_backend_data): Initialize
8032 get_elt_at_filepos field.
8033 * archive.c (_bfd_generic_read_ar_hdr_mag): New function, copied
8034 from _bfd_generic_read_ar_hdr with minor changes.
8035 (_bfd_generic_read_ar_hdr): Use _bfd_generic_read_ar_hdr_mag.
8036 * libbfd-in.h (_bfd_generic_read_ar_hdr_mag): Declare.
8037 * libbfd.h: Rebuild.
8038
8039 * bfd-in.h (BFD_IN_MEMORY): Define.
8040 * libbfd-in.h (struct bfd_in_memory): Define.
8041 * libbfd.c (bfd_read): Handle BFD_IN_MEMORY flag.
8042 (bfd_get_file_window): Don't try to map a BFD_IN_MEMORY file.
8043 (bfd_write, bfd_stat): Abort if BFD_IN_MEMORY is set.
8044 (bfd_tell, bfd_flush, bfd_seek): Handle BFD_IN_MEMORY flag.
8045 * bfd.c (struct _bfd): Change iostream field from char * to PTR.
8046 (bfd_get_size): Handle BFD_IN_MEMORY flag.
8047 * cache.c (bfd_cache_close): Ignore BFD_IN_MEMORY files.
8048 (bfd_open_file): Cast to PTR, not char *, when setting iostream.
8049 (bfd_cache_lookup_worker): Abort if BFD_IN_MEMORY is set.
8050 * opncls.c (bfd_fdopenr): Cast to PTR, not char *, when setting
8051 iostream.
8052 (bfd_openstreamr): Likewise.
8053 * aoutx.h (NAME(aout,some_aout_object_p)): Only fstat iostream if
8054 BFD_IN_MEMORY is not set.
8055 * riscix.c (riscix_some_aout_object_p): Likewise.
8056 * bfd-in2.h, libbfd.h: Rebuild.
8057
8058 * targets.c (bfd_target): Add _bfd_get_elt_at_index field.
8059 (BFD_JUMP_TABLE_ARCHIVE): Add _get_elt_at_index.
8060 (bfd_get_elt_at_index): Define.
8061 * archive.c (_bfd_generic_get_elt_at_index): Rename from
8062 bfd_get_elt_at_index. Change index parameter from int to
8063 symindex.
8064 * libbfd-in.h (_bfd_generic_get_elt_at_index): Declare.
8065 (_bfd_noarchive_get_elt_at_index): Define.
8066 (_bfd_archive_bsd_get_elt_at_index): Define.
8067 (_bfd_archive_coff_get_elt_at_index): Define.
8068 * bfd-in2.h, libbfd.h: Rebuild.
8069 * aout-target.h (MY_get_elt_at_index): Define if not defined.
8070 * coff-rs6000.c (xcoff_get_elt_at_index): Define.
8071 * ieee.c (ieee_get_elt_at_index): Define.
8072 * libecoff.h (_bfd_ecoff_get_elt_at_index): Define.
8073 * oasys.c (oasys_get_elt_at_index): Define.
8074 * som.c (som_get_elt_at_index): Define.
8075
8076 * ecoff.c (_bfd_ecoff_find_nearest_line): Don't restrict line
8077 numbers to the .text section.
8078
8079 Mon Jan 8 17:00:57 1996 Ian Lance Taylor <ian@cygnus.com>
8080
8081 * ieee.c (ieee_write_debug_part): Change return type to boolean.
8082 If there is a SEC_DEBUGGING section, get the contents of the debug
8083 information part from it.
8084 (ieee_set_section_contents): Store the contents of a SEC_DEBUGGING
8085 section in memory.
8086 (ieee_write_object_contents): Check ieee_write_debug_part return.
8087
8088 Thu Jan 4 17:12:37 1996 Fred Fish <fnf@cygnus.com>
8089
8090 * config.bfd (i[345]86-*-freebsd*): Add target.
8091 * configure.in (i386freebsd_vec): Add vec.
8092 * configure: Regenerate.
8093 * Makefile.in (BFD32_BACKENDS): Add i386freebsd.o.
8094 (BFD32_BACKENDS_CFILES): Add i386freebsd.c.
8095 Rebuild dependencies..
8096 * freebsd.h: New file.
8097 * i386freebsd.c: New file.
8098 * targets.c (i386freebsd_vec): Declare.
8099 (bfd_target_vector): Add i386freebsd_vec.
8100 * i386linux.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
8101 * i386netbsd.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
8102
8103 Thu Jan 4 16:27:46 1996 Ian Lance Taylor <ian@cygnus.com>
8104
8105 * ieee.c (ieee_slurp_debug): New static function.
8106 (ieee_object_p): Call it.
8107 (ieee_slurp_section_data): Skip debugging sections.
8108 (ieee_get_reloc_upper_bound): Likewise.
8109 (ieee_get_section_contents): Likewise.
8110 (ieee_canonicalize_reloc): Likewise.
8111 (ieee_write_section_part): Likewise.
8112 (ieee_write_debug_part): Likewise.
8113 (ieee_write_data_part): Likewise.
8114 (init_for_output): Likewise.
8115
8116 Wed Jan 3 19:42:47 1996 Michael Meissner <meissner@wogglebug.tiac.net>
8117
8118 * elf32-ppc.c (ppc_elf_relocate_section): Make @GOT relocations
8119 work.
8120 (ppc_elf_howto_raw): Just use bfd_elf_generic_reloc for all howto
8121 relocs, since ppc_elf_relocate_section handles the linker case.
8122 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_reloc): Delete, no longer
8123 used.
8124 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_inner): Merge these into
8125 ppc_elf_relocate_section since that is now the only caller.
8126 (ppc_elf_relocate_section): Ditto.
8127
8128 Wed Jan 3 15:11:30 1996 Ian Lance Taylor <ian@cygnus.com>
8129
8130 * coffcode.h (coff_write_object_contents): If we don't know the
8131 section of the entry point for an XCOFF executable, always set the
8132 entry address to -1.
8133
8134 Tue Jan 2 14:17:15 1996 Michael Meissner <meissner@tiktok.cygnus.com>
8135
8136 * elf.c (bfd_section_from_shdr): Add support for note sections.
8137
8138 Tue Jan 2 13:10:25 1996 Ian Lance Taylor <ian@cygnus.com>
8139
8140 * bfd-in.h (struct _symbol_info): Add stab_type field.
8141 * bfd-in2.h: Rebuild.
8142 * aoutx.h (NAME(aout,get_symbol_info)): Set stab_type.
8143
8144 * elf32-ppc.c: Remove trailing newline from calls to
8145 _bfd_error_handler.
8146 (ppc_elf_merge_private_bfd_data): Only warn about endianness
8147 difference if target endianness is known.
8148
8149 Thu Dec 21 12:43:49 1995 Michael Meissner <meissner@tiktok.cygnus.com>
8150
8151 * elf32-ppc.c (ppc_elf_howto_raw): Add a phony reloc to handle the
8152 old style TOC16 references without using R_PPC_GOT.
8153 (ppc_reloc_type): Ditto.
8154 (ppc_elf_reloc_type_lookup): Add support for TOC16.
8155 (ppc_elf_toc16_inner): Renamed from ppc_elf_got16_inner.
8156 (ppc_elf_toc16_reloc): Renamed from ppc_elf_toc16_reloc.
8157 (ppc_elf_got16_{inner,reloc}): Stubs for real GOT support.
8158 (ppc_elf_check_relocs): New function for GOT/PLT support that is
8159 work in progress.
8160 (ppc_elf_adjust_dynamic_symbol): Ditto.
8161 (ppc_elf_adjust_dynindx): Ditto.
8162 (ppc_elf_size_dynamic_sections): Ditto.
8163 (ppc_elf_finish_dynamic_symbol): Ditto.
8164 (ppc_elf_finish_dynamic_sections): Ditto.
8165 (ELF_DYNAMIC_INTERPRETER): Define.
8166
8167 Wed Dec 20 19:14:18 1995 Ken Raeburn <raeburn@cygnus.com>
8168
8169 * elf.c (copy_private_bfd_data): When attaching sections to
8170 segments ignore sections that won't be allocated. Patch from
8171 Andreas Schwab.
8172
8173 Tue Dec 19 20:01:43 1995 Ken Raeburn <raeburn@cygnus.com>
8174
8175 * config.bfd: Match on m68k-cbm-* only if OS doesn't match
8176 anything else.
8177
8178 Tue Dec 19 16:38:59 1995 Ian Lance Taylor <ian@cygnus.com>
8179
8180 * coff-i960.c (CALC_ADDEND): Define.
8181 (coff_i960_relocate_section): Add the input section VMA to the
8182 addend for PC relative relocs.
8183
8184 Sun Dec 17 20:11:55 1995 Kim Knuttila <krk@cygnus.com>
8185
8186 * peicode.h (pe_print_pdata): Must test the entire entry for zero
8187 to correctly terminate.
8188
8189 Fri Dec 15 12:05:57 1995 Ian Lance Taylor <ian@cygnus.com>
8190
8191 * targets.c (enum bfd_endian): Define.
8192 (bfd_target): Rename byteorder_big_p to byteorder, and change it
8193 from boolean to enum bfd_endian. Change header_byteorder_big_p
8194 correspondingly.
8195 * bfd-in.h (bfd_big_endian, bfd_little_endian): New macros.
8196 (bfd_header_big_endian, bfd_header_little_endian): New macros.
8197 * bfd-in2.h: Rebuild.
8198 * All targets: Change initialization of byteorder and
8199 header_byteorder to use enum bfd_endian values rather than
8200 booleans.
8201 * All files: Change all references to byteorder_big_p and
8202 header_byteorder_big_p to use new bfd_*_endian macros.
8203
8204 * coffgen.c (make_a_section_from_file): Set lma to s_paddr, not
8205 s_vaddr.
8206 * coffcode.h (coff_write_object_contents): Set s_paddr to lma, not
8207 vma.
8208 * ecoff.c (_bfd_ecoff_write_object_contents): Likewise.
8209
8210 Fri Dec 15 07:32:09 1995 steve chamberlain <sac@slash.cygnus.com>
8211
8212 * pe[i]-i386.c (TARGET_UNDERSCORE): Define to '_'.
8213
8214 Thu Dec 14 13:45:37 1995 Ian Lance Taylor <ian@cygnus.com>
8215
8216 * ieee.c: Lots of minor cleanups. Make many functions return
8217 errors rather than calling abort. Also:
8218 (ieee_write_twobyte): Remove; change callers to call existing
8219 ieee_write_2bytes function.
8220 (ieee_write_expression): Don't output the section twice when
8221 outputting a local symbol. Don't emit an extraneous zero if there
8222 is only one term.
8223 (ieee_slurp_sections): Set the lma as well as the vma.
8224 (ieee_archive_p): Use bfd_alloc_grow rather than an obstack.
8225
8226 * ihex.c (ihex_set_arch_mach): Don't accept any architecture, just
8227 a recognized one or bfd_arch_unknown.
8228 (ihex_get_symtab_upper_bound): Define as bfd_0l, to permit objcopy
8229 to succeed.
8230 (ihex_get_symtab): Likewise.
8231
8232 Wed Dec 13 15:44:06 1995 Ian Lance Taylor <ian@cygnus.com>
8233
8234 * aoutx.h: Include <ctype.h>.
8235 (struct aout_link_includes_table): Define.
8236 (struct aout_link_includes_totals): Define.
8237 (struct aout_link_includes_entry): Define.
8238 (aout_link_includes_lookup): Define macro.
8239 (struct aout_final_link_info): Add includes field.
8240 (aout_link_includes_newfunc): New static function.
8241 (NAME(aout,final_link)): Initialize includes hash table.
8242 (aout_link_write_symbols): Eliminate duplicate N_BINCL entries.
8243
8244 Wed Dec 13 10:52:14 1995 Stan Shebs <shebs@andros.cygnus.com>
8245
8246 * mpw-config.in: Match on mips-*-* instead of mips-idt-ecoff.
8247
8248 Wed Dec 13 11:07:45 1995 Kim Knuttila <krk@cygnus.com>
8249
8250 * coff-ppc.c (coff_ppc_relocate_section): removed debugging code.
8251
8252 Tue Dec 12 17:42:06 1995 Kim Knuttila <krk@cygnus.com>
8253
8254 * peicode.h (pe_print_reloc): New function to dump the .reloc section.
8255 (pe_print_private_bfd_data): call pe_print_reloc.
8256 * coffcode.h (coff_set_alignment_hook): .reloc section alignment.
8257 * coff-ppc.c (in_reloc_p): Added missing non-eligible relocs. Spiffed
8258 up some debugging as well.
8259
8260 Tue Dec 12 11:34:23 1995 Ian Lance Taylor <ian@cygnus.com>
8261
8262 * config.bfd: Handle sparc-*-elf*. From Ronald F. Guilmette
8263 <rfg@monkeys.com>.
8264
8265 Fri Dec 8 17:47:07 1995 Ian Lance Taylor <ian@cygnus.com>
8266
8267 * elflink.h (elf_link_add_object_symbols): Set section_count to 0
8268 when setting sections to NULL.
8269
8270 Wed Dec 6 17:05:37 1995 Ian Lance Taylor <ian@cygnus.com>
8271
8272 * xcofflink.c (struct xcoff_loader_info): Add export_defineds
8273 field.
8274 (bfd_xcoff_size_dynamic_sections): Add export_defineds parameter.
8275 (xcoff_build_ldsyms): If export_defineds is set, set XCOFF_EXPORT
8276 for all symbols.
8277 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
8278 * bfd-in2.h: Rebuild.
8279
8280 Mon Dec 4 16:40:47 1995 Kim Knuttila <krk@cygnus.com>
8281
8282 * coffcode.h (coff_set_alignment_hook): Removed some debugging printf's
8283
8284 Mon Dec 4 11:25:39 1995 Ian Lance Taylor <ian@cygnus.com>
8285
8286 * ihex.c (ihex_scan): Handle record types 4 and 5.
8287 (ihex_object_p): Permit types 4 and 5.
8288 (ihex_set_section_contents): Remove check for out of range
8289 addresses.
8290 (ihex_write_object_contents): Generate types 4 and 5.
8291
8292 * elflink.h (elf_link_output_extsym): Just ignore warning and
8293 indirect references to symbols which don't really exist.
8294
8295 Sun Dec 3 19:00:27 1995 Kim Knuttila <krk@cygnus.com>
8296
8297 * peicode.h (pe_print_idata): Minor format fixes
8298 (pe_print_edata): New function. Under private printing, this formats
8299 the edata section of a PE file.
8300 (pe_print_private_bfd_data): Added call to pe_print_edata.
8301
8302 Sun Dec 3 16:46:54 1995 Richard Earnshaw (rearnsha@armltd.co.uk)
8303
8304 * aout-arm.c (MY_swap_std_reloc_out): Use KEEPIT to get the symbol
8305 index, don't call stoi.
8306
8307 Fri Dec 1 14:46:51 1995 Ian Lance Taylor <ian@cygnus.com>
8308
8309 * srec.c (srec_scan): Set lma as well as vma.
8310
8311 * ihex.c: New file; support for Intel Hex format.
8312 * targets.c (enum bfd_flavour): Add bfd_target_ihex_flavour.
8313 (ihex_vec): Declare.
8314 (bfd_target_vector): Always include ihex_vec.
8315 * bfd.c (struct _bfd): Add ihex_data field to tdata union.
8316 * Makefile.in: Rebuild dependencies.
8317 (BFD_LIBS): Add ihex.o
8318 (BFD_LIBS_CFILES): Add ihex.c.
8319 * bfd-in2.h: Rebuild.
8320
8321 * elf.c (assign_file_positions_for_segments): Sort the sections in
8322 each segment.
8323 (get_program_header_size): Return the right size if segment_map is
8324 not NULL.
8325 (copy_private_bfd_data): Don't bother to sort the sections.
8326
8327 * bfd.c (bfd_record_phdr): New function.
8328 * bfd-in.h (bfd_record_phdr): Declare.
8329 * bfd_in2.h: Rebuild.
8330
8331 * elf32-sparc.c (elf32_sparc_relocate_section): Remove bogus
8332 BFD_ASSERT.
8333
8334 * libbfd.c (bfd_malloc, bfd_realloc): New functions.
8335 (bfd_zmalloc): Return PTR, not char *. Take size_t, not
8336 bfd_size_type.
8337 * libbfd-in.h (bfd_malloc, bfd_realloc): Declare.
8338 (bfd_zmalloc): Change declaration.
8339 * libbfd.h: Rebuild.
8340 * Many files: Use bfd_malloc and bfd_realloc rather than malloc
8341 and realloc. Don't set bfd_error_no_memory if they fail.
8342
8343 Thu Nov 30 19:32:26 1995 Kim Knuttila <krk@cygnus.com>
8344
8345 * coff-ppc.c: Added macros to tidy up toc cell treatment. Numerous
8346 uses as well. Added a new howto to deal with TOCREL16 relocs that
8347 are TOCDEFN as well.
8348 (coff_ppc_relocate_section): Expanded treatment of ADDR32NB relocs
8349 to handle RVA relocs from dlltool.
8350 (ppc_coff_rtype2howto): TOCDEFN reloc addition.
8351 (coff_ppc_rtype_to_howto): TOCDEFN reloc addition.
8352 (ppc_coff_reloc_type_lookup): TOCDEFN reloc addition.
8353
8354 * coffcode.h (coff_set_alignment_hook): check idata$X sections
8355 to get the right section alignment.
8356
8357 Thu Nov 30 16:48:18 1995 Ian Lance Taylor <ian@cygnus.com>
8358
8359 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
8360 p_paddr if p_paddr is zero.
8361 (make_mapping): Set includes_filehdr and includes_phdrs for first
8362 PT_LOAD segment.
8363 (map_sections_to_segments): Set includes_phdrs for PT_PHDR
8364 segment.
8365 (assign_file_positions_for_segments): Handle includes_filehdr and
8366 includes_phdrs. Remove special handling of PT_PHDR and first
8367 PT_LOAD segments.
8368 (copy_private_bfd_data): Set includes_filehdr and includes_phdr
8369 when appropriate. Remove special handling of PT_PHDR segment.
8370 Use a more complex condition for when a section is included in a
8371 segment to handle Solaris linker oddities.
8372
8373 Thu Nov 30 11:17:33 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
8374
8375 * coff-m88k.c (howto_table): Reformatted for easier reading;
8376 special_function now points to new function m88k_special_reloc.
8377 (howto_hvrt16): Function previously used for handling HVRT16 relocs
8378 removed.
8379 (rtype2howto): Do not add reloc's r_offset to the addend, this will
8380 be done correctly by m88k_special_reloc.
8381 (reloc_processing): New function to be used by RELOC_PROCESSING.
8382 (RELOC_PROCESSING): Define to call reloc_processing.
8383
8384 Wed Nov 29 12:42:36 1995 Ian Lance Taylor <ian@cygnus.com>
8385
8386 * peicode.h (pe_print_idata): Call malloc rather than xmalloc.
8387 (pe_print_pdata): Likewise.
8388
8389 * opncls.c (bfd_alloc_by_size_t): Set bfd_error_no_memory if
8390 obstack_alloc fails.
8391 (bfd_alloc_finish): Set bfd_error_no_memory if obstack_finish
8392 fails.
8393 * libbfd.c (bfd_zmalloc): Set bfd_error_no_memory if malloc fails.
8394 * Many files: don't set bfd_error_no_memory if one of the above
8395 routines fails.
8396
8397 * elf.c (assign_file_positions_for_segments): Don't adjust p_paddr
8398 if p_paddr_valid is set.
8399 (copy_private_bfd_data): New static function.
8400 (_bfd_elf_copy_private_section_data): Call copy_private_bfd_data.
8401
8402 * elf.c (assign_file_positions_for_segments): Fix case where extra
8403 program headers were allocated.
8404
8405 * elf.c (_bfd_elf_print_private_bfd_data): New function.
8406 * elf-bfd.h (_bfd_elf_print_private_bfd_data): Declare.
8407 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define to
8408 _bfd_elf_print_private_bfd_data.
8409
8410 * coff-alpha.c (alpha_ecoff_swap_reloc_in): Don't abort if
8411 r_symndx is RELOC_SECTION_NONE for an ALPHA_R_IGNORE reloc.
8412 Change a RELOC_SECTION_LITA symndx to RELOC_SECTION_ABS.
8413 (alpha_ecoff_swap_reloc_out): Change RELOC_SECTION_ABS to
8414 RELOC_SECTION_LITA for ALPHA_R_IGNORE.
8415 (alpha_adjust_reloc_out): For ALPHA_R_IGNORE, don't change
8416 RELOC_SECTION_ABS to RELOC_SECTION_NONE.
8417
8418 Tue Nov 28 16:59:50 1995 Ian Lance Taylor <ian@cygnus.com>
8419
8420 * elf-bfd.h (struct elf_obj_tdata): Add segment_map field.
8421 * elf.c (make_mapping): New static function.
8422 (map_sections_to_segments): New static function.
8423 (elf_sort_sections): New static function.
8424 (assign_file_positions_for_segments): New static function.
8425 (map_program_segments): Remove.
8426 (get_program_header_size): Remove sorted_hdrs, count, and
8427 maxpagesize parameters. Simplify.
8428 (assign_file_positions_except_relocs): When generating an
8429 executable, use assign_file_positions_for_segments.
8430 (elf_sort_hdrs): Remove.
8431 (_bfd_elf_sizeof_headers): Remove eliminated parameters from call
8432 to get_program_header_size.
8433
8434 Mon Nov 27 12:27:46 1995 Ian Lance Taylor <ian@cygnus.com>
8435
8436 * hp300hpux.c (MY(callback)): Set lma as well as vma.
8437
8438 * configure, config.in: Regenerate with autoconf 2.7.
8439
8440 * elf32-i386.c (elf_backend_plt_readonly): Set correctly, to 1.
8441 * elf32-sparc.c (elf_backend_plt_readonly): Set correctly, to 0.
8442
8443 Wed Nov 22 12:02:09 1995 Ian Lance Taylor <ian@cygnus.com>
8444
8445 * ecoff.c (_bfd_ecoff_new_section_hook): Handle .rconst section.
8446 (ecoff_sec_to_styp_flags): Likewise.
8447 (_bfd_ecoff_styp_to_sec_flags): Handle STYP_RCONST.
8448 (ecoff_set_symbol_info): Handle scRConst.
8449 (ecoff_slurp_reloc_table): Handle RELOC_SECTION_RCONST.
8450 (ecoff_compute_section_file_positions): Handle .rconst section.
8451 (_bfd_ecoff_write_object_contents): Likewise.
8452 (ecoff_link_check_archive_element): Handle scRConst.
8453 (ecoff_link_add_externals): Likewise.
8454 (ecoff_link_write_external): Handle .rconst section.
8455 (ecoff_reloc_link_order): Likewise.
8456 * ecofflink.c (bfd_ecoff_debug_accumulate): Handle scRConst.
8457 * coff-alpha.c (alpha_convert_external_reloc): Handle .rconst
8458 section.
8459 (alpha_relocate_section): Handle RELOC_SECTION_RCONST.
8460
8461 * sunos.c (sunos_scan_dynamic_symbol): Only set written if the
8462 DEF_DYNAMIC flag is set.
8463
8464 Tue Nov 21 13:25:29 1995 Ken Raeburn <raeburn@cygnus.com>
8465
8466 * host-aout.c: If TRAD_HEADER is defined, include it.
8467
8468 Tue Nov 21 13:03:57 1995 Ian Lance Taylor <ian@cygnus.com>
8469
8470 * aclocal.m4 (AC_PROG_CC): Remove local definition.
8471 (BFD_BINARY_FOPEN): Require AC_CANONICAL_SYSTEM.
8472 (BFD_NEED_DECLARATION): New function.
8473 * configure.in: Use BFD_NEED_DECLARATION.
8474 * acconfig.h: Put NEED_DECLARATION_* in @TOP@ section.
8475 * configure, config.in: Rebuild with autoconf 2.6.
8476
8477 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Clear
8478 special_sections before returning when called with a non XCOFF
8479 BFD.
8480
8481 * coffgen.c (coff_renumber_symbols): Sort common symbols with
8482 global symbols.
8483
8484 * coffcode.h (coff_compute_section_file_positions): Only pad the
8485 previous section to force file alignment when creating an
8486 executable.
8487
8488 Mon Nov 20 14:54:09 1995 Ian Lance Taylor <ian@cygnus.com>
8489
8490 * coffcode.h (coff_compute_section_file_positions): If
8491 RS6000COFF_C, set up the .debug section.
8492
8493 * xcofflink.c (xcoff_link_input_bfd): Adjust the TOC anchor value
8494 if it is not large enough to accomodate the entire TOC area with
8495 signed 16 bit offsets.
8496 (xcoff_write_global_symbol): Handle negative TOC offsets in global
8497 linkage code.
8498 (_bfd_ppc_xcoff_relocate_section): Adjust relocations against a
8499 TOC anchor to use the TOC value used in the output file.
8500
8501 Sat Nov 18 18:01:41 1995 Ian Lance Taylor <ian@cygnus.com>
8502
8503 * coffgen.c (_bfd_coff_get_external_symbols): Cast malloc return.
8504 (_bfd_coff_read_string_table): Likewise.
8505
8506 Sat Nov 18 19:43:04 1995 Richard Earnshaw (rearnsha@armltd.co.uk)
8507
8508 * pe-arm.c: Fix typos.
8509 * coff-arm.c: Likewise.
8510
8511 Fri Nov 17 16:22:04 1995 Kim Knuttila <krk@cygnus.com>
8512
8513 * coff-ppc.c (list_ele): Added "cat"egory member.
8514 (record_toc): New category parameter (priv or pub).
8515 (ppc_record_toc_entry): Check to see if toc bounds exceeded.
8516 (ppc_process_before_allocation): Removed embrionic data-in-toc from
8517 the mainline. It addes extra toc cells in error.
8518 (ppc_coff_swap_sym_in_hook): Added some documentation.
8519 (dump_toc): Can now diagnose "virtual toc" chicanery.
8520
8521 Fri Nov 17 10:41:25 1995 Philippe De Muyter <phdm@info.ucl.ac.be>
8522
8523 * elf-bfd.h (struct elf_link_hash_table): Change type of
8524 dynsymcount and bucketcount fields from size_t to bfd_size_type.
8525
8526 Fri Nov 17 10:02:58 1995 Ian Lance Taylor <ian@cygnus.com>
8527
8528 * coffcode.h (coff_pointerize_aux_hook): I960 version: don't
8529 pointerize C_LEAFSTAT or C_LEAFEXT entries.
8530
8531 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Only create
8532 DT_INIT and DT_FINI entries if the _init or _fini symbol is
8533 defined or mentioned in a regular file.
8534
8535 Thu Nov 16 15:16:42 1995 Kim Knuttila <krk@cygnus.com>
8536
8537 * coff-ppc.c (ppc_record_data_in_toc_entry): new function
8538 (coff_ppc_relocate_section): Handle TOCDEFN attribute
8539 (coff_ppc_relocate_section): Correct REL24 handling
8540 (ppc_process_before_allocation): Correct TOCDEFN handling
8541
8542 * peicode.h (dir_names): Added name descriptions
8543
8544 Thu Nov 16 03:38:03 1995 Ken Raeburn <raeburn@cygnus.com>
8545
8546 * VERSION: Updated to cygnus-2.6.
8547
8548 Wed Nov 15 19:30:07 1995 Ken Raeburn <raeburn@cygnus.com>
8549
8550 * targets.c (m68k4knetbsd_vec): Declare.
8551
8552 Wed Nov 15 18:05:52 1995 Ian Lance Taylor <ian@cygnus.com>
8553
8554 * targets.c (bfd_target): Change type of second argument to
8555 _bfd_print_private_bfd_data from void * to PTR.
8556 * libbfd-in.h (_bfd_generic_bfd_print_private_bfd_data): Cast
8557 using PTR rather than void *.
8558 * bfd-in2, libbfd.h: Rebuild.
8559 * peicode.h (pe_print_private_bfd_data): Change vfile from void *
8560 to PTR.
8561 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define as
8562 _bfd_generic_bfd_print_private_bfd_data rather than casting
8563 bfd_true.
8564
8565 Wed Nov 15 04:09:14 1995 Ken Raeburn <raeburn@cygnus.com>
8566
8567 * Makefile.in (.dep1): Fix stupid typo in last change. Remove any
8568 "DO NOT DELETE" lines or blank lines that mkdep writes on some
8569 systems.
8570 (BFD_LIBS_CFILES, ALL_MACHINES_CFILES, BFD32_BACKENDS_CFILES,
8571 BFD64_BACKENDS_CFILES): New variables.
8572 (CFILES): Use them.
8573
8574 Tue Nov 14 11:52:23 1995 Ian Lance Taylor <ian@cygnus.com>
8575
8576 * peicode.h (coff_swap_aouthdr_out): For PPC PE, start isize at 0,
8577 not at the file position of the first section.
8578 * coffcode.h (coff_compute_section_file_positions): Avoid using
8579 unportable #elif.
8580 (coff_write_object_contents): When generating a PPC PE executable
8581 with no symbols, round up the file size to a COFF_PAGE_SIZE
8582 boundary.
8583 * cofflink.c (_bfd_coff_final_link): If there are no symbols,
8584 don't write out a string table.
8585
8586 * elf.c (bfd_section_from_shdr): When using a different section
8587 header, pass the new one to _bfd_elf_make_section_from_shdr.
8588 (elf_fake_sections): Don't set sh_info and sh_entsize fields.
8589 (elf_map_symbols): Add section VMA to symbol value when comparing
8590 against 0.
8591 (_bfd_elf_compute_section_file_positions): Only build symbol table
8592 if there are some symbols. Set file offset of symtab and strtab
8593 sections.
8594 (assign_file_positions_except_relocs): Remove dosyms parameter.
8595 Change all callers. Never set file offset of symtab and strtab
8596 sections.
8597 (_bfd_elf_copy_private_section_data): New function.
8598 (MAP_ONESYMTAB, MAP_DYNSYMTAB, MAP_STRTAB, MAP_SHSTRTAB): Define.
8599 (_bfd_elf_copy_private_symbol_data): New function.
8600 (swap_out_syms): Check for special mapping of st_shndx created by
8601 copy_private_symbol_data.
8602 * elfxx-target.h: Use new copy routines.
8603 * elf-bfd.h (_bfd_elf_copy_private_symbol_data): Declare.
8604 (_bfd_elf_copy_private_section_data): Declare.
8605
8606 * config.bfd (sh-*-*): Set targ_defvec to shcoff_vec.
8607
8608 * coffcode.h (coff_slurp_symbol_table): If COFF_WITH_PE, handle
8609 C_NT_WEAK.
8610
8611 * coff-sh.c (shlcoff_vec): Use _bfd_generic_archive_p, not
8612 _bfd_dummy_target, matching the recent change to archive
8613 recognition.
8614
8615 Mon Nov 13 13:24:38 1995 Ian Lance Taylor <ian@cygnus.com>
8616
8617 * libbfd.c (bfd_get_file_window): Use casts to avoid doing
8618 arithmetic on PTR types.
8619
8620 * aout-target.h (MY(callback)): Set the lma of the sections.
8621
8622 * ecoff.c (ecoff_reloc_link_order): Turn a reloc against a defined
8623 symbol into a reloc against the section.
8624
8625 Mon Nov 13 07:31:35 1995 Kim Knuttila <krk@cygnus.com>
8626
8627 * coff-ppc.c (ppc_coff_link_hash_entry): added support for inline
8628 glue for the relocs: IMGLUE and IFGLUE.
8629 (record_toc): new function - tracks toc contents
8630 (ppc_mark_symbol_as_glue): new function - supports the IMGLUE reloc
8631 (coff_ppc_relocate_section): Added support and fixes for IMGLUE/IFGLUE
8632 (ppc_coff_rtype2howto): removed invalid IMGLUE hack
8633 (coff_ppc_rtype_to_howto): removed invalid IMGLUE hack
8634 (ppc_record_toc_entry): Removed a debug define (duh)
8635
8636 * peicode.h (coff_swap_scnhdr_out): Fixed invalid strcmp for ".reldata"
8637 (pe_print_idata): New function - formats the idata section data
8638 (pe_print_pdata): New function - formats the pdata section data
8639 (pe_print_private_bfd_data): calls to above
8640
8641 Sun Nov 12 12:23:24 1995 Stan Shebs <shebs@andros.cygnus.com>
8642
8643 * Makefile.in (bfd_libs_here, etc): Provide empty definitions.
8644 * coff-rs6000.c (rs6000coff_vec): Add conditional defines
8645 TARGET_SYM and TARGET_NAME for vector and BFD name.
8646 * coff-pmac.c (pmac_xcoff_vec): Remove.
8647 (TARGET_SYM, TARGET_NAME): Define.
8648 * coffcode.h (coff_set_arch_mach_hook) [POWERMAC]: Set the
8649 machine to 0, not all PowerMacs are 601s.
8650
8651 Fri Nov 10 12:10:14 1995 Ian Lance Taylor <ian@cygnus.com>
8652
8653 * elfcode.h (elf_object_p): Read in any program headers.
8654 * elf.c (_bfd_elf_make_section_from_shdr): Adjust section lma
8655 based on the program headers, if any.
8656 (elf_fake_sections): Set sh_addr from the vma, not the lma.
8657 (map_program_segments): Set p_paddr of program headers based on
8658 the lma.
8659
8660 Thu Nov 9 13:01:31 1995 Ian Lance Taylor <ian@cygnus.com>
8661
8662 * archive.c (bfd_generic_archive_p): Preserve tdata in case of
8663 failure.
8664
8665 * aoutx.h (NAME(aout,final_link)): Report a reasonable error when
8666 trying to do a relocateable link with a non-a.out object file.
8667
8668 * archive.c (bfd_generic_archive_p): Check the first object file
8669 in an archive even if target_defaulted is set. If the object file
8670 has the wrong xvec, reject it.
8671
8672 * aoutx.h (NAME(aout,set_section_contents)): If a section can not
8673 be represented, report the name via _bfd_error_handler.
8674 (translate_to_native_sym_flags): Likewise.
8675 * elf32-mips.c (mips_elf_final_link): Likewise.
8676 * oasys.c (oasys_write_sections): Likewise.
8677
8678 * coffcode.h (coff_set_alignment_hook): Write RS6000COFF_C version
8679 which checks for STYP_OVRFLO sections.
8680 (coff_compute_section_file_positions): If RS6000COFF_C, handle
8681 reloc and lineno count overflows.
8682 (coff_write_object_contents): Call coff_count_linenumbers before
8683 coff_compute_section_file_positions. If RS6000COFF_C, handle
8684 reloc and lineno count overflows.
8685 * xcofflink.c (_bfd_xcoff_bfd_final_link): Count line numbers and
8686 relocs before dealing with .pad sections. Count overflow section
8687 headers when handling .pad sections.
8688
8689 * coffcode.h (coff_write_object_contents): Set a.out vstamp to 1
8690 if RS6000COFF_C.
8691
8692 * xcofflink.c (XCOFF_DESCRIPTOR): Define.
8693 (struct xcoff_link_hash_table): Add descriptor_section and
8694 special_sections fields.
8695 (_bfd_xcoff_bfd_link_hash_table_create): Initialize new fields.
8696 (xcoff_link_add_symbols): Set linkage section alignment. Create
8697 descriptor section. Check for magic symbol names (_text, etc.),
8698 and record them in special_sections if found. Set
8699 XCOFF_DESCRIPTOR flag for a function descriptor, and set its
8700 descriptor field to point back to the function code symbol.
8701 (xcoff_sweep): Always mark the special descriptor_section.
8702 (bfd_xcoff_export_symbol): Check whether the symbol might be a
8703 function descriptor, and mark it if it is.
8704 (bfd_xcoff_size_dynamic_sections): Add new special_sections
8705 parameter, and fill it in. Allocate space for the descriptor
8706 section.
8707 (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR flag when defining
8708 global linkage code. If an undefined function descriptor is
8709 exported, arrange to define it. Warn about any other undefined
8710 exported symbol.
8711 (_bfd_xcoff_bfd_final_link): Write out the descriptor section.
8712 (xcoff_write_global_symbol): Create a function descriptor when
8713 necessary.
8714 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
8715 * bfd-in2.h: Rebuild.
8716
8717 Thu Nov 9 08:40:23 1995 Kim Knuttila <krk@cygnus.com>
8718
8719 * coff-ppc.c (ppc_coff_link_hash_entry): new types for hashing
8720 (ppc_coff_link_hash_table): new types for hashing
8721 (ppc_coff_link_hash_newfunc): hash entry constructor
8722 (ppc_coff_link_hash_table_init): hash table initializer
8723 (ppc_coff_link_hash_table_create): hash table constructor
8724 (ppc_record_toc_entry): changed references to hash table
8725 (coff_ppc_relocate_section): changed references to hash table
8726
8727 * libcoff-in.h (coff_link_hash_entry): removed toc_offset
8728 * libcoff.h: Rebuild
8729
8730 * cofflink.c (_bfd_coff_link_hash_newfunc): removed toc_offset init
8731 (coff_link_add_symbols): removed toc_offset init
8732
8733 Thu Nov 9 04:00:38 1995 Ken Raeburn <raeburn@cygnus.com>
8734
8735 * Makefile.in (.dep1): Make sure the file mkdep is to write exists
8736 first.
8737
8738 * configure.in: Added new option --with[out]-mmap. Set USE_MMAP
8739 if it is given and mmep is available.
8740 * acconfig.h: Undef USE_MMAP.
8741 * configure, config.in: Regenerated.
8742 * aoutx.h: If USE_MMAP is not defined, do all symbol and string
8743 table handling the old way.
8744 (aout_get_external_symbols): Don't complain if last byte of string
8745 table is nonzero.
8746 * libbfd.c [HAVE_MADVISE]: Include sys/types.h and sys/mman.h.
8747 (bfd_free_window) [! USE_MMAP]: Don't define.
8748 (bfd_get_file_window,
8749 _bfd_generic_get_section_contents_in_window) [! USE_MMAP]: Abort.
8750
8751 Wed Nov 8 20:03:44 1995 Eric Freudenthal <freudenthal@nyu.edu>
8752
8753 * coff-a29k.c (SIGN_EXTEND_HWORD): Use ~0xffff rather than
8754 0xffff0000.
8755
8756 Wed Nov 8 11:31:11 1995 Ian Lance Taylor <ian@cygnus.com>
8757
8758 * coff-a29k.c (a29k_reloc): Change handling of R_IREL reloc to be
8759 compatible with AMD generated COFF files. Try to support both AMD
8760 and GNU formats simultaneously.
8761 (coff_a29k_relocate_section): Likewise.
8762
8763 * libbfd.c (bfd_get_file_window): Change writable parameter from
8764 int to boolean; update all callers. Pass MAP_SHARED if not
8765 writable--it's required on Solaris. Cast fprintf argument to
8766 avoid warning.
8767 * bfd-in.h (bfd_get_file_window): Update declaration.
8768 * bfd-in2.h: Rebuild.
8769 * aoutx.h: Update calls to bfd_get_file_window.
8770
8771 * xcofflink.c (XCOFF_DEF_DYNAMIC): Rename from XCOFF_REF_DYNAMIC.
8772 Change all uses.
8773 (xcoff_swap_ldhdr_in): New static function.
8774 (xcoff_swap_ldsym_in): New static function.
8775 (xcoff_find_reloc): Handle the case of a single reloc correctly.
8776 (xcoff_link_add_symbols): If we just created a descriptor, pass it
8777 to _bfd_generic_link_add_one_symbol, to save a hash lookup.
8778 Handle XTY_ER/XMC_XO symbols correctly.
8779 (xcoff_link_add_dynamic_symbols): Rewrite to read .loader symbols
8780 rather than normal symbol table.
8781 (bfd_xcoff_import_symbol): It's not an error if the symbol is
8782 already defined with the same absolute value.
8783 (xcoff_mark): When considering called symbols, check whether the
8784 descriptor is from a dynamic object, rather than the symbol
8785 itself.
8786 (xcoff_build_ldsyms): Likewise.
8787
8788 * libbfd.c (bfd_get_file_window): Change return type to boolean.
8789 Cast realloc and malloc return values. If malloc or realloc fail,
8790 set bfd_error_no_memory.
8791 * bfd-in.h (bfd_get_file_window): Change type to boolean.
8792 * bfd-in2.h: Rebuild.
8793
8794 Tue Nov 7 11:53:48 1995 Kim Knuttila <krk@cygnus.com>
8795
8796 * coff-ppc.c (ppc_record_toc_entry): new function.
8797 (in_reloc_p): changed return value.
8798 (coff_ppc_relocate_section): much rework.
8799 (ppc_allocate_toc_section): new function.
8800 (ppc_process_before_allocation): new function.
8801 (ppc_coff_swap_sym_in_hook): new function.
8802
8803 * cofflink.c (_bfd_coff_link_hash_newfunc): initialize toc_offset.
8804 (coff_link_add_symbols): initialize toc_offset.
8805
8806 * peicode.h (coff_swap_sym_in): Added coff_swap_sym_in_hook
8807 (coff_swap_aouthdr_out): Added more sections to the data
8808 dictionary for the pe file header. Also changed linker version
8809 number on the ppc side.
8810 (dir_names): small improvements to the dictionary printing.
8811 (pe_mkobject_hook): save the file level flags.
8812
8813 * libcoff-in.h (coff_link_hash_entry): added toc_offset field
8814 (pe_tdata): added real_flags field
8815 (coff_tdata): added local_toc_sym_map and access macro
8816
8817 * libcoff.h (coff_link_hash_entry): added toc_offset field
8818 (pe_tdata): added real_flags field
8819 (coff_tdata): added local_toc_sym_map and access macro
8820
8821 * coffcode.h (coff_set_alignment_hook): added hook for PE.
8822 (coff_mkobject): init for local_toc_sym_map
8823 (coff_write_object_contents): set the internal_a.magic to
8824 IMAGE_NT_OPTIONAL_HDR_MAGIC which appears to be what other
8825 ppc compilers use.
8826
8827 Tue Nov 7 13:48:58 1995 Ian Lance Taylor <ian@cygnus.com>
8828
8829 * ecofflink.c (_bfd_ecoff_locate_line): Keep looking through stabs
8830 entries until both the line number address and the function name
8831 address are too large.
8832
8833 * configure.in: Call AC_CHECK_PROG to find and cache AR.
8834 * configure: Rebuilt.
8835
8836 * aclocal.m4 (BFD_CC_FOR_BUILD): Don't define CC_FOR_BUILD if it
8837 is defined in the environment.
8838
8839 Tue Nov 7 10:57:24 1995 Jeffrey A Law (law@cygnus.com)
8840
8841 * som.c (som_get_section_contents_in_window): Define to use
8842 generic version.
8843
8844 Mon Nov 6 17:13:15 1995 Harry Dolan <dolan@ssd.intel.com>
8845
8846 * coff-i860.c: New file, based on coff-i386.c.
8847 * cpu-i860.c: New file, based on cpu-i386.c.
8848 * hosts/i860mach3.h: New file, based on hosts/i386mach3.h.
8849 * config.bfd (i860-*-mach3*, i860-*-osf1*, i860-*-coff*): New
8850 targets, using i860coff_vec.
8851 * configure.in (i860-*-mach3*, i860-*-osf1*): New hosts, using
8852 trad-core.o and hosts/i860mach3.h.
8853 (i860coff_vec): Use coff-i860.o and cofflink.o.
8854 * configure: Rebuild.
8855 * Makefile.in: Rebuild dependencies.
8856 (ALL_MACHINES): Add cpu-i860.o.
8857 (BFD32_BACKENDS): Add coff-i860.o.
8858 (CFILES): Add cpu-i860.c and coff-i860.c.
8859 * targets.c (i860coff_vec): Declare.
8860 (bfd_target_vector): Add &i860coff_vec.
8861 * archures.c (bfd_i860_arch): Declare.
8862 (bfd_archures_list): Add &bfd_i860_arch.
8863 * coffcode.h (coff_set_arch_mach_hook): Handle I860 magic number.
8864 (coff_set_flags): Handle bfd_arch_i860.
8865 (coff_write_object_contents): Handle I860 a.out magic number.
8866
8867 Mon Nov 6 14:34:07 1995 Ian Lance Taylor <ian@cygnus.com>
8868
8869 * xcofflink.c (xcoff_link_add_symbols): Set the alignment power of
8870 the created .tc section to 2.
8871 (xcoff_mark): Don't keep a .loader reloc for a call to an
8872 undefined symbol when creating a shared library.
8873 (xcoff_build_ldsyms): When creating a shared library, generate
8874 global linkage code for a call to an undefined symbol.
8875
8876 Sun Nov 5 21:44:13 1995 Ken Raeburn <raeburn@cygnus.com>
8877
8878 * Makefile.in (CFILES): Rebuild list from BFD_LIBS, ALL_MACHINES,
8879 BFD32_BACKENDS, BFD64_BACKENDS.
8880 (.dep1): Put mkdep output in a separate file.
8881 Rebuilt dependencies.
8882
8883 * ecoff.c (_bfd_ecoff_slurp_armap): Cast _bfd_read_ar_hdr return
8884 value.
8885
8886 Permit use of mmap when available:
8887
8888 * configure.in: Check for mmap, madvise, mprotect.
8889 * config.in, configure: Regenerated.
8890
8891 * libbfd.c (struct _bfd_window_internal): Define type.
8892 (bfd_init_window, bfd_free_window, bfd_get_file_window): New
8893 functions.
8894 (ok_to_map): New static variable for debugging.
8895 (_bfd_generic_get_section_contents_in_window): New function.
8896 * bfd-in.h (bfd_window_internal): Declare type.
8897 (bfd_window): Define type.
8898 (bfd_init_window, bfd_free_window, bfd_get_file_window): Declare.
8899 * libbfd-in.h (_bfd_generic_get_section_contents_in_window):
8900 Declare.
8901
8902 * libaout.h (struct aoutdata): Add two window fields.
8903 (obj_aout_sym_window, obj_aout_string_window): New macros.
8904 * aoutx.h (some_aout_object_p): Initialize windows.
8905 (aout_get_external_symbols): Get symbol data and strings in
8906 windows instead of explicitly allocated buffers.
8907 (slurp_symbol_table): Free window instead of memory.
8908 (bfd_free_cached_info): Release windows instead of freeing storage
8909 directly.
8910 (aout_link_free_symbols): Ditto.
8911
8912 * targets.c (bfd_target): Add new field for
8913 get_section_contents_in_window.
8914 (BFD_JUMP_TABLE_GENERIC): Updated.
8915 * aout-adobe.c, aout-target.h, binary.c, bout.c, coff-alpha.c,
8916 coff-mips.c, elfxx-target.h, i386msdos.c, i386os9k.c, ieee.c,
8917 libcoff-in.h, oasys.c, srec.c, tekhex.c, versados.c: Added new
8918 macros for get_section_contents_in_window field.
8919
8920 Sat Nov 4 12:23:26 1995 Fred Fish <fnf@cygnus.com>
8921
8922 * core.c: Renamed to corefile.c
8923 * makefile.dos (OBJS): Change core.o to corefile.o
8924 * Makefile.in (CFILES, BFD_LIBS): Use corefile.c instead of core.c
8925
8926 Fri Nov 3 15:54:59 1995 Ian Lance Taylor <ian@cygnus.com>
8927
8928 * xcofflink.c (xcoff_link_add_symbols): Rename local variable sub
8929 to o. Clobber and restore the list of new csects around the call
8930 to _bfd_generic_link_add_one_symbol, in case it wants to report a
8931 linker error and the linker wants to read the symbol table. Reset
8932 the line number count of a real section even if it has no relocs.
8933 (_bfd_xcoff_bfd_final_link): If shared, set the DYNAMIC flag.
8934
8935 * coffgen.c (_bfd_coff_read_string_table): Warn if the string size
8936 is too small.
8937
8938 Thu Nov 2 23:16:39 1995 Ian Lance Taylor <ian@cygnus.com>
8939
8940 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Don't warn about
8941 an undefined symbol in a shared link.
8942
8943 * linker.c (_bfd_generic_link_add_one_symbol): Correct type of
8944 oldtype from bfd_link_order_type to bfd_link_hash_type. From
8945 phdm@info.ucl.ac.be (Philippe De Muyter).
8946
8947 Wed Nov 1 14:26:02 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
8948
8949 * coff-m88k.c (rtype2howto): New static function.
8950 (RTYPE2HOWTO): Use it rather than a macro definition.
8951
8952 * coffcode.h (coff_write_object_contents): set internal_a.magic
8953 to PAGEMAGICPEXECPAGED #if defined (M68) && !defined (LYNXOS).
8954
8955 * configure.in: m68*-motorola-sysv* does not use ptrace-core.o;
8956 define TRAD_HEADER to new file hosts/delta68.h.
8957 m88*-motorola-sysv*, however, does use ptrace-core.o.
8958 * hosts/delta68.h: New file.
8959
8960 * ptrace-core.c (ptrace_unix_core_file_p): change bfd_zmalloc to
8961 bfd_zalloc; provide proper parm abfd to calls to bfd_zalloc.
8962
8963 Wed Nov 1 13:51:54 1995 Ken Raeburn <raeburn@cygnus.com>
8964
8965 * i386linux.c (MY(vec)): Declare before use.
8966
8967 Wed Nov 1 11:45:07 1995 Ian Lance Taylor <ian@cygnus.com>
8968
8969 * reloc16.c (bfd_coff_reloc16_get_relocated_section_contents):
8970 Pass input_bfd, not in_bfd, to bfd_coff_reloc16_extra_cases.
8971
8972 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
8973 BFD is not of the right type.
8974 (bfd_elf_get_needed_list): Likewise.
8975 * i386linux.c (bfd_linux_size_dynamic_sections): Likewise.
8976 * sunos.c (bfd_sunos_get_needed_list): Likewise.
8977 * xcofflink.c (XCOFF_XVECP): Define.
8978 (bfd_xcoff_link_record_set): Don't do anything if the BFD is not
8979 of the right type.
8980 (bfd_xcoff_import_symbol): Likewise.
8981 (bfd_xcoff_export_symbol): Likewise.
8982 (bfd_xcoff_link_count_reloc): Likewise.
8983 (bfd_xcoff_record_link_assignment): Likewise.
8984 (bfd_xcoff_size_dynamic_sections): Likewise.
8985
8986 * sunos.c (sunos_scan_ext_relocs): Only check the reloc symbol
8987 table index against the number of symbols for a base relative
8988 reloc.
8989
8990 * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Change from macro to
8991 static function.
8992 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Set
8993 full_aouthdr flag here...
8994 (_bfd_xcoff_bfd_final_link): ...not here.
8995
8996 Tue Oct 31 12:52:02 1995 Fred Fish <fnf@cygnus.com>
8997
8998 * libelf.h: Rename to elf-bfd.h to avoid conflict with
8999 systems that have a system <libelf.h>.
9000 * Makefile.in: Globally replace libelf.h with elf-bfd.h.
9001 * bfd.c, elf.c, elf32-arc.c, elf32-gen.c, elf32-hppa.c,
9002 elf32-hppa.h, elf32-i386.c, elf32-i860.c, elf32-m68k.c,
9003 elf32-m88k.c, elf32-mips.c, elf32-ppc.c, elf32-sparc.c,
9004 elf64-gen.c, elf64-sparc.c, elfcode.h, elflink.c,
9005 elfxx-target.h: Include elf-bfd.h rather than libelf.h.
9006 * elfxx-target.h: Change libelf.h reference to elf-bfd.h.
9007
9008 Tue Oct 31 15:30:07 1995 David Mosberger-Tang <davidm@azstarnet.com>
9009
9010 * ecoff.c (ecoff_set_symbol_info): Add new parameter weak. If
9011 set, set BSF_WEAK in symbol. Change all callers.
9012 (ecoff_get_extr): Set weakext based on BSF_WEAK.
9013 (ecoff_link_add_externals): If weakext is set, pass BSF_WEAK to
9014 _bfd_generic_link_add_one_symbol.
9015 (ecoff_indirect_link_order): Check that the section tdata relocs
9016 are not NULL before using them.
9017
9018 * configure.in (alpha*-*-linux*): Set COREFILE to trad-core.o and
9019 define TRAD_HEADER as hosts/alphalinux.h.
9020 * configure: Rebuild.
9021 * hosts/alphalinux.h: New file.
9022 * trad-core.c (trad_unix_core_file_p): Cast u.u_ar0 to bfd_vma,
9023 not int.
9024
9025 Tue Oct 31 12:34:11 1995 Ian Lance Taylor <ian@cygnus.com>
9026
9027 * coffcode.h (coff_slurp_symbol_table): Accept C_BCOMM and
9028 C_ECOMM storage classes.
9029
9030 * xcofflink.c (xcoff_mark_symbol): New static function, broken out
9031 of xcoff_mark.
9032 (xcoff_mark): Call xcoff_mark_symbol.
9033 (bfd_xcoff_export_symbol): Call xcoff_mark_symbol.
9034 (bfd_xcoff_link_count_reloc): Call xcoff_mark_symbol rather than
9035 doing it by hand.
9036 (xcoff_build_ldsyms): Build a .loader symbol for an export symbol.
9037
9038 Mon Oct 30 14:53:48 1995 Ian Lance Taylor <ian@cygnus.com>
9039
9040 * xcofflink.c (struct xcoff_final_link_info): Add new line_filepos
9041 field.
9042 (xcoff_find_reloc): New static function.
9043 (xcoff_link_add_symbols): Use it.
9044 (_bfd_xcoff_bfd_final_link): Set finfo.line_filepos.
9045 (xcoff_link_input_bfd): Handle C_BINCL and C_EINCL. Don't
9046 relocate the value of C_DECL.
9047
9048 * elf.c (elf_fake_sections): Remove bogus BFD_ASSERT.
9049
9050 Sat Oct 28 01:25:34 1995 steve chamberlain <sac@slash.cygnus.com>
9051
9052 * cofflink.c (_bfd_coff_generic_relocate_section): Make
9053 callback decide what goes in .relocs.
9054 * pe[i]-i386.c (TARGET_UNDERSCORE): Define.
9055 * peicode.h (pe_mkobject_hook): Only copy aouthdr if
9056 there is one.
9057
9058 Sat Oct 28 01:51:02 1995 Ian Lance Taylor <ian@cygnus.com>
9059
9060 * xcofflink.c (xcoff_link_add_symbols): Handle csects in the
9061 absolute section.
9062
9063 Fri Oct 27 18:14:39 1995 Ian Lance Taylor <ian@cygnus.com>
9064
9065 * xcofflink.c: More improvements, mostly to fix handling of
9066 constructors and a few other special cases.
9067 * coff-rs6000.c (rs6000coff_vec): Set symbol_leading_char back to
9068 zero, reverting yesterday's change.
9069 * bfd-in.h (bfd_xcoff_link_record_set): Declare.
9070 (bfd_xcoff_link_count_reloc): Declare.
9071 (bfd_xcoff_record_link_assignment): Declare.
9072 * bfd-in2.h: Rebuild.
9073
9074 Fri Oct 27 14:42:15 1995 Niklas Hallqvist <niklas@appli.se>
9075
9076 * PORTING, aout-arm.c, aout-encap.c, aout-target.h,
9077 aoutx.h, gen-aout.c, host-aout.c, hp300bsd.c, i386aout.c
9078 i386bsd.c, i386dynix.c, i386linux.c, i386lynx.c, i386mach3.c,
9079 i386netbsd.c, m68klynx.c, m88kmach3.c, mipsbsd.c, newsos3.c,
9080 ns32knetbsd.c, pc532-mach.c, riscix.c, sparclynx.c, sparcnetbsd.c:
9081 Change PAGE_SIZE to TARGET_PAGE_SIZE.
9082
9083 * m68knetbsd.c: Ditto as well as add support for the m68k4k object
9084 format.
9085
9086 * netbsd.h: Double ditto (incl. m68k4k support). NetBSD's text
9087 segments includes the a.out header. See to that the magic number
9088 *always* is big-endian.
9089
9090 * config.bfd: Add m68*-hp*-netbsd* case. Cross-pollinate m68k and
9091 m68k4k NetBSD configurations.
9092
9093 * configure.in, configure: Separate i386 & mips NetBSD
9094 configurations from other BSD ones. Don't assume DEC is the only
9095 thing NetBSD/mips run on. Add {m68k,ns32k,sparc}-*-netbsd*
9096 configurations. Add support for m68k4k NetBSD object format.
9097
9098 * libaout.h: Added M_68K4K_NETBSD magic.
9099
9100 * m68k4knetbsd.c: New file.
9101
9102 * hosts/{m68k,sparc}nbsd.h: Don't define HOST_BIG_ENDIAN_P.
9103
9104 * hosts/nbsd.h: Define HOST_BIG_ENDIAN_P according to
9105 <machine/endian.h>.
9106
9107 * hosts/mipsnbsd.h: New file.
9108
9109 Thu Oct 26 14:16:47 1995 Ian Lance Taylor <ian@cygnus.com>
9110
9111 * xcofflink.c: Numerous changes to get closer to a working XCOFF
9112 linker.
9113 * libcoff-in.h (struct xcoff_tdata): Add full_aouthdr,
9114 toc_section, and entry_section fields.
9115 (struct xcoff_section_tdata): Remove ldrel_count field.
9116 * libcoff.h: Rebuild.
9117 * coffcode.h (coff_mkobject_hook): Initialize new xcoff_data
9118 fields.
9119 (coff_compute_section_file_positions): If RS6000COFF_C, generate
9120 full a.out header if full_aouthdr is set in xcoff_data.
9121 (coff_write_object_contents): Likewise. Set o_snentry and o_sntoc
9122 based on sections stored in xcoff_data.
9123 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy new xcoff_data
9124 fields.
9125 (xcoff_reloc_type_lookup): Handle BFD_RELOC_CTOR.
9126 (rs6000coff_vec): Set symbol_leading_char to '.'.
9127 * coffgen.c (coff_get_symbol_info): If fix_value is set, fix the
9128 value stored in ret rather than returning a pointer value.
9129
9130 Wed Oct 25 23:10:39 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9131
9132 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Remove MAC
9133 format for now.
9134
9135 Wed Oct 25 16:19:27 1995 Jeffrey A Law (law@cygnus.com)
9136
9137 * som.c (som_slurp_string_table): Allocate the strings with malloc
9138 since they're free'd by free_cached_info.
9139 (som_slurp_symbol_table): Similarly for the symbol table.
9140
9141 Wed Oct 25 14:59:22 1995 Per Bothner <bothner@kalessin.cygnus.com>
9142
9143 * Makefile.in (diststuff): Don't make headers.
9144
9145 Wed Oct 25 11:32:54 1995 Ian Lance Taylor <ian@cygnus.com>
9146
9147 * Makefile.in: Rebuild dependencies.
9148
9149 * sunos.c (bfd_sunos_record_link_assignment): Don't do anything if
9150 output_bfd is not SunOS.
9151 (bfd_sunos_size_dynamic_sections): Likewise. Don't scan relocs of
9152 non-SunOS input files.
9153
9154 * xcofflink.c: Extensive changes to support linking shared objects
9155 and generating a .loader section.
9156 * libcoff-in.h (struct xcoff_tdata): Add import_file_id field.
9157 (struct xcoff_section_tdata): Add lineno_count, first_symndx,
9158 last_symndx, and ldrel_count fields.
9159 * libcoff.h: Rebuild.
9160 * coff-rs6000.c (xcoff_howto_table): Correct reloc names.
9161 * coffcode.h (styp_to_sec_flags): Don't set any flags if STYP_PAD
9162 is set.
9163 * bfd-in.h (bfd_xcoff_import_symbol): Declare.
9164 (bfd_xcoff_export_symbol): Declare.
9165 (bfd_xcoff_size_dynamic_sections): Declare.
9166 * bfd-in2.h: Rebuild.
9167
9168 Tue Oct 24 17:44:20 1995 Stan Shebs <shebs@andros.cygnus.com>
9169
9170 * configure.in: Add xcofflink.o to pmac_xcoff_vec.
9171 * configure: Rebuild.
9172 * mpw-config.in: Add xcofflink.c.o to powerpc-apple-macos.
9173 * coff-pmac.c: Include coff-rs6000.c instead of duplicating its
9174 contents.
9175 (pmac_xcoff_vec): Update to use new xcoff support.
9176 * coff-rs6000.c (xcoff_generic_stat_arch_elt): Make static.
9177 (xcoff_write_armap): Declare buf as unsigned char.
9178 * xcofflink.c (xcoff_link_add_symbols): Declare a local as PTR.
9179
9180 * mpw-make.sed: Generalize subdir_do edit.
9181
9182 Tue Oct 24 10:25:01 1995 Jeffrey A Law (law@cygnus.com)
9183
9184 * hppabsd-core.c (make_bfd_asection): Initialize asect->filepos
9185 correctly. Don't initialize asect->vma.
9186
9187 Fri Oct 20 13:23:48 1995 Ken Raeburn <raeburn@cygnus.com>
9188
9189 * opncls.c (_bfd_new_bfd): If _bfd_chunksize wasn't preset, use
9190 something a little less than the page size.
9191
9192 Thu Oct 19 13:06:09 1995 Ian Lance Taylor <ian@cygnus.com>
9193
9194 * coff-i960.c (coff_i960_adjust_symndx): Clear *adjustedp.
9195
9196 Wed Oct 18 16:20:08 1995 steve chamberlain <sac@slash.cygnus.com>
9197
9198 * coff-i386.c (coff_i386_reloc_type_lookup): New.
9199 * coffcode.h (coff_write_object_contents): If .bss is before
9200 .data us that as data_start.
9201 * cofflink.c (_bfd_coff_generic_relocate_section): Get reloc
9202 calc correct.
9203 * peicode.h (add_data_entry): Use _cooked_size of data directory.
9204 (coff_swap_outhdr_out): Hardwire in version number.
9205
9206 Wed Oct 18 16:50:54 1995 Ken Raeburn <raeburn@cygnus.com>
9207
9208 * sunos.c (sunos_add_dynamic_symbols): Rename local variables
9209 major and minor to *_vno, since the former are also macros in
9210 SunOS header files. Cast result of bfd_alloc to appropriate
9211 type.
9212
9213 * coffgen.c (coff_find_nearest_line): Cast used_by_bfd value
9214 before assigning to sec_data.
9215
9216 Wed Oct 18 13:25:17 1995 Ian Lance Taylor <ian@cygnus.com>
9217
9218 * ecoff.c (_bfd_ecoff_find_nearest_line): The offset argument is
9219 now relative to the section, not absolute.
9220 * ecofflink.c (_bfd_ecoff_locate_line): Use the right symbol to
9221 get the file name when there is a N_SO directory name. When
9222 handling stabs, remember that section->vma was added to the
9223 offset.
9224
9225 Tue Oct 17 18:24:54 1995 Ian Lance Taylor <ian@cygnus.com>
9226
9227 * sunos.c (struct sunos_link_hash_table): Add needed field.
9228 (sunos_link_hash_table_create): Call bfd_release, not free.
9229 (sunos_link_hash_table_create): Initialize needed field.
9230 (sunos_add_dynamic_symbols): Record needed objects.
9231 (bfd_sunos_get_needed_list): New function.
9232 * bfd-in.h (bfd_sunos_get_needed_list): Declare.
9233 * bfd-in2.h: Rebuild.
9234
9235 Mon Oct 16 14:43:59 1995 steve chamberlain <sac@slash.cygnus.com>
9236
9237 * libcoff-in.h (pe_data_type.in_reloc_p): New.
9238
9239 Mon Oct 16 10:52:50 1995 Ian Lance Taylor <ian@cygnus.com>
9240
9241 * bfd-in.h (struct bfd_link_needed_list): Rename from
9242 bfd_elf_link_needed_list.
9243 * bfd-in2.h: Rebuild.
9244 * elf.c, elflink.h, libelf.h: Corresponding changes.
9245
9246 Add start at AIX linker support; no shared libraries yet.
9247 * xcofflink.c: New file.
9248 * configure.in (rs600coff_vec): Use xcofflink.o.
9249 * configure: Rebuild.
9250 * libcoff-in.h (struct xcoff_tdata): Add csects and debug_indices
9251 fields.
9252 (struct xcoff_section_tdata): Define.
9253 (xcoff_section_data): Define macro.
9254 (_bfd_xcoff_bfd_link_hash_table_create): Declare.
9255 (_bfd_xcoff_bfd_link_add_symbols): Declare.
9256 (_bfd_xcoff_bfd_final_link): Declare.
9257 (_bfd_ppc_xcoff_relocate_section): Declare.
9258 * libcoff.h: Rebuild.
9259 * coff-rs6000.c: Clean up a bit.
9260 (xcoff_mkobject): Default modtype to 1L, not RE. Initialize
9261 cputype, csects, and debug_indices.
9262 (xcoff_copy_private_bfd_data): Copy cputype.
9263 (xcoff_howto_table): Rename from rs6000coff_howto_table.
9264 (xcoff_rtype2howto): Rename from rs6000coff_rtype2howto.
9265 (xcoff_reloc_type_lookup): Rename from
9266 rs6000coff_reloc_type_lookup.
9267 (coff_relocate_section): Define.
9268 (_bfd_xcoff_sizeof_headers): Define.
9269 (_bfd_xcoff_bfd_get_relocated_section_contents): Define.
9270 (_bfd_xcoff_bfd_relax_section): Define.
9271 (_bfd_xcoff_bfd_link_split_section): Define.
9272 (rs6000coff_vec): For BFD_JUMP_TABLE_LINK, use _bfd_xcoff, not
9273 coff.
9274 * coffcode.h (coff_compute_section_file_positions): If AIX,
9275 increment sofar by SMALL_AOUTSZ if not executable.
9276 (coff_write_object_contents): If AIX, always output an a.out
9277 header; if not executable, header size of SMALL_AOUTSZ.
9278 * hash.c (struct bfd_strtab_hash): Add xcoff field.
9279 (_bfd_stringtab_init): Initialize xcoff field.
9280 (_bfd_xcoff_stringtab_init): New function.
9281 (_bfd_stringtab_add): In XCOFF mode, leave two bytes for length.
9282 (_bfd_stringtab_emit): In XCOFF mode, write out length.
9283 * libbfd-in.h (_bfd_xcoff_stringtab_init): Declare.
9284 * libbfd.h: Rebuild.
9285 * Makefile.in: Rebuild dependencies.
9286 (BFD32_BACKENDS): Add xcofflink.o.
9287 (CFILES): Add xcofflink.c.
9288
9289 * elf32-mips.c (mips_elf_symbol_processing): Set SEC_ALLOC, not
9290 SEC_NO_FLAGS, for .acommon section. From Peter Schauer
9291 <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>.
9292
9293 Sat Oct 14 21:36:02 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9294
9295 * coff-ppc.c (in_reloc_p): Add, clone from coff-i386.c.
9296
9297 Fri Oct 13 17:48:43 1995 Ken Raeburn <raeburn@cygnus.com>
9298
9299 * acconfig.h (HAVE_SYS_PROCFS_H): Undef, with comment.
9300 * config.in: Regenerated.
9301
9302 * opncls.c (getpagesize) [!HAVE_GETPAGESIZE]: Define as 2048.
9303 (_bfd_chunksize): New variable.
9304 (_bfd_new_bfd): Set it to getpagesize() if negative, and use it
9305 for obstack chunk size.
9306 * configure.in: Check for getpagesize.
9307 * configure: Regenerated.
9308
9309 Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
9310
9311 * trad-core.c (rawptr): Make it a local variable of
9312 ptrace_unix_core_file_p.
9313
9314 Fri Oct 13 11:22:01 1995 steve chamberlain <sac@slash.cygnus.com>
9315
9316 * coff-arm.c (in_reloc_p): New.
9317 * coff-i386.c (in_reloc_p): New.
9318 * coffcode.h: Allways include peicode.h if COFF_WITH_PE.
9319 (coff_write_object_contents): Only set has_reloc_section
9320 if PE_IMAGE.
9321 * cofflink.c (_bfd_coff_generic_relocate_section): Call
9322 in_reloc_p to decide if reloc should be emitted.
9323 * libcoff.h (pe_data_type.in_reloc_p): New.
9324 * peicode.h (pe_mkobject): Initialize in_reloc_p.
9325
9326 Wed Oct 11 00:49:29 1995 Ian Lance Taylor <ian@cygnus.com>
9327
9328 * cofflink.c (_bfd_coff_internal_syment_name): Move to coffgen.c.
9329 (_bfd_coff_read_internal_relocs): Likewise.
9330 * coffgen.c (_bfd_coff_internal_syment_name): Copy from coffgen.c.
9331 (_bfd_coff_read_internal_relocs): Likewise.
9332
9333 * elflink.h (elf_link_add_object_symbols): Correct conditions
9334 under which type and size change warnings are issued.
9335
9336 Tue Oct 10 18:32:46 1995 Ian Lance Taylor <ian@cygnus.com>
9337
9338 * coffgen.c (coff_count_linenumbers): Don't count line numbers for
9339 a symbol which is not in a real section.
9340 (coff_write_native_symbol): Corresponding change.
9341
9342 * cofflink.c (_bfd_coff_link_hash_newfunc): Rename from
9343 coff_link_hash_newfunc and make non-static.
9344 (_bfd_coff_link_hash_table_init): New function, broken out of
9345 _bfd_coff_link_hash_table_create.
9346 (_bfd_coff_link_hash_table_create): Use it.
9347 (process_embedded_commands): Make static.
9348 * libcoff-in.h ((_bfd_coff_link_hash_newfunc): Declare.
9349 (_bfd_coff_link_hash_table_init): Declare.
9350 * libcoff.h: Rebuild.
9351
9352 * coffcode.h (coff_mkobject_hook): If RS6000COFF_C, set cputype
9353 field in XCOFF tdata.
9354 (coff_set_arch_mach_hook): Check ifdef RS6000COFF_C, not ifdef
9355 U802ROMAGIC, for clarity. Try to set arch and machine correctly
9356 based on cputype stored in a.out header, or in n_type of initial
9357 .file symbol.
9358 (coff_write_object_contents): Set cputype correctly in a.out
9359 header.
9360 (coff_slurp_symbol_table): Add casts to file_ptr to avoid
9361 warnings.
9362 * coffswap.h (coff_swap_aouthdr_in): Swap in cputype field.
9363 (coff_swap_aouthdr_out): Swap out cputype field. Don't clear
9364 old resv1 field.
9365 * libcoff-in.h (struct xcoff_tdata): Add cputype field.
9366 * libcoff.h: Rebuild.
9367
9368 * cpu-rs6000.c (rs6000_compatible): New static function.
9369 (bfd_rs6000_arch): Use it.
9370 * cpu-powerpc.c (powerpc_compatible): New static function.
9371 (arch_info_struct): Define various flavours of PowerPC.
9372 (bfd_powerpc_arch): Use powerpc_compatible. Point at
9373 arch_info_struct.
9374
9375 Tue Oct 10 10:50:46 1995 Fred Fish <fnf@cygnus.com>
9376
9377 * Makefile.in (FLAGS_TO_PASS): Remove BISON.
9378
9379 Tue Oct 10 01:28:29 1995 Ian Lance Taylor <ian@cygnus.com>
9380
9381 * elflink.h (elf_link_add_object_symbols): Don't warn about
9382 changing the size or type if the old definition was weak.
9383
9384 Mon Oct 9 11:24:08 1995 Ian Lance Taylor <ian@cygnus.com>
9385
9386 * coffcode.h (combined_entry_type): Add fix_line field.
9387 (coff_slurp_line_table): Warn if we try to set the lineno field of
9388 a symbol twice.
9389 (coff_slurp_symbol_table): If RS6000COFF_C, handle C_BINCL and
9390 C_EINCL by setting fix_line. Fix C_BSTAT symbol value.
9391 * coffgen.c (coff_mangle_symbols): Handle fix_line.
9392 (coff_write_symbol): Only use N_DEBUG if the symbol is in the
9393 absolute section.
9394 (coff_print_symbol): Print fix_value symbols in a useful fashion.
9395 * libcoff.h: Rebuild.
9396
9397 * libcoff-in.h (struct xcoff_tdata): Define.
9398 (xcoff_data): Define.
9399 * bfd.c (struct _bfd): Add xcoff_obj_data field to tdata union.
9400 * bfd-in2.h, libcoff.h: Rebuild.
9401 * coff-rs6000.c (xcoff_mkobject): New static function.
9402 (coff_mkobject): Define.
9403 (xcoff_copy_private_bfd_data): New static function.
9404 (coff_bfd_copy_private_bfd_data): Define.
9405 (rs6000coff_howto_table): Change R_TOC complain_on_overflow from
9406 signed to bitfield.
9407 (rs6000coff_vec): Add DYNAMIC to object_flags.
9408 * coffcode.h (sec_to_styp_flags): If RS6000COFF_C, handle .pad and
9409 .loader sections specially.
9410 (coff_new_section_hook): If RS6000COFF_C, get the .text and .data
9411 section alignment from the XCOFF tdata information.
9412 (coff_mkobject_hook): If RS6000COFF_C, set DYNAMIC based on
9413 F_SHROBJ, and copy the extra a.out header information into the
9414 XCOFF tdata structure.
9415 (coff_write_object_contents): If RS6000COFF_C, set F_SHROBJ,
9416 F_DYNLOAD and the extra a.out header information.
9417 (coff_slurp_symbol_table): Set BSF_NOT_AT_END for a C_EXT or
9418 C_HIDEXT symbol with attached csect information.
9419 * coffswap.h (coff_swap_aouthdr_in): If RS6000COFF_C, swap
9420 in the o_maxdata field.
9421 (coff_swap_aouthdr_out): If RS6000COFF_C, swap extra XCOFF fields.
9422 * coffgen.c (coff_renumber_symbols): Don't move any symbol to the
9423 end if BSF_NOT_AT_END is set.
9424
9425 * targets.c (bfd_target): Rename _bfd_read_ar_hdr field to
9426 _bfd_read_ar_hdr_fn.
9427 * libbfd-in.h (_bfd_read_ar_hdr): Update accordingly.
9428 * bfd-in2.h, libbfd.h: Rebuild.
9429 * archive.c (_bfd_get_elt_at_filepos): Cast _bfd_read_ar_hdr
9430 return value.
9431 (do_slurp_bsd_armap, do_slurp_coff_armap): Likewise.
9432 (bfd_slurp_bsd_armap_f2): Likewise.
9433 (_bfd_slurp_extended_name_table): Likewise.
9434
9435 Fri Oct 6 16:18:35 1995 Ken Raeburn <raeburn@cygnus.com>
9436
9437 Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
9438
9439 * archive.c (bfd_get_next_mapent): Return BFD_NO_MORE_SYMBOLS
9440 when the symbol table is empty.
9441
9442 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Don't reserve
9443 space for section symbols, since we don't output them either.
9444 (elf_m68k_adjust_dynindx): Removed.
9445
9446 * ptrace-core.c (rawptr): Make it a local variable of
9447 ptrace_unix_core_file_p.
9448
9449 Fri Oct 6 12:24:47 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9450
9451 * coff-rs6000.c (xcoff_write_archive_contents): Return false, not
9452 NULL.
9453
9454 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Add NT, and
9455 Mac object file formats.
9456
9457 Fri Oct 6 12:04:02 1995 Ian Lance Taylor <ian@cygnus.com>
9458
9459 * coffgen.c (coff_fix_symbol_name): Don't try to set up file
9460 auxent if there isn't one.
9461 (coff_write_symbols): If there is no file auxent, use SYMNMLEN
9462 rather than FILNMLEN as the maximum name length.
9463
9464 * coffcode.h (bfd_coff_backend_data): Add new field
9465 _bfd_coff_print_aux.
9466 (bfd_coff_print_aux): New static function.
9467 (coff_pointerize_aux_hook (RS6000COFF_C version)): Pointerize the
9468 scnlen field of an XTY_LD csect aux entry.
9469 (coff_print_aux): New static function.
9470 (coff_slurp_symbol_table): Don't pointerize scnlen field; now done
9471 in coff_pointerize_aux_hook.
9472 (bfd_coff_std_swap_table): Initialize new field.
9473 * coffgen.c (coff_print_symbol): Call bfd_coff_print_aux.
9474 * libcoff.h: Rebuild.
9475 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
9476 * coff-mips.c (mips_ecoff_backend_data): Likewise.
9477
9478 * coffcode.h (coff_write_object_contents): On AIX, clear F_RELFLG
9479 if there are symbols, for native AIX ld compatibility.
9480
9481 * coffcode.h (bfd_coff_backend_data): Add new field
9482 _bfd_coff_pointerize_aux_hook.
9483 (coff_pointerize_aux_hook): Define as a function if RS6000COFF_C
9484 or I960, and as 0 otherwise.
9485 (bfd_coff_std_swap_table): Initialize new field.
9486 * libcoff.h: Rebuild.
9487 * coffgen.c (coff_pointerize_aux): Change parameters to take
9488 symbol pointer instead of type and class, and to take aux index.
9489 Call _bfd_coff_pointerize_aux_hook if it is defined.
9490 (coff_get_normalized_symtab): Always call coff_pointerize_aux.
9491 * coff-alpha.c (alpha_ecoff_backend_data): Initialize all fields.
9492 * coff-mips.c (mips_ecoff_backend_data): Likewise.
9493
9494 * coff-rs6000.c: Add full support for AIX archives. Rewrite old
9495 read-only/host-only support.
9496
9497 * coffcode.h (coff_slurp_symbol_table): Set C_HIDEXT symbols to be
9498 BSF_LOCAL.
9499 (OTHER_GLOBAL_CLASS): Do not define to be C_HIDEXT if
9500 RS6000COFF_C.
9501
9502 * targets.c (bfd_target): Add _bfd_read_ar_hdr field. Modify
9503 BFD_JUMP_TABLE_ARCHIVE accordingly.
9504 * libbfd-in.h (_bfd_snarf_ar_hdr): Don't declare.
9505 (_bfd_compute_and_write_armap): Declare.
9506 (_bfd_generic_read_ar_hdr): Declare.
9507 (_bfd_read_ar_hdr): Define.
9508 (_bfd_noarchive_read_ar_hdr): Define.
9509 (_bfd_archive_bsd_read_ar_hdr): Define.
9510 (_bfd_archive_coff_read_ar_hdr): Define.
9511 * archive.c: Change all callers of _bfd_snarf_ar_hdr to call
9512 _bfd_read_ar_hdr instead.
9513 (_bfd_generic_read_ar_hdr): Rename from _bfd_snarf_ar_hdr.
9514 (_bfd_compute_and_write_armap): Rename from
9515 compute_and_write_armap. Make non-static. Change all callers.
9516 * ecoff.c (_bfd_ecoff_slurp_armap): Call _bfd_read_ar_hdr rather
9517 than _bfd_snarf_ar_hdr.
9518 * aout-target.h (MY_read_ar_hdr): Define if not defined.
9519 * ieee.c (ieee_read_ar_hdr): Define.
9520 * libecoff.h (_bfd_ecoff_read_ar_hdr): Define.
9521 * oasys.c (oasys_read_ar_hdr): Define.
9522 * som.c (som_read_ar_hdr): Define.
9523 * bfd-in2.h, libbfd.h: Rebuild.
9524
9525 Thu Oct 5 14:04:07 1995 steve chamberlain <sac@slash.cygnus.com>
9526
9527 * peicode.c (coff_swap_filehdr_in): If symptr is
9528 zero, there aren't any symbols, even if nsyms is set.
9529
9530 Thu Oct 5 11:45:02 1995 Ian Lance Taylor <ian@cygnus.com>
9531
9532 * libecoff.h (struct ecoff_backend_data): Add adjust_headers
9533 field.
9534 * ecoff.c (ecoff_sec_to_styp_flags): Check for various Alpha
9535 sections, and set styp correctly for them: .got, .hash, .dynamic,
9536 .liblist, .rel.dyn, .conflic, .dynstr, .dynsym, .comment.
9537 (_bfd_ecoff_styp_to_sec_flags): Check for various Alpha section
9538 types.
9539 (ecoff_sort_hdrs): New static function.
9540 (ecoff_compute_section_file_positions): Return boolean, not void.
9541 Sort the sections by VMA before looking through them. Put the
9542 first non SEC_ALLOC section on a new page. Put every SEC_ALLOC
9543 section on an appropriate boundary within the page.
9544 (ecoff_compute_reloc_file_positions): Check return value of
9545 ecoff_compute_section_file_positions.
9546 (_bfd_ecoff_set_section_contents): Likewise.
9547 (_bfd_ecoff_write_object_contents): Check for various Alpha
9548 section types when incrementing text_size and data_size. Call
9549 adjust_headers backend function if it exists.
9550 * coff-alpha.c (alpha_adjust_headers): New static function.
9551 (alpha_ecoff_backend_data): Initialize adjust_headers field.
9552 * coff-mips.c (mips_ecoff_backend_data): Likewise.
9553
9554 * hosts/i386bsd.h: Restore file incorrectly deleted on Sep 6.
9555
9556 Wed Oct 4 18:15:02 1995 Jeff Law (law@hurl.cygnus.com)
9557
9558 * rs6000-core.c (CORE_VERSION_1): Use CORE_VERSION_1 instead
9559 of ALTERNATE_AIX_CORE_FORMAT.
9560 * configure.in (aix4): No longer need CORE_FLAGS.
9561 * configure: Updated.
9562
9563 Wed Oct 4 15:36:36 1995 Ken Raeburn <raeburn@cygnus.com>
9564
9565 NS32k changes from Ian Dall:
9566 * aoutx.h (MY_final_link_relocate, MY_relocate_contents): New
9567 macros.
9568 (aout_link_input_section_std, aout_link_input_section_ext,
9569 aout_link_reloc_link_order): Call them instead of _bfd_*
9570 versions.
9571 * aout-target.h (MY_exec_header_not_counted): New macro, defaults
9572 to zero.
9573 (backend_data): Use it instead of hardcoded zero.
9574
9575 * aout-ns32k.c (CTOR_TABLE_RELOC_HOWTO): New macro.
9576 (MY_swap_std_reloc_out): Use udata.i for KEEPIT, don't call stoi.
9577
9578 * ns32knetbsd.c: Include bfd.h.
9579 (MY_text_includes_header, MY_bfd_reloc_type_lookup): New macros.
9580 (MY_bfd_reloc_type_lookup): Declare function too.
9581 * pc532-mach.c (set_sizes): Don't declare.
9582 (MY_text_includes_header, MY_exec_header_not_counted): Define.
9583 (backend_data, MY_backend_data): Don't define.
9584
9585 * config.bfd: Treat ns32k-pc532-ux* like ns32k-pc532-mach*, and
9586 ns32k-*-lites* like ns32k-*-netbsd*.
9587
9588 * hosts/nbsd.h: Swap order of sys/vmparam.h and sys/param.h, to
9589 compile on lites.
9590
9591 Wed Oct 4 14:15:52 1995 Ian Lance Taylor <ian@cygnus.com>
9592
9593 * coffcode.h (coff_write_object_contents): Restore setting
9594 f_timdat to 0, deleted on August 22.
9595
9596 Tue Oct 3 16:28:32 1995 steve chamberlain <sac@slash.cygnus.com>
9597
9598 * coffcode.h (coff_bfd_copy_private_symbol_data,
9599 coff_bfd_copy_private_section_data,
9600 coff_bfd_copy_private_bfd_data): ifdef to allow overrides.
9601 * peicode.h (coff_bfd_copy_private_bfd_data): New
9602 (pe_bfd_copy_private_bfd_data): New.
9603 (coff_swap_scnhdr_in): Swap bss size into the right place.
9604 (pe_print_private_bfd_data): Add some newlines.
9605
9606 Tue Oct 3 11:53:04 1995 Jeff Law (law@hurl.cygnus.com)
9607
9608 * som.c (setup_sections): Don't die if a space has no subspaces.
9609
9610 Mon Oct 2 14:08:55 1995 Ian Lance Taylor <ian@cygnus.com>
9611
9612 * elflink.h (elf_link_add_object_symbols): Don't let a weak
9613 dynamic symbol override a common symbol. Don't change the size or
9614 type if they have been set and the new symbol is not a definition.
9615 Warn if the size or type changes.
9616
9617 Sun Oct 1 01:34:41 1995 Jeff Law (law@hurl.cygnus.com)
9618
9619 * som.c (som_begin_writing): Don't write the symbol table or
9620 symbol strings.
9621 (som_finish_writing): Write them here. Place them after the
9622 subspace data, but before the relocs.
9623
9624 Fri Sep 29 11:01:55 1995 Ian Lance Taylor <ian@cygnus.com>
9625
9626 * sunos.c (sunos_add_one_symbol): Just pass false, not
9627 info->shared_library, to sunos_create_dynamic_sections.
9628 (sunos_scan_ext_relocs): Don't warn about a reloc in the .text
9629 section.
9630 (sunos_check_dynamic_reloc): Remove .text section assertion.
9631
9632 Thu Sep 28 18:48:47 1995 Stan Shebs <shebs@andros.cygnus.com>
9633
9634 * config.bfd: Add powerpc-*-macos*, powerpc-*-mpw*.
9635 * configure, configure.in: Add pmac_xcoff_vec case.
9636 * Makefile.in (BFD32_BACKENDS): Add coff-pmac.o.
9637 * coff-pmac.c: New file, PowerMac XCOFF support.
9638 * coffcode.h (coff_set_arch_mach_hook): Add PowerMac case.
9639 * targets.c (pmac_xcoff_vec): Declare.
9640
9641 * mpw-config.in: Various changes to be compatible with the
9642 autoconf-based configury.
9643 * mpw-make.sed: New file, sed commands to translate Unix
9644 makefile into MPW syntax.
9645 * mpw-make.in: Remove.
9646 * hosts/mpw.h: Remove.
9647 * bfd-in.h, bfd-in2.h: If MPW, include the file that defines
9648 true and false as enums, then define TRUE_FALSE_ALREADY_DEFINED.
9649
9650 Thu Sep 28 17:06:23 1995 steve chamberlain <sac@slash.cygnus.com>
9651
9652 * binary.c (binary_get_symtab): Return an empty string on error.
9653 * opncls.c (bfd_fdpenr): Change WIN32 restriction to WINGDB.
9654
9655 Thu Sep 28 15:30:44 1995 Kim Knuttila <krk@nellie>
9656
9657 * coff-ppc.c: Reformatted according to gnu conventions
9658 Removed irrelevant "if 0" code
9659
9660 Thu Sep 28 11:19:53 1995 Ian Lance Taylor <ian@cygnus.com>
9661
9662 * hp300hpux.c (convert_sym_type): Treat secondary symbols as weak
9663 symbols rather than as indirect symbols.
9664 (MY(slurp_symbol_table)): Don't do anything special about
9665 secondary symbols.
9666
9667 * coffcode.h (coff_new_section_hook): Make sure that the alignment
9668 of .ctors and .dtors sections is no larger than 2.
9669
9670 * sunos.c (sunos_add_one_symbol): Don't change
9671 bfd_link_hash_common to bfd_link_hash_new, since it may be on the
9672 undef list.
9673 (bfd_sunos_record_link_assignment): Don't put __DYNAMIC in the
9674 dynamic symbols when creating a shared library.
9675 (sunos_scan_ext_relocs): Handle relocs correctly when creating a
9676 shared library.
9677 (sunos_scan_dynamic_symbol): Don't mark the __DYNAMIC symbol as
9678 written even if it is not defined in a regular object.
9679 (sunos_write_dynamic_symbol): Use plt_offset for the address of
9680 the jump table reloc. Add an assertion. Use RELOC_JMP_SLOT
9681 rather than the constant 22.
9682 (sunos_check_dynamic_reloc): Handle creating a shared library.
9683 (sunos_finish_dynamic_link): Set the first entry in the GOT to
9684 zero when creating a shared library.
9685 * aoutx.h (NAME(aout,final_link)): If there is a symbol __DYNAMIC,
9686 write it out at the start of the symbol table.
9687
9688 * Makefile.in (BFD32_BACKENDS): Add coff-arm.o.
9689
9690 Thu Sep 28 00:58:05 1995 Doug Evans <dje@deneb.cygnus.com>
9691
9692 * config.bfd: Add arm-*-coff.
9693 * configure.in, configure: Add armcoff_{little,big}_vec.
9694 * targets.c (armcoff_{little,big}_vec): Declare.
9695 (bfd_target_vector): Add armcoff_{little,big}_vec.
9696 * coff-arm.c (armcoff_{little,big}_vec): Always define.
9697
9698 Wed Sep 27 10:37:14 1995 Ian Lance Taylor <ian@cygnus.com>
9699
9700 * targets.c (bfd_find_target): Remove debugging code.
9701
9702 Wed Sep 27 07:23:39 1995 Kim Knuttila <krk@nellie>
9703
9704 * coff-ppc.c, pe-ppc.c, pei-ppc.c: Initial bfd for coff/PE
9705 support on powerpc.
9706 * Makefile.in: added *-ppc files
9707 * coffcode.h: ppc MAGIC, and use peicode.h rather than coffswap.h to
9708 allow pe based .o's to be shared with other tools on ppc/NT
9709 * config.bfd: added powerpc[le]-[pe|winnt] config support
9710 * configure, configure.in: added bfd_powerpc[le]_pe[i]_vec
9711 * peicode.h: Added more section flags for PE on ppc
9712 Added coff_swap_filehdr_out to allow peicode.h to be
9713 used for non-image PE files on ppc.
9714 Check for image, or not, before copying pe_opthdr
9715 * targets.c: Added new bfd's
9716 * targets.c: Removed two inactive bfds that shouldn't have made it this
9717 far.
9718
9719 Tue Sep 26 14:06:41 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9720
9721 * elf32-ppc.c (ppc_reloc_type): Rename from reloc_type, and use
9722 explicit values to initialize all relocs. Change all users.
9723 (ppc_elf_brtaken_inner): New function to handle branch predicition
9724 relocs.
9725 (ppc_elf_brtaken_reloc): Ditto.
9726 (ppc_elf_howto_raw): Use new functions. Make sure all unsupported
9727 relocs use ppc_elf_unsupported_reloc.
9728 (ppc_elf_merge_private_bfd_data): Keep track of whether an error
9729 needs to be reported.
9730 (ppc_elf_relocate_section): Support branch prediction relocs.
9731
9732 Tue Sep 26 12:48:05 1995 Ian Lance Taylor <ian@cygnus.com>
9733
9734 * bfd.c (bfd_assert): Remove \n from string passed to
9735 _bfd_error_handler.
9736
9737 * coff-i386.c: (TWO_DATA_SECS): Don't define.
9738 * coffcode.h (bfd_coff_backend_data): Remove _bfd_make_section_hook.
9739 (bfd_coff_make_section_hook): Don't define.
9740 (coff_make_section_hook): Remove.
9741 (sec_to_styp_flags): Remove TWO_DATA_SECS case.
9742 (styp_to_sec_flags): Likewise.
9743 (coff_write_object_contents): Likewise.
9744 (bfd_coff_std_swap_table): Don't initialize make_section_hook
9745 field.
9746 * libcoff.h: Rebuild.
9747 * coffgen.c (make_a_section_from_file): Just call
9748 bfd_make_section_anyway, not bfd_make_section or
9749 bfd_coff_make_section_hook.
9750 * ecoff.c (_bfd_ecoff_make_section_hook): Remove.
9751 * libecoff.h (_bfd_ecoff_make_section_hook): Don't declare.
9752 * coff-alpha.c (alpha_ecoff_backend_data): Don't initialize
9753 make_section_hook field.
9754 * coff-mips.c (mips_ecoff_backend_data): Likewise.
9755
9756 * aoutx.h (translate_from_native_sym_flags): Don't try to stuff
9757 pointers into value field for warning and indirect symbols; just
9758 leave the value field alone.
9759 * linker.c (generic_link_add_symbol_list): Use next symbol for
9760 warning and indirect symbols, rather than looking in symbol value.
9761 * ecoff.c (ecoff_set_symbol_info): Remove indirect_ptr_ptr
9762 parameter. Change all callers. Remove support for indirect
9763 symbols; it didn't work anyhow.
9764 (_bfd_ecoff_slurp_symbol_table): Remove indirect_ptr variable.
9765 * syms.c: Change comments about BSF_WARNING and BSF_INDIRECT.
9766 * bfd-in2.h: Rebuild.
9767
9768 Mon Sep 25 16:04:09 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9769
9770 * elf32-ppc.c (ppc_elf_howto_raw): For all 14-bit branch relocs,
9771 go back to telling the tools this reloc operates on 32 bits.
9772
9773 Mon Sep 25 11:48:02 1995 Ian Lance Taylor <ian@cygnus.com>
9774
9775 * aout-adobe.c (aout_adobe_callback): Use _bfd_error_handler
9776 rather than a direct fprintf.
9777 * archive.c (_bfd_write_archive_contents): Likewise.
9778 * coffcode.h (coff_slurp_symbol_table): Likewise.
9779 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Likewise.
9780 (ppc_elf_unsupported_reloc): Likewise.
9781 (ppc_elf_relocate_section): Likewise.
9782 * i386linux.c (linux_tally_symbols): Likewise.
9783 (linux_finish_dynamic_link): Likewise.
9784 * osf-core.c (osf_core_core_file_p): Likewise.
9785 * rs6000-core.c (rs6000coff_get_section_contents): Likewise.
9786 * som.c (som_sizeof_headers): Likewise.
9787 * srec.c (srec_bad_byte): Likewise.
9788 * bfd.c (bfd_assert): Likewise. Also change file to be const.
9789 * libbfd-in.h (bfd_assert): Declare first parameter const.
9790 * libbfd.h: Rebuild.
9791 * coff-a29k.c (a29k_reloc): Don't bother to fprintf; returning
9792 bfd_reloc_overflow is enough.
9793 * coff-h8300.c (rtype2howto): Don't bother to fprintf; just abort.
9794 * coff-h8500.c (rtype2howto): Likewise.
9795 * coff-z8k.c (rtype2howto): Likewise.
9796 * coffcode.h (dummy_reloc16_extra_cases): Likewise.
9797 * elf.c (_bfd_elf_get_lineno): Likewise.
9798 (_bfd_elf_no_info_to_howto): Likewise.
9799 (_bfd_elf_no_info_to_howto_rel): Likewise.
9800 * hp300hpux.c (convert_sym_type): Likewise.
9801 (MY(swap_std_reloc_in)): Likewise.
9802 * elf.c (bfd_section_from_shdr): Remove #if 0 sections.
9803
9804 * libaout.h (struct aoutdata): Add line_buf field.
9805 * aoutx.h (NAME(aout,find_nearest_line)): Remove statics buffer
9806 and filename_buffer. Instead, use a malloc buffer stored in the
9807 new line_buf field. Remove length restrictions.
9808
9809 * coffgen.c (string_size): Remove static variable.
9810 (debug_string_size, debug_string_section): Likewise.
9811 (coff_fix_symbol_name): Add string_size_p, debug_string_section_p,
9812 and debug_string_size_p parameters. Use them instead of the
9813 global variables. Change all callers.
9814 (coff_write_symbol): Likewise.
9815 (coff_write_alien_symbol, coff_write_native_symbol): Likewise.
9816 (coff_write_symbols): Add local variables to replace removed
9817 global variables.
9818
9819 * libcoff-in.h (struct coff_section_tdata): Add offset, i,
9820 function, and line_base fields.
9821 * libcoff.h: Rebuild.
9822 * coffgen.c (coff_find_nearest_line): Use section tdata to cache
9823 information, rather than using static variables.
9824
9825 * sunos.c (sunos_read_dynamic_info): Adjust offsets in an NMAGIC
9826 file. From Peter DeWolf <pld@amt.tay1.dec.com>.
9827
9828 * init.c (initialized): Remove static variable.
9829 (bfd_init): Don't bother setting initialized.
9830 (bfd_check_init): Remove.
9831 * opncls.c (_bfd_new_bfd): Don't call bfd_check_init.
9832 * libbfd.h: Rebuild.
9833
9834 Sat Sep 23 01:22:23 1995 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
9835
9836 * rs6000-core.c (rs6000coff_core_p): Don't check the core file
9837 size for full core dumps. Copy core file header to private data.
9838 (rs6000coff_core_file_failing_command,
9839 rs6000coff_core_file_failing_signal): New functions to extract
9840 the file name and terminating signal from the core file.
9841 * coff-rs6000.c: Use them.
9842
9843 Fri Sep 22 17:44:47 1995 Ian Lance Taylor <ian@cygnus.com>
9844
9845 Change arch info to be const, initialized at compile time.
9846 * archures.c: Reindent many functions. Change CONST to const.
9847 (bfd_arch_info_type): Make arch_name const. Remove disassemble;
9848 nothing set it anyhow. Make next const.
9849 (bfd_arch_info_list): Remove.
9850 (bfd_archures_list): Rename from archures_init_table. Change from
9851 a table of function pointers to a table of bfd_arch_info_type
9852 structure addresses.
9853 (bfd_scan_arch): Rewrite accordingly. Return a const pointer.
9854 (bfd_lookup_arch): Likewise.
9855 (bfd_set_arch_info): Rewrite accordingly. Change argument to be a
9856 const pointer.
9857 (bfd_default_arch_struct): Make const.
9858 (bfd_arch_init, bfd_arch_linkin): Remove.
9859 (bfd_get_arch_info): Return a const pointer.
9860 * init.c (bfd_init): Don't call bfd_arch_init.
9861 * bfd.c (struct _bfd): Make arch_info const.
9862 * bfd-in2.h: Rebuild.
9863 * libbfd.h: Rebuild.
9864 * configure.in: Put & before everything in $selarchs.
9865 * configure: Rebuild.
9866 * cpu-*.c: Change bfd_*_arch from a function which calls
9867 bfd_arch_linkin to a const structure.
9868 * ieee.c (ieee_object_p): Make arch const.
9869
9870 Fri Sep 22 16:23:18 1995 Michael Meissner <meissner@tiktok.cygnus.com>
9871
9872 * reloc.c (bfd_reloc_code_type): Add relocations to support all of
9873 PowerPC V.4.
9874 * bfd-in2.h: Regenerate.
9875 * libbfd.h: Regenerate.
9876
9877 * elf32-ppc.c (reloc_type): Update names to match current draft.
9878 (ppc_elf_howto_raw): Mark 14 bit relocs as short sized and PC
9879 relative. Update names to current V.4 draft.
9880 (ppc_elf_reloc_type_lookup): Add support for more relocations.
9881 (ppc_elf_relocate_section): Rename relocations to match draft.
9882
9883 Thu Sep 21 21:53:18 1995 Michael Meissner <meissner@cygnus.com>
9884
9885 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Allow modules
9886 compiled with -mrelocatable-lib to be linked with either normal
9887 modules or -mrelocatable modules.
9888
9889 Wed Sep 20 12:03:26 1995 Ian Lance Taylor <ian@cygnus.com>
9890
9891 * coffcode.h (coff_write_object_contents): Clear the vstamp field
9892 in the a.out header.
9893
9894 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Don't set r_extern for
9895 a reloc against a local symbol, even if it's not a section.
9896
9897 Tue Sep 19 17:02:26 1995 Ian Lance Taylor <ian@cygnus.com>
9898
9899 * targets.c (bfd_target): Remove unused align_power_min field.
9900 * bfd-in2.h: Rebuild.
9901 * All backends: Remove initialization of align_power_min.
9902
9903 Tue Sep 19 14:02:21 1995 steve chamberlain <sac@slash.cygnus.com>
9904
9905 * peicode.h (coff_swap_scnhdr_out): Get sizes for BSS right.
9906
9907 Mon Sep 18 14:35:01 1995 Arne H. Juul <arnej@pvv.unit.no>
9908
9909 * config.bfd (mips-dec-netbsd*): New target.
9910 * configure.host (mips-dec-netbsd*): New host.
9911 * configure.in (mips-dec-netbsd*): New native.
9912 * configure: Rebuild.
9913
9914 Fri Sep 15 10:24:36 1995 Ian Lance Taylor <ian@cygnus.com>
9915
9916 Make the COFF backend linker merge common types:
9917 * cofflink.c (struct coff_debug_merge_element): Define.
9918 (struct coff_debug_merge_type): Define.
9919 (struct coff_debug_merge_hash_entry): Define.
9920 (struct coff_debug_merge_hash_table): Define.
9921 (coff_debug_merge_hash_table_init): Define.
9922 (coff_debug_merge_hash_table_free): Define.
9923 (coff_debug_merge_hash_lookup): Define.
9924 (struct coff_final_link_info): Add debug_merge field.
9925 (coff_debug_merge_hash_newfunc): New static function.
9926 (_bfd_coff_final_link): Allocate and free debug_merge table.
9927 (coff_link_input_bfd): Merge identical enum, struct and union
9928 types.
9929
9930 Thu Sep 14 14:53:58 1995 Ian Lance Taylor <ian@cygnus.com>
9931
9932 Convert i960 COFF to use COFF backend linker.
9933 * coff-i960.c (coff_i960_relocate): Use a coff_section_data
9934 structure to store the symbol being used.
9935 (coff_i960_start_final_link): New static function.
9936 (coff_i960_relocate_section): New static function.
9937 (coff_i960_adjust_symndx): New static function.
9938 (coff_start_final_link): Define.
9939 (coff_relocate_section): Define.
9940 (coff_adjust_symndx): Define.
9941 * coffcode.h (bfd_coff_backend_data): Add new callback function
9942 _bfd_coff_start_final_link.
9943 (bfd_coff_start_final_link): Define.
9944 (coff_start_final_link): Define if not defined.
9945 (bfd_coff_std_swap_table): Add coff_start_final_link.
9946 * cofflink.c (_bfd_coff_internal_syment_name): Make globally
9947 visible.
9948 (_bfd_coff_final_link): Call bfd_coff_start_final_link if the
9949 function callback is not NULL.
9950 * libcoff-in.h (struct coff_section_tdata): Add tdata field.
9951 (_bfd_coff_internal_syment_name): Declare.
9952 * libcoff.h: Rebuild.
9953 * configure.in (icoff_big_vec): Add cofflink.o.
9954 (icoff_little_vec): Likewise.
9955 * configure: Rebuild.
9956
9957 Wed Sep 13 17:38:23 1995 Fred Fish <fnf@rtl.cygnus.com>
9958
9959 * Makefile.in (clean-info): Remove extraneous tab from line
9960 following action.
9961
9962 Wed Sep 13 13:27:53 1995 Ian Lance Taylor <ian@cygnus.com>
9963
9964 * cofflink.c (coff_link_input_bfd): Fail if a section with no
9965 contents has relocs.
9966
9967 Thu Sep 12 12:45:34 1995 steve chamberlain <sac@slash.cygnus.com>
9968
9969 * coffcode.h (coff_compute_section_file_positions): Keep the
9970 raw size safe.
9971 (coff_write_object_contents): Remember if it's a relocatable
9972 file.
9973 * libcoff-in.h (pe_data_type): New member 'has_reloc_section'
9974 * peicode.h (coff_swap_filehdr_out): Clear not-reloc flag
9975 if relocatable file. Swap out saved raw size.
9976
9977 Tue Sep 12 12:14:33 1995 Ian Lance Taylor <ian@cygnus.com>
9978
9979 * Makefile.in (do_maintainer_clean): Rename from do_realclean.
9980 (maintainer-clean): Rename from realclean, passing
9981 maintainer-clean down to subdirectories, but leave realclean as a
9982 synonym.
9983
9984 * linker.c (_bfd_generic_link_add_one_symbol): Pass symbol name to
9985 warning callback.
9986
9987 * dep-in.sed: Remove config.h from generated dependencies.
9988
9989 * sunos.c (sunos_slurp_dynamic_symtab): New static function,
9990 broken out of sunos_canonicalize_dynamic_symtab.
9991 (sunos_canonicalize_dynamic_symtab): Call new function
9992 sunos_slurp_dynamic_symtab.
9993 (sunos_add_dynamic_symbols): Add three new parameters. Return the
9994 dynamic symbol table to the caller.
9995 * aoutx.h (aout_link_add_symbols): Permit add_dynamic_symbols
9996 callback to override the symbols being read.
9997 * libaout.h (struct aout_backend_data): Add three new parameters
9998 to add_dynamic_symbols callback.
9999
10000 Extensive minor changes to avoid various gcc warnings. Also:
10001 * Makefile.in (BFD32_BACKENDS): Remove coff-arm.o.
10002 * archures.c (bfd_arch_info_type): Change mach field from long to
10003 unsigned long.
10004 (bfd_lookup_arch): Change machine parameter from long to unsigned
10005 long.
10006
10007 Mon Sep 11 10:55:47 1995 Ian Lance Taylor <ian@cygnus.com>
10008
10009 * sunos.c (sunos_scan_std_relocs): Fix BFD_ASSERT: it's OK to find
10010 a symbol with a non-zero plt_offset.
10011
10012 Fri Sep 8 11:47:24 1995 Ian Lance Taylor <ian@cygnus.com>
10013
10014 * elfcode.h (align_file_position): Remove; not used.
10015
10016 * configure.in: Only check for <sys/procfs.h> on a native system,
10017 and make sure it defines prstatus_t.
10018 * configure: Rebuild.
10019
10020 Thu Sep 7 12:48:01 1995 Ian Lance Taylor <ian@cygnus.com>
10021
10022 * sunos.c (sunos_write_dynamic_symbol): Correct m68k abort test.
10023
10024 * config.in: Rename from config.h.in.
10025 * configure.in: Call AC_CONFIG_HEADER with config.h:config.in.
10026 Check for config.h:config.in when creating stamp-h.
10027 * configure: Rebuild.
10028 * Makefile.in (stamp-h): Depend upon config.in rather than
10029 config.h.in. Set CONFIG_HEADERS to config.h:config.in when
10030 calling config.status.
10031
10032 * Makefile.in (do_distclean): Remove config.h and stamp-h.
10033 (Makefile): Just rebuild Makefile.
10034 (config.h, stamp-h): New targets.
10035 * configure.in: Create stamp-h when rebuilding config.h.
10036 * configure: Rebuild.
10037
10038 Wed Sep 6 15:00:33 1995 Ian Lance Taylor <ian@cygnus.com>
10039
10040 * configure.in: Call AC_CONFIG_HEADER. Substitute
10041 HOST_64BIT_LONG. Check that various header files exist. Check
10042 that fcntl exists. Call BFD_BINARY_FOPEN. Check whether malloc
10043 and/or free need to be declared. Don't make a link to sysdep.h.
10044 Define TRAD_HEADER for various hosts.
10045 * configure: Rebuild.
10046 * configure.host: Don't set my_host. Add definitions taken from
10047 host header files for various entries. Remove entries which now
10048 do nothing.
10049 * acconfig.h: New file.
10050 * config.h.in: New file, built by autoheader.
10051 * sysdep.h: New file.
10052 * Makefile.in (do_distclean): Don't remove sysdep.h.
10053 (RECONFIG): Remove.
10054 (LOCAL_H_DEPS): New variable.
10055 ($(BFD_LIBS)): Use $(LOCAL_H_DEPS) rather than libbfd.h and
10056 $(RECONFIG).
10057 ($(BFD_MACHINES), $(BFD_BACKENDS)): Likewise.
10058 ($(OPTIONAL_BACKENDS)): Likewise.
10059 (stmp-bfd.h): Just substitute for BFD_HOST_64BIT_LONG, rather than
10060 looking through sysdep.h.
10061 * bfd-in.h (BFD_HOST_64BIT_LONG): Define; set by Makefile.
10062 (BFD_HOST_64_BIT): Define based on BFD_HOST_64BIT_LONG.
10063 (fprintf_vma, sprintf_vma): Likewise.
10064 (int64_type, uint64_type): Don't define.
10065 * bfd-in2.h: Rebuild.
10066 * archures.c, bfd.c, srec.c: Include <ctype.h>.
10067 * elfcore.h: Check HAVE_SYS_PROCFS_H rather than HAVE_PROCFS.
10068 * lynx-core.c: Include stuff from old hosts/lynx.h.
10069 * opncls.c (bfd_fdopenr): Check HAVE_FNCTL and defined (F_GETFL),
10070 rather than NO_FCNTL.
10071 * targets.c (bfd_target_list): Check HOST_HPPAHPUX and ! __STDC__
10072 rather than NATIVE_HPPAHPUX_COMPILER.
10073 * trad-core.c: Don't include <errno.h>. Include TRAD_HEADER if it
10074 is defined.
10075 * hosts/*.h: Remove all header files which merely include,
10076 declare, and define things. Leave header files which define
10077 information needed by trad-core.c.
10078
10079 * aclocal.m4 (BFD_BINARY_FOPEN): Define.
10080 (BFD_CC_FOR_BUILD): Define.
10081 * configure.in: Use BFD_CC_FOR_BUILD.
10082 * configure: Rebuild.
10083
10084 Tue Sep 5 19:35:28 1995 Ian Lance Taylor <ian@cygnus.com>
10085
10086 * aclocal.m4: Don't try to grep ../Makefile if it doesn't exist.
10087 * configure: Rebuild.
10088
10089 * coff-sparc.c (CALC_ADDEND): Don't set the addend to the value of
10090 a global symbol.
10091
10092 Tue Sep 5 12:48:26 1995 Jason Molenda (crash@phydeaux.cygnus.com)
10093
10094 * config.bfd: i386pe_ve -> i386pe_vec.
10095
10096 Mon Sep 4 14:02:43 1995 Ian Lance Taylor <ian@cygnus.com>
10097
10098 * configure.host: Incorporate host Makefile fragments by setting
10099 shell variables.
10100 * configure.in: Call AC_PROG_CC. Substitute CFLAGS, HDEFINES and
10101 AR. Call AC_PROG_INSTALL. Substitute CC_FOR_BUILD, choosing a
10102 value based on whether the code is being compiled by a cross
10103 compiler. Don't substitute host_makefile_frag or frags.
10104 * aclocal.m4: New file to define local AC_PROG_CC.
10105 * configure: Rebuild.
10106 * Makefile.in (INSTALL): Set to @INSTALL@.
10107 (INSTALL_PROGRAM): Set to @INSTALL_PROGRAM@.
10108 (INSTALL_DATA): Set to @INSTALL_DATA@.
10109 (AR): Set to @AR@.
10110 (CC): Define as @CC@.
10111 (CFLAGS): Set to @CFLAGS@.
10112 (CC_FOR_BUILD): Set to @CC_FOR_BUILD@.
10113 (@host_makefile_frag@): Remove.
10114 (ALL_CFLAGS): Change $(HDEFINES) to @HDEFINES@. Move $(CFLAGS)
10115 after other options.
10116 (config.status): Remove dependency upon @frags@.
10117 * config/*.mh, config/README: Remove.
10118
10119 * config.bfd: Rewrite to incorporate the contents of the Makefile
10120 fragments by setting shell variables, rather than merely returning
10121 the name of a Makefile fragment.
10122 * configure.in: Use shell variables set by config.bfd rather than
10123 looking at the target Makefile fragment files. Don't substitute
10124 target_makefile_frag. Do substitute TDEFINES.
10125 * configure: Rebuild.
10126 * Makefile.in (@target_makefile_frag@): Remove.
10127 (ALL_CFLAGS): Change $(TDEFINES) to @TDEFINES@.
10128 * config/*.mt: Remove.
10129
10130 Mon Sep 4 03:13:28 1995 Ken Raeburn <raeburn@cygnus.com>
10131
10132 * configure.in: Put changequote lines around "i[345]86" patterns
10133 section of core file support.
10134
10135 Sun Sep 3 11:31:58 1995 Jeff Law (law@snake.cs.utah.edu)
10136
10137 * som.c (som_bfd_print_private_bfd_data): Define to use the
10138 generic version.
10139
10140 Fri Sep 1 17:08:40 1995 steve chamberlain <sac@slash.cygnus.com>
10141
10142 * peicode.h (coff_swap_aouthdr_in): Add ImageBase to
10143 entry, text_start and data_start.
10144
10145 Fri Sep 1 18:06:28 1995 Ian Lance Taylor <ian@cygnus.com>
10146
10147 * Makefile.in (OFILES): Remove $(TDEPFILES).
10148 * config/apollo.mt (TDEPFILES): Remove.
10149 * config/README: Update.
10150
10151 * configure.in: For a native configuration, set COREFILE and
10152 COREFLAG based on the canonical host name.
10153 * configure: Rebuild.
10154 * Makefile.in: Rebuild dependencies.
10155 (ALL_CFLAGS): Add @COREFLAG@.
10156 (OFILES): Replace $(HDEPFILES) with @COREFILE@.
10157 * coff-rs6000.c: Check AIX_CORE rather than HOST_AIX for core file
10158 support routines. Check LYNX_CORE rather than HOST_LYNX.
10159 * lynx-core.c: Check LYNX_CORE rather than HOST_LYNX.
10160 * i386lynx.c: Likewise.
10161 * m68klynx.c: Likewise.
10162 * sparclynx.c: Likewise.
10163 * rs6000-core.c: Check AIX_CORE rather than HOST_AIX.
10164 * *-core.c: Comment changes.
10165 * config/decstation.mh (HDEPFILES): Remove.
10166 (HDEFINES): Remove -DTRAD_CORE.
10167 * config/irix3.mh (RANLIB): Remove.
10168 * config/irix4.mh (HDEPFILES, RANLIB): Remove.
10169 (HDEFINES): Remove -DIRIX_CORE.
10170 * config/riscos.mh (RANLIB, HDEPFILES): Remove.
10171 (HDEFINES): Remove -DTRAD_CORE.
10172 * config/ncr3000.mh (AR_FLAGS, RANLIB): Remove.
10173 * config/ultra3.mh (RANLIB): Remove.
10174 * config/aix4.mh, config/alphaosf.mh, config/amix.mh: Remove.
10175 * config/apollo.mh, config/delta68.mh, config/delta88.mh: Remove.
10176 * config/dpx2.mh, config/esix.mh, config/harris.mh: Remove.
10177 * config/hp300.mh, config/hp300bsd.mh, config/hppabsd.mh: Remove.
10178 * config/hppahpux.mh, config/hppaosf.mh: Remove.
10179 * config/i386aix.mh, config/i386bsd.mh: Remove.
10180 * config/i386linux.mh, config/i386mach3.mh: Remove.
10181 * config/i386sco.mh, config/i386v.mh, config/i386v4.mh: Remove.
10182 * config/irix5.mh, config/m88kmach3.mh, config/mipsbsd.mh: Remove.
10183 * config/mipsmach3.mh, config/news-mips.mh: Remove.
10184 * config/news.mh, config/pc532mach.mh, config/riscix.mh: Remove.
10185 * config/rs600.mh, config/rs6000lynx.mh: Remove.
10186 * config/solaris2.mh, config/stratus.mh: Remove.
10187 * config/symmetry.mh, config/sysv4.mh, config/tahoe.mh: Remove.
10188 * config/vaxbsd.mh, config/vaxult.mh, config/vaxult2.mh: Remove.
10189
10190 Fri Sep 1 15:18:50 1995 Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>
10191
10192 * elflink.h (elf_bfd_final_link): Don't change a DT_INIT or
10193 DT_FINI entry if the appropriate symbol is not in the hash table.
10194
10195 * libelf.h (struct elf_backend_data): Add create_program_headers
10196 and want_hdr_in_seg fields.
10197 * elfxx-target.h (elf_backend_want_hdr_in_seg): Define if not
10198 defined.
10199 (elf_backend_create_program_headers): Likewise.
10200 (elfNN_bed): Initialize create_program_headers and
10201 want_hdr_in_seg.
10202 * elf.c (get_program_header_size): Call create_program_headers
10203 backend routine.
10204 (map_program_segments): Check want_hdr_in_seg backend field. Call
10205 create_program_headers backend routine.
10206
10207 * elf.c (assign_file_positions_except_relocs): Align non allocated
10208 sections when creating an executable.
10209
10210 * elfcode.h (elf_swap_phdr_in): Make non static.
10211 (elf_swap_phdr_out): Make non static.
10212 * libelf.h (bfd_elf32_swap_phdr_in): Declare.
10213 (bfd_elf32_swap_phdr_out): Declare.
10214 (bfd_elf64_swap_phdr_in): Declare.
10215 (bfd_elf64_swap_phdr_out): Declare.
10216
10217 * ecofflink.c (ecoff_collect_shuffle): New static function.
10218 (_bfd_ecoff_get_accumulated_pdr): New function.
10219 (_bfd_ecoff_get_accumulated_sym): New function.
10220 (_bfd_ecoff_get_accumulated_ss): New function.
10221 * libbfd-in.h (_bfd_ecoff_get_accumulated_pdr): Declare.
10222 (_bfd_ecoff_get_accumulated_sym): Declare.
10223 (_bfd_ecoff_get_accumulated_ss): Declare.
10224 * libbfd.h: Rebuild.
10225
10226 Fri Sep 1 13:20:25 1995 Ian Lance Taylor <ian@cygnus.com>
10227
10228 * libecoff.h (_bfd_ecoff_bfd_print_private_bfd_data): Fix typo.
10229
10230 * elflink.h (elf_link_add_object_symbols): Handle indirect and
10231 warning symbols. If any section is named .gnu.warning.XXX, treat
10232 the contents as a warning to be issued if the symbol XXX is
10233 referenced.
10234 (elf_link_output_extsym): For an indirect or warning symbol, just
10235 output the symbol it points to.
10236
10237 * linker.c (_bfd_link_hash_newfunc): Don't bother to set bfd_error
10238 if bfd_hash_allocate fails, since it will already be set.
10239 (generic_link_hash_newfunc): Likewise.
10240 (archive_hash_newfunc): Likewise.
10241 (hash_entry_bfd): New static function.
10242 (_bfd_generic_link_add_one_symbol): Pass new arguments to warning
10243 callback. Allocate a new warning using the hash table newfunc.
10244 Use bfd_hash_replace to update the entry in the hash table, rather
10245 than assuming we can copy the fields with structure assignment.
10246
10247 * hash.c (bfd_hash_replace): New function.
10248 * bfd-in.h (bfd_hash_replace): Declare.
10249 * bfd-in2.h: Rebuild.
10250
10251 Fri Sep 1 08:12:50 1995 James G. Smith <jsmith@beauty.cygnus.com>
10252
10253 * config.bfd: Add mips*vr4300-*-elf* target.
10254 * config/mipsbvr4300.mt: Added.
10255
10256 See file ChangeLog.2
10257
10258 \f
10259 Local Variables:
10260 mode: change-log
10261 left-margin: 8
10262 fill-column: 74
10263 version-control: never
10264 End: