* elf.c (elf_map_symbols): Don't create new section symbols; Use
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
079e9a2f
AM
12001-10-10 Alan Modra <amodra@bigpond.net.au>
2
3 * elf.c (elf_map_symbols): Don't create new section symbols; Use
4 existing section syms. Update comments.
5 (copy_private_bfd_data): Formatting fixes.
6 (elfcore_grok_win32pstatus): Likewise.
7 (swap_out_syms): Likewise. Remove unnecessary level of braces.
8
945906ff
AM
92001-10-09 Alan Modra <amodra@bigpond.net.au>
10
11 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
12 "group_name".
13 (elf_group_name): Define.
14 (elf_next_in_group): Define.
15 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
16 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
17 first member section; Instead use elf_next_in_group.
18 (bfd_section_from_shdr): Likewise.
19 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
20
dbb410c3
AM
212001-10-09 Alan Modra <amodra@bigpond.net.au>
22
23 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
24 "next_in_group". Fix gp and gp_size comments.
25 * elf.c (union elf_internal_group): New.
26 (setup_group): New function.
27 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
28 Call setup_group for SHF_GROUP sections.
29 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
30 (elf_fake_sections): Set header type for SEC_GROUP, and header
31 flags for sections in a group.
32 (set_group_contents): New function.
33 (_bfd_elf_compute_section_file_positions): Call it.
34 (assign_section_numbers): Set sh_link for SHT_GROUP.
945906ff 35
dbb410c3
AM
36 * elflink.h (gc_mark_hook): Handle section groups.
37 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
38 * section.c (SEC_GROUP): Define.
39 (struct sec): Comment fixes.
40 * bfd-in2.h: Regenerate.
41
42 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
43 out of function args.
44 (_bfd_elf_canonicalize_reloc): Similarly.
45 (_bfd_elf_get_symtab): Here too.
46 (_bfd_elf_canonicalize_dynamic_symtab): And here.
47 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
48 bfd_bread, and remove unnecessary cast.
49
24c603fa
AH
502001-10-08 Aldy Hernandez <aldyh@redhat.com>
51
52 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
53
3f5864e1
SC
542001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
55
56 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
57 compilation unit.
58
fb9ceeac
AM
592001-10-06 Alan Modra <amodra@bigpond.net.au>
60
aec2f561
AM
61 * bfd.c (bfd_assert): Report bfd version.
62 (_bfd_abort): Likewise.
63
50b4d486
AM
64 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
65 section sym values. Instead replace any relocs against them with
66 relocs against STN_UNDEF, which has a zero value.
67
fb9ceeac
AM
68 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
69 relocs.
70
17617495
JL
712001-10-05 Jeff Law <law@redhat.com>
72
73 * som.h (som_exec_data): New field "version_id".
74 * som.c (som_object_setup): Record the version_id if it
75 exists.
76 (som_prep_headers): Do not initialize version_id here.
77 (som_finish_writing): Initialize version_id here.
78
792000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7e766c3b
TS
80
81 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
82 according to the MIPS/SGI ELF64 ABI Draft.
83 (mips_elf_sort_hash_table): Typo.
84
58e3d09d
AM
852001-10-04 Alan Modra <amodra@bigpond.net.au>
86
8ea52284
AM
87 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
88
58e3d09d
AM
89 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
90 copying flags if this is a weakdef.
91
b13c7b49
AM
922001-10-04 Alan Modra <amodra@bigpond.net.au>
93
a90b9fca
AM
94 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
95 packing.
96
3a6b8597
AM
97 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
98 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
99 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
100
b13c7b49
AM
101 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
102 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
103 backends we configure. Run "make dep-am".
104 (install-data-local): Install symcat.h.
105 * dep-in.sed: Remove symcat.h from dependencies.
106 * Makefile.in: Regenerate.
107
8bd621d8
AM
1082001-10-03 Vassili Karpov <malc@pulsesoft.com>
109
110 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
111
1e2be829
TS
1122001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
113
114 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
115 (elf_backend_default_use_rela_p): New define.
116
0a991dfe
AM
1172001-10-03 Alan Modra <amodra@bigpond.net.au>
118
57c7194e
AM
119 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
120 change.
121
87b632fc
AM
122 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
123 * configure: Regenerate.
124 * Makefile.am (BFD_H_FILES): Add version.h.
125 * Makefile.in: Regenerate.
126 * po/SRC-POTFILES.in: Regenerate.
127
0a991dfe
AM
128 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
129 elf_backend_copy_indirect_symbol so that backend has a chance to
130 copy other necessary fields.
131 * elf-bfd.h (struct elf_backend_data): Update description of
132 elf_backend_copy_indirect_symbol.
133 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
134 copying flags if this is a weakdef.
135 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
136 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
137 than bfd_link_hash_lookup.
138 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Don't do copy
139 reloc processing for weakdefs.
140 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
141 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
142
a33d1f77
AM
1432001-10-02 Alan Modra <amodra@bigpond.net.au>
144
145 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
146 result of ELF64_R_TYPE to enum before using in a switch.
147 (ppc64_elf_gc_mark_hook): Likewise.
148 (ppc64_elf_gc_sweep_hook): Likewise.
149 (ppc64_elf_reloc_type_class): Likewise.
150
e43d48cc
AM
1512001-10-02 Alan Modra <amodra@bigpond.net.au>
152
153 * version.h: New file.
154 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
155 (BFD_VERSION_DATE): Define.
156 (BFD_VERSION_STRING): Define.
157 * configure.in: AC_SUBST bfd_version, bfd_version_date and
158 bfd_version_string.
159 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
160 * bfd-in2.h: Regenerate.
161 * configure: Regenerate.
162 * Makefile.am: Run "make dep-am".
163 * Makefile.in: Regenerate.
164
165 * bfd-in.h: Include "symcat.h".
166 (CONCAT4): Redefine as for old CAT4.
167 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
168 Add warning regarding whitespace.
169 * aout-cris.c: Likewise.
170 * aout-ns32k.c: Likewise.
171 * aout-sparcle.c: Likewise.
172 * aout-tic30.c: Likewise.
173 * aout0.c: Likewise.
174 * armnetbsd.c: Likewise.
175 * demo64.c: Likewise.
176 * elf-bfd.h: Likewise.
177 * gen-aout.c: Likewise.
178 * host-aout.c: Likewise.
179 * hp300bsd.c: Likewise.
180 * hp300hpux.c: Likewise.
181 * i386aout.c: Likewise.
182 * i386bsd.c: Likewise.
183 * i386dynix.c: Likewise.
184 * i386freebsd.c: Likewise.
185 * i386linux.c: Likewise.
186 * i386lynx.c: Likewise.
187 * i386mach3.c: Likewise.
188 * i386netbsd.c: Likewise.
189 * libaout.h: Likewise.
190 * m68k4knetbsd.c: Likewise.
191 * m68klinux.c: Likewise.
192 * m68klynx.c: Likewise.
193 * m68knetbsd.c: Likewise.
194 * m88kmach3.c: Likewise.
195 * mipsbsd.c: Likewise.
196 * newsos3.c: Likewise.
197 * ns32knetbsd.c: Likewise.
198 * pc532-mach.c: Likewise.
199 * pdp11.c: Likewise.
200 * riscix.c: Likewise.
201 * sparclinux.c: Likewise.
202 * sparclynx.c: Likewise.
203 * sparcnetbsd.c: Likewise.
204 * sunos.c: Likewise.
205 * targets.c: Likewise.
206 * vaxnetbsd.c: Likewise.
207 * vms-hdr.c: Likewise.
208
4eef72c7
AM
2092001-10-01 Alan Modra <amodra@bigpond.net.au>
210
211 * bfd-in.h: Remove comments regarding generated files.
212 * libbfd-in.h: Likewise.
213 * libcoff-in.h: Likewise.
214 * bfd-in2.h: Regenerate.
215 * libbfd.h: Likewise.
216 * libcoff.h: Likewise.
217
146be91a
HPN
2182001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
219 Hans-Peter Nilsson <hp@bitrange.com>
220
221 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
222 partial_inplace, matching assembler output. Set src_mask to
223 all ones.
224 (sh_elf_relocate_section): Delete misplaced comment.
225 For relocatable linking against section symbol, call
226 _bfd_relocate_contents for partial_inplace relocs and adjust
227 rel->r_addend for others.
228 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
229 bfd_get_32, not at rel->r_addend.
230
3c3e9281
AM
2312001-09-30 Alan Modra <amodra@bigpond.net.au>
232
233 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
234 the old dir refcount, so we indirectly set them to init_refcount.
235 Short-circuit asserts when we've just verified they are true.
236
862517b6
AM
2372001-09-29 Alan Modra <amodra@bigpond.net.au>
238
239 * section.c (struct sec): Remove kept_section.
240 (STD_SECTION): Remove kept_section initialisation.
241 (bfd_make_section_anyway): Here too.
242 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
243 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
244 * elflink.h (elf_link_input_bfd): Set discarded link-once section
245 symbols to zero, and remove all code involved with kept_section
246 and tracking section symbol values.
247 * bfd-in2.h: Regenerate.
248 * configure.in: Bump version number.
249 * configure: Regenerate.
250
65f38f15
AM
2512001-09-29 Alan Modra <amodra@bigpond.net.au>
252
253 * elf64-ppc.c (struct ppc_dyn_relocs): New.
254 (IS_ABSOLUTE_RELOC): Define.
255 (struct ppc_link_hash_entry): New.
256 (struct ppc_link_hash_table): New.
257 (ppc_hash_table): Define.
258 (link_hash_newfunc): New function.
259 (ppc64_elf_link_hash_table_create): New function.
260 (create_got_section): New function.
261 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
262 pointers to our dynamic sections in hash table.
263 (ppc64_elf_copy_indirect_symbol): New function.
264 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
265 dynamic sections. Localise vars. Modify code for refcounts
266 starting from zero. Don't allocate here, or force symbols dynamic.
267 Don't copy all relocs if shared, select ones we need. Add code
268 to track possible copy relocs for non-shared link.
269 (ppc64_elf_gc_mark_hook): Update comment.
270 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
271 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
272 code for reference counting garbage collection. Don't create .plt
273 entries for functions that don't comply with ABI naming convention,
274 and don't allocate .plt space here. Use short-cuts to dynamic
275 sections. If possible, keep dynamic relocations instead of using
276 copy relocs. Remove confused comments.
277 (ppc_adjust_dynindx): Delete.
278 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
279 (allocate_dynrelocs): New function.
280 (readonly_dynrelocs): New function.
281 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
282 space here, and call allocate_dynrelocs to allocate space for
283 global .plt, .got and reloc sections. Use short-cuts to dynamic
284 sections. Call readonly_dynrelocs to determine whether we need
285 DT_TEXTREL. Don't generate section symbols here, the generic
286 ELF linker code does it for us.
287 (ppc64_elf_final_link): Call regular ELF backend linker rather than
288 gc variety, since we do our own .got handling.
289 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
290 dynamic section short-cuts. Localise vars, and delay setting.
291 Handle unknown relocs in main switch statement. Replace ugly
292 complicated tests for unresolvable relocs with a simple direct
293 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
294 before allowing an undefined sym in a shared lib. Do R_*_DS tests
295 after main switch, when we've set addend. Do non-addend insn
296 tweaks before main swithc. Ignore input_section->vma when
297 calculating reloc offsets as it's always zero. Rewrite dynamic
298 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
299 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
300 of dynamic section short-cuts. Reorganise .plt handling code.
301 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
302 Move expressions out of swap_reloca_out function calls.
303 (ppc64_elf_reloc_type_class): New function.
304 (ppc64_elf_info_to_howto): Move common expression to local var.
305 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
306 of dynamic section short-cuts. Don't fiddle with section syms
307 here as the ELF linker does it for us.
308 (elf_backend_can_refcount): Define.
309 (bfd_elf64_bfd_link_hash_table_create): Define.
310 (elf_backend_copy_indirect_symbol): Define.
311 (elf_backend_reloc_type_class): Define.
312 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
313
21d17a58
AM
3142001-09-29 Alan Modra <amodra@bigpond.net.au>
315
51b64d56
AM
316 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
317 (struct elf_backend_data): Add can_refcount.
318 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
319 got.refcount and plt.refcount from init_refcount.
320 (_bfd_elf_link_hash_table_init): Set up init_refcount.
321 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
322 rather than got/plt.offset, and test for <= 0 rather than -1.
323 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
324 * elfxx-target.h (elf_backend_can_refcount): Define.
325 (elfNN_bed): Init can_refcount.
326 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
327 (_bfd_generic_link_hash_newfunc): Likewise.
328 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
329 starting from zero.
330 (elf_backend_can_refcount): Define.
331 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
332 starting from zero.
333 (elf32_hppa_copy_indirect_symbol): Make static to agree with
334 prototype.
335 (elf_backend_can_refcount): Define.
336 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
337 starting from zero.
338 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
339 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
340 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
341 (elf_backend_can_refcount): Define.
342 (elf_i386_copy_indirect_symbol): Make static to agree with
343 prototype. Formatting fix.
344 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
345 starting from zero.
346 (elf_backend_can_refcount): Define.
347 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
348 starting from zero.
349 (elf_backend_can_refcount): Define.
350 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
351 starting from zero.
352 (elf_backend_can_refcount): Define.
353 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
354 starting from zero.
355 (elf_backend_can_refcount): Define.
356 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
357 starting from zero.
358 (elf_backend_can_refcount): Define.
359
21d17a58
AM
360 * som.c (som_write_symbol_strings): Cast current_offset in
361 bfd_seek call to match param type.
362
78ae4cb9
JB
3632001-09-28 J. Brobecker <brobecker@gnat.com>
364
365 * som.c (som_write_symbol_strings): Fix incorrect type of
366 current_offset to match the function definition. Fixes a build
367 failure on HPUX-11.00.
368
65db3b0d
RH
3692001-09-28 Richard Henderson <rth@redhat.com>
370
e0aae569
RH
371 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
372 SEC_MERGE, SEC_STRINGS.
373
65db3b0d
RH
374 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
375 * bfd-in2.h: Rebuild.
376
ced53ee5
AM
3772001-09-28 Alan Modra <amodra@bigpond.net.au>
378
ffaef159
AM
379 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
380 reloc code using x86_64_reloc_map.
381
3ac8354b
AM
382 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
383 no longer allocate here. Localise some vars to blocks where they
384 are used.
385 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
386 setting of vars until needed.
387 (allocate_dynrelocs): Don't create a .plt entry without a reloc
388 when symbol visibilty makes a function local.
389 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
390 swap_reloca_out function calls.
391 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
392 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
393 switch statement.
394
0ac8d2ca
AM
395 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
396 no longer allocate here. Localise some vars to blocks where they
397 are used. Remove separate switch stmt for creating .got sec.
398 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
399 redundant casts and aborts. Delay setting of vars until needed.
400 (allocate_dynrelocs): Remove redundant casts and aborts.
401 (elf_i386_size_dynamic_sections): Move comment.
402 (elf_i386_finish_dynamic_symbol): Move expressions out of function
403 calls.
404 (elf_i386_relocate_section): Likewise. Comment typo fix.
405 (elf_i386_finish_dynamic_sections): Migrate common code out of
406 switch statement.
407 (elf_backend_* defines): Sort.
408
ced53ee5
AM
409 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
410 without a reloc when symbol visibilty makes a function local.
411
63b0f745
NC
4122001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
413
06317a27
NC
414 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
415 conflicting float flags.
63b0f745 416
ebe50bae
AM
4172001-09-26 Alan Modra <amodra@bigpond.net.au>
418
419 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
420 (elf_backend_copy_indirect_symbol): Define.
421 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
422 (struct elf_i386_link_hash_table): Likewise.
423 (link_hash_newfunc): Get rid of unnecessary casts.
424 (elf_i386_link_hash_table_create): Likewise.
425 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
426 Don't test input section SEC_READONLY here to try to avoid copy
427 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
428 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
429 here to properly test whether we need copy relocs. Do so for weak
430 syms too.
431
432 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
433 (elf_backend_copy_indirect_symbol): Define.
434 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
435 (stub_hash_newfunc): Get rid of unnecessary casts.
436 (hppa_link_hash_newfunc): Likewise.
437 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
438 Don't test input section SEC_READONLY here to try to avoid copy
439 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
440 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
441 here to properly test whether we need copy relocs. Do so for weak
442 syms too.
443
af6166c0
AM
4442001-09-26 Alan Modra <amodra@bigpond.net.au>
445
446 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
447 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
448 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
449
e62de969
JJ
4502001-09-25 Jakub Jelinek <jakub@redhat.com>
451
452 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
453 computation.
454
09c1cc88
L
4552001-09-25 H.J. Lu <hjl@gnu.org>
456
457 * bfd-in2.h: Regenerated.
458
38701953
AM
4592001-09-25 Alan Modra <amodra@bigpond.net.au>
460
461 * elf32-i386.c: Add comment re linker function names and ordering.
462 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
463 (elf_i386_grok_prstatus): Move before linker functions.
464 (elf_i386_grok_psinfo): Likewise.
465 (elf_i386_fake_sections): Move so that functions are ordered.
466 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
467
98ceb8ce
AM
4682001-09-25 Alan Modra <amodra@bigpond.net.au>
469
0ac8d2ca 470 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
83c81bfe
AM
471 throughout file.
472
98ceb8ce
AM
473 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
474 code handling this option.
475 (LONG_BRANCH_VIA_PLT): Likewise.
476 (RELATIVE_DYNRELOCS): Define as zero.
477 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
478 "pc_count" fields. Remove "section" field.
479 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
480 (elf32_hppa_check_relocs): Don't allocate space for dynamic
481 relocs here. Instead, record all needed dynamic relocs via
482 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
483 in elf_section_data.
484 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
485 (allocate_plt_and_got_and_discard_relocs): Rename to
486 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
487 (readonly_dynrelocs): New function.
488 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
489 Call readonly_dynrelocs to determine need for DT_TEXTREL.
490 Rename "i" to "ibfd". Allocate space for local dyn relocs.
491 (elf32_hppa_relocate_section): Make use of cached sreloc.
492 (elf32_hppa_reloc_type_class): New function.
493 (elf_backend_reloc_type_class): Define.
494
0c715baa
AM
4952001-09-25 Alan Modra <amodra@bigpond.net.au>
496
497 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
498 and "sreloc" fields.
499 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
500 "pc_count" fields. Remove "section" field.
501 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
502 allocate space for dynamic relocs here. Instead, record all
503 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
504 pointer to "sreloc" section in elf_section_data.
505 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
506 (allocate_plt_and_got_and_discard_relocs): Rename to
507 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
508 (readonly_dynrelocs): New function.
509 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
510 Rename "i" to "ibfd". Allocate space for local dyn relocs.
511 (elf_i386_relocate_section): Make use of cached sreloc.
512
f51e552e
AM
5132001-09-24 Alan Modra <amodra@bigpond.net.au>
514
515 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
516 reloc rather than just the type.
517 (_bfd_elf_reloc_type_class): Likewise.
518 * elf.c (_bfd_elf_reloc_type_class): Likewise.
519 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
520 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
521 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
522 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
523 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
524 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
525 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
526 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
527 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
528 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
529 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
530 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
531 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
532 * elflink.h: Formatting fixes.
533 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
534 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
535 o->contents to PTR. Update call to elf_backend_reloc_type_class.
536
0c35f01a
AM
5372001-09-22 John Reiser <jreiser@BitWagon.com>
538
539 * elfcode.h (elf_object_p): Allow for no section header at all in
540 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
541
1e738b87
NC
5422001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
543
544 * elfxx-ia64.c: Fix compile time warning messages.
09c1cc88
L
545 * coff-mcore.c: Fix compile time warning messages.
546 * coff-ppc.c: Fix compile time warning messages.
547 * coffcode.h: Fix compile time warning messages.
548 * elf32-mips.c: Fix compile time warning messages.
549 * elf64-alpha.c: Fix compile time warning messages.
550 * libbfd.c: Fix compile time warning messages.
551 * bfd-in2.h: Regenerate.
1e738b87 552
923f08ff
AM
5532001-09-21 Alan Modra <amodra@bigpond.net.au>
554
555 * Makefile.am: Run "make dep-am".
556 * Makefile.in: Regenerate.
557
558 * aoutx.h: Formatting fixes.
559 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
560
561 * linker.c: Replace bfd_get_filename with bfd_archive_filename
562 in error message.
563
8f615d07
AM
5642001-09-21 Alan Modra <amodra@bigpond.net.au>
565
566 * bfd.c (bfd_archive_filename): New function.
567 * bfd-in2.h: Regenerate.
568 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
569 in error messages where the bfd is an input bfd.
570 * aout-cris.c: Likewise.
571 * coff-arm.c: Likewise.
572 * coff-mcore.c: Likewise.
573 * coff-ppc.c: Likewise.
574 * coff-rs6000.c: Likewise.
575 * coff-sh.c: Likewise.
576 * coff-tic54x.c: Likewise.
577 * coff-tic80.c: Likewise.
578 * coff64-rs6000.c: Likewise.
579 * coffcode.h: Likewise.
580 * coffgen.c: Likewise.
581 * cofflink.c: Likewise.
582 * ecofflink.c: Likewise.
583 * elf-hppa.h: Likewise.
584 * elf.c: Likewise.
585 * elf32-arm.h: Likewise.
586 * elf32-cris.c: Likewise.
587 * elf32-gen.c: Likewise.
588 * elf32-hppa.c: Likewise.
589 * elf32-i370.c: Likewise.
590 * elf32-i386.c: Likewise.
591 * elf32-m32r.c: Likewise.
592 * elf32-mcore.c: Likewise.
593 * elf32-mips.c: Likewise.
594 * elf32-ppc.c: Likewise.
595 * elf32-s390.c: Likewise.
596 * elf32-sh.c: Likewise.
597 * elf32-sparc.c: Likewise.
598 * elf32-v850.c: Likewise.
599 * elf64-alpha.c: Likewise.
600 * elf64-gen.c: Likewise.
601 * elf64-ppc.c: Likewise.
602 * elf64-s390.c: Likewise.
603 * elf64-sparc.c: Likewise.
604 * elf64-x86-64.c: Likewise.
605 * elflink.h: Likewise.
606 * elfxx-ia64.c: Likewise.
607 * ieee.c: Likewise.
608 * ihex.c: Likewise.
609 * libbfd.c: Likewise.
610 * pdp11.c: Likewise.
611 * pe-mips.c: Likewise.
612 * peicode.h: Likewise.
613 * srec.c: Likewise.
614 * xcofflink.c: Likewise.
615
616 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
617
618 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
619 error message.
620
621 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
622 error message.
623
624 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
625 Consolidate error messages, and split long messages to two lines.
626
671bae9c 6272001-09-20 John Reiser <jreiser@BitWagon.com>
83c81bfe 628
f51e552e
AM
629 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
630 and info->allow_shlib_undefined.
631 * elf32-cris.c: Likewise.
632 * elf32-hppa.c: Likewise.
633 * elf32-m68k.c: Likewise.
634 * elf32-mips.c: Likewise.
635 * elf32-ppc.c: Likewise.
636 * elf32-s390.c: Likewise.
637 * elf32-sh.c: Likewise.
638 * elf32-sparc.c: Likewise.
639 * elf64-alpha.c: Likewise.
640 * elf64-hppa.c: Likewise.
641 * elf64-ppc.c: Likewise.
642 * elf64-s390.c: Likewise.
643 * elf64-sparc.c: Likewise.
644 * elf64-x86-64.c: Likewise.
645 * elfxx-ia64.c: Likewise.
671bae9c 646
3882b010
L
6472001-09-18 Bruno Haible <haible@clisp.cons.org>
648
649 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
650 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
651 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
652 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
653 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
654 (bfd_default_scan): Use ISDIGIT instead of isdigit.
655 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
656 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
657 isxdigit/isdigit/islower.
658 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
659 (mangle_name): Use ISALNUM instead of isalnum.
660 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
661 (scan): Use ISDIGIT instead of isdigit.
662 * hosts/alphavms.h: Don't include <ctype.h>.
663 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
664 (ieee_object_p): Use TOUPPER instead of toupper.
665 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
666 (ihex_bad_byte): Use ISPRINT instead of isprint.
667 * merge.c: Don't include <ctype.h>.
668 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
669 (oasys_write_sections): Use ISDIGIT instead of isdigit.
670 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
671 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
672 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
673 (mangle_name): Use ISALNUM instead of isalnum.
674 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
675 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
676 isupper/islower/isdigit.
677 (som_decode_symclass): Use TOUPPER instead of toupper.
678 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
679 (srec_bad_byte): Use ISPRINT instead of isprint.
680 (srec_scan): Use ISSPACE instead of isspace.
681 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
682 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
683 * syms.c: Include "safe-ctype.h"
684 (islower, toupper): Remove macro definitions.
685 (bfd_decode_symclass): Use TOUPPER instead of toupper.
686 * vms-gsd.c: Don't include <ctype.h>.
687 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
688 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
689 islower/toupper.
690 * vms-tir.c: Don't include <ctype.h>.
691
dc810e39
AM
6922001-09-18 Alan Modra <amodra@bigpond.net.au>
693
694 * libbfd.c (bfd_bread): New function replacing bfd_read without
695 redundant params. Allow reads up to (size_t) -2 in length.
696 (bfd_bwrite): Similarly for bfd_write.
697 (real_read): Return a size_t.
698 (bfd_read): Call bfd_bread.
699 (bfd_write): Call bfd_bwrite.
700 (warn_deprecated): New function to annoy everybody.
701 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
702 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
703 (bfd_read, bfd_write): Define as macro.
704 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
705 likewise for bfd_write. Ensure function args are correct size by
706 using casts or local vars. In some cases, remove unnecessary
707 casts. Formatting fixes, in some cases removing a large expression
708 from function args by using a local var. Replace CONST with const.
709 Modify variable types to avoid warings. Use casts to avoid
710 warnings when using negative numbers in unsigned expressions.
711 * aout-adobe.c: Likewise.
712 * aout-arm.c: Likewise.
713 * aout-cris.c: Likewise.
714 * aout-encap.c: Likewise.
715 * aout-ns32k.c: Likewise.
716 * aout-target.h: Likewise.
717 * aout-tic30.c: Likewise.
718 * aoutf1.h: Likewise.
719 * aoutx.h: Likewise.
720 * archive.c: Likewise.
721 * archures.c: Likewise.
722 * bfd-in.h: Likewise.
723 * bfd.c: Likewise.
724 * binary.c: Likewise.
725 * bout.c: Likewise.
726 * cache.c: Likewise.
727 * cisco-core.c: Likewise.
728 * coff-a29k.c: Likewise.
729 * coff-alpha.c: Likewise.
730 * coff-arm.c: Likewise.
731 * coff-h8300.c: Likewise.
732 * coff-h8500.c: Likewise.
733 * coff-i386.c: Likewise.
734 * coff-i860.c: Likewise.
735 * coff-i960.c: Likewise.
736 * coff-ia64.c: Likewise.
737 * coff-m68k.c: Likewise.
738 * coff-m88k.c: Likewise.
739 * coff-mcore.c: Likewise.
740 * coff-mips.c: Likewise.
741 * coff-ppc.c: Likewise.
742 * coff-rs6000.c: Likewise.
743 * coff-sh.c: Likewise.
744 * coff-sparc.c: Likewise.
745 * coff-stgo32.c: Likewise.
746 * coff-tic30.c: Likewise.
747 * coff-tic54x.c: Likewise.
748 * coff-tic80.c: Likewise.
749 * coff-w65.c: Likewise.
750 * coff-z8k.c: Likewise.
751 * coff64-rs6000.c: Likewise.
752 * coffcode.h: Likewise.
753 * coffgen.c: Likewise.
754 * cofflink.c: Likewise.
755 * coffswap.h: Likewise.
756 * corefile.c: Likewise.
757 * cpu-arc.c: Likewise.
758 * cpu-h8300.c: Likewise.
759 * cpu-h8500.c: Likewise.
760 * cpu-i960.c: Likewise.
761 * cpu-ia64-opc.c: Likewise.
762 * cpu-ns32k.c: Likewise.
763 * cpu-pdp11.c: Likewise.
764 * cpu-pj.c: Likewise.
765 * cpu-sh.c: Likewise.
766 * cpu-w65.c: Likewise.
767 * cpu-z8k.c: Likewise.
768 * dwarf1.c: Likewise.
769 * dwarf2.c: Likewise.
770 * ecoff.c: Likewise.
771 * ecofflink.c: Likewise.
772 * ecoffswap.h: Likewise.
773 * elf-bfd.h: Likewise.
774 * elf-hppa.h: Likewise.
775 * elf-m10200.c: Likewise.
776 * elf-m10300.c: Likewise.
777 * elf.c: Likewise.
778 * elf32-arc.c: Likewise.
779 * elf32-arm.h: Likewise.
780 * elf32-avr.c: Likewise.
781 * elf32-cris.c: Likewise.
782 * elf32-fr30.c: Likewise.
783 * elf32-gen.c: Likewise.
784 * elf32-h8300.c: Likewise.
785 * elf32-hppa.c: Likewise.
786 * elf32-i370.c: Likewise.
787 * elf32-i386.c: Likewise.
788 * elf32-i860.c: Likewise.
789 * elf32-m32r.c: Likewise.
790 * elf32-m68k.c: Likewise.
791 * elf32-mcore.c: Likewise.
792 * elf32-mips.c: Likewise.
793 * elf32-openrisc.c: Likewise.
794 * elf32-pj.c: Likewise.
795 * elf32-ppc.c: Likewise.
796 * elf32-s390.c: Likewise.
797 * elf32-sh-lin.c: Likewise.
798 * elf32-sh.c: Likewise.
799 * elf32-sparc.c: Likewise.
800 * elf32-v850.c: Likewise.
801 * elf64-alpha.c: Likewise.
802 * elf64-hppa.c: Likewise.
803 * elf64-mips.c: Likewise.
804 * elf64-ppc.c: Likewise.
805 * elf64-s390.c: Likewise.
806 * elf64-sparc.c: Likewise.
807 * elf64-x86-64.c: Likewise.
808 * elfarm-nabi.c: Likewise.
809 * elfcode.h: Likewise.
810 * elfcore.h: Likewise.
811 * elflink.c: Likewise.
812 * elflink.h: Likewise.
813 * elfxx-ia64.c: Likewise.
814 * elfxx-target.h: Likewise.
815 * format.c: Likewise.
816 * hash.c: Likewise.
817 * hp300hpux.c: Likewise.
818 * hppabsd-core.c: Likewise.
819 * hpux-core.c: Likewise.
820 * i386aout.c: Likewise.
821 * i386dynix.c: Likewise.
822 * i386linux.c: Likewise.
823 * i386lynx.c: Likewise.
824 * i386mach3.c: Likewise.
825 * i386msdos.c: Likewise.
826 * i386os9k.c: Likewise.
827 * ieee.c: Likewise.
828 * ihex.c: Likewise.
829 * irix-core.c: Likewise.
830 * libaout.h: Likewise.
831 * libbfd-in.h: Likewise.
832 * libbfd.c: Likewise.
833 * libcoff-in.h: Likewise.
834 * libecoff.h: Likewise.
835 * libieee.h: Likewise.
836 * libnlm.h: Likewise.
837 * libpei.h: Likewise.
838 * libxcoff.h: Likewise.
839 * linker.c: Likewise.
840 * lynx-core.c: Likewise.
841 * m68klinux.c: Likewise.
842 * merge.c: Likewise.
843 * mipsbsd.c: Likewise.
844 * netbsd-core.c: Likewise.
845 * nlm.c: Likewise.
846 * nlm32-alpha.c: Likewise.
847 * nlm32-i386.c: Likewise.
848 * nlm32-ppc.c: Likewise.
849 * nlm32-sparc.c: Likewise.
850 * nlmcode.h: Likewise.
851 * nlmswap.h: Likewise.
852 * ns32k.h: Likewise.
853 * oasys.c: Likewise.
854 * opncls.c: Likewise.
855 * osf-core.c: Likewise.
856 * pc532-mach.c: Likewise.
857 * pdp11.c: Likewise.
858 * pe-mips.c: Likewise.
859 * peXXigen.c: Likewise.
860 * peicode.h: Likewise.
861 * ppcboot.c: Likewise.
862 * ptrace-core.c: Likewise.
863 * reloc.c: Likewise.
864 * reloc16.c: Likewise.
865 * riscix.c: Likewise.
866 * rs6000-core.c: Likewise.
867 * sco5-core.c: Likewise.
868 * section.c: Likewise.
869 * som.c: Likewise.
870 * sparclinux.c: Likewise.
871 * sparclynx.c: Likewise.
872 * srec.c: Likewise.
873 * stabs.c: Likewise.
874 * sunos.c: Likewise.
875 * syms.c: Likewise.
876 * targets.c: Likewise.
877 * tekhex.c: Likewise.
878 * trad-core.c: Likewise.
879 * versados.c: Likewise.
880 * vms-gsd.c: Likewise.
881 * vms-hdr.c: Likewise.
882 * vms-misc.c: Likewise.
883 * vms-tir.c: Likewise.
884 * vms.c: Likewise.
885 * vms.h: Likewise.
886 * xcofflink.c: Likewise.
887 * bfd-in2.h: Regenerate.
888 * libbfd.h: Regenerate.
889 * libcoff.h: Regenerate.
890
891 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
892 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
893 (ufile_ptr): Define.
894 (bfd_tell): Return a ufile_ptr.
895 * libbfd.c (bfd_tell): Likewise.
896 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
897 unnecessarily.
898 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
899 * aoutf1.h: Likewise.
900 * som.c: Likewise.
901 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
902 larger than unsigned long can represent.
903
904 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
905 size overflows size_t.
906 (bfd_realloc): Likewise.
907 (bfd_zmalloc): Likewise.
908 * opncls.c (bfd_alloc): Likewise.
909 (bfd_zalloc): Likewise.
910 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
911 (bfd_alloc, bfd_zalloc): Update.
912
913 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
914 8 bits.
915 (bfd_get_signed_8): Likewise.
916 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
917 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
918 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
919 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
920 * libaout.h: Likewise define and use here.
921 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
922 * aout-arm.c: Likewise.
923 * aout-encap.c: Likewise.
924 * aout-ns32k.c: Likewise.
925 * aout-tic30.c: Likewise.
926 * aoutf1.h: Likewise.
927 * aoutx.h: Likewise.
928 * bout.c: Likewise.
929 * coff-alpha.c: Likewise.
930 * coff-h8300.c: Likewise.
931 * coff-h8500.c: Likewise.
932 * coff-i960.c: Likewise.
933 * coff-ia64.c: Likewise.
934 * coff-m88k.c: Likewise.
935 * coff-mips.c: Likewise.
936 * coff-ppc.c: Likewise.
937 * coff-rs6000.c: Likewise.
938 * coff-sh.c: Likewise.
939 * coff-sparc.c: Likewise.
940 * coff-stgo32.c: Likewise.
941 * coff-tic30.c: Likewise.
942 * coff-tic80.c: Likewise.
943 * coff-w65.c: Likewise.
944 * coff-z8k.c: Likewise.
945 * coff64-rs6000.c: Likewise.
946 * coffgen.c: Likewise.
947 * cofflink.c: Likewise.
948 * coffswap.h: Likewise.
949 * ecoff.c: Likewise.
950 * ecoffswap.h: Likewise.
951 * elf.c: Likewise.
952 * elf32-mips.c: Likewise.
953 * elf64-mips.c: Likewise.
954 * hp300hpux.c: Likewise.
955 * i386dynix.c: Likewise.
956 * i386lynx.c: Likewise.
957 * i386msdos.c: Likewise.
958 * i386os9k.c: Likewise.
959 * libpei.h: Likewise.
960 * nlm32-alpha.c: Likewise.
961 * nlm32-i386.c: Likewise.
962 * nlm32-ppc.c: Likewise.
963 * nlmcode.h: Likewise.
964 * nlmswap.h: Likewise.
965 * oasys.c: Likewise.
966 * pdp11.c: Likewise.
967 * pe-mips.c: Likewise.
968 * peXXigen.c: Likewise.
969 * peicode.h: Likewise.
970 * riscix.c: Likewise.
971 * sunos.c: Likewise.
972 * xcofflink.c: Likewise.
973 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
974 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
975 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
976 equivalent H_PUT_* macro instead.
977 (GETWORD, GETHALF, GETBYTE): Similarly.
978 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
979 (GETWORD, GETHALF, GETBYTE): Likewise.
980 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
981
982 * bfd-in.h (struct orl): Change "pos" to a union.
983 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
984 (bsd_write_armap): Here too.
985 (coff_write_armap): And here.
986 * coff-rs6000.c (xcoff_write_armap_old): And here.
987 (xcoff_write_one_armap_big): And here.
988 (xcoff_write_armap_big): And here.
989 * ecoff.c (_bfd_ecoff_write_armap): And here.
990 * elf64-mips.c (mips_elf64_write_armap): And here.
991
992 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
993 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
994 * elf32-h8300.c (elf32_h8_mach): Likewise.
995 * elf32-mips.c (elf_mips_mach): Likewise.
996 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
997
998 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
999 calls.
1000 (aix386_core_vec): Typo fix.
1001
1002 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1003 etc. to avoid redefined macro warning.
1004 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1005 (MY(fix_pcrel_26)): Likewise.
1006 * aout-ns32k.c (MY(put_reloc)): Likewise.
1007 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1008 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1009 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1010
1011 * aout-encap.c: Include "file", not <file> for binutils headers.
1012 (encap_object_p): Half baked attempt to fix compile errors in
1013 code dealing with "magic".
1014
1015 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1016 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1017 bfd_vma's rather than longs.
1018 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1019 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1020 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1021 remove case 3.
1022 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1023 Use unsigned comparisons.
1024 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1025 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1026 (_bfd_do_ns32k_reloc_contents): Likewise.
1027 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1028 (_bfd_ns32k_get_immediate): Likewise.
1029 (_bfd_ns32k_put_displacement): Likewise.
1030 (_bfd_ns32k_put_immediate): Likewise.
1031 (bfd_reloc_status_type): Likewise.
1032
1033 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1034 to avoid shadowing.
1035 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1036 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1037 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1038 avoid shadowing.
1039 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1040 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1041 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1042 shadow warning.
1043 (_bfd_elfcore_strndup): Likewise for "dup".
1044 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1045 "name" to avoid shadowing.
1046 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1047 definition of "off".
1048 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1049 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1050 definition of "s".
1051 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1052 "secpp".
1053 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1054 to avoid shadowing.
1055 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1056 to avoid shadowing.
1057 (elf_link_input_bfd): Likewise.
1058 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1059 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1060 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1061 "input_section".
1062 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1063 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1064 (sunos_write_dynamic_symbol): Remove unused vars.
1065 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1066 innermost "directory_name" and "file_name" vars.
1067 * tekhex.c (first_phase): Rename local var "type" to "stype".
1068 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1069 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1070 doing comparison at caller.
1071 (vms_esecflag_by_name): Likewise.
1072 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1073 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1074 (xcoff_write_global_symbol): Rename "p" param to "inf".
1075
1076 * cisco-core.c: Add missing prototypes.
1077 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1078 (cisco_core_file_failing_signal): Likewise.
1079 (cisco_core_file_matches_executable_p): Likewise.
1080 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1081 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1082 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1083 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1084
1085 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1086 thumb_glue_size and arm_glue_size.
1087 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1088
1089 * coff64-rs6000.c: Group prototypes together.
1090
1091 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1092 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1093
1094 * cpu-arc.c: Add missing prototypes.
1095 * cpu-h8500.c: Likewise.
1096 * cpu-i960.c: Likewise.
1097 * cpu-pj.c: Likewise.
1098 * cpu-sh.c: Likewise.
1099 * cpu-w65.c: Likewise.
1100 * cpu-z8k.c: Likewise.
1101 * elf32-fr30.c: Likewise.
1102 * elf32-h8300.c: Likewise.
1103 * elf32-i370.c: Likewise.
1104 * hpux-core.c: Likewise.
1105 * versados.c: Likewise.
1106
1107 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1108 * cpu-h8500.c: Likewise.
1109 * cpu-i960.c: Likewise.
1110 * cpu-z8k.c: Likewise.
1111
1112 * cpu-ia64-opc.c: Correct comment.
1113
1114 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1115
1116 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1117 to unsigned.
1118 (bfd_elf32_write_out_phdrs): Likewise.
1119 (bfd_elf64_write_out_phdrs): Likewise.
1120 (elf_linker_section_pointers): Change addend to bfd_vma.
1121 (_bfd_elf_find_pointer_linker_section): Likewise.
1122 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1123 filepos to unsigned file_ptr.
1124 (_bfd_elfcore_strndup): Change max param to size_t.
1125 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1126 (_bfd_elfcore_strndup): Likewise.
1127 (_bfd_elf_find_pointer_linker_section): Likewise.
1128
1129 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1130 insn and sym_value to ints.
1131
1132 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1133 bfd_size_type.
1134 (elfcore_read_notes): Likewise.
1135
1136 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1137 param from unsigned char to int.
1138 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1139 for info_to_howto call.
1140 (add_dynamic_entry): Define macro.
1141 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1142
1143 * elf32-cris.c (add_dynamic_entry): Define macro.
1144 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1145
1146 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1147 (elf32_h8_object_p): Likewise.
1148 (elf32_h8_merge_private_bfd_data): Likewise.
1149 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1150
1151 * elf32-hppa.c (add_dynamic_entry): Define macro.
1152 (elf32_hppa_size_dynamic_sections): Use it.
1153 * elf32-i370.c (add_dynamic_entry): Define macro.
1154 (i370_elf_size_dynamic_sections): Use it.
1155 (i370_noop): Make static.
1156 * elf32-i386.c (add_dynamic_entry): Define macro.
1157 (elf_i386_size_dynamic_sections): Use it.
1158 * elf32-m68k.c (add_dynamic_entry): Define macro.
1159 (elf_m68k_size_dynamic_sections): Use it.
1160 * elf32-ppc.c (add_dynamic_entry): Define macro.
1161 (ppc_elf_size_dynamic_sections): Use it.
1162 * elf32-s390.c (add_dynamic_entry): Define macro.
1163 (elf_s390_size_dynamic_sections): Use it.
1164 * elf64-alpha.c (add_dynamic_entry): Define macro.
1165 (elf64_alpha_size_dynamic_sections): Use it.
1166 * elf64-hppa.c (add_dynamic_entry): Define macro.
1167 (elf64_hppa_size_dynamic_sections): Use it.
1168 * elf64-ppc.c (add_dynamic_entry): Define macro.
1169 (ppc64_elf_size_dynamic_sections): Use it.
1170 * elf64-s390.c (add_dynamic_entry): Define macro.
1171 (elf_s390_size_dynamic_sections): Use it.
1172 * elf64-sparc.c (add_dynamic_entry): Define macro.
1173 (sparc64_elf_size_dynamic_sections): Use it.
1174 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1175 (elf64_x86_64_size_dynamic_sections): Use it.
1176 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1177 (elfNN_ia64_size_dynamic_sections): Use it.
1178
1179 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1180 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1181
1182 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1183 false if the first malloc fails rather than going via error_return.
1184
1185 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1186 "index" param.
1187 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1188
1189 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1190
1191 * elfxx-ia64.c (global_sym_index): Return a long.
1192
1193 * ieee.c (get_symbol): Use int rather than char param.
1194 (ieee_slurp_sections): Move "section" var to inner blocks.
1195 (copy_expression): Don't init "value" to zero or worry about
1196 clearing to zero after using.
1197 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1198 shadowing.
1199
1200 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1201 unsigned int.
1202
1203 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1204 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1205
1206 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1207
1208 * pc532-mach.c (MYNSX): Delete.
1209 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1210 (write_object_contents): Correct prototype.
1211
1212 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1213 than unsigned short.
1214
1215 * section.c (bfd_set_section_contents): Remove redundant
1216 "offset < 0" test. Check that "count" doesn't overflow size_t.
1217 (bfd_get_section_contents): Likewise.
1218
1219 * som.c (som_fixup_formats): Add missing braces.
1220 (som_reloc_addend): Pass a bfd_vma for "addend".
1221
1222 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1223 (srec_write_symbols): Remove an unnecessary var.
1224
1225 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1226 to match.
1227 * configure.in: Sort to match. Bump version number.
1228 * configure: Regenerate.
1229
1230 * tekhex.c (move_section_contents): Assert offset == 0.
1231
1232 * versados.c (new_symbol_string): Constify arg.
1233 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1234 (versados_get_symbol_info): Make static.
1235 (versados_print_symbol): Likewise.
1236 (versados_get_reloc_upper_bound): Likewise.
1237 (versados_canonicalize_reloc): Likewise.
1238
417412a2
NC
12392001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1240
1241 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1242
bb731fb6
L
12432001-09-17 H.J. Lu <hjl@gnu.org>
1244
1245 * dwarf1.c (parse_die): Take a new arg for the end of the
1246 section. Return false if die is beyond the section.
1247 (parse_functions_in_unit): Pass the end of the section to
1248 parse_die ().
1249 (_bfd_dwarf1_find_nearest_line): Likewise.
1250
841989d6
NC
12512001-09-14 Michael Rauch <mrauch@netbsd.org>
1252
1253 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1254 just like R_SPARC_32.
1255
056a1d49
NC
12562001-09-14 Kevin Lo <kevlo@openbsd.org>
1257
1258 * configure.bfd: Add arm-openbsd target.
1259
4008bd9b
TS
12602001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1261
1262 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1263 Add support for mips64.
1264
c11cc227
AO
12652001-09-13 Alexandre Oliva <aoliva@redhat.com>
1266
1267 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1268
aa4f99bb
AO
12692001-09-12 Alexandre Oliva <aoliva@redhat.com>
1270
1271 * elf.c (prep_headers): Get the machine code from the elf
1272 backend data.
1273 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1274 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1275 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1276 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1277 * elf-arc.c (arc_elf_final_write_processing): Don't override
1278 e_machine, it's now properly set in prep_headers.
1279 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1280 EM_AVR_OLD.
1281 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1282 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1283 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1284 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1285 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1286 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1287 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1288 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1289 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1290 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1291 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1292 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1293
204692d7
RH
12942001-09-11 Richard Henderson <rth@redhat.com>
1295
1296 * elf64-alpha.c (elf64_alpha_section_flags): New.
1297 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1298
f94952df
RH
12992001-09-11 Richard Henderson <rth@redhat.com>
1300
1301 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1302 apply HINT relocations against dynamic symbols.
1303
146f1a87
L
13042001-09-11 H.J. Lu <hjl@gnu.org>
1305
f94952df 1306 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
146f1a87 1307
1cd6895c
RH
13082001-09-09 Richard Henderson <rth@redhat.com>
1309
96e2734b
RH
1310 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1311
1cd6895c
RH
1312 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1313 following a call to a near function.
1314
f16fbd61
RH
13152001-09-08 Richard Henderson <rth@redhat.com>
1316
1317 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1318 relocation errors. Fail gp-relative relocations against
1319 dynamic symbols.
1320
56882138
AM
13212001-09-08 Alan Modra <amodra@bigpond.net.au>
1322
1323 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1324 as well as DEF_DYNAMIC in test for avoided copy relocs.
1325 (allocate_plt_and_got_and_discard_relocs): Likewise.
1326 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1327 (allocate_plt_and_got_and_discard_relocs): Likewise.
1328
cb56d3d3
TS
13292001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1330
1331 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1332 of R_MIPS_PC16.
56882138
AM
1333
13342001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1335
1336 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1337 definitions.
1338 (mips_elf64_howto_table_rel): Likewise.
1339
13402001-09-05 Tom Rix <trix@redhat.com>
1341
1342 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1343 and syscall symbols.
1344 (write_global_symbol) : Same.
1345 (bfd_xcoff_export_symbol): Remove unused syscall param.
1346 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1347 bfd_xcoff_import_symbol.
1348 * bfd-in.h: Same.
1349 * bfd-in2.h : Regenerate.
1350
13512001-09-04 Richard Henderson <rth@redhat.com>
1352
1353 * elf64-alpha.c (SKIP_HOWTO): New.
1354 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1355 Fix sizes of 16-bit mem format relocs.
1356 (elf64_alpha_reloc_map): Update to match.
1357 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1358 (elf64_alpha_relax_without_lituse): Likewise.
1359 (elf64_alpha_check_relocs): Handle GPREL16.
1360 (elf64_alpha_relocate_section): Likewise.
1361 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1362 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1363 * bfd-in2.h, libbfd.h: Rebuild.
1364
13652001-09-04 Jeff Law <law@redhat.com>
1366
1367 * elf32-h8300.c (elf32_h8_relax_section): New function.
1368 (elf32_h8_relax_delete_bytes): Likewise.
1369 (elf32_h8_symbol_address_p): Likewise.
1370 (elf32_h8_get_relocated_section_contents): Likewise.
1371 (bfd_elf32_bfd_relax_section): Define.
1372 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1373
1374 * elf32-h8300.c (special): New function.
1375 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1376 all relocations.
1377 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1378 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1379 Fix minor problems with 8bit and 16bit PC relative relocations.
1380
13812001-09-01 Andreas Jaeger <aj@suse.de>
1382
1383 * vms-tir.c: Add missing prototypes.
1384 * vms-hdr.c: Likewise.
1385 * vms-gsd.c: Likewise.
1386 * vms-misc.c: Likewise.
1387
13882001-08-31 H.J. Lu <hjl@gnu.org>
1389
1390 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1391 with bad relocation.
1392
13932001-08-31 Eric Christopher <echristo@redhat.com>
1394 Jason Eckhardt <jle@redhat.com>
1395
1396 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1397 mips32_4k and mips64.
1398 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1399 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1400 * bfd/cpu-mips.c: Ditto.
1401 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1402 * bfd/bfd-in2.h: Regenerate.
1403
14042001-08-31 Jakub Jelinek <jakub@redhat.com>
1405
1406 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1407 value into R_ALPHA_RELATIVE's addend.
1408 (elf64_alpha_finish_dynamic_symbol): Likewise.
1409
14102001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1411
1412 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1413 recomputed addend during relocatable link if not USE_REL.
1414
1415 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1416 error.
1417
14182001-08-30 H.J. Lu <hjl@gnu.org>
1419
1420 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1421 2 changes.
1422 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1423 relocations for weak definitions.
1424
14252001-08-30 H.J. Lu <hjl@gnu.org>
1426
1427 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1428 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1429 * Makefile.in: Rebuild.
1430
14312001-08-30 H.J. Lu <hjl@gnu.org>
1432
1433 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1434 dynamic relocation for undefined weak symbols when creating
1435 executables. Check h->root.root.type, instead of h->root.type.
1436
14372001-08-29 Joel Sherrill <joel@OARcorp.com>
1438
1439 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1440 default from coff to elf.
1441
14422001-08-29 Jeff Law <law@redhat.com>
1443
1444 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1445 relocations.
1446 (h8_reloc_map): Similarly.
1447 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1448 Add support for PC relative relocations.
1449
1450 * elf32-h8300.c: Put all prototypes together.
1451 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1452 (elf32_h8_final_link_relocate): New function for linker.
1453 (elf32_h8_relocate_section): Similarly.
1454 (elf_backend_relocate_section): Define.
1455
1456 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1457 (h8300_scan): Handle architecture:machine encodings typically
1458 found in linker scripts.
1459 * elf.c (prep_headers): Do not try to do H8 machine recognition
1460 here.
1461 * elf32-h8300.c: Add some missing prototypes.
1462 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1463 (elf32_h8_object_p): Similarly.
1464
14652001-08-29 Tom Rix <trix@redhat.com>
1466
1467 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1468 does not follow a XTY_SD.
1469
14702001-08-29 Alan Modra <amodra@bigpond.net.au>
1471
1472 * targmatch.sed: Delete case statements.
1473 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1474 aix4.3 and above.
1475
1476Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1477
1478 * Makefile.am (elf32-h8300.lo): New target.
1479 * config.bfd (h8300*-*-elf): New case.
1480 * configure.in (bfd_elf32_h8300_vec): New case.
1481 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1482 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1483 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1484 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1485 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1486 * elf32-h8300.c: New file.
1487 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1488
14892001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1490
1491 * sparclynx.c: Add missing prototypes.
1492 * coff-mcore.c: Add missing prototypes.
1493 * elf32-pj.c: Add missing prototypes.
1494 * nlm32-sparc.c: Add missing prototypes.
1495 * oasys.c: Add missing prototypes.
1496 * pdp11.c: Add missing prototypes.
1497 * pe-mips.c: Add missing prototypes.
1498 * riscix.c: Add missing prototypes.
1499
15002001-08-27 Daniel Jacobowitz <drow@mvista.com>
1501
1502 * elf32-i386.c: Add missing prototypes.
1503 * elf32-ppc.c: Likewise.
1504 * elf32-sh-lin.c: Likewise.
1505 * elfarm-nabi.c: Likewise.
1506
15072001-08-27 Daniel Jacobowitz <drow@mvista.com>
1508
1509 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1510 (elf_i386_grok_psinfo): New function.
1511 (elf_backend_grok_prstatus): Define.
1512 (elf_backend_grok_psinfo): Likewise.
1513 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1514 (ppc_elf_grok_psinfo): New function.
1515 (elf_backend_grok_prstatus): Define.
1516 (elf_backend_grok_psinfo): Likewise.
1517 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1518 (elf32_shlin_grok_psinfo): New function.
1519 (elf_backend_grok_prstatus): Define.
1520 (elf_backend_grok_psinfo): Likewise.
1521 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1522 (elf32_arm_nabi_grok_psinfo): New function.
1523 (elf_backend_grok_prstatus): Define.
1524 (elf_backend_grok_psinfo): Likewise.
1525
15262001-08-27 H.J. Lu <hjl@gnu.org>
1527
1528 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1529 sanity check.
1530 (mips_elf_calculate_relocation): Create dynamic relocation for
1531 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1532 bit is not set.
1533
15342001-08-27 H.J. Lu <hjl@gnu.org>
1535
1536 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1537 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1538 (_bfd_elf32_mips_grok_prstatus): Likewise.
1539 (_bfd_elf32_mips_grok_psinfo): Likewise.
1540 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1541 `struct mips_elf_link_hash_entry *'.
1542 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1543
15442001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1545
1546 * mipsbsd.c: Add missing prototypes.
1547 * hp300hpux.c: Add missing prototypes.
1548 * i386aout.c: Add missing prototypes.
1549 * i386lynx.c: Add missing prototypes.
1550 * i386mach3.c: Add missing prototypes.
1551 * i386msdos.c: Add missing prototypes.
1552 * i386os9k.c: Add missing prototypes.
1553
15542001-08-27 Linus Nordberg <linus@swox.se>
1555 Torbjorn Granlund <tege@swox.com>
1556 Staffan Ulfberg <staffanu@swox.se>
1557 Alan Modra <amodra@bigpond.net.au>
1558
1559 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1560 targ64_selvecs for 32 bit powerpc targets.
1561 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1562 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1563 Run "make dep-am".
1564 * Makefile.in: Regenerate.
1565 * configure.in: Add elf64_powerpc vecs.
1566 * configure: Regenerate.
1567 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1568 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1569 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1570 * elf64-ppc.c: New file.
1571 * reloc.c: Add powerpc64 relocs.
1572 * libbfd.h: Regenerate.
1573 * bfd-in2.h: Regenerate.
1574
15752001-08-27 Andreas Schwab <schwab@suse.de>
1576
1577 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1578 reloc is against read-only section.
1579 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1580 looking up section names for DT_TEXTREL.
1581 (elf32_m68k_reloc_type_class): New function.
1582 (elf_backend_reloc_type_class): Define.
1583
15842001-08-27 Andreas Jaeger <aj@suse.de>
1585
1586 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1587 reloc is against read-only section.
1588 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1589 looking up section names for DT_TEXTREL.
1590 (elf_s390_reloc_type_class): New.
1591 (elf_backend_reloc_type_class): Define.
1592
1593 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1594 reloc is against read-only section.
1595 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1596 looking up section names for DT_TEXTREL.
1597 (elf_s390_reloc_type_class): New.
1598 (elf_backend_reloc_type_class): Define.
1599
1600 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1601 is against read-only section.
1602 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1603 looking up section names for DT_TEXTREL.
1604 (ppc_elf_reloc_type_class): New.
1605 (elf_backend_reloc_type_class): Define.
1606
16072001-08-26 Andreas Jaeger <aj@suse.de>
1608
1609 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1610 reloc is against read-only section.
1611 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1612 looking up section names for DT_TEXTREL.
1613 (elf_cris_reloc_type_class): New.
1614 (elf_backend_reloc_type_class): Define.
1615
1616 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1617 against read-only section.
1618 (elf_backend_reloc_type_class): Define.
1619 (sh_elf_reloc_type_class): New.
1620 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1621 looking up section names for DT_TEXTREL.
1622
1623 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1624 reloc is against read-only section.
1625 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1626 looking up section names for DT_TEXTREL.
1627 (elf32_arm_reloc_type_class): New.
1628 (elf_backend_reloc_type_class): Define.
1629
16302001-08-25 Andreas Jaeger <aj@suse.de>
1631
1632 * oasys.c: Add missing prototypes.
1633
1634 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1635 attribute for parameter.
1636 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1637
1638 * versados.c (get_4): Make static.
1639 (get_10): Make static.
1640 Add missing prototypes.
1641 (process_esd): Fix call to versados_new_symbol.
1642
16432001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1644
1645 * coff-a29k.c: Add missing prototypes.
1646 * coff-apollo.c: Add missing prototypes.
1647 * coff-arm.c: Add missing prototypes.
1648 * coff-i860.c: Add missing prototypes.
1649 * coff-rs6000.c: Add missing prototypes.
1650 * coff-tic80.c: Add missing prototypes.
1651 * elf-m10200.c: Add missing prototypes.
1652 * elf-m10300.c: Add missing prototypes.
1653 * elf32-arm.h: Add missing prototypes.
1654 * elf32-d10v.c: Add missing prototypes.
1655 * elf32-m32r.c: Add missing prototypes.
1656 * elf32-mcore.c: Add missing prototypes.
1657 * elf32-openrisc.c: Add missing prototypes.
1658 * elf32-sh.c: Add missing prototypes.
1659 * elf32-sparc.c: Add missing prototypes.
1660 * elf32-v850.c: Add missing prototypes.
1661 * elfarm-nabi.c: Add missing prototypes.
1662 * elfarm-oabi.c: Add missing prototypes.
1663
16642001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1665
1666 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1667 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1668
16692001-08-24 H.J. Lu <hjl@gnu.org>
1670
1671 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1672 hash structure.
1673
16742001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1675
1676 * elf-bfd.h (elf_hash_table): Revert definition.
1677 (is_elf_hash_table): New macro.
1678 * elflink.h (elf_link_add_object_symbols): Test
1679 is_elf_hash_table before accessing ELF only fields in hash
1680 structure.
1681 (elf_link_create_dynamic_sections): Fail if not using an ELF
1682 hash structure.
1683 (elf_add_dynamic_entry): Fail if not using an ELF hash
1684 structure.
1685 (elf_link_record_local_dynamic_symbol): Fail if not using an
1686 ELF hash structure.
1687 (size_dynamic_sections): Fail if not using an ELF hash
1688 structure.
1689 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1690 hash structure.
1691 (elf_bfd_final_link): Fail if not using an ELF hash
1692 structure.
1693
16942001-08-24 H.J. Lu <hjl@gnu.org>
1695
1696 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1697 table is not an ELF linker hash table.
1698
1699 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1700 table type to bfd_link_elf_hash_table.
1701
1702 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1703 the last change.
1704
1705 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1706 table type to bfd_link_generic_hash_table.
1707
17082001-08-24 Alexandre Oliva <aoliva@redhat.com>
1709
1710 * bfd.c (bfd_alt_mach_code): New function.
1711 * bfd-in2.h: Rebuilt.
1712
17132001-08-24 Alexandre Oliva <aoliva@redhat.com>
1714
1715 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1716 `type' field in the hash entry when deciding whether to follow a
1717 link.
1718
17192001-08-24 Jakub Jelinek <jakub@redhat.com>
1720
1721 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1722 last.
1723 (elf_link_sort_relocs): Adjust accordingly.
1724
1725 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1726 (elf64_alpha_check_relocs): Set it if section this reloc is against
1727 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1728 read-only section.
1729 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1730 is is against read-only section.
1731 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1732 check section names.
1733 (elf64_alpha_reloc_type_class): New.
1734 (elf_backend_reloc_type_class): Define.
1735
17362001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1737
1738 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
1739 by bfd_malloc().
1740
17412001-08-23 Andreas Jaeger <aj@suse.de>
1742
1743 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
1744 the reloc is against read-only section.
1745 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
1746 of looking up section names for DT_TEXTREL.
1747 (elf64_x86_64_reloc_type_class): New.
1748 (elf_backend_reloc_type_class): Define.
1749
17502001-08-23 H.J. Lu <hjl@gnu.org>
1751
1752 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
1753 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
1754
1755 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
1756 bfd_print_symbol_vandf.
1757 * coffgen.c (coff_print_symbol): Likewise.
1758 * elf.c (bfd_elf_print_symbol): Likewise.
1759 * ieee.c (ieee_print_symbol): Likewise.
1760 * nlmcode.h (nlm_print_symbol): Likewise.
1761 * oasys.c (oasys_print_symbol): Likewise.
1762 * pdp11.c (NAME(aout,print_symbol)): Likewise.
1763 * som.c (som_print_symbol): Likewise.
1764 * srec.c (srec_print_symbol): Likewise.
1765 * tekhex.c (tekhex_print_symbol): Likewise.
1766 * versados.c (versados_print_symbol): Likewise.
1767 * vms.c (vms_print_symbol): Likewise.
1768
1769 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
1770 with bfd_fprintf_vma.
1771 (bfd_elf_print_symbol): Likewise.
1772 * syms.c (bfd_print_symbol_vandf): Likewise.
1773
17742001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
1775
1776 * aoutf1.h (sunos_write_object_contents): Silence compile time
1777 warning.
1778 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
1779
1780 * bout.c: Add missing function prototypes. Fix formatting.
1781 * coff-z8k.c: Add missing function prototypes. Fix formatting.
1782 * coff-w65.c: Add missing function prototypes. Fix formatting.
1783 * coff-h8500.c: Add missing function prototypes. Fix formatting.
1784 * coff-h8300.c: Add missing function prototypes. Fix formatting.
1785 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
1786 * coff-tic30.c: Add missing function prototypes. Fix formatting.
1787 * coff-m68k.c: Add missing function prototypes. Fix formatting.
1788 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
1789 * coff-sh.c: Add missing function prototypes. Fix formatting.
1790
17912001-08-23 Jakub Jelinek <jakub@redhat.com>
1792
1793 * elf-bfd.h (enum elf_reloc_type_class): New.
1794 (struct elf_backend_data): Add elf_backend_reloc_type_class.
1795 (_bfd_elf_reloc_type_class): New.
1796 * elfxx-target.h (elf_backend_reloc_type_class): Define.
1797 (elfNN_bed): Add elf_backend_reloc_type_class.
1798 * elf.c (_bfd_elf_reloc_type_class): New.
1799 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
1800 is against read-only section.
1801 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
1802 looking up section names for DT_TEXTREL.
1803 (elf_i386_reloc_type_class): New.
1804 (elf_backend_reloc_type_class): Define.
1805 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
1806 reloc is against read-only section.
1807 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
1808 looking up section names for DT_TEXTREL.
1809 (elf32_sparc_reloc_type_class): New.
1810 (elf_backend_reloc_type_class): Define.
1811 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
1812 reloc is against read-only section.
1813 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1814 looking up section names for DT_TEXTREL.
1815 (sparc64_elf_reloc_type_class): New.
1816 (elf_backend_reloc_type_class): Define.
1817 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
1818 (elfNN_ia64_hash_table_create): Clear ia64_info.
1819 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
1820 section.
1821 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
1822 instead of looking up section names for DT_TEXTREL.
1823 (elfNN_ia64_reloc_type_class): New.
1824 (elf_backend_reloc_type_class): Define.
1825 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
1826 (struct elf_link_sort_rela): New.
1827 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
1828 (elf_bfd_final_link): Call elf_link_sort_relocs.
1829 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
1830 necessary.
1831
18322001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
1833
1834 * configure.in (x86-bsdi): No corefile support.
1835 * configure: Regenerate.
1836
18372001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
1838
1839 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
1840 comma.
1841
18422001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
1843
1844 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
1845 the alignment of dwarf2 linkonce sections to 0.
1846 * coff-sto32.c: Likewise.
1847
18482001-08-20 Andreas Jaeger <aj@suse.de>
1849
1850 * coff-sparc.c: Add missing prototypes.
1851 * elf32-s390.c: Likewise.
1852 * elf32-i960.c: Likewise.
1853 * aout-target.h: Likewise.
1854
18552001-08-20 H.J. Lu <hjl@gnu.org>
1856
1857 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
1858 (elf_num_section_syms): New for num_section_syms.
1859
1860 * elf.c (elf_map_symbols): Set num_section_syms.
1861 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
1862 the section symbol index.
1863
18642001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
1865
1866 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
1867 select the generic has table creator. All elf backends need elf
1868 specific fields in the hash table.
1869
18702001-08-20 Alan Modra <amodra@bigpond.net.au>
1871
1872 * archive.c (offsetof): Remove define.
1873 * elf.c: Likewise.
1874 * oasys.c: Likewise
1875 * sysdep.h (offsetof): Define.
1876
18772001-08-17 Alan Modra <amodra@bigpond.net.au>
1878
1879 * bfd.c (bfd_get_gp_size): Return an unsigned int.
1880 (bfd_set_gp_size): Make param unsigned.
1881 * bfd-in2.h: Regenerate.
1882 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
1883 than calling bfd_get_gp_size.
1884 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
1885 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
1886
18872001-08-17 Alan Modra <amodra@bigpond.net.au>
1888
1889 * linker.c (default_fill_link_order): Handle four byte fill value.
1890
18912001-08-17 Alan Modra <amodra@bigpond.net.au>
1892
1893 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
1894 prototype.
1895 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
1896
1897 * elf64-mips.c (UNUSED_RELOC): Define.
1898 (mips_elf64_howto_table_rel): Use it.
1899 (mips_elf64_howto_table_rela): Here too.
1900 (mips_elf64_write_relocs): Fix signed/unsigned warning.
1901
1902 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
1903 silence warning.
1904 * coffgen.c (coff_print_symbol): Fix warnings.
1905 (coff_find_nearest_line): Likewise.
1906 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
1907 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
1908 * format.c (bfd_check_format_matches): Likewise.
1909 (bfd_set_format): Likewise.
1910 * coff-ia64.c: Add missing prototypes.
1911 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
1912 signed to silence warnings.
1913 (elf64_alpha_relocate_section): Likewise.
1914 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
1915 (elf64_alpha_add_symbol_hook): Likewise.
1916 (elf64_alpha_final_link): Likewise.
1917 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
1918 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
1919 (elf64_alpha_size_got_sections): Likewise.
1920 * elfxx-ia64.c: Add missing prototypes.
1921 (elfNN_ia64_relocate_section): Fix warning.
1922 (elfNN_ia64_unwind_entry_compare): Make params const.
1923
19242001-08-17 Alan Modra <amodra@bigpond.net.au>
1925
1926 * config.bfd (targ64_selvecs): New.
1927 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
1928
1929 * bfd-in.h (BFD_VERSION): Remove wrong comment.
1930 (BFD_DEFAULT_TARGET_SIZE): New.
1931 (BFD_ARCH_SIZE): Comment.
1932 * configure.in (target_size): New. Set instead of target64 in
1933 selvecs case statement. Set target64 from it.
1934 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
1935 * bfd-in2.h: Regenerate.
1936 * configure: Regenerate.
1937
19382001-08-17 Alan Modra <amodra@bigpond.net.au>
1939
1940 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
1941 (bfd_errmsgs): Add corresponding message.
1942 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
1943 finding an archive that contains different format object files.
1944 Return bfd_error_wrong_object_format for this case.
1945 * format.c: Formatting fixes. s/CONST/const/.
1946 (bfd_check_format_matches): Accept archives that give
1947 bfd_error_wrong_object_format if no full match is found. Tidy
1948 code handling matching_vector. Don't return a pointer to freed
1949 memory in `matching'. Handle ambiguous matches as for partial
1950 archive matches.
1951 * bfd-in2.h: Regenerate.
1952
19532001-08-15 Alan Modra <amodra@bigpond.net.au>
1954
1955 * libieee.h (common_header_type): Add last_byte field.
1956
1957 * ieee.c: Add missing prototypes. Some format fixes.
1958 (struct output_buffer_struct): Move for availability to prototypes.
1959 (ieee_part_after): New function.
1960 (ieee_slurp_debug): Use it here.
1961 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
1962 ieee_part_after to set last_byte to one past end of current part.
1963 Update callers.
1964 (ieee_pos): Pass in ieee_data_struct rather than bfd.
1965 Update callers.
1966 (parse_expression): Don't go beyond the end of the current part.
1967 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
1968 (ieee_get_symtab_upper_bound, ieee_get_symtab,
1969 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
1970 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
1971 ieee_set_section_contents, ieee_write_object_contents,
1972 ieee_make_empty_symbol): Make static.
1973 (ieee_archive_p): Correct comments regarding bfd_read.
1974 (ieee_object_p): Similarly.
1975 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
1976 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
1977 input_bfd, output_bfd, output_buffer.
1978 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
1979 do_with_relocs, ie. as a symbol for relocatable files.
1980 (ieee_vec): Add comments showing functions referenced by macros.
1981
19822001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
1983
1984 * aout-tic30.c: Add missing prototypes. Fix formatting.
1985 * aout-ns32k.c: Add missing prototypes. Fix formatting.
1986 * peXXigen.c: Add missining prototypes. Fix formatting.
1987 * aout-adobe.c: Add missining prototypes. Fix formatting.
1988
19892001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
1990
1991 * elf32-v850.c: Add missing function prototypes.
1992 Fix some formatting.
1993
1994 * cpu-v850.c: Add missing function prototype.
1995 Fix some formatting.
1996
19972001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
1998
1999 * elf-bfd.h (struct elf_backend_data): Add new fields
2000 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2001 (bfd_elf_sprintf_vma): Rename function prototype to
2002 '_bfd_elf_sprintf_vma'.
2003 (bfd_elf_fprintf_vma): Rename function prototype to
2004 '_bfd_elf_fprintf_vma'.
2005 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2006 directly, instead indirect via the elf_backend_data structure.
2007 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2008 instead indirect via the elf_backend_data structure.
2009 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2010 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2011 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2012 already defined.
2013 (elf_backend_fprintf_vma): Initialise if not already defined.
2014 (struct elf_backend_data): Initialise the
2015 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2016
20172001-08-10 Andreas Jaeger <aj@suse.de>
2018
2019 * elf64-sparc.c: Add missing prototypes.
2020 * elf32-cris.c: Likewise.
2021 * elf32-i370.c: Likewise.
2022 * elf64-hppa.c: Likewise.
2023 * elf64-s390.c: Likewise.
2024
20252001-08-10 Andreas Jaeger <aj@suse.de>
2026
2027 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2028 Add prototypes where needed.
2029
20302001-08-10 H.J. Lu <hjl@gnu.org>
2031
2032 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2033 (bfd_fprintf_vma): Likewise.
2034
20352001-08-10 H.J. Lu <hjl@gnu.org>
2036
2037 * bfd.c (bfd_sprintf_vma): Don't return void.
2038 (bfd_fprintf_vma): Likewise.
2039
20402001-08-10 Andreas Jaeger <aj@suse.de>
2041
2042 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2043 to build warnings.
2044 * configure: Regenerate.
2045
20462001-08-10 Alan Modra <amodra@bigpond.net.au>
2047
2048 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2049 warning if not BFD64. Add braces so emacs auto format works.
2050 (bfd_elf_fprintf_vma): Likewise.
2051
2052 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2053 of _xcoff_swap_ld*.
2054 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2055 param to agree with libxcoff.h.
2056 (xcoff_swap_ldhdr_out): Likewise.
2057 (xcoff_swap_ldsym_in): Likewise.
2058 (xcoff_swap_ldsym_out): Likewise.
2059 (xcoff_swap_ldrel_in): Likewise.
2060 (xcoff_swap_ldrel_out): Likewise.
2061 (xcoff_create_csect_from_smclas): Likewise.
2062 * coff64-rs6000.c: Add missing prototypes.
2063 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2064 with libxcoff.h.
2065 (xcoff64_swap_ldhdr_out): Likewise.
2066 (xcoff64_swap_ldsym_in): Likewise.
2067 (xcoff64_swap_ldsym_out): Likewise.
2068 (xcoff64_swap_ldrel_in): Likewise.
2069 (xcoff64_swap_ldrel_out): Likewise.
2070 (xcoff64_ppc_relocate_section): Make static.
2071 (xcoff64_slurp_armap): Likewise.
2072 (xcoff64_archive_p): Likewise.
2073 (xcoff64_openr_next_archived_file): Likewise.
2074 (xcoff64_sizeof_headers): Likewise.
2075 (xcoff64_is_lineno_count_overflow): Likewise.
2076 (xcoff64_is_reloc_count_overflow): Likewise.
2077 (xcoff64_loader_symbol_offset): Likewise.
2078 (xcoff64_loader_reloc_offset): Likewise.
2079 * elf64-gen.c: Add missing prototypes.
2080
20812001-08-09 H.J. Lu <hjl@gnu.org>
2082
2083 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2084 (bfd_elf_fprintf_vma): Likewise.
2085
20862001-08-09 H.J. Lu <hjl@gnu.org>
2087
2088 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2089 to ...
2090 * elf-bfd.h: Here.
2091 * bfd-in2.h: Regenerated.
2092
20932001-08-09 H.J. Lu <hjl@gnu.org>
2094
2095 * bfd-in.h (bfd_sprintf_vma): New prototype.
2096 (bfd_fprintf_vma): Likewise.
2097 (bfd_elf_sprintf_vma): Likewise.
2098 (bfd_elf_fprintf_vma): Likewise.
2099 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2100 * bfd-in2.h: Regenerated.
2101
2102 * bfd.c (bfd_sprintf_vma): New. Defined.
2103 (bfd_fprintf_vma): Likewise.
2104
2105 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2106 (bfd_elf_fprintf_vma): Likewise.
2107
21082001-08-09 Alan Modra <amodra@bigpond.net.au>
2109
2110 * coff-rs6000.c: Add missing prototypes.
2111 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2112 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2113 xcoff_loader_reloc_offset): Make static.
2114 * dwarf1.c: Add missing prototypes.
2115 * dwarf2.c: Add missing prototypes.
2116 (struct abbrev_info): Move definition.
2117 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2118 * elf.c: Add missing prototypes.
2119 * elf32-gen.c: Likewise.
2120 * elf32-i386.c: Likewise.
2121 * elf32-ppc.c: Likewise.
2122 (ppc_elf_sort_rela): Use PTR instead of "void *".
2123 * elflink.h: Add missing prototypes. Formatting fixes.
2124 * merge.c: Add missing prototypes.
2125 (last4_eq): Use PTR instead of "void *".
2126 (last_eq): Likewise.
2127 * syms.c: Add missing prototypes.
2128
21292001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2130
2131 * bfd.c: Fix formatting.
2132 * bfd-in2.h: Regenerate.
2133
21342001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2135
2136 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2137 true (this target uses REL relocations) and 'pcrel_offset' to
2138 false (the PC is implied, not stored in the offset).
2139
21402001-08-08 Alan Modra <amodra@bigpond.net.au>
2141
2142 1999-10-19 Linus Nordberg <linus@swox.se>
2143 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2144 * elfxx-target.h (elf_backend_want_got_sym): Define.
2145 (elfNN_bed): Add elf_backend_want_got_sym.
2146 * elflink.c (_bfd_elf_create_got_section): Define
2147 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2148
21492001-08-08 Alexandre Oliva <aoliva@redhat.com>
2150
2151 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2152 (find_rela_addend): New function.
2153 (parse_comp_unit): Call it to find the abbrev offset addend.
2154 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2155 members of dwarf2_debug as debugging information is read.
2156
21572001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2158
2159 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2160 targets as well as sh-pe.
2161
21622001-08-03 Ben Harris <bjh21@netbsd.org>
2163
2164 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2165 reloc from start of section when computing value for R_ARM_REL32
2166 reloc.
2167
21682001-08-03 Alan Modra <amodra@bigpond.net.au>
2169
2170 From H.J. Lu <hjl@gnu.org>
2171 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2172 keep relocs for undefined syms if there are no dynamic sections in
2173 executable.
2174 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2175
21762001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2177
2178 * cofflink.c (coff_link_check_ar_symbols): also search for
2179 __imp__symbol as well as _symbol.
2180 * linker.c (_bfd_generic_link_add_archive_symbols): also
2181 search for __imp__symbol as well as _symbol.
2182
21832001-08-01 Adam Nemet <anemet@lnxw.com>
2184
2185 * elf.c (elf_sort_sections): Return zero only as the last step.
2186
21872001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2188
2189 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2190 ARM_COFF_BUGFIX.
2191 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2192 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2193 ARM_COFF_BUGFIX.
2194
21952001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2196
2197 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2198 to match corresponding bfd_coff_backend data member.
2199
22002001-07-24 Alan Modra <amodra@bigpond.net.au>
2201
2202 * Makefile.am: Update dependencies with "make dep-am".
2203 * Makefile.in: Regenerate
2204
22052001-07-15 H.J. Lu <hjl@gnu.org>
2206
2207 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2208 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2209 * Makefile.in: Regenerate.
2210
22112001-07-11 H.J. Lu <hjl@gnu.org>
2212
2213 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2214 flags when creating the reloc section if the ALLOC flag in the
2215 source section is set.
2216
22172001-07-11 Steve Ellcey <sje@cup.hp.com>
2218
2219 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2220 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2221 * bfd-in2.h: Regenerate.
2222 * libbfd.h: Regenerate.
2223 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2224 new relocations.
2225 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2226 (elfNN_ia64_check_relocs): Likewise.
2227 (elfNN_ia64_install_value): Likewise.
2228 (elfNN_ia64_relocate_section): Likewise.
2229
22302001-07-11 Jakub Jelinek <jakub@redhat.com>
2231
2232 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2233 R_SPARC_UA64.
2234 (elf32_sparc_check_relocs): Likewise.
2235 Only create .rela section for alloced sections in shared libraries.
2236 (elf32_sparc_relocate_section): Likewise.
2237 Remove redundant check.
2238 Optimize unaligned reloc usage.
2239 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2240 check.
2241
22422001-07-11 H.J. Lu <hjl@gnu.org>
2243
2244 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2245 ALLOC|LOAD flags as the source section for debugging sections
2246 when creating the reloc section.
2247
22482001-07-05 Jim Wilson <wilson@redhat.com>
2249
2250 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2251 the section of the bigger symbol.
2252
2253 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2254
22552001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2256
2257 * peicode.h (coff_swap_scnhdr_in): For sections containing
2258 uninitialised data, only set their size to s_paddr if this does
2259 not reset their size to zero. MS's latest compilers will set
2260 s_paddr to zero.
2261
22622001-07-04 H.J. Lu <hjl@gnu.org>
2263
2264 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2265 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2266 bfd_mach_mips5000.
2267
22682001-07-03 Mark Elbrecht <snowball3@softhome.net>
2269
2270 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2271
2272 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2273 sections being discarded.
2274
22752001-06-30 Alan Modra <amodra@bigpond.net.au>
2276
2277 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2278 instead of _bfd_elfcore_section_from_phdr.
2279 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2280 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2281 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2282 (elfcore_grok_prstatus): Likewise.
2283 (elfcore_grok_lwpstatus): Likewise.
2284 (bfd_get_elf_phdr_upper_bound): Likewise.
2285 (elfcore_make_note_pseudosection): Formatting.
2286 (_bfd_elfcore_strndup): Formatting.
2287 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2288 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2289
22902001-06-29 Daniel Jacobowitz <drow@mvista.com>
2291
2292 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2293 and _bfd_elfcore_strndup.
2294 (struct elf_backend_data): Add elf_backend_grok_prstatus
2295 and elf_backend_grok_psinfo.
2296 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2297 (elfcore_grok_prstatus): Use it.
2298 (elfcore_make_note_pseudosection): Likewise.
2299 (elfcore_strndup): Rename to...
2300 (_bfd_elfcore_strndup): Here, and make global.
2301 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2302 (elfcore_grok_note): Call elf_backend_grok_prstatus
2303 and elf_backend_grok_psinfo if available.
2304 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2305 (_bfd_elf32_mips_grok_psinfo): New function.
2306 (elf_backend_grok_prstatus): Define.
2307 (elf_backend_grok_psinfo): Define.
2308 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2309 (elf_backend_grok_psinfo): Likewise.
2310 (elfNN_bed): Include elf_backend_grok_prstatus and
2311 elf_backend_grok_psinfo.
2312
23132001-06-29 H.J. Lu <hjl@gnu.org>
2314
2315 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2316 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2317 is NULL before filling PLT.
2318
23192001-06-29 Alan Modra <amodra@bigpond.net.au>
2320
2321 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2322
23232001-06-27 Alan Modra <amodra@bigpond.net.au>
2324
2325 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2326 here..
2327 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2328 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2329 after gc has run.
2330
2331 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2332 (IS_ABSOLUTE_RELOC): Define.
2333 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2334 (hppa_link_hash_newfunc): Always init it.
2335 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2336 create COPY relocs only when the reloc is in a read-only section.
2337 Instead, allocate space for a dynamic reloc to reference the
2338 library symbol directly. Keep track of space we allocate using
2339 relocs_entries.
2340 (hppa_discard_copies): Delete, and move code to..
2341 (allocate_plt_and_got): ..here. Rename to
2342 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2343 relocs for non-shared link.
2344 (elf32_hppa_size_dynamic_sections): Update calls to above.
2345 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2346 in lieu of COPY relocs.
2347
2348 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2349 here..
2350 (elf_i386_adjust_dynamic_symbol): ..nor here..
2351 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2352 after gc has run.
2353 (elf_i386_size_dynamic_sections): Fix a comment.
2354 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2355 involved in writing reloc out.
2356
23572001-06-25 Alan Modra <amodra@bigpond.net.au>
2358
2359 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2360 Ensure syms are dynamic if we might be emitting a reloc.
2361 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2362 for undefweak or undefined syms..
2363 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2364
2365 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2366 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2367 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2368 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2369
23702001-06-24 H.J. Lu <hjl@gnu.org>
2371
2372 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2373 strncasecmp/strcasecmp instead of strncmp/strcmp.
2374
23752001-06-23 H.J. Lu <hjl@gnu.org>
2376
2377 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2378 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2379 in the regular object file and treat the weak definition as
2380 the normal one.
2381
23822001-06-23 Alan Modra <amodra@bigpond.net.au>
2383
2384 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2385 unresolved_reloc test to exclude cases where we use "relocation"
2386 before setting it to point into the .got. Reinstate fudge for
2387 unresolved relocs in debugging sections.
2388
2389 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2390 complicated tests for unresolvable relocs with a simple direct
2391 scheme using "unresolved_reloc" var.
2392
2393 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2394 elf_i386_dyn_relocs. Update comment.
2395 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2396 dyn_relocs.
2397 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2398 others to aborts.
2399 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2400 abort.
2401 (elf_i386_size_dynamic_sections): Likewise.
2402 (elf_i386_finish_dynamic_symbol): Likewise.
2403 (elf_i386_finish_dynamic_sections): Likewise.
2404 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2405 handling code.
2406
2407 Avoid creating COPY relocs if possible.
2408 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2409 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2410 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2411 reloc is in a read-only section. Instead, allocate space for a
2412 dynamic reloc to reference the library symbol directly. Keep
2413 track of space we allocate using pcrel_relocs_copied.
2414 (discard_copies): Delete, and move code to ..
2415 (allocate_plt_and_got): ..here. Rename to
2416 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2417 relocs for non-shared link.
2418 (elf_i386_size_dynamic_sections): Update calls to above functions.
2419 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2420 more ugly logic to avoid "unresolvable relocation" error. Use
2421 htab shortcut in place of elf_hash_table macro.
2422 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2423 not always be created now.
2424
24252001-06-20 Bo Thorsen <bo@suse.co.uk>
2426
2427 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2428 shared libraries.
2429
24302001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2431
2432 * configure.host (mips64-*-linux): Reformat.
2433
24342001-06-21 Alan Modra <amodra@bigpond.net.au>
2435
2436 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2437 allocate local .got space. Use shortcuts from hash table for .got
2438 and .plt rather than comparing section names.
2439 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2440 adjusting index into local_got_refcounts to document what we are
2441 really doing.
2442 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2443 Tidy .got and .plt error checking.
2444
24452001-06-20 Catherine Moore <clm@redhat.com>
2446
2447 * elf-bfd.h (struct elf_backend_data):
2448 elf_backend_emit_relocs: New field: Function for emitting
2449 relocs.
2450 elf_backend_count_relocs: New field: Function for determining
2451 the number of relocs to be emitted.
2452 * elfxx-target.h: Provide default (NULL) values for
2453 elf_backend_emit_relocs and elf_backend_count_relocs.
2454 * elflink.h (elf_link_size_reloc_section): Make the hash table
2455 big enough to hold the relocs counted by either reloc_count or
2456 o->reloc_count.
2457 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2458 should be emitted, either because of a command line option
2459 stored in the info structure or because the target provides a
2460 special reloc emitting function.
2461 If the target provides a reloc counting function use it,
2462 unless performing a relocatable link or emitting all relocs.
2463 Also set the SEC_RELOC flag on any output section which will
2464 contain relocs.
2465 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2466 should be emitted, either because of a command line option
2467 stored in the info structure or because the target provides a
2468 special reloc emitting function.
2469 If the target provides a reloc emitting function, use it,
2470 unless performing a relocatable link or emitting all relocs.
2471
24722001-06-20 H.J. Lu <hjl@gnu.org>
2473
2474 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2475 allocate local .got space.
2476
24772001-06-19 Andreas Jaeger <aj@suse.de>
2478
2479 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2480 dynamic symbols.
2481
24822001-06-18 Hans-Peter Nilsson <hp@axis.com>
2483
2484 * elflink.h (struct elf_assign_sym_version_info): Remove member
2485 export_dynamic. All users changed to use info member.
2486 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2487 export_dynamic, instead use member in parameter info.
2488 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2489 bfd_elf64_size_dynamic_sections): Update prototype.
2490 * bfd-in2.h: Regenerate.
2491
24922001-06-18 H.J. Lu <hjl@gnu.org>
2493
2494 * elflink.h (elf_info_failed): Add a new field, verdefs.
2495 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2496 elf_export_symbol.
2497 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2498 should be exported.
2499
25002001-06-17 H.J. Lu <hjl@gnu.org>
2501
2502 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2503 readonly_reloc, to record if a relocation in the .rel.dyn
2504 section is against a read-only section.
2505 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2506 field to false.
2507 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2508 in the .rel.dyn section against a read-only section by setting
2509 DF_TEXTREL or readonly_reloc.
2510 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2511 it is true.
2512 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2513 there is a relocation in the .rel.dyn section against a
2514 read-only section.
2515 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2516 DF_TEXTREL is set.
2517
25182001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2519
2520 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2521 function. Move flagword result into parameter list. Remove
2522 comment about setting bfd_error_handler to intercept failure
2523 results.
2524 * coffgen.c (make_a_section_from_file): Examine result of
2525 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2526 caller.
2527 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2528 function. Move flagword result into parameter list.
2529 * libcoff.h: Regenerate.
2530 * libecoff.h: Regenerate.
2531
25322001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2533
2534 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2535 section is going to follow it.
2536
25372001-06-12 Catherine Moore <clm@redhat.com>
2538
2539 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2540 with the file_align entry from elf_backend_data.
2541 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2542 (elf_gc_record_vtentry): Likewise.
2543
25442001-06-10 Alan Modra <amodra@bigpond.net.au>
2545
2546 * elflink.h: Whitespace changes.
2547 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2548 rather than "unsigned char".
2549 (elf_link_output_relocs): Likewise.
2550 (elf_link_input_bfd): Likewise.
2551 (elf_reloc_link_order): LIkewise.
2552 * elf.c: s/CONST/const/. Whitespace changes.
2553 * elf32-mips.c: Formatting fix.
2554
2555 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2556 * Makefile.in: Regenerate.
2557 * po/Make-in: Remove trailing tab.
2558
25592001-06-09 Philip Blundell <philb@gnu.org>
2560
2561 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2562 change.
2563 (elf32_arm_plt_entry): Likewise.
2564
25652001-06-08 H.J. Lu <hjl@gnu.org>
2566
2567 * elf.c (swap_out_syms): Keep names for global section symbols.
2568
25692001-06-07 H.J. Lu <hjl@gnu.org>
2570
2571 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2572 MIPS-based machines need it.
2573
25742001-06-07 H.J. Lu <hjl@gnu.org>
2575
2576 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2577 for SGI only.
2578
2579 * config.bfd: Remove ecoff from Linux/mips.
2580
25812001-06-07 Andreas Jaeger <aj@suse.de>
2582
2583 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2584 assertion.
2585 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2586 alignment of 8 for .rela sections; handle further relocations.
2587
25882001-06-06 Christian Groessler <cpg@aladdin.de>
2589
2590 * coff-z8k.c: Fix formatting.
2591 Fix howtos: howto->size was always 1.
2592
25932001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2594
2595 * configure.host (mips64*-*-linux*): Define.
2596
25972001-06-05 Alan Modra <amodra@bigpond.net.au>
2598
2599 * elf32-i386.c (elf_i386_discard_copies): Rename to
2600 discard_copies, and use elf_link_hash_entry arg rather than
2601 elf_i386_link_hash_entry.
2602 (elf_i386_link_hash_traverse): Delete.
2603 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2604 Tidy sizing of dynamic sections.
2605 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2606 possible .plt entries.
2607 (elf_i386_gc_sweep_hook): Likewise.
2608 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2609 everything with plt.refcount <= 0.
2610
2611 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2612 .relgot space here.
2613 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2614 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2615 .rel.plt here..
2616 (allocate_plt_and_got): ..instead do it all here. New function.
2617 (elf_i386_size_dynamic_sections): Allocate local .got space and
2618 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2619 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2620 rather than gc variety).
2621 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2622 (elf_i386_relocate_section): Use it here and correct handling of
2623 R_386_GOT32. Provide section and offset for "unresolvable
2624 relocation" error message.
2625 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2626
2627 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2628 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2629 (elf_i386_link_hash_table_create): Init them.
2630 (create_got_section): New function.
2631 (elf_i386_create_dynamic_sections): New function.
2632 (elf_backend_create_dynamic_sections): Set to above.
2633 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2634 calling bfd_get_section_by_name.
2635 (elf_i386_gc_sweep_hook): Likewise.
2636 (elf_i386_adjust_dynamic_symbol): Likewise.
2637 (elf_i386_size_dynamic_sections): Likewise.
2638 (elf_i386_relocate_section): Likewise.
2639 (elf_i386_finish_dynamic_sections): Likewise.
2640
2641 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2642
26432001-06-02 H.J. Lu <hjl@gnu.org>
2644
2645 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2646 and ELFOSABI_HPUX.
2647 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2648
26492001-06-02 H.J. Lu <hjl@gnu.org>
2650
2651 * aout-cris.c (MACHTYPE_OK): New. Defined.
2652
26532001-06-02 Hans-Peter Nilsson <hp@axis.com>
2654
2655 * section.c (_bfd_strip_section_from_output): Handle NULL
2656 output_section.
2657
26582001-06-02 H.J. Lu <hjl@gnu.org>
2659
2660 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2661 rs6000coff64_vec only if BFD64 is defined.
2662 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2663
26642001-06-02 H.J. Lu <hjl@gnu.org>
2665
2666 * coff-ia64.c (ia64coff_object_p): Rewrite with
2667 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2668
26692001-06-01 Andreas Jaeger <aj@suse.de>
2670
2671 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2672 relocation, small reformatting.
2673
26742001-05-29 Andreas Jaeger <aj@suse.de>
2675
2676 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2677 (elf64_x86_64_relocate_section): Likewise.
2678
26792001-05-30 Alan Modra <amodra@one.net.au>
2680
2681 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2682 millicode. Don't allocate .got and .rela.got space here..
2683 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2684 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2685 .rela.plt here..
2686 (hppa_handle_PIC_calls): ..nor here..
2687 (allocate_plt_and_got): ..instead do it all here. New function.
2688 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2689 call allocate_plt_and_got. No need to zap .got if not dynamic.
2690 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2691 gc_common_final_link.
2692 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2693 (elf32_hppa_relocate_section): Use it here.
2694 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2695 dynamic_sections_created.
2696 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2697
26982001-05-28 Andreas Jaeger <aj@suse.de>
2699
2700 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2701 generic version since we want a hashsize of 4.
2702 (elf_backend_size_info): Likewise.
2703
27042001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2705
2706 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2707 a zeroing loop.
2708 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2709 (elf_link_input_bfd): Likewise.
2710 (elf_reloc_link_order): Likewise.
2711 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2712 relocations correctly.
2713
27142001-05-28 Nicolas Pitre <nico@cam.org>
2715
2716 * elf32-arm.h: fix PLT generation for big endian ARM
2717
27182001-05-28 Alan Modra <amodra@one.net.au>
2719
2720 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2721 for symbols forced local that need plabels.
2722 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2723 .plt.rela for local syms if non-shared.
2724 (hppa_build_one_stub): Mask lsb of plt.offset.
2725 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2726 (clobber_millicode_symbols): Correct comment.
2727 (elf32_hppa_relocate_section): Likewise.
2728 (elf32_hppa_finish_dynamic_symbol): Likewise.
2729
27302001-05-28 Jeff Sturm <jsturm@one-point.com>
2731
2732 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2733 * bfd-in2.h: Regenerate.
2734 * libbfd.h: Regenerate.
2735 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2736 and BFD_RELOC_SPARC_UA64 mapping
2737 * elf64-sparc.c: Likewise.
2738
27392001-05-25 H.J. Lu <hjl@gnu.org>
2740
2741 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
2742 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
2743 (coff-rs6000.lo): Remove the old dependency.
2744 * Makefile.in: Rebuild.
2745
2746 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
2747 coff-rs6000.lo.
2748
27492001-05-25 H.J. Lu <hjl@gnu.org>
2750
2751 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
2752 rs6000coff_core_file_matches_executable_p,
2753 rs6000coff_core_file_failing_command and
2754 rs6000coff_core_file_failing_signal only if AIX_CORE is
2755 defined.
2756 (pmac_xcoff_vec): Likewise.
2757 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2758
27592001-05-25 Timothy Wall <twall@redhat.com>
2760
2761 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
2762 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
2763
27642001-05-25 H.J. Lu <hjl@gnu.org>
2765
2766 * bfd-in2.h: Regenerated.
2767 * libcoff.h: Likewise.
2768
27692001-05-25 Alan Modra <amodra@one.net.au>
2770
2771 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
2772 undefined millicode syms in shared libs.
2773 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
2774 (elf32_hppa_check_relocs): Likewise.
2775 (elf32_hppa_adjust_dynamic_symbol): Likewise.
2776 (elf32_hppa_size_dynamic_sections): Likewise.
2777 (elf32_hppa_relocate_section): Likewise.
2778 (elf32_hppa_finish_dynamic_symbol): Likewise.
2779 (elf32_hppa_finish_dynamic_sections): Likewise.
2780
27812001-05-24 Tom Rix <trix@redhat.com>
2782
2783 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
2784 xcoff-target.h not used to define rs6000 or ppc bfd.
2785 * Makefile.in same
2786
2787 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
2788 to 64 bit.
2789
2790 * coff-rs6000.c : Many changes for 64 bit support. Move common
2791 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
2792 and pmac_xcoff_vec
2793
2794 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
2795 linker now supported. Explictly define the rs6000coff64_vec.
2796
2797 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
2798 (coff_print_aux) same
2799 (coff_write_object_contents) same
2800 (coff_slurp_line_table) same
2801
2802 * coffgen.c : (coff_fix_symbol_name) formatting
2803 (coff_mangle_symbols) xcoff 64 bit support
2804 (coff_write_symbol) same
2805 (coff_write_alien_symbol) same
2806 (coff_write_native_symbol) same
2807 (coff_write_symbols) same
2808 (coff_get_symbol_info) same
2809 (bfd_coff_get_syment) same
2810 (coff_print_symbol) same
2811
2812 * config.bfd : add powerpc64-*-aix* target
2813
2814 * libcoff-in.h : formatting
2815
2816 * libcoff.h : move xcoff extern declarations to libxcoff.h
2817
2818 * libxcoff.h : New file
2819
2820 * xcofflink.c : Many changes for xcoff64 support. Move common
2821 structures to include/coff/xcoff.h. Move specific structure to
2822 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
2823 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
2824
2825 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
2826 aix4.2+ -binitfini.
2827
2828 (xcoff_build_ldsyms) : handle special __rtinit symbol.
2829
28302001-05-23 Alexandre Oliva <aoliva@redhat.com>
2831
2832 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
2833 s/ENTIRES/ENTRIES/.
2834
28352001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2836
2837 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
2838 * libbfd.h: Regenerate.
2839 * bfd-in2.h: Regenerate.
2840
2841 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
2842 * archures.c (bfd_mach_mips12000): Define.
2843 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
2844 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
2845 support.
2846 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
2847 * bfd-in2.h: Regenerate.
2848 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
2849
28502001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
2851
2852 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
2853 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
2854 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
2855 that is used by GCC.
2856
28572001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
2858
2859 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
2860 of entries in a structured section.
2861 * elf.c: Use new macro.
2862 * elf32-i386.c: Use new macro.
2863 * elf32-mips.c: Use new macro.
2864 * elf64-alpha.c: Use new macro.
2865 * elf64-sparc.c: Use new macro.
2866 * elfcode.h: Use new macro.
2867 * elflink.h: Use new macro.
2868
28692001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
2870
2871 * bfdint.texi: Replace -oformat with --oformat.
2872
28732001-05-21 Andreas Jaeger <aj@suse.de>
2874
2875 * dwarf2.c (decode_line_info): Fix error message.
2876 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
2877 adjust error message.
2878
28792001-05-18 H.J. Lu <hjl@gnu.org>
2880
2881 * elflink.h (elf_link_add_object_symbols): Revert the last
2882 change.
2883
28842001-05-17 Alan Modra <amodra@one.net.au>
2885
2886 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
2887 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
2888 (hppa_build_one_stub): Add an assert to check plt.offset.
2889
28902001-05-17 H.J. Lu <hjl@gnu.org>
2891
2892 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
2893 version definition to basename of the output filename.
2894
28952001-05-17 H.J. Lu <hjl@gnu.org>
2896
2897 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
2898 basename of the bfd filename.
2899
29002001-05-16 Alan Modra <amodra@one.net.au>
2901
2902 * section.c (asection): Add linker_has_input field.
2903 (STD_SECTION): Adjust initialization to suit.
2904 * ecoff.c (bfd_debug_section): Likewise.
2905 * bfd-in2.h: Regenerate.
2906
29072001-05-15 Alexandre Oliva <aoliva@redhat.com>
2908
2909 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
2910 negative 32-bit operands to 16 operands when the operand is
2911 going to be zero-extended by the modified opcode.
2912
29132001-05-12 Peter Targett <peter.targett@arccores.com>
2914
2915 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
2916 name for 'arc5' core versions.
2917 (bfd_arc_arch): Make bfd_mach_arc_6 default.
2918
2919 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
2920 architecture.
2921 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
2922
29232001-05-11 Jakub Jelinek <jakub@redhat.com>
2924
2925 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
2926 sections as well.
2927 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
2928 to .gnu.linkonce.t.FOO text section.
2929
29302001-05-11 Jakub Jelinek <jakub@redhat.com>
2931
2932 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
2933 fields, change sec into secinfo.
2934 (struct sec_merge_info): Add chain, remove last fields.
2935 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
2936 (sec_merge_hash_lookup): If lookup could not use a string only
2937 because it has bad alignment, mark the old string for deletion.
2938 (sec_merge_add): Add secinfo argument. Don't compute entry's
2939 position, instead record the section.
2940 (sec_merge_emit): Update for the sec into secinfo change in
2941 struct sec_merge_hash_entry.
2942 (_bfd_merge_section): Only record the section for merging, defer
2943 putting strings into the hash table.
2944 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
2945 _bfd_merge_sections): New functions.
2946 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
2947 changes.
2948 * libbfd-in.h (_bfd_merge_sections): Add prototype.
2949 (_bfd_nolink_bfd_merge_sections): Define.
2950 * libbfd.h: Likewise.
2951 (bfd_generic_merge_sections): Add prototype.
2952 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
2953 (struct bfd_target): Likewise.
2954 * bfd.c (bfd_merge_sections): Define.
2955 * bfd-in2.h: Rebuilt.
2956 * elf.c (_bfd_elf_merge_sections): New function.
2957 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
2958 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
2959 * reloc.c (bfd_generic_merge_sections): New function.
2960 * vms.c (vms_bfd_merge_sections): New function.
2961 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
2962 * aout-target.h (MY_bfd_merge_sections): Define.
2963 * aout-tic30.c (MY_bfd_merge_sections): Define.
2964 * binary.c (binary_bfd_merge_sections): Define.
2965 * bout.c (b_out_bfd_merge_sections): Define.
2966 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
2967 * coffcode.c (coff_bfd_merge_sections): Define.
2968 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
2969 * i386msdos.c (msdos_bfd_merge_sections): Define.
2970 * i386os9k.c (os9k_bfd_merge_sections): Define.
2971 * ieee.c (ieee_bfd_merge_sections): Define.
2972 * ihex.c (ihex_bfd_merge_sections): Define.
2973 * nlm-target.h (nlm_bfd_merge_sections): Define.
2974 * oasys.c (oasys_bfd_merge_sections): Define.
2975 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
2976 * som.c (som_bfd_merge_sections): Define.
2977 * srec.c (srec_bfd_merge_sections): Define.
2978 * tekhex.c (tekhex_bfd_merge_sections): Define.
2979 * versados.c (versados_bfd_merge_sections): Define.
2980 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
2981
29822001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
2983
2984 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
2985 to be unsigned long, in order to match its use.
2986
29872001-05-10 H.J. Lu <hjl@gnu.org>
2988
2989 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
2990 indirect symbols.
2991
29922001-05-09 H.J. Lu <hjl@gnu.org>
2993
2994 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
2995 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
2996 Remove the unused veriable `dynver'.
2997
29982001-05-08 Ian Lance Taylor <ian@zembu.com>
2999
3000 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3001 NULL or is not COFF.
3002 (coff_i386_rtype_to_howto): Don't dump core if output section
3003 owner is not COFF.
3004
30052001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3006
3007 * ecoff.c (bfd_debug_section): Fix initialization.
3008 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3009 is always a positive integer. Cast away sign mismatch.
3010 * elf32-mips.c: Fix misleading comment and typo.
3011 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3012 correct data type.
3013 * elflink.c: Fix typo.
3014 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3015 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3016
30172001-05-04 Richard Henderson <rth@redhat.com>
3018
3019 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3020
30212001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3022
3023 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3024 EF_ARM_HASENTRY if the start address is set.
3025
30262001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3027
3028 * targets.c (_bfd_target_vector_entries): Compute value based on
3029 the size of the _bfd_target_vector and not bfd_target_vector.
3030
30312001-05-03 H.J. Lu <hjl@gnu.org>
3032
3033 * elfcode.h: Include "libiberty.h".
3034
3035 * elflink.h (elf_link_add_object_symbols): Set
3036 elf_dt_name (abfd) to basename of the bfd filename.
3037 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3038 of the bfd filename.
3039
30402001-05-03 Andreas Jaeger <aj@suse.de>
3041
3042 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3043 (elf_generic_info_to_howto_rel): Likewise.
3044 * coff-alpha.c (reloc_nil): Likewise.
3045 (alpha_ecoff_bad_format_hook): Likewise.
3046 (alpha_adjust_reloc_out): Likewise.
3047 (alpha_bfd_reloc_type_lookup): Likewise.
3048 (alpha_convert_external_reloc): Likewise.
3049 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3050 (elf64_alpha_reloc_bad): Likewise.
3051 (elf64_alpha_reloc_gpdisp): Likewise.
3052 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3053 (elf64_alpha_info_to_howto): Likewise.
3054 (elf64_alpha_add_symbol_hook): Likewise.
3055 (elf64_alpha_create_got_section): Likewise.
3056 (elf64_alpha_is_local_label_name): Likewise.
3057 (elf64_alpha_merge_ind_symbols): Likewise.
3058 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3059 (mips_elf64_get_reloc_upper_bound): Likewise.
3060 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3061 (nlm_alpha_get_public_offset): Likewise.
3062
30632001-05-02 Johan Rydberg <jrydberg@opencores.org>
3064
3065 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3066 about overflow in R_OPENRISC_LO_16_IN_INSN and
3067 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3068
30692001-04-30 H.J. Lu <hjl@gnu.org>
3070
3071 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3072 only for ELF_LINK_FORCED_LOCAL.
3073 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3074 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3075 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3076
3077 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3078 if the symbol has hidden or internal visibility.
3079
30802001-04-30 Alan Modra <amodra@one.net.au>
3081
3082 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3083 calls to undefined weak symbols.
3084
30852001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3086
3087 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3088 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3089
30902001-04-27 Andreas Jaeger <aj@suse.de>
3091
3092 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3093 out handled entries.
3094 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3095 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3096 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3097 GOT32.
3098
30992001-04-27 Sean McNeil <sean@mcneil.com>
3100
3101 * config.bfd: Add arm-vxworks target.
3102 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3103 addend (fro VXworks targets).
3104
31052001-04-26 H.J. Lu <hjl@gnu.org>
3106
3107 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3108 valid.
3109
31102001-04-25 Frank Ch. Eigler <fche@redhat.com>
3111
3112 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3113 * bfd-in2.h: Regenerated.
3114
31152001-04-24 Jakub Jelinek <jakub@redhat.com>
3116
3117 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3118 (struct sec_merge_hash): Remove alignment_power.
3119 (sec_merge_hash_newfunc): Clear alignment.
3120 (sec_merge_hash_lookup): Pass alignment as argument.
3121 Use hashp->root.next, not hashp->next to walk the hash chain.
3122 If a string already in the hashtable does not have required
3123 alignment, create a new hashtable entry.
3124 (sec_merge_init): Remove alignment_power argument.
3125 (sec_merge_add): Add alignment argument.
3126 (sec_merge_emit): Alignment is now a per-entity thing, not per
3127 section.
3128 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3129 for proper alignment.
3130 Pass alignment information to sec_merge_add.
3131
31322001-04-24 Christian Groessler <cpg@aladdin.de>
3133
3134 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3135 and R_REL16 reloc types; accept odd values for R_REL16 type
3136
31372001-04-24 Johan Rydberg <jrydberg@opencores.org>
3138
3139 * cpu-openrisc.c: New file.
3140 * elf32-openrisc.c: Likewise.
3141
3142 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3143 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3144 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3145 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3146 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3147 * Makefile.in: Regenerated.
3148 * config.bfd: (openrisc-*-elf): New target.
3149 * configure.in (bfd_elf32_openrisc_vec): New vector.
3150 * configure: Regenerated.
3151 * libbfd.h: Regenerated.
3152 * bfd-in2.h: Regenerated.
3153 * reloc.c: Add OpenRISC relocations.
3154 * targets.c (bfd_elf32_openrisc_vec): Declare.
3155 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3156 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3157 (bfd_openrisc_arch): Declare.
3158 (bfd_archures_list): Add bfd_openrisc_arch.
3159 * elf.c (prep_headers): Add bfd_arch_openrisc.
3160
31612001-04-23 Bo Thorsen <bo@suse.de>
3162
3163 * elf64-x86-64.c: Add c++ vtable hack.
3164 Small whitespace and comment changes.
3165
31662001-04-19 Andreas Jaeger <aj@suse.de>
3167
3168 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3169 (elf64_x86_64_plt_entry): Likewise.
3170 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3171 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3172
31732001-04-17 Hans-Peter Nilsson <hp@axis.com>
3174
3175 * elf32-cris.c: Tweak comments related to dynamic linking.
3176 (cris_elf_relocate_section): When not creating shared object, fill
3177 in the .got table for any symbol not in the dynamic symbol table.
3178 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3179 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3180 table.
3181 (cris_elf_check_relocs): Use variable r_type in all places rather
3182 than the original expression. Add default case in switch for
3183 reloc types.
3184 (elf_cris_size_dynamic_sections): Iterate over
3185 elf_cris_discard_excess_program_dynamics when not creating shared
3186 library.
3187 (elf_cris_discard_excess_dso_dynamics): Renamed from
3188 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3189 (elf_cris_discard_excess_program_dynamics): New.
3190
31912001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3192
3193 * coffcode.h (coff_write_object_contents): Use
3194 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3195
31962001-04-14 H.J. Lu <hjl@gnu.org>
3197
3198 * bfd-in2.h: Regenerate.
3199
32002001-04-14 Jakub Jelinek <jakub@redhat.com>
3201
3202 * section.c (STD_SECTION): Add entsize.
3203
32042001-04-13 H.J. Lu <hjl@gnu.org>
3205
3206 * section.c (SEC_MERGE): Define new flag for merging.
3207 (SEC_STRINGS): Likewise.
3208 (entsize): New field.
3209
32102001-04-13 Roger Sayle <roger@metaphorics.com>
3211
3212 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3213 flag on pe-i386 targets.
3214
32152001-04-13 Jakub Jelinek <jakub@redhat.com>
3216
3217 * libbfd-in.h (_bfd_merge_section): New.
3218 (_bfd_write_merged_section): New.
3219 (_bfd_merged_section_offset): New.
3220 * libbfd.h: Rebuilt.
3221 * linker.c (_bfd_generic_link_output_symbols): Handle
3222 discard_sec_merge.
3223 * aoutx.h (aout_link_write_symbols): Likewise.
3224 * pdp11.c (aout_link_write_symbols): Likewise.
3225 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3226 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3227 sections.
3228 (elf_link_sec_merge_syms): New.
3229 (elf_link_input_bfd): Call _bfd_merged_section_offset
3230 and _bfd_write_merged_section.
3231 Handle discard_sec_merge.
3232 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3233 field.
3234 (struct bfd_elf_section_data): Likewise.
3235 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3236 SEC_STRINGS section flags and entsize from their ELF counterparts.
3237 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3238 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3239 from their BFD counterparts.
3240 * merge.c: New file.
3241 * Makefile.am: Add strtab.lo.
3242 * Makefile.in: Rebuilt.
3243
32442001-04-09 Hans-Peter Nilsson <hp@axis.com>
3245
3246 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3247 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3248
32492001-04-05 Steven J. Hill <sjhill@cotw.com>
3250
3251 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3252 endian MIPS ELF target.
3253 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3254 MIPS ELF target.
3255
3256 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3257 64bit big endian MIPS ELF target.
3258 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3259 endian MIPS ELF target.
3260 * configure: Regenerated.
3261
3262 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3263 little endian targets.
3264 (mips_elf_sym_is_global): Handle traditional targets.
3265
3266 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3267 64bit big endian MIPS ELF target.
3268 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3269 endian MIPS ELF target.
3270
3271 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3272 and bfd_elf64_tradlittlemips_vec.
3273
32742001-04-05 David Mosberger <davidm@hpl.hp.com>
3275
3276 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3277 ordinary "progbits" section.
3278
32792001-04-04 Alan Modra <alan@linuxcare.com.au>
3280
3281 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3282 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3283
32842001-04-03 David Mosberger <davidm@hpl.hp.com>
3285
3286 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3287
32882001-03-30 H.J. Lu <hjl@gnu.org>
3289
3290 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3291 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3292
32932001-03-26 H.J. Lu <hjl@gnu.org>
3294
3295 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3296 if there are any relocations for generic ELF.
3297 (bfd_elf32_bfd_link_add_symbols): Defined to
3298 elf32_generic_link_add_symbols.
3299 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3300 if there are any relocations for generic ELF.
3301 (bfd_elf64_bfd_link_add_symbols): Defined to
3302 elf64_generic_link_add_symbols.
3303
33042001-03-23 Nick Clifton <nickc@redhat.com>
3305
3306 * Makefile.am (BUILD_CFILES): New variable: List of C source
3307 files created in build directory.
3308 (BUILD_HFILES): New variable: List of header files created in
3309 build directory.
3310 (POTFILES): Delete.
3311 (po/POTFILES.in): Replace rule with empty entry.
3312 (po/SRC-POTFILES.in): New rule: Create a list of source files
3313 in the source directory.
3314 (po/BLD-POTFILES.in): New rule: Create a list of source files
3315 in the build directory.
3316 (MOSTLYCLEAN): Do not delete source files created in build
3317 directory.
3318 * Makefile.in: Regenerate.
3319 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3320 into po/Makefile.
3321 * configure: Regenerate.
3322
3323 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3324 and BLD_POTFILES.
3325 Add .. to the search path when building bfd.pot.
3326 Delete POTFILES when performing distclean.
3327 Add comment describing why distclean is broken in maintainer mode.
3328 * po/POTFILES.in: Delete.
3329 * po/SRC-POTFILES.in: New file.
3330 * po/BLD-POTFILES.in: New file.
3331 * po/bfd.pot: Regenerate.
3332
33332001-03-22 Hans-Peter Nilsson <hp@axis.com>
3334
3335 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3336 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3337 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3338 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3339 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3340 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3341 functions.
3342 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3343 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3344 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3345 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3346 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3347 New HOWTO members for new relocs.
3348 (cris_reloc_map): Map new relocs.
3349 (ELF_DYNAMIC_INTERPRETER): Define.
3350 (PLT_ENTRY_SIZE): Define.
3351 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3352 elf_cris_pic_plt_entry): New, PLT templates.
3353 (struct elf_cris_pcrel_relocs_copied, struct
3354 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3355 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3356 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3357 positive values. Adjust PCREL relocs to be relative to location
3358 after relocation.
3359 (cris_elf_relocate_section): Handle relocations to dynamic
3360 objects. Handle new relocations. Call error handler when seeing
3361 non-PIC relocation for read-only sections while generating shared
3362 object.
3363 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3364 entries.
3365 (bfd_elf32_bfd_link_hash_table_create,
3366 elf_backend_adjust_dynamic_symbol,
3367 elf_backend_size_dynamic_sections,
3368 elf_backend_finish_dynamic_symbol,
3369 elf_backend_finish_dynamic_sections,
3370 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3371 elf_backend_hide_symbol, elf_backend_want_got_plt,
3372 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3373 elf_backend_got_header_size, elf_backend_plt_header_size):
3374 Define.
3375
3376 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3377 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3378 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3379 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3380 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3381 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3382 * bfd-in2.h, libbfd.h: Regenerate.
3383
33842001-03-21 Diego Novillo <dnovillo@redhat.com>
3385
3386 (_bfd_mips_elf_relocate_section): Give a better error message when
3387 a relocation is not recognized.
3388
33892001-03-21 Alan Modra <alan@linuxcare.com.au>
3390
3391 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3392 non-NULL before attempting to dereference.
3393
33942001-03-20 H.J. Lu <hjl@gnu.org>
3395
3396 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3397 * configure: Rebuild.
3398
33992001-03-20 Andreas Schwab <schwab@suse.de>
3400
3401 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3402 relocation value when resolving a reference from a debugging
3403 section.
3404
34052001-03-16 Scott Thomason <SThomaso@hii.com>
3406
3407 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3408 (xcoff64_swap_sym_out): Fix syntax errors.
3409
34102001-03-16 Richard Sandiford <rsandifo@redhat.com>
3411
3412 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3413
34142001-03-15 Alan Modra <alan@linuxcare.com.au>
3415
3416 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3417 (hppa_link_hash_newfunc): Init it.
3418 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3419 section appears to be non-PIC.
3420 (final_link_relocate): Likewise.
3421 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3422 possible candidate function, and set pic_call for those that will
3423 only have a .plt entry for the PIC call stub.
3424 (hppa_handle_PIC_calls): Set maybe_pic_call.
3425
34262001-03-12 DJ Delorie <dj@redhat.com>
3427
3428 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3429 R_SH_DIR8WP* relocs if they're against external symbols, else
3430 they're just for relaxing. Validate the reloc values.
3431
34322001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3433
3434 * binary.c (bfd_external_binary_architecture): Declare.
3435 (binary_object_p): If bfd_external_binary_architecture is defined,
3436 set the architecture to this string.
3437
34382001-03-11 Philip Blundell <philb@gnu.org>
3439
3440 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3441 entries that could serve as a definition for a weak symbol.
3442
34432001-03-08 Nick Clifton <nickc@redhat.com>
3444
3445 * Most files: Update copyright notices using Perl script created
3446 by Kevin Buettner <kevinb@redhat.com>.
3447
34482001-03-07 Nick Clifton <nickc@redhat.com>
3449
3450 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3451 prior patch on ! defined OLD_ARM_ABI.
3452
34532001-03-07 Andreas Jaeger <aj@suse.de>
3454
3455 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3456 some relocation values.
3457
34582001-03-06 Nick Clifton <nickc@redhat.com>
3459
3460 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3461 of offset in BLX(1) instruction.
3462 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3463 offset in BLX(1) instruction.
3464 Fix formatting.
3465
34662001-03-06 Nick Clifton <nickc@redhat.com>
3467
3468 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3469 BFD_RELOC_THUMB_PCREL_BLX.
3470
34712001-03-06 Igor Shevlyakov <igor@windriver.com>
3472
3473 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3474 * bfd-in2.h: Regenerate.
3475 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3476 * ieee.c (ieee_write_processor): Set proper id for
3477 Coldfire CPUs.
3478
34792001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3480
3481 * configure.in: Add s390 target.
3482 * configure: Regenerate.
3483
34842001-02-28 Andreas Jaeger <aj@suse.de>
3485
3486 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3487 to addend.
3488
34892001-02-28 Philip Blundell <pb@futuretv.com>
3490
3491 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3492 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3493
34942001-02-27 H.J. Lu <hjl@gnu.org>
3495
3496 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3497 abfd->tdata.aout_data == NULL.
3498
34992001-02-27 Alan Modra <alan@linuxcare.com.au>
3500
3501 * elf32-hppa.c: Correct field selector in stub comments.
3502 (clobber_millicode_symbols): Formatting fix.
3503
3504 * configure.in: Bump version to 2.11.90.
3505 * configure: Regenerate.
3506 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3507 (CFILES): $SOURCE_CFILES + generated C files.
3508 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3509 Run "make dep-am"
3510 * Makefile.in: Regenerate.
3511 * doc/Makefile.in: This too.
3512
35132001-02-26 Timothy Wall <twall@cygnus.com>
3514
3515 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3516 comments.
3517
35182001-02-26 Nick Clifton <nickc@redhat.com>
3519
3520 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3521 up, replacing multiple if statements with a switch.
3522 (handle_COMDAT): New function.
3523
35242001-02-26 H.J. Lu <hjl@gnu.org>
3525
3526 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3527 a warning for section flags we do not handle instead of
3528 aborting.
3529
35302001-02-26 Andreas Jaeger <aj@suse.de>
3531
3532 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3533
35342001-02-22 Timothy Wall <twall@cygnus.com>
3535
3536 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3537 * configure.in: Add objects for elf64_ia64_aix vectors.
3538 * configure: Regenerated.
3539 * configure.host: Recognize ia64-*-aix*.
3540 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3541 for AIX. AIX5 requires most relocations to be dynamic (*all*
3542 binaries are somewhat similar to shared libraries).
3543 * targets.c: Add elf64_ia64_aix vectors.
3544
35452001-02-21 David Mosberger <davidm@hpl.hp.com>
3546
3547 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3548 C8 said "1" instead of "8". Clarify error string for IMM22:
3549 "signed integer" instead of just "integer".
3550
35512001-02-20 Andreas Jaeger <aj@suse.de>
3552
3553 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3554 PLT entries that could serve as a definition for a weak symbol.
3555
35562001-02-19 Jakub Jelinek <jakub@redhat.com>
3557
3558 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3559 entries that could serve as a definition for a weak symbol.
3560 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3561
35622001-02-18 David O'Brien <obrien@FreeBSD>
3563
3564 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3565 FreeBSD/i386-CURRENT differently until I can figure out the needed
3566 corefile changes.
3567 * configure: Regenerate.
3568 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3569 FreeBSD/PowerPC, and FreeBSD/sparc64.
3570
35712001-02-18 lars brinkhoff <lars@nocrew.org>
3572
3573 * Makefile.am: Add PDP-11 a.out target.
3574 * config.bfd: Likewise.
3575 * configure.in: Likewise.
3576 * targets.c: Likewise.
3577 * archures.c: Likewise.
3578 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3579 * libbfd.h: Add PDP-11 relocations.
3580 * reloc.c: Likewise.
3581 * cpu-pdp11.c: New file.
3582 * pdp11.c: New file.
3583
3584 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3585 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3586 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3587 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3588 (GET_MAGIC): New macro.
3589 (PUT_MAGIC): Likewise.
3590 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3591
35922001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3593
3594 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3595 multiarch needs it).
3596
35972001-02-18 H.J. Lu <hjl@gnu.org>
3598
3599 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3600 index.
3601
36022001-02-18 Kazu Hirata <kazu@hxi.com>
3603
3604 * vms-misc.c: Fix formatting.
3605
36062001-02-16 Kazu Hirata <kazu@hxi.com>
3607
3608 * vms.c: Fix formatting.
3609
36102001-02-14 H.J. Lu <hjl@gnu.org>
3611
3612 * elf.c (elf_find_function): New function.
3613 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3614 the file name and function name.
3615
36162001-02-14 Nick Clifton <nickc@redhat.com>
3617
3618 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3619 asection structure.
3620
3621 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3622 (BFD64_BACKENDS): Add pepigen.c
3623 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3624
3625 * Makefile.in: Regenerate.
3626 * configure: Regenerate.
3627 * po/POTFILES.in: Regenerate.
3628 * po/bfd.pot: Regenerate.
3629
36302001-02-14 H.J. Lu <hjl@gnu.org>
3631
3632 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3633 force_minimum_alignment.
3634
36352001-02-14 Bo Thorsen <bo@suse.de>
3636
3637 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3638 (elf64_86_64_size_info): Struct added to fix a problem
3639 with the hashtable string entries.
3640 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3641 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3642 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3643 remove the FIXME for this.
3644 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3645 section. Also removed the FIXME for it.
3646 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3647 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3648 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3649
36502001-02-13 Richard Henderson <rth@redhat.com>
3651
3652 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3653 and not user provided.
3654
36552001-02-13 Kazu Hirata <kazu@hxi.com>
3656
3657 * vms.c (vms_print_symbol): Remove unreachable code.
3658
3659 * rs6000-core.c: Fix formatting.
3660
36612001-02-13 David Mosberger <davidm@hpl.hp.com>
3662
3663 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3664 as _bfd_XXi_only_swap_filehdr_out.
3665 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3666 pe->force_minimum_alignment to TRUE.
3667 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3668 PEI_TARGET_SUBSYSTEM.
3669 (pe_print_private_bfd_data): Call
3670 _bfd_XX_print_private_bfd_data_common() instead of
3671 _bfd_pe_print_private_bfd_data_common().
3672 (pe_bfd_copy_private_bfd_data): Call
3673 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3674 _bfd_pe_bfd_copy_private_bfd_data_common().
3675 (coff_bfd_copy_private_section_data): Define as
3676 _bfd_XX_bfd_copy_private_section_data instead of
3677 _bfd_pe_bfd_copy_private_section_data.
3678 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3679 of a _bfd_pe_get_symbol_info.
3680
3681 * peigen.c: Delete.
3682
3683 * peXXigen.c: Renamed from peigen.c.
3684 (COFF_WITH_XX): Define this macro (will get expanded into
3685 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3686 compiled as peigen.c or pepigen.c.
3687 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3688 define the canonical PEP structures and definitions.
3689 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3690 effect, enforce minimum file and section alignments. If
3691 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3692 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3693 so, by default, this is a no-op).
3694
3695 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3696 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3697 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3698 _bfd_pefoo if it's not defined. Use these macros to define
3699 coff swap macros.
3700
3701 * libcoff.h (pe_tdata): Add members target_subsystem and
3702 force_minimum_alignment.
3703
3704 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3705 COFF_WITH_pep.
3706 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3707
3708 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3709 peigen.lo.
3710
3711 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3712 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3713 PEPAOUTHDR.
3714
3715 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3716 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3717 (peigen.c): Add rule to generate from peXXigen.c.
3718 (pepigen.c): Ditto.
3719 (pepigen.lo): List dependencies for pepigen.lo.
3720
37212001-02-13 Alan Modra <alan@linuxcare.com.au>
3722
3723 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3724 $global$ referenced but not defined, set its value here.
3725
37262001-02-09 Bo Thorsen <bo@suse.de>
3727
3728 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3729 alignment to 3.
3730 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3731 and relocation.
3732 (elf64_x86_64_relocate_section): Fix formatting.
3733 (elf64_x86_64_relocate_section): Fix addend for relocation of
3734 R_X86_64_(8|16|32|PC8|PC16|PC32).
3735
37362001-02-12 Jan Hubicka <jh@suse.cz>
3737
3738 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3739
37402001-02-11 H.J. Lu <hjl@gnu.org>
3741
3742 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
3743 alignment.
3744
37452001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3746
3747 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
3748 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
3749 relocations against dynsym symbols.
3750
3751 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
3752 the R_MIPS_26 relocation.
3753 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
3754 the R_MIPS_26 relocation.
3755 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
3756 relocation.
3757 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
3758 the R_MIPS_26 relocation.
3759 (mips_elf64_howto_table_rela): Likewise.
3760
3761 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
3762 member to mark symbols that have non-CALL relocations against
3763 them.
3764 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
3765 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
3766 R_MIPS_GOT16.
3767 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
3768 non-CALL relocation against it is encountered.
3769 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
3770 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
3771 no_fn_stub is not set.
3772
3773 * elf32-mips.c (mips_elf_output_extsym): Get the output section
3774 information from the real symbol for indirect ones.
3775 Check no_fn_stub to find out if a symbol has a function stub
3776 indeed.
3777
37782001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3779
3780 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
3781 * Makefile.in: Regenerate.
3782
37832001-02-09 David Mosberger <davidm@hpl.hp.com>
3784
3785 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
3786 true if section name is an unwind table section name.
3787 (elfNN_ia64_additional_program_headers): Count each unwind section
3788 separately.
3789 (elfNN_ia64_modify_segment_map): Install one unwind program header
3790 for each unwind separate section. Note: normally the linker
3791 script merges the unwind sections that go into a single segment,
3792 so this still generates at most one unwind program header per
3793 segment.
3794
3795 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
3796 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
3797 (elfNN_ia64_fake_sections): Mark sections with names that start
3798 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
3799 unwind section.
3800
3801 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
3802 Use it to make sh_info in unwind section point to the text section
3803 it applies to.
3804
38052001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
3806
3807 * Makefile.am: Add linux target for S/390.
3808 * archures.c: Likewise.
3809 * bfd-in2.h: Likewise.
3810 * config.bfd: Likewise.
3811 * configure.in: Likewise.
3812 * elf.c: Likewise.
3813 * libbfd.h: Likewise.
3814 * targets.c: Likewise.
3815 * cpu-s390.c: New file.
3816 * elf32-s390.c: New file.
3817 * elf64-s390.c: New file.
3818
38192001-02-09 Nick Clifton <nickc@redhat.com>
3820
3821 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
3822 ImageBase. This has already been done by coff_swap_hdr_in.
3823
38242001-02-09 Jakub Jelinek <jakub@redhat.com>
3825
3826 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
3827
38282001-02-09 Jakub Jelinek <jakub@redhat.com>
3829
3830 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
3831 (sparc64_elf_relocate_section): Likewise.
3832
38332001-02-09 Mark Kettenis <kettenis@gnu.org>
3834
3835 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
3836 similar to R_SPARC_32.
3837 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
3838
38392001-02-08 H.J. Lu <hjl@gnu.org>
3840
3841 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
3842 relocation entries for weak definitions when building DSO with
3843 -Bsymbolic.
3844
38452001-02-08 Richard Henderson <rth@redhat.com>
3846
3847 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
3848 before visibility. Locally defined protected symbols are not
3849 dynamic.
3850
38512001-02-08 Geoffrey Keating <geoffk@redhat.com>
3852
3853 * config.bfd: Enable coff64 for rs6000-*. Patch from
3854 <hzoli@austin.ibm.com>.
3855
38562001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
3857
3858 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
3859 found, do not attempt to find dwarf2 info before returning.
3860
38612001-02-07 Jakub Jelinek <jakub@redhat.com>
3862
3863 * elflink.h (is_global_symbol_definition): Rename to
3864 is_global_data_symbol_definition and have it reject function
3865 symbols.
3866 (elf_link_is_defined_archive_symbol): Use renamed function.
3867
38682001-02-07 Todd Vierling <tv@wasabisystems.com>
3869
3870 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
3871 * libbfd.h (bfd_target_vector): Likewise.
3872 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
3873 make static; create pointer reference named bfd_target_vector.
3874 (_bfd_target_vector_entries): Calculate this based on the array
3875 typed _bfd_target_vector.
3876
38772001-02-06 H.J. Lu <hjl@gnu.org>
3878
3879 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
3880 internal symbols are not dynamic.
3881 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
3882
38832001-02-06 Nick Clifton <nickc@redhat.com>
3884
3885 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
3886 that it will not be pulled into the list of files that make up
3887 po/POTFILES.in.
3888 * Makefile.in: Regenerate.
3889 * po/bfd.pot: Regenerate.
3890
38912001-02-06 H.J. Lu <hjl@gnu.org>
3892
3893 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
3894 checking.
3895 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
3896 external_PEI_IMAGE_hdr.
3897
38982001-02-06 Kazu Hirata <kazu@hxi.com>
3899
3900 * elf-m10200.c: Fix formatting.
3901
39022001-02-04 Nick Clifton <nickc@redhat.com>
3903
3904 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
3905 rel, it will be handled later on.
3906
39072001-02-02 Fred Fish <fnf@ninemoons.com>
3908
3909 * Makefile.in: Fix typo.
3910
39112001-02-01 Kazu Hirata <kazu@hxi.com>
3912
3913 * elf-m10300.c: Fix formatting.
3914
39152001-01-30 Alan Modra <alan@linuxcare.com.au>
3916
3917 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
3918 (elf_backend_get_symbol_type): Define.
3919 (elf64_hppa_object_p): Set architecture and machine from elf
3920 header flags.
3921
39222001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
3923
3924 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
3925 before mdebug.
3926
39272001-01-26 Richard Henderson <rth@redhat.com>
3928
3929 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
3930 for non-default visibility.
3931 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
3932 delete ugly macro and replace with pretty function.
3933
39342001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
3935
3936 * coff-go32.c: Update copyright.
3937 * coff-stgo32.c: Likewise.
3938 * coff-go32.c (COFF_LONG_FILENAMES): Define.
3939 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
3940 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
3941 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
3942
39432001-01-25 Kazu Hirata <kazu@hxi.com>
3944
3945 * bfd-in2.h: Rebuild.
3946 * libbfd.h: Likewise.
3947
39482001-01-23 H.J. Lu <hjl@gnu.org>
3949
3950 * bfd-in2.h: Rebuild.
3951
39522001-01-23 H.J. Lu <hjl@gnu.org>
3953
3954 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
3955 is NULL or PRIV(vms_rec) is outside of the buffer.
3956
39572001-01-23 Kazu Hirata <kazu@hxi.com>
3958
3959 * coff64-rs6000.c: Fix formatting.
3960 * coff-arm.c: Likewise.
3961 * coffgen.c: Likewise.
3962 * cofflink.c: Likewise.
3963 * coff-mcore.c: Likewise.
3964 * coff-mips.c: Likewise.
3965 * coff-pmac.c: Likewise.
3966 * coff-ppc.c: Likewise.
3967 * coff-rs6000.c: Likewise.
3968 * elf32.c: Likewise.
3969 * elf32-fr30.c: Likewise.
3970 * elf32-i370.c: Likewise.
3971 * elf32-i860.c: Likewise.
3972 * elf32-m32r.c: Likewise.
3973 * elf32-m68k.c: Likewise.
3974 * elf32-mcore.c: Likewise.
3975 * elf32-ppc.c: Likewise.
3976 * elf32-sh.c: Likewise.
3977 * elf32-v850.c: Likewise.
3978 * elf64-alpha.c: Likewise.
3979 * elf64-sparc.c: Likewise.
3980 * elflink.c: Likewise.
3981 * elflink.h: Likewise.
3982 * elf-m10200.c: Likewise.
3983 * elf-m10300.c: Likewise.
3984 * elfxx-ia64.c: Likewise.
3985
3986 * aoutx.h: Fix formatting.
3987 * bfd.c: Likewise.
3988 * bfd-in2.h: Likewise.
3989 * bfd-in.h: Likewise.
3990 * cpu-i386.c: Likewise.
3991 * cpu-m68hc11.c: Likewise.
3992 * dwarf2.c: Likewise.
3993 * elf64-x86-64.c: Likewise.
3994 * format.c: Likewise.
3995 * freebsd.h: Likewise.
3996 * hash.c: Likewise.
3997 * hp300hpux.c: Likewise.
3998 * hppabsd-core.c: Likewise.
3999 * hpux-core.c: Likewise.
4000
40012001-01-22 Bo Thorsen <bo@suse.de>
4002
4003 * elf64-x86-64.c: Added PIC support for X86-64.
4004 (elf64_x86_64_link_hash_newfunc): Function added.
4005 (elf64_x86_64_link_hash_table_create): Likewise.
4006 (elf64_x86_64_check_relocs): Likewise.
4007 (elf64_x86_64_gc_mark_hook): Likewise.
4008 (elf64_x86_64_gc_sweep_hook): Likewise.
4009 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4010 (elf64_x86_64_size_dynamic_sections): Likewise.
4011 (elf64_x86_64_discard_copies): Likewise.
4012 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4013 (elf64_x86_64_finish_dynamic_sections): Likewise.
4014 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4015
40162001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4017
4018 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4019 * Makefile.in: Regenerate.
4020
40212001-01-21 Kazu Hirata <kazu@hxi.com>
4022
4023 * coff-a29k.c: Fix formatting.
4024
40252001-01-19 H.J. Lu <hjl@gnu.org>
4026
4027 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4028 relocation section names.
4029 (elf_i386_relocate_section): Report files with bad relocation
4030 section names and return false.
4031
40322001-01-17 Bo Thorsen <bo@suse.de>
4033
4034 * targets.c: Alphabetize list of xvecs.
4035
40362001-01-14 Alan Modra <alan@linuxcare.com.au>
4037
4038 * config.bfd: Add linux target variant for elfxx-hppa.
4039 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4040 bfd_elf64_hppa_linux_vec.
4041 * configure: Regenerate.
4042 * elf64-hppa.c: Include elf64-target.h again to support linux
4043 target variant.
4044 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4045 * elf32-hppa.c: Include elf32-target.h again to support linux
4046 target variant.
4047 (elf32_hppa_post_process_headers): New function.
4048 (elf_backend_post_process_headers): Define.
4049 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4050 bfd_elf32_hppa_linux_vec.
4051
4052 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4053 and data_segment_base fields.
4054 (elf32_hppa_link_hash_table_create ): Init them.
4055 (elf32_hppa_check_relocs): Update comments.
4056 (hppa_record_segment_addr): New function.
4057 (elf32_hppa_relocate_section): Call it.
4058 (final_link_relocate): Handle R_PARISC_SEGREL32.
4059 (elf32_hppa_final_link): New function.
4060 (bfd_elf32_bfd_final_link): Define to call it.
4061 (hppa_unwind_entry_compare): New function.
4062 * cache.c (bfd_open_file): Create files in write+read mode.
4063
4064 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4065 SEGREL32 and numerous other relocs. Change duplicate
4066 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4067
4068 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4069 O_ACCMODE.
4070
4071 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4072 .plt entries for DT_INIT and DT_FINI.
4073 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4074 DT_INIT and DT_FINI.
4075
4076 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4077 offsets for stub .plt access if wide mode. Check offset in range.
4078
40792001-01-13 Nick Clifton <nickc@redhat.com>
4080
4081 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4082 line.
4083
4084 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4085 line.
4086
40872001-01-12 Alan Modra <alan@linuxcare.com.au>
4088
4089 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4090 * configure: Regenerate.
4091
40922001-01-11 Peter Targett <peter.targett@arccores.com>
4093
4094 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4095 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4096 * cpu-arc.c (arch_info_struct): Add entries for variants.
4097 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4098 (arc_get_mach) Don't assume machine names prefixed arc- before
4099 testing.
4100 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4101 selections.
4102 (arc_elf_final_write_processing) Likewise.
4103 (ELF_MACHINE_CODE) Use EM_ARC.
4104
41052001-01-10 Nick Clifton <nickc@redhat.com>
4106
4107 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4108
41092001-01-07 Philip Blundell <philb@gnu.org>
4110
4111 * README: Replace `bug-gnu-utils@gnu.org' with
4112 `bug-binutils@gnu.org'.
4113
41142001-01-04 Kazu Hirata <kazu@hxi.com>
4115
4116 * som.c: Fix formatting.
4117
41182001-01-03 Kazu Hirata <kazu@hxi.com>
4119
4120 * ecoffswap.h: Fix formatting.
4121 * elf-bfd.h: Likewise.
4122 * elfarm-nabi.c: Likewise.
4123 * elfarm-oabi.c: Likewise.
4124 * elfcode.h: Likewise.
4125 * elfcore.h: Likewise.
4126 * elflink.c: Likewise.
4127 * elflink.h: Likewise.
4128 * elfxx-ia64.c: Likewise.
4129 * elfxx-target.h: Likewise.
4130 * libbfd.c: Likewise
4131 * linker.c: Likewise.
4132 * lynx-core.c: Likewise.
4133
41342001-01-02 Kazu Hirata <kazu@hxi.com>
4135
4136 * pc532-mach.c: Fix formatting.
4137 * pe-arm.c: Likewise.
4138 * pe-i386.c: Likewise.
4139 * pe-mips.c: Likewise.
4140 * pe-ppc.c: Likewise.
4141 * pe-sh.c: Likewise.
4142 * pei-mips.c: Likewise.
4143 * pei-sh.c: Likewise.
4144 * peicode.h: Likewise.
4145 * ppcboot.c: Likewise.
4146 * ptrace-core.c: Likewise.
4147
41482001-01-01 Kazu Hirata <kazu@hxi.com>
4149
4150 * reloc.c: Fix formatting.
4151 * riscix.c: Likewise.
4152 * rs6000-core.c: Likewise.
4153 * xcoff-target.h: Likewise.
4154
41552000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4156
4157 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4158 error, by calling bfd_default_set_arch_mach with incoming
4159 values.
4160
41612000-12-26 Kazu Hirata <kazu@hxi.com>
4162
4163 * vaxnetbsd.c: Fix formatting.
4164 * versados.c: Likewise.
4165 * vms-gsd.c: Likewise.
4166 * vms-hdr.c: Likewise.
4167 * vms-misc.c: Likewise.
4168
41692000-12-25 Alexandre Oliva <aoliva@redhat.com>
4170
4171 * archive.c (coff_write_armap): Don't write more than symbol_count
4172 `archive_member_file_ptr's.
4173
41742000-12-25 Kazu Hirata <kazu@hxi.com>
4175
4176 * vms-tir.c: Fix formatting.
4177
41782000-12-23 Kazu Hirata <kazu@hxi.com>
4179
4180 * vms.c: Fix formatting.
4181 * vms.h: Likewise.
4182
41832000-12-21 Santeri Paavolainen <santtu@ssh.com>
4184
4185 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4186
4187 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4188
4189 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4190 arithmetic.
4191
4192 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4193
4194 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4195
41962000-12-21 Richard Sandiford <rsandifo@redhat.com>
4197
4198 * libbfd.c (bfd_get_bits): Added
4199 (bfd_put_bits): Likewise
4200 * bfd-in.h: Declared the above.
4201 * bfd-in2.h: Regenerated.
4202
42032000-12-20 Kazu Hirata <kazu@hxi.com>
4204
4205 * targets.c: Fix formatting.
4206 * tekhex.c: Likewise.
4207 * trad-core.c: Likewise.
4208
42092000-12-19 Kazu Hirata <kazu@hxi.com>
4210
4211 * sco5-core.c: Fix formatting.
4212 * section.c: Likewise.
4213 * sparclinux.c: Likewise.
4214 * sparclynx.c: Likewise.
4215 * sparcnetbsd.c: Likewise.
4216 * srec.c: Likewise.
4217 * stabs.c: Likewise.
4218 * stab-syms.c: Likewise.
4219 * sunos.c: Likewise.
4220 * syms.c: Likewise.
4221 * sysdep.h: Likewise.
4222
42232000-12-18 Nick Clifton <nickc@redhat.com>
4224
4225 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4226 defined.
4227 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4228 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4229
42302000-12-18 Nick Clifton <nickc@redhat.com>
4231
4232 * vms-misc.c (_bfd_vms_get_record): Add default case to
4233 file_format switch.
4234
42352000-12-15 Miloslav Trmac <mitr@volny.cz>
4236
4237 * elfcore.h (elf_core_file_p): Move to the start of the program
4238 headers before attempting to read them.
4239
42402000-12-14 Kazu Hirata <kazu@hxi.com>
4241
4242 * peigen.c: Fix formatting.
4243 * som.c: Likewise.
4244 * som.h: Likewise.
4245
42462000-12-13 Kazu Hirata <kazu@hxi.com>
4247
4248 * peigen.c: Fix formatting.
4249
42502000-12-12 Jim Wilson <wilson@redhat.com>
4251
4252 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4253
42542000-12-08 Mark Salter <msalter@redhat.com>
4255
4256 * binary.c (binary_set_section_contents): Ignore sections
4257 with zero size.
4258
42592000-12-12 Kazu Hirata <kazu@hxi.com>
4260
4261 * m68klinux.c: Fix formatting.
4262 * m68knetbsd.c: Likewise.
4263 * mipsbsd.c: Likewise.
4264 * netbsd-core.c: Likewise.
4265 * netbsd.h: Likewise.
4266 * newsos3.c: Likewise.
4267 * nlm32-alpha.c: Likewise.
4268 * nlm32-i386.c: Likewise.
4269 * nlm32-ppc.c: Likewise.
4270 * nlm32-sparc.c: Likewise.
4271 * nlmcode.h: Likewise.
4272 * nlmswap.h: Likewise.
4273 * nlm-target.h: Likewise.
4274 * ns32knetbsd.c: Likewise.
4275
42762000-12-10 Fred Fish <fnf@be.com>
4277
4278 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4279 symbols in shared objects if allow_shlib_undefined is true.
4280
42812000-12-12 Nick Clifton <nickc@redhat.com>
4282
4283 * cpu-sh.c: Fix formattng.
4284 * elf.c: Fix formattng.
4285 * elf32-mips.c: Fix formattng.
4286 * elf32-sh.c: Fix formattng.
4287 * elf64-alpha.c: Fix formattng.
4288
42892000-12-09 Nick Clifton <nickc@redhat.com>
4290
4291 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4292 dwarf2_find_line_info as last parameter to invocation of
4293 _bfd_dwarf2_find_nearest_line.
4294 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4295 dwarf2_find_line_info as last parameter to invocation of
4296 _bfd_dwarf2_find_nearest_line.
4297
42982000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4299
4300 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4301 (BFD_LIBS): ...to here.
4302 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4303 (BFD_LIBS_CFILES): ...to here.
4304 * Makefile.in: Regenerate.
4305 * configure.in: Remove dwarf.lo from the elf shell variable.
4306 * configure: Regenerate.
4307 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4308 * libcoff.h: Regenerate.
4309 * coffgen.c (coff_find_nearest_line): Call
4310 _bfd_dwarf2_find_nearest_line.
4311 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4312 accordingly.
4313 (read_abbrevs): Likewise
4314 (decode_line_info): Likewise.
4315 (parse_comp_unit): Likewise.
4316 (comp_unit_find_nearest_line): Likewise.
4317 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4318 * libbfd.h: Regenerate.
4319 * elf.c (_bfd_elf_find_nearest_line): Update call.
4320 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4321 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4322 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4323 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4324 (styp_to_sec_flags): Handle DWARF2 sections.
4325 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4326 to _bfd_find_nearest_line.
4327 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4328 call to _bfd_find_nearest_line.
4329
43302000-12-08 Kazu Hirata <kazu@hxi.com>
4331
4332 * coffgen.c: Fix formatting.
4333 * elf-m10300.c: Likewise.
4334 * elf32-i386.c: Likewise.
4335 * elf32-i960.c: Likewise.
4336 * elf32-m68k.c: Likewise.
4337 * elf32-mcore.c: Likewise.
4338 * elf32-ppc.c: Likewise.
4339 * elf32-sh.c: Likewise.
4340 * elf32-sparc.c: Likewise.
4341 * elf32-v850.c: Likewise.
4342 * elf64-alpha.c: Likewise.
4343 * elf64-hppa.c: Likewise.
4344 * elf64-mips.c: Likewise.
4345 * elf64-sparc.c: Likewise.
4346
43472000-12-07 Kazu Hirata <kazu@hxi.com>
4348
4349 * elf32-ppc.c: Fix formatting.
4350 * elf64-x86-64.c: Likewise.
4351
43522000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4353
4354 From Ralf Baechle <ralf@gnu.org>
4355
4356 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4357 BFDs containing no sections or empty .text, .data or .bss sections
4358 to be merged, regardless of their flags.
4359
43602000-12-06 Kazu Hirata <kazu@hxi.com>
4361
4362 * elf32-m32r.c: Fix formatting.
4363 * elf32-m68hc11.c: Likewise.
4364 * elf32-m68hc12.c: Likewise.
4365 * elf32-m68k.c: Likewise.
4366 * elf32-mcore.c: Likewise.
4367 * elf32-pj.c: Likewise.
4368 * elf32-ppc.c: Likewise.
4369
43702000-12-05 Kazu Hirata <kazu@hxi.com>
4371
4372 * elf32-fr30.c: Fix formatting.
4373 * elf32-hppa.c: Likewise.
4374 * elf32-i370.c: Likewise.
4375 * elf32-i386.c: Likewise.
4376 * elf32-i860.c: Likewise.
4377 * elf32-i960.c: Likewise.
4378
43792000-12-03 Kazu Hirata <kazu@hxi.com>
4380
4381 * elf32-arm.h: Fix formatting.
4382 * elf32-avr.c: Likewise.
4383 * elf32-cris.c: Likewise.
4384 * elf32-d10v.c: Likewise.
4385 * elf32-d30v.c: Likewise.
4386 * elf-hppa.h: Likewise.
4387 * elf-m10200.c: Likewise.
4388 * elf-m10300.c: Likewise.
4389
43902000-12-01 Chris Demetriou <cgd@sibyte.com>
4391
4392 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4393 bfd_mach_mips32_4k. Update FIXME comment.
4394 * archures.c (bfd_mach_mips32): New constant.
4395 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4396 the latter, renumber it.
4397 * bfd-in2.h (bfd_mach_mips32): New constant.
4398 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4399 the latter, renumber it.
4400 * cpu-mips.c (I_mips32): New constant.
4401 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4402 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4403 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4404 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4405 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4406 with E_MIPS_MACH_MIPS32_4K.
4407 (_bfd_mips_elf_final_write_processing): Replace
4408 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4409 bfd_mach_mips32 case.
4410 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4411 comparison with support for MIPS32.
4412 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4413 MIPS32.
4414
4415 * aoutx.h (NAME(aout,machine_type)): Add cases for
4416 bfd_mach_mips5 and bfd_mach_mips64.
4417 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4418 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4419 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4420 (arch_info_struct): Add entries for bfd_mach_mips5 and
4421 bfd_mach_mips64.
4422 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4423 _bfd_mips_elf_print_private_bfd_data): Add cases for
4424 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4425 (_bfd_mips_elf_final_write_processing): Add cases for
4426 bfd_mach_mips5 and bfd_mach_mips64.
4427
4428 * aoutx.h (NAME(aout,machine_type)): Add a
4429 bfd_mach_mips_sb1 case.
4430 * archures.c (bfd_mach_mips_sb1): New constant.
4431 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4432 * cpu-mips.c (I_sb1): New constant.
4433 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4434 * elf32-mips.c (elf_mips_mach): Add case for
4435 E_MIPS_MACH_SB1.
4436 (_bfd_mips_elf_final_write_processing): Add case for
4437 bfd_mach_mips_sb1.
4438
44392000-12-01 Joel Sherrill <joel@OARcorp.com>
4440
4441 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4442 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4443 (sparc*-*-rtems*): Switched from a.out to ELF.
4444
44452000-11-30 Jan Hubicka <jh@suse.cz>
4446
4447 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4448 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4449 (elf64-x86-64.lo): Add dependencies.
4450 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4451 bfd_mach_x86_64_intel_syntax.
4452 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4453 * config.bfd (x86_64): Add.
4454 * configure.in: Add support for bfd_elf64_x86_64_vec.
4455 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4456 (bfd_i386_arch, i8086_ar): Link in.
4457 * elf64-x86-64.c: New file.
4458 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4459 * targets.c (bfd_elf64_x86_64_vec): Add.
4460 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4461
44622000-11-30 Kazu Hirata <kazu@hxi.com>
4463
4464 * xcofflink.c: Fix formatting.
4465
44662000-11-28 Kazu Hirata <kazu@hxi.com>
4467
4468 * aoutx.h: Fix formatting.
4469 * bfd-in.h: Likewise.
4470 * bfd-in2.h: Likewise.
4471 * cache.c: Likewise.
4472 * cisco-core.c: Likewise.
4473 * coff64-rs6000.c: Likewise.
4474 * coffcode.h: Likewise.
4475 * coffswap.h: Likewise.
4476 * corefile.c: Likewise.
4477 * elf32-mips.c: Likewise.
4478
44792000-11-27 Kazu Hirata <kazu@hxi.com>
4480
4481 * aout-adobe.c: Fix formatting.
4482 * coff64-rs6000.c: Likewise.
4483 * coffgen.c: Likewise.
4484 * cofflink.c: Likewise.
4485
44862000-11-27 Philip Blundell <pb@futuretv.com>
4487
4488 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4489 (obj_coff_strings_written): New accessor macro for above.
4490 * libcoff.h: Regenerate.
4491 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4492 strings.
4493 * coffcode.h (coff_write_object_contents): No need to write out
4494 the string table if it's already been done.
4495
44962000-11-22 Philip Blundell <pb@futuretv.com>
4497
4498 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4499 weak undefined symbols.
4500
45012000-11-24 Nick Clifton <nickc@redhat.com>
4502
4503 * archures.c (bfd_mach_arm_5TE): Define.
4504 (bfd_mach_arm+XScale): Define.
4505 * bfd-in2.h: Regenerate.
4506
4507 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4508 BFD_RELOC_ARM_PCREL_BLX.
4509
4510 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4511 XScale machine numbers.
4512
4513 * config.bfd (xscale-elf): Add target.
4514 (xscale-coff): Add target.
4515
4516 * cpu-arm.c: Add xscale machine name.
4517 Add v5t, v5te and XScale machine numbers.
4518
45192000-11-23 Kazu Hirata <kazu@hxi.com>
4520
4521 * aix386-core.c: Fix formatting.
4522
45232000-11-22 Jim Wilson <wilson@redhat.com>
4524
4525 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4526 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4527 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4528 (ins_imms_scaled): Initialize sign_bit at function entry.
4529 (elf64_ia64_operands): Add missing initializers.
4530 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4531 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4532 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4533 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4534 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4535 parameters.
4536 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4537 and free_extsyms at function entry.
4538 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4539 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4540 (get_got): Delete unused local srel.
4541 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4542 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4543
45442000-11-21 Kazu Hirata <kazu@hxi.com>
4545
4546 * coff-a29k.c: Fix formatting.
4547 * coff-h8500.c: Likewise.
4548 * coff-i960.c: Likewise.
4549 * coff-ppc.c: Likewise.
4550 * coff-rs6000.c: Likewise.
4551 * coff-stgo32.c: Likewise.
4552 * coff-tic54x.c: Likewise.
4553 * coff-w65.c: Likewise.
4554 * cpu-h8500.c: Likewise.
4555 * cpu-hppa.c: Likewise.
4556 * cpu-ns32k.c: Likewise.
4557 * ecoff.c: Likewise.
4558 * ecofflink.c: Likewise.
4559
45602000-11-21 Nick Clifton <nickc@redhat.com>
4561
4562 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4563 remove possibility of infinite loop.
4564
45652000-11-20 Kazu Hirata <kazu@hxi.com>
4566
4567 * aix386-core.c: Fix formatting.
4568 * aout-adobe.c: Likewise.
4569 * aout-arm.c: Likewise.
4570 * aout-encap.c: Likewise.
4571 * aout-ns32k.c: Likewise.
4572 * aout-target.h: Likewise.
4573 * aout-tic30.c: Likewise.
4574 * aoutf1.h: Likewise.
4575 * aoutx.h: Likewise.
4576 * archive.c: Likewise.
4577 * bfd-in.h: Likewise.
4578 * bfd-in2.h: Likewise.
4579 * bfd.c: Likewise.
4580 * bout.c: Likewise.
4581
45822000-11-17 H.J. Lu <hjl@gnu.org>
4583
4584 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4585 pltoff entries for DT_INIT and DT_FINI.
4586 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4587 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4588 entries.
4589
45902000-11-16 Richard Henderson <rth@redhat.com>
4591
4592 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4593 (allocate_dynrel_entries): Likewise.
4594 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4595 (set_pltoff_entry): Likewise.
4596 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4597 (elfNN_ia64_reloc_type_lookup): Likewise.
4598 (elfNN_ia64_install_value): Likewise.
4599 (elfNN_ia64_relocate_section): Likewise.
4600 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4601 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4602
46032000-11-16 Kazu Hirata <kazu@hxi.com>
4604
4605 * cpu-a29k.c: Fix formatting.
4606 * cpu-alpha.c: Likewise.
4607 * cpu-arm.c: Likewise.
4608 * cpu-avr.c: Likewise.
4609 * cpu-d10v.c: Likewise.
4610 * cpu-h8500.c: Likewise.
4611 * cpu-hppa.c: Likewise.
4612 * cpu-i370.c: Likewise.
4613 * cpu-i386.c: Likewise.
4614 * cpu-i960.c: Likewise.
4615 * cpu-ia64-opc.c: Likewise.
4616 * cpu-ia64.c: Likewise.
4617 * cpu-m32r.c: Likewise.
4618 * cpu-m68hc11.c: Likewise.
4619 * cpu-m68hc12.c: Likewise.
4620 * cpu-m68k.c: Likewise.
4621 * cpu-m88k.c: Likewise.
4622 * cpu-mips.c: Likewise.
4623 * cpu-ns32k.c: Likewise.
4624 * cpu-pj.c: Likewise.
4625 * cpu-powerpc.c: Likewise.
4626 * cpu-sh.c: Likewise.
4627 * cpu-sparc.c: Likewise.
4628 * cpu-tic54x.c: Likewise.
4629 * cpu-v850.c: Likewise.
4630 * cpu-vax.c: Likewise.
4631 * cpu-w65.c: Likewise.
4632 * cpu-we32k.c: Likewise.
4633 * cpu-z8k.c: Likewise.
4634 * dwarf1.c: Likewise.
4635 * dwarf2.c: Likewise.
4636
46372000-11-15 Kazu Hirata <kazu@hxi.com>
4638
4639 * coff-arm.c: Fix formatting.
4640 * coff-ppc.c: Likewise.
4641 * coff-rs6000.c: Likewise.
4642 * coff-sh.c: Likewise.
4643 * coff-sparc.c: Likewise.
4644 * coff-tic30.c: Likewise.
4645 * coff-tic54x.c: Likewise.
4646 * coff-tic80.c: Likewise.
4647 * coff-w65.c: Likewise.
4648 * coff-we32k.c: Likewise.
4649 * coff-z8k.c: Likewise.
4650
46512000-11-15 Richard Henderson <rth@redhat.com>
4652
4653 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4654 section with the same ALLOC|LOAD flags as the source section.
4655
46562000-11-14 Jakub Jelinek <jakub@redhat.com>
4657
4658 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4659 by STO_ALPHA constants.
4660
46612000-11-14 Kazu Hirata <kazu@hxi.com>
4662
4663 * coff-pmac.c: Fix formatting.
4664 * coff-ppc.c: Likewise.
4665
46662000-11-13 H.J. Lu <hjl@gnu.org>
4667
4668 * elflink.h (elf_link_add_object_symbols): Also add indirect
4669 symbols for common symbols with the default version.
4670
46712000-11-09 Philip Blundell <pb@futuretv.com>
4672
4673 * section.c (STD_SECTION): Set gc_mark flag.
4674
46752000-11-11 Kazu Hirata <kazu@hxi.com>
4676
4677 * coff-i960.c: Likewise.
4678 * coff-m68k.c: Likewise.
4679 * coff-m88k.c: Likewise.
4680 * coff-mcore.c: Likewise.
4681 * coff-mips.c: Likewise.
4682
46832000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4684
4685 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4686
46872000-11-10 Kazu Hirata <kazu@hxi.com>
4688
4689 * coff-h8300.c: Fix formatting.
4690 * coff-h8500.c: Likewise.
4691 * coff-i386.c: Likewise.
4692 * coff-i860.c: Likewise.
4693 * coff-i960.c: Likewise.
4694 * coff-ia64.c: Likewise.
4695
46962000-11-09 Kazu Hirata <kazu@hxi.com>
4697
4698 * archive.c: Fix formatting.
4699 * archures.c: Likewise.
4700
47012000-11-07 Richard Henderson <rth@redhat.com>
4702
4703 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4704 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4705 * section.c (bfd_set_section_contents): Call memcpy if
4706 section->contents set and location not equal to contents plus offset.
4707
47082000-11-08 Kazu Hirata <kazu@hxi.com>
4709
4710 * bfd-in.h: Fix formatting.
4711 * bfd-in2.h: Likewise.
4712 * bfd.c: Likewise.
4713 * binary.c: Likewise.
4714 * bout.c: Likewise.
4715 * coff-a29k.c: Likewise.
4716 * coff-alpha.c: Likewise.
4717 * coff-apollo.c: Likewise.
4718 * coff-aux.c: Likewise.
4719
47202000-11-07 Kazu Hirata <kazu@hxi.com>
4721
4722 * aix386-core.c: Fix formatting.
4723 * aoutf1.h: Likewise.
4724 * aoutx.h: Likewise.
4725 * archures.c: Likewise.
4726 * armnetbsd.c: Likewise.
4727
47282000-11-07 Alan Modra <alan@linuxcare.com.au>
4729
4730 * coff-h8300.c (special): Adjust reloc address.
4731
47322000-11-06 Steve Ellcey <sje@cup.hp.com>
4733
4734 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4735 to differentiate elf32 and elf64 on ia64.
4736 * bfd-in2.h: Regenerate.
4737 * config.bfd: Add target for "ia64*-*-hpux*".
4738 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4739 * configure: Regenerate.
4740 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
4741 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
4742
4743 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
4744 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
4745 * Makefile.in: Regnerate.
4746 * elf64-ia64.c: Deleted.
4747 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
4748
47492000-11-06 Kazu Hirata <kazu@hxi.com>
4750
4751 * aout-adobe.c: Fix formatting.
4752 * aout-arm.c: Likewise.
4753 * aout-cris.c: Likewise.
4754 * aout-encap.c: Likewise.
4755 * aout-ns32k.c: Likewise.
4756 * aout-target.h: Likewise.
4757 * aout-tic30.c: Likewise.
4758
47592000-11-05 Philip Blundell <philb@gnu.org>
4760
4761 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
4762 BFDs containing no sections to be merged, regardless of their flags.
4763
47642000-11-04 Philip Blundell <philb@gnu.org>
4765
4766 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
4767 if a relocation for an undefined symbol also results in an
4768 overflow.
4769
47702000-11-06 Christopher Faylor <cgf@cygnus.com>
4771
4772 * config.bfd: Add support for Sun Chorus.
4773
47742000-11-05 David O'Brien <obrien@FreeBSD.org>
4775
4776 * configure.in: Recognize alpha-*-freebsd*.
4777 * configure: Regenerate.
4778
47792000-11-02 Luciano Gemme <ishitawa@yahoo.com>
4780
4781 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
4782 (Chunk): New global variable set by a parameter in objcopy.c.
4783 (S3Forced): New global variable set by a parameter in
4784 objcopy.c.
4785 (srec_set_section_contents): If S3Forced is true, always generate
4786 S3 records.
4787 (srec_write_section): Use 'Chunk' to limit maximum length of S
4788 records.
4789
47902000-11-02 Per Lundberg <plundis@chaosdev.org>
4791
4792 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
4793 * Makefile.in: Regenerate.
4794 * bfd-in2.h: Regenerate.
4795 * po/bfd.pot: Regenerate.
4796
47972000-10-31 Philip Blundell <philb@gnu.org>
4798
4799 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
4800 EF_SOFT_FLOAT if it is defined.
4801
48022000-10-27 Philip Blundell <philb@gnu.org>
4803
4804 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
4805 attempts to mix PIC code with non-PIC, just mark the output as
4806 being position dependent.
4807 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
4808 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
4809 all mismatches, not just the first one.
4810
48112000-10-25 Chris Demetriou <cgd@sibyte.com>
4812
4813 * ieee.c (ieee_archive_p): Plug one of many possible
4814 memory leaks in error handling.
4815
48162000-10-20 Jakub Jelinek <jakub@redhat.com>
4817
4818 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
4819 elf32_sparc_object_p, elf32_sparc_final_write_processing):
4820 Support v8plusb.
4821 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
4822 sparc64_elf_object_p): Support v9b.
4823 * archures.c: Declare v8plusb and v9b machines.
4824 * bfd-in2.h: Ditto.
4825 * cpu-sparc.c: Ditto.
4826
48272000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
4828
4829 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
4830 of a GOT reloc.
4831
4832 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
4833 (SYMBOL_CALLS_LOCAL): New macro.
4834 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
4835 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
4836 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
4837 (ppc_elf_relocate_section): Use flag variable to determine
4838 whether the relocation refers to a local symbol.
4839 Test whether a PLTREL24 reloc will produce a reloc by looking
4840 to see whether a PLT entry was made.
4841
48422000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
4843
4844 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
4845 entries that could serve as a definition for a weak symbol.
4846
48472000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
4848
4849 From Ralf Baechle <ralf@gnu.org>
4850
4851 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
4852 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
4853 against local symbols.
4854 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
4855
48562000-10-12 Alan Modra <alan@linuxcare.com.au>
4857
4858 * section.c (struct sec): Add kept_section.
4859 (struct bfd_comdat_info): Remove sec, we can use above.
4860 (STD_SECTION): Add initializer.
4861 (bfd_make_section_anyway): Init here too.
4862
4863 * bfd-in2.h: Regenerate.
4864
4865 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
4866 zeroing of `flags'.
4867 (elf_link_input_bfd): Set all asection->symbol->value's here, and
4868 fudge values for discarded link-once section symbols.
4869
4870 * elf64-hppa.c: Include alloca-conf.h
4871
48722000-10-11 Alan Modra <alan@linuxcare.com.au>
4873
4874 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
4875
4876 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
4877
48782000-10-10 Alan Modra <alan@linuxcare.com.au>
4879
4880 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
4881
48822000-10-10 Tom Rix <trix@redhat.com>
4883
4884 * section.c (bfd_make_section_anyway): Release newsect ptr when
4885 newsect->symbol fails to alloc. Use bfd_release instead of free.
4886
48872000-10-09 Richard Henderson <rth@cygnus.com
4888
4889 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
4890 (elf64_ia64_unwind_entry_compare): New.
4891 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
4892
48932000-10-07 Alan Modra <alan@linuxcare.com.au>
4894
4895 * elflink.h (size_dynamic_sections): Don't create various tags if
4896 .dynstr is excluded from the link. Don't set first dynsym entry
4897 if dynsymcount is zero.
4898 (elf_bfd_final_link): Don't try to swap out dynamic syms if
4899 .dynsym excluded from the link. Don't try to write any dynamic
4900 sections excluded from the link.
4901
4902 * elf.c (swap_out_syms): Handle global section symbols.
4903
49042000-10-05 DJ Delorie <dj@redhat.com>
4905
4906 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
4907 * coffcode.h (coff_set_alignment_hook): read extended reloc count
4908 (coff_write_relocs): write extended reloc count
4909 (coff_write_object_contents): account for extended relocs
4910
49112000-10-05 Jim Wilson <wilson@cygnus.com>
4912
4913 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
4914 field.
4915 * elf.c (_bfd_elf_make_section_from_shdr): Call the
4916 elf_backend_section_flags function.
4917 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
4918 code.
4919 (elf64_ia64_section_flags): New function containing flag conversion
4920 code.
4921 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
4922 * elfxx-target.h (elf_backend_section_flags): Define.
4923 (elfNN_bed): Initialize elf_backend_section_flags field.
4924
49252000-10-02 Alan Modra <alan@linuxcare.com.au>
4926
4927 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
4928 _bfd_elf32_gc_record_vtable. Correct a comment.
4929
49302000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
4931
4932 From Ralf Baechle <ralf@gnu.org>
4933
4934 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
4935 produces binaries with got[1] = 0x80000001 to differenciate them
4936 for the dynamic linker from the broken binaries produced by old
4937 versions.
4938
49392000-09-30 Petr Sorfa <petrs@sco.com>
4940
4941 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
4942 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
4943 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
4944 * configure: Regenerate.
4945
49462000-09-27 Hans-Peter Nilsson <hp@axis.com>
4947
4948 Define two bfd_targets for absence and presence of leading
4949 underscore on symbols. Make sure to only link same kind.
4950 * elf32-cris.c (cris_elf_object_p,
4951 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
4952 cris_elf_merge_private_bfd_data): New.
4953 (elf_backend_object_p, elf_backend_final_write_processing,
4954 bfd_elf32_bfd_print_private_bfd_data,
4955 bfd_elf32_bfd_merge_private_bfd_data): Define.
4956 <Target vector definition>: Include elf32-target.h twice with
4957 different macro settings:
4958 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
4959 bfd_elf32_us_cris_vec.
4960 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
4961 (elf_symbol_leading_char): First as 0, then '_'.
4962 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
4963 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
4964 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
4965 * configure: Regenerate.
4966 * targets.c: Declare bfd_elf32_us_cris_vec.
4967 * po/bfd.pot: Regenerate.
4968
49692000-09-29 Momchil Velikov <velco@fadata.bg>
4970
4971 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
4972 R_ARM_THM_PC22 relocations.
4973
49742000-09-29 NIIBE Yutaka <gniibe@chroot.org>
4975
4976 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
4977
49782000-09-29 Momchil Velikov <velco@fadata.bg>
4979
4980 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
4981 is has the SEC_HAS_CONTENTS flag set.
4982