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