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