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