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