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