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