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