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