* vms-tir.c: Add missing prototypes.
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2001-09-01 Andreas Jaeger <aj@suse.de>
2
3 * vms-tir.c: Add missing prototypes.
4 * vms-hdr.c: Likewise.
5 * vms-gsd.c: Likewise.
6 * vms-misc.c: Likewise.
7
8 2001-08-31 H.J. Lu <hjl@gnu.org>
9
10 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
11 with bad relocation.
12
13 2001-08-31 Eric Christopher <echristo@redhat.com>
14 Jason Eckhardt <jle@redhat.com>
15
16 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
17 mips32_4k and mips64.
18 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
19 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
20 * bfd/cpu-mips.c: Ditto.
21 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
22 * bfd/bfd-in2.h: Regenerate.
23
24 2001-08-31 Jakub Jelinek <jakub@redhat.com>
25
26 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
27 value into R_ALPHA_RELATIVE's addend.
28 (elf64_alpha_finish_dynamic_symbol): Likewise.
29
30 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
31
32 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
33 recomputed addend during relocatable link if not USE_REL.
34
35 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
36 error.
37
38 2001-08-30 H.J. Lu <hjl@gnu.org>
39
40 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
41 2 changes.
42 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
43 relocations for weak definitions.
44
45 2001-08-30 H.J. Lu <hjl@gnu.org>
46
47 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
48 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
49 * Makefile.in: Rebuild.
50
51 2001-08-30 H.J. Lu <hjl@gnu.org>
52
53 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
54 dynamic relocation for undefined weak symbols when creating
55 executables. Check h->root.root.type, instead of h->root.type.
56
57 2001-08-29 Joel Sherrill <joel@OARcorp.com>
58
59 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
60 default from coff to elf.
61
62 2001-08-29 Jeff Law <law@redhat.com>
63
64 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
65 relocations.
66 (h8_reloc_map): Similarly.
67 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
68 Add support for PC relative relocations.
69
70 * elf32-h8300.c: Put all prototypes together.
71 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
72 (elf32_h8_final_link_relocate): New function for linker.
73 (elf32_h8_relocate_section): Similarly.
74 (elf_backend_relocate_section): Define.
75
76 * cpu-h8300.c (h8300_scan, compatible): Prototype.
77 (h8300_scan): Handle architecture:machine encodings typically
78 found in linker scripts.
79 * elf.c (prep_headers): Do not try to do H8 machine recognition
80 here.
81 * elf32-h8300.c: Add some missing prototypes.
82 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
83 (elf32_h8_object_p): Similarly.
84
85 2001-08-29 Tom Rix <trix@redhat.com>
86
87 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
88 does not follow a XTY_SD.
89
90 2001-08-29 Alan Modra <amodra@bigpond.net.au>
91
92 * targmatch.sed: Delete case statements.
93 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
94 aix4.3 and above.
95
96 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
97
98 * Makefile.am (elf32-h8300.lo): New target.
99 * config.bfd (h8300*-*-elf): New case.
100 * configure.in (bfd_elf32_h8300_vec): New case.
101 * elf.c (prep_headers): Add case for bfd_arch_h8300.
102 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
103 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
104 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
105 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
106 * elf32-h8300.c: New file.
107 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
108
109 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
110
111 * sparclynx.c: Add missing prototypes.
112 * coff-mcore.c: Add missing prototypes.
113 * elf32-pj.c: Add missing prototypes.
114 * nlm32-sparc.c: Add missing prototypes.
115 * oasys.c: Add missing prototypes.
116 * pdp11.c: Add missing prototypes.
117 * pe-mips.c: Add missing prototypes.
118 * riscix.c: Add missing prototypes.
119
120 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
121
122 * elf32-i386.c: Add missing prototypes.
123 * elf32-ppc.c: Likewise.
124 * elf32-sh-lin.c: Likewise.
125 * elfarm-nabi.c: Likewise.
126
127 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
128
129 * elf32-i386.c (elf_i386_grok_prstatus): New function.
130 (elf_i386_grok_psinfo): New function.
131 (elf_backend_grok_prstatus): Define.
132 (elf_backend_grok_psinfo): Likewise.
133 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
134 (ppc_elf_grok_psinfo): New function.
135 (elf_backend_grok_prstatus): Define.
136 (elf_backend_grok_psinfo): Likewise.
137 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
138 (elf32_shlin_grok_psinfo): New function.
139 (elf_backend_grok_prstatus): Define.
140 (elf_backend_grok_psinfo): Likewise.
141 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
142 (elf32_arm_nabi_grok_psinfo): New function.
143 (elf_backend_grok_prstatus): Define.
144 (elf_backend_grok_psinfo): Likewise.
145
146 2001-08-27 H.J. Lu <hjl@gnu.org>
147
148 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
149 sanity check.
150 (mips_elf_calculate_relocation): Create dynamic relocation for
151 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
152 bit is not set.
153
154 2001-08-27 H.J. Lu <hjl@gnu.org>
155
156 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
157 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
158 (_bfd_elf32_mips_grok_prstatus): Likewise.
159 (_bfd_elf32_mips_grok_psinfo): Likewise.
160 (_bfd_mips_elf_hide_symbol): Make it static and cast to
161 `struct mips_elf_link_hash_entry *'.
162 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
163
164 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
165
166 * mipsbsd.c: Add missing prototypes.
167 * hp300hpux.c: Add missing prototypes.
168 * i386aout.c: Add missing prototypes.
169 * i386lynx.c: Add missing prototypes.
170 * i386mach3.c: Add missing prototypes.
171 * i386msdos.c: Add missing prototypes.
172 * i386os9k.c: Add missing prototypes.
173
174 2001-08-27 Linus Nordberg <linus@swox.se>
175 Torbjorn Granlund <tege@swox.com>
176 Staffan Ulfberg <staffanu@swox.se>
177 Alan Modra <amodra@bigpond.net.au>
178
179 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
180 targ64_selvecs for 32 bit powerpc targets.
181 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
182 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
183 Run "make dep-am".
184 * Makefile.in: Regenerate.
185 * configure.in: Add elf64_powerpc vecs.
186 * configure: Regenerate.
187 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
188 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
189 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
190 * elf64-ppc.c: New file.
191 * reloc.c: Add powerpc64 relocs.
192 * libbfd.h: Regenerate.
193 * bfd-in2.h: Regenerate.
194
195 2001-08-27 Andreas Schwab <schwab@suse.de>
196
197 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
198 reloc is against read-only section.
199 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
200 looking up section names for DT_TEXTREL.
201 (elf32_m68k_reloc_type_class): New function.
202 (elf_backend_reloc_type_class): Define.
203
204 2001-08-27 Andreas Jaeger <aj@suse.de>
205
206 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
207 reloc is against read-only section.
208 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
209 looking up section names for DT_TEXTREL.
210 (elf_s390_reloc_type_class): New.
211 (elf_backend_reloc_type_class): Define.
212
213 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
214 reloc is against read-only section.
215 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
216 looking up section names for DT_TEXTREL.
217 (elf_s390_reloc_type_class): New.
218 (elf_backend_reloc_type_class): Define.
219
220 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
221 is against read-only section.
222 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
223 looking up section names for DT_TEXTREL.
224 (ppc_elf_reloc_type_class): New.
225 (elf_backend_reloc_type_class): Define.
226
227 2001-08-26 Andreas Jaeger <aj@suse.de>
228
229 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
230 reloc is against read-only section.
231 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
232 looking up section names for DT_TEXTREL.
233 (elf_cris_reloc_type_class): New.
234 (elf_backend_reloc_type_class): Define.
235
236 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
237 against read-only section.
238 (elf_backend_reloc_type_class): Define.
239 (sh_elf_reloc_type_class): New.
240 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
241 looking up section names for DT_TEXTREL.
242
243 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
244 reloc is against read-only section.
245 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
246 looking up section names for DT_TEXTREL.
247 (elf32_arm_reloc_type_class): New.
248 (elf_backend_reloc_type_class): Define.
249
250 2001-08-25 Andreas Jaeger <aj@suse.de>
251
252 * oasys.c: Add missing prototypes.
253
254 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
255 attribute for parameter.
256 * elf.c (_bfd_elf_reloc_type_class): Likewise.
257
258 * versados.c (get_4): Make static.
259 (get_10): Make static.
260 Add missing prototypes.
261 (process_esd): Fix call to versados_new_symbol.
262
263 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
264
265 * coff-a29k.c: Add missing prototypes.
266 * coff-apollo.c: Add missing prototypes.
267 * coff-arm.c: Add missing prototypes.
268 * coff-i860.c: Add missing prototypes.
269 * coff-rs6000.c: Add missing prototypes.
270 * coff-tic80.c: Add missing prototypes.
271 * elf-m10200.c: Add missing prototypes.
272 * elf-m10300.c: Add missing prototypes.
273 * elf32-arm.h: Add missing prototypes.
274 * elf32-d10v.c: Add missing prototypes.
275 * elf32-m32r.c: Add missing prototypes.
276 * elf32-mcore.c: Add missing prototypes.
277 * elf32-openrisc.c: Add missing prototypes.
278 * elf32-sh.c: Add missing prototypes.
279 * elf32-sparc.c: Add missing prototypes.
280 * elf32-v850.c: Add missing prototypes.
281 * elfarm-nabi.c: Add missing prototypes.
282 * elfarm-oabi.c: Add missing prototypes.
283
284 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
285
286 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
287 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
288
289 2001-08-24 H.J. Lu <hjl@gnu.org>
290
291 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
292 hash structure.
293
294 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
295
296 * elf-bfd.h (elf_hash_table): Revert definition.
297 (is_elf_hash_table): New macro.
298 * elflink.h (elf_link_add_object_symbols): Test
299 is_elf_hash_table before accessing ELF only fields in hash
300 structure.
301 (elf_link_create_dynamic_sections): Fail if not using an ELF
302 hash structure.
303 (elf_add_dynamic_entry): Fail if not using an ELF hash
304 structure.
305 (elf_link_record_local_dynamic_symbol): Fail if not using an
306 ELF hash structure.
307 (size_dynamic_sections): Fail if not using an ELF hash
308 structure.
309 (elf_adjust_dynamic_symbol): Fail if not using an ELF
310 hash structure.
311 (elf_bfd_final_link): Fail if not using an ELF hash
312 structure.
313
314 2001-08-24 H.J. Lu <hjl@gnu.org>
315
316 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
317 table is not an ELF linker hash table.
318
319 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
320 table type to bfd_link_elf_hash_table.
321
322 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
323 the last change.
324
325 * linker.c (_bfd_link_hash_table_init): Set the linker hash
326 table type to bfd_link_generic_hash_table.
327
328 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
329
330 * bfd.c (bfd_alt_mach_code): New function.
331 * bfd-in2.h: Rebuilt.
332
333 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
334
335 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
336 `type' field in the hash entry when deciding whether to follow a
337 link.
338
339 2001-08-24 Jakub Jelinek <jakub@redhat.com>
340
341 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
342 last.
343 (elf_link_sort_relocs): Adjust accordingly.
344
345 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
346 (elf64_alpha_check_relocs): Set it if section this reloc is against
347 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
348 read-only section.
349 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
350 is is against read-only section.
351 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
352 check section names.
353 (elf64_alpha_reloc_type_class): New.
354 (elf_backend_reloc_type_class): Define.
355
356 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
357
358 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
359 by bfd_malloc().
360
361 2001-08-23 Andreas Jaeger <aj@suse.de>
362
363 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
364 the reloc is against read-only section.
365 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
366 of looking up section names for DT_TEXTREL.
367 (elf64_x86_64_reloc_type_class): New.
368 (elf_backend_reloc_type_class): Define.
369
370 2001-08-23 H.J. Lu <hjl@gnu.org>
371
372 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
373 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
374
375 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
376 bfd_print_symbol_vandf.
377 * coffgen.c (coff_print_symbol): Likewise.
378 * elf.c (bfd_elf_print_symbol): Likewise.
379 * ieee.c (ieee_print_symbol): Likewise.
380 * nlmcode.h (nlm_print_symbol): Likewise.
381 * oasys.c (oasys_print_symbol): Likewise.
382 * pdp11.c (NAME(aout,print_symbol)): Likewise.
383 * som.c (som_print_symbol): Likewise.
384 * srec.c (srec_print_symbol): Likewise.
385 * tekhex.c (tekhex_print_symbol): Likewise.
386 * versados.c (versados_print_symbol): Likewise.
387 * vms.c (vms_print_symbol): Likewise.
388
389 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
390 with bfd_fprintf_vma.
391 (bfd_elf_print_symbol): Likewise.
392 * syms.c (bfd_print_symbol_vandf): Likewise.
393
394 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
395
396 * aoutf1.h (sunos_write_object_contents): Silence compile time
397 warning.
398 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
399
400 * bout.c: Add missing function prototypes. Fix formatting.
401 * coff-z8k.c: Add missing function prototypes. Fix formatting.
402 * coff-w65.c: Add missing function prototypes. Fix formatting.
403 * coff-h8500.c: Add missing function prototypes. Fix formatting.
404 * coff-h8300.c: Add missing function prototypes. Fix formatting.
405 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
406 * coff-tic30.c: Add missing function prototypes. Fix formatting.
407 * coff-m68k.c: Add missing function prototypes. Fix formatting.
408 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
409 * coff-sh.c: Add missing function prototypes. Fix formatting.
410
411 2001-08-23 Jakub Jelinek <jakub@redhat.com>
412
413 * elf-bfd.h (enum elf_reloc_type_class): New.
414 (struct elf_backend_data): Add elf_backend_reloc_type_class.
415 (_bfd_elf_reloc_type_class): New.
416 * elfxx-target.h (elf_backend_reloc_type_class): Define.
417 (elfNN_bed): Add elf_backend_reloc_type_class.
418 * elf.c (_bfd_elf_reloc_type_class): New.
419 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
420 is against read-only section.
421 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
422 looking up section names for DT_TEXTREL.
423 (elf_i386_reloc_type_class): New.
424 (elf_backend_reloc_type_class): Define.
425 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
426 reloc is against read-only section.
427 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
428 looking up section names for DT_TEXTREL.
429 (elf32_sparc_reloc_type_class): New.
430 (elf_backend_reloc_type_class): Define.
431 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
432 reloc is against read-only section.
433 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
434 looking up section names for DT_TEXTREL.
435 (sparc64_elf_reloc_type_class): New.
436 (elf_backend_reloc_type_class): Define.
437 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
438 (elfNN_ia64_hash_table_create): Clear ia64_info.
439 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
440 section.
441 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
442 instead of looking up section names for DT_TEXTREL.
443 (elfNN_ia64_reloc_type_class): New.
444 (elf_backend_reloc_type_class): Define.
445 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
446 (struct elf_link_sort_rela): New.
447 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
448 (elf_bfd_final_link): Call elf_link_sort_relocs.
449 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
450 necessary.
451
452 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
453
454 * configure.in (x86-bsdi): No corefile support.
455 * configure: Regenerate.
456
457 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
458
459 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
460 comma.
461
462 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
463
464 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
465 the alignment of dwarf2 linkonce sections to 0.
466 * coff-sto32.c: Likewise.
467
468 2001-08-20 Andreas Jaeger <aj@suse.de>
469
470 * coff-sparc.c: Add missing prototypes.
471 * elf32-s390.c: Likewise.
472 * elf32-i960.c: Likewise.
473 * aout-target.h: Likewise.
474
475 2001-08-20 H.J. Lu <hjl@gnu.org>
476
477 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
478 (elf_num_section_syms): New for num_section_syms.
479
480 * elf.c (elf_map_symbols): Set num_section_syms.
481 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
482 the section symbol index.
483
484 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
485
486 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
487 select the generic has table creator. All elf backends need elf
488 specific fields in the hash table.
489
490 2001-08-20 Alan Modra <amodra@bigpond.net.au>
491
492 * archive.c (offsetof): Remove define.
493 * elf.c: Likewise.
494 * oasys.c: Likewise
495 * sysdep.h (offsetof): Define.
496
497 2001-08-17 Alan Modra <amodra@bigpond.net.au>
498
499 * bfd.c (bfd_get_gp_size): Return an unsigned int.
500 (bfd_set_gp_size): Make param unsigned.
501 * bfd-in2.h: Regenerate.
502 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
503 than calling bfd_get_gp_size.
504 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
505 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
506
507 2001-08-17 Alan Modra <amodra@bigpond.net.au>
508
509 * linker.c (default_fill_link_order): Handle four byte fill value.
510
511 2001-08-17 Alan Modra <amodra@bigpond.net.au>
512
513 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
514 prototype.
515 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
516
517 * elf64-mips.c (UNUSED_RELOC): Define.
518 (mips_elf64_howto_table_rel): Use it.
519 (mips_elf64_howto_table_rela): Here too.
520 (mips_elf64_write_relocs): Fix signed/unsigned warning.
521
522 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
523 silence warning.
524 * coffgen.c (coff_print_symbol): Fix warnings.
525 (coff_find_nearest_line): Likewise.
526 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
527 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
528 * format.c (bfd_check_format_matches): Likewise.
529 (bfd_set_format): Likewise.
530 * coff-ia64.c: Add missing prototypes.
531 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
532 signed to silence warnings.
533 (elf64_alpha_relocate_section): Likewise.
534 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
535 (elf64_alpha_add_symbol_hook): Likewise.
536 (elf64_alpha_final_link): Likewise.
537 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
538 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
539 (elf64_alpha_size_got_sections): Likewise.
540 * elfxx-ia64.c: Add missing prototypes.
541 (elfNN_ia64_relocate_section): Fix warning.
542 (elfNN_ia64_unwind_entry_compare): Make params const.
543
544 2001-08-17 Alan Modra <amodra@bigpond.net.au>
545
546 * config.bfd (targ64_selvecs): New.
547 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
548
549 * bfd-in.h (BFD_VERSION): Remove wrong comment.
550 (BFD_DEFAULT_TARGET_SIZE): New.
551 (BFD_ARCH_SIZE): Comment.
552 * configure.in (target_size): New. Set instead of target64 in
553 selvecs case statement. Set target64 from it.
554 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
555 * bfd-in2.h: Regenerate.
556 * configure: Regenerate.
557
558 2001-08-17 Alan Modra <amodra@bigpond.net.au>
559
560 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
561 (bfd_errmsgs): Add corresponding message.
562 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
563 finding an archive that contains different format object files.
564 Return bfd_error_wrong_object_format for this case.
565 * format.c: Formatting fixes. s/CONST/const/.
566 (bfd_check_format_matches): Accept archives that give
567 bfd_error_wrong_object_format if no full match is found. Tidy
568 code handling matching_vector. Don't return a pointer to freed
569 memory in `matching'. Handle ambiguous matches as for partial
570 archive matches.
571 * bfd-in2.h: Regenerate.
572
573 2001-08-15 Alan Modra <amodra@bigpond.net.au>
574
575 * libieee.h (common_header_type): Add last_byte field.
576
577 * ieee.c: Add missing prototypes. Some format fixes.
578 (struct output_buffer_struct): Move for availability to prototypes.
579 (ieee_part_after): New function.
580 (ieee_slurp_debug): Use it here.
581 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
582 ieee_part_after to set last_byte to one past end of current part.
583 Update callers.
584 (ieee_pos): Pass in ieee_data_struct rather than bfd.
585 Update callers.
586 (parse_expression): Don't go beyond the end of the current part.
587 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
588 (ieee_get_symtab_upper_bound, ieee_get_symtab,
589 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
590 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
591 ieee_set_section_contents, ieee_write_object_contents,
592 ieee_make_empty_symbol): Make static.
593 (ieee_archive_p): Correct comments regarding bfd_read.
594 (ieee_object_p): Similarly.
595 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
596 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
597 input_bfd, output_bfd, output_buffer.
598 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
599 do_with_relocs, ie. as a symbol for relocatable files.
600 (ieee_vec): Add comments showing functions referenced by macros.
601
602 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
603
604 * aout-tic30.c: Add missing prototypes. Fix formatting.
605 * aout-ns32k.c: Add missing prototypes. Fix formatting.
606 * peXXigen.c: Add missining prototypes. Fix formatting.
607 * aout-adobe.c: Add missining prototypes. Fix formatting.
608
609 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
610
611 * elf32-v850.c: Add missing function prototypes.
612 Fix some formatting.
613
614 * cpu-v850.c: Add missing function prototype.
615 Fix some formatting.
616
617 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
618
619 * elf-bfd.h (struct elf_backend_data): Add new fields
620 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
621 (bfd_elf_sprintf_vma): Rename function prototype to
622 '_bfd_elf_sprintf_vma'.
623 (bfd_elf_fprintf_vma): Rename function prototype to
624 '_bfd_elf_fprintf_vma'.
625 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
626 directly, instead indirect via the elf_backend_data structure.
627 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
628 instead indirect via the elf_backend_data structure.
629 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
630 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
631 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
632 already defined.
633 (elf_backend_fprintf_vma): Initialise if not already defined.
634 (struct elf_backend_data): Initialise the
635 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
636
637 2001-08-10 Andreas Jaeger <aj@suse.de>
638
639 * elf64-sparc.c: Add missing prototypes.
640 * elf32-cris.c: Likewise.
641 * elf32-i370.c: Likewise.
642 * elf64-hppa.c: Likewise.
643 * elf64-s390.c: Likewise.
644
645 2001-08-10 Andreas Jaeger <aj@suse.de>
646
647 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
648 Add prototypes where needed.
649
650 2001-08-10 H.J. Lu <hjl@gnu.org>
651
652 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
653 (bfd_fprintf_vma): Likewise.
654
655 2001-08-10 H.J. Lu <hjl@gnu.org>
656
657 * bfd.c (bfd_sprintf_vma): Don't return void.
658 (bfd_fprintf_vma): Likewise.
659
660 2001-08-10 Andreas Jaeger <aj@suse.de>
661
662 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
663 to build warnings.
664 * configure: Regenerate.
665
666 2001-08-10 Alan Modra <amodra@bigpond.net.au>
667
668 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
669 warning if not BFD64. Add braces so emacs auto format works.
670 (bfd_elf_fprintf_vma): Likewise.
671
672 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
673 of _xcoff_swap_ld*.
674 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
675 param to agree with libxcoff.h.
676 (xcoff_swap_ldhdr_out): Likewise.
677 (xcoff_swap_ldsym_in): Likewise.
678 (xcoff_swap_ldsym_out): Likewise.
679 (xcoff_swap_ldrel_in): Likewise.
680 (xcoff_swap_ldrel_out): Likewise.
681 (xcoff_create_csect_from_smclas): Likewise.
682 * coff64-rs6000.c: Add missing prototypes.
683 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
684 with libxcoff.h.
685 (xcoff64_swap_ldhdr_out): Likewise.
686 (xcoff64_swap_ldsym_in): Likewise.
687 (xcoff64_swap_ldsym_out): Likewise.
688 (xcoff64_swap_ldrel_in): Likewise.
689 (xcoff64_swap_ldrel_out): Likewise.
690 (xcoff64_ppc_relocate_section): Make static.
691 (xcoff64_slurp_armap): Likewise.
692 (xcoff64_archive_p): Likewise.
693 (xcoff64_openr_next_archived_file): Likewise.
694 (xcoff64_sizeof_headers): Likewise.
695 (xcoff64_is_lineno_count_overflow): Likewise.
696 (xcoff64_is_reloc_count_overflow): Likewise.
697 (xcoff64_loader_symbol_offset): Likewise.
698 (xcoff64_loader_reloc_offset): Likewise.
699 * elf64-gen.c: Add missing prototypes.
700
701 2001-08-09 H.J. Lu <hjl@gnu.org>
702
703 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
704 (bfd_elf_fprintf_vma): Likewise.
705
706 2001-08-09 H.J. Lu <hjl@gnu.org>
707
708 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
709 to ...
710 * elf-bfd.h: Here.
711 * bfd-in2.h: Regenerated.
712
713 2001-08-09 H.J. Lu <hjl@gnu.org>
714
715 * bfd-in.h (bfd_sprintf_vma): New prototype.
716 (bfd_fprintf_vma): Likewise.
717 (bfd_elf_sprintf_vma): Likewise.
718 (bfd_elf_fprintf_vma): Likewise.
719 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
720 * bfd-in2.h: Regenerated.
721
722 * bfd.c (bfd_sprintf_vma): New. Defined.
723 (bfd_fprintf_vma): Likewise.
724
725 * elf.c (bfd_elf_sprintf_vma): New. Defined.
726 (bfd_elf_fprintf_vma): Likewise.
727
728 2001-08-09 Alan Modra <amodra@bigpond.net.au>
729
730 * coff-rs6000.c: Add missing prototypes.
731 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
732 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
733 xcoff_loader_reloc_offset): Make static.
734 * dwarf1.c: Add missing prototypes.
735 * dwarf2.c: Add missing prototypes.
736 (struct abbrev_info): Move definition.
737 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
738 * elf.c: Add missing prototypes.
739 * elf32-gen.c: Likewise.
740 * elf32-i386.c: Likewise.
741 * elf32-ppc.c: Likewise.
742 (ppc_elf_sort_rela): Use PTR instead of "void *".
743 * elflink.h: Add missing prototypes. Formatting fixes.
744 * merge.c: Add missing prototypes.
745 (last4_eq): Use PTR instead of "void *".
746 (last_eq): Likewise.
747 * syms.c: Add missing prototypes.
748
749 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
750
751 * bfd.c: Fix formatting.
752 * bfd-in2.h: Regenerate.
753
754 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
755
756 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
757 true (this target uses REL relocations) and 'pcrel_offset' to
758 false (the PC is implied, not stored in the offset).
759
760 2001-08-08 Alan Modra <amodra@bigpond.net.au>
761
762 1999-10-19 Linus Nordberg <linus@swox.se>
763 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
764 * elfxx-target.h (elf_backend_want_got_sym): Define.
765 (elfNN_bed): Add elf_backend_want_got_sym.
766 * elflink.c (_bfd_elf_create_got_section): Define
767 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
768
769 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
770
771 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
772 (find_rela_addend): New function.
773 (parse_comp_unit): Call it to find the abbrev offset addend.
774 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
775 members of dwarf2_debug as debugging information is read.
776
777 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
778
779 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
780 targets as well as sh-pe.
781
782 2001-08-03 Ben Harris <bjh21@netbsd.org>
783
784 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
785 reloc from start of section when computing value for R_ARM_REL32
786 reloc.
787
788 2001-08-03 Alan Modra <amodra@bigpond.net.au>
789
790 From H.J. Lu <hjl@gnu.org>
791 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
792 keep relocs for undefined syms if there are no dynamic sections in
793 executable.
794 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
795
796 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
797
798 * cofflink.c (coff_link_check_ar_symbols): also search for
799 __imp__symbol as well as _symbol.
800 * linker.c (_bfd_generic_link_add_archive_symbols): also
801 search for __imp__symbol as well as _symbol.
802
803 2001-08-01 Adam Nemet <anemet@lnxw.com>
804
805 * elf.c (elf_sort_sections): Return zero only as the last step.
806
807 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
808
809 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
810 ARM_COFF_BUGFIX.
811 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
812 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
813 ARM_COFF_BUGFIX.
814
815 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
816
817 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
818 to match corresponding bfd_coff_backend data member.
819
820 2001-07-24 Alan Modra <amodra@bigpond.net.au>
821
822 * Makefile.am: Update dependencies with "make dep-am".
823 * Makefile.in: Regenerate
824
825 2001-07-15 H.J. Lu <hjl@gnu.org>
826
827 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
828 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
829 * Makefile.in: Regenerate.
830
831 2001-07-11 H.J. Lu <hjl@gnu.org>
832
833 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
834 flags when creating the reloc section if the ALLOC flag in the
835 source section is set.
836
837 2001-07-11 Steve Ellcey <sje@cup.hp.com>
838
839 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
840 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
841 * bfd-in2.h: Regenerate.
842 * libbfd.h: Regenerate.
843 * elfxx-ia64.c (ia64_howto_table): Define how to handle
844 new relocations.
845 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
846 (elfNN_ia64_check_relocs): Likewise.
847 (elfNN_ia64_install_value): Likewise.
848 (elfNN_ia64_relocate_section): Likewise.
849
850 2001-07-11 Jakub Jelinek <jakub@redhat.com>
851
852 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
853 R_SPARC_UA64.
854 (elf32_sparc_check_relocs): Likewise.
855 Only create .rela section for alloced sections in shared libraries.
856 (elf32_sparc_relocate_section): Likewise.
857 Remove redundant check.
858 Optimize unaligned reloc usage.
859 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
860 check.
861
862 2001-07-11 H.J. Lu <hjl@gnu.org>
863
864 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
865 ALLOC|LOAD flags as the source section for debugging sections
866 when creating the reloc section.
867
868 2001-07-05 Jim Wilson <wilson@redhat.com>
869
870 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
871 the section of the bigger symbol.
872
873 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
874
875 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
876
877 * peicode.h (coff_swap_scnhdr_in): For sections containing
878 uninitialised data, only set their size to s_paddr if this does
879 not reset their size to zero. MS's latest compilers will set
880 s_paddr to zero.
881
882 2001-07-04 H.J. Lu <hjl@gnu.org>
883
884 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
885 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
886 bfd_mach_mips5000.
887
888 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
889
890 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
891
892 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
893 sections being discarded.
894
895 2001-06-30 Alan Modra <amodra@bigpond.net.au>
896
897 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
898 instead of _bfd_elfcore_section_from_phdr.
899 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
900 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
901 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
902 (elfcore_grok_prstatus): Likewise.
903 (elfcore_grok_lwpstatus): Likewise.
904 (bfd_get_elf_phdr_upper_bound): Likewise.
905 (elfcore_make_note_pseudosection): Formatting.
906 (_bfd_elfcore_strndup): Formatting.
907 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
908 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
909
910 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
911
912 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
913 and _bfd_elfcore_strndup.
914 (struct elf_backend_data): Add elf_backend_grok_prstatus
915 and elf_backend_grok_psinfo.
916 * elf.c (_bfd_elfcore_make_pseudosection): New function.
917 (elfcore_grok_prstatus): Use it.
918 (elfcore_make_note_pseudosection): Likewise.
919 (elfcore_strndup): Rename to...
920 (_bfd_elfcore_strndup): Here, and make global.
921 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
922 (elfcore_grok_note): Call elf_backend_grok_prstatus
923 and elf_backend_grok_psinfo if available.
924 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
925 (_bfd_elf32_mips_grok_psinfo): New function.
926 (elf_backend_grok_prstatus): Define.
927 (elf_backend_grok_psinfo): Define.
928 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
929 (elf_backend_grok_psinfo): Likewise.
930 (elfNN_bed): Include elf_backend_grok_prstatus and
931 elf_backend_grok_psinfo.
932
933 2001-06-29 H.J. Lu <hjl@gnu.org>
934
935 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
936 hplink->sgot is NULL before filling GOT. Check if hplink->splt
937 is NULL before filling PLT.
938
939 2001-06-29 Alan Modra <amodra@bigpond.net.au>
940
941 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
942
943 2001-06-27 Alan Modra <amodra@bigpond.net.au>
944
945 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
946 here..
947 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
948 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
949 after gc has run.
950
951 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
952 (IS_ABSOLUTE_RELOC): Define.
953 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
954 (hppa_link_hash_newfunc): Always init it.
955 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
956 create COPY relocs only when the reloc is in a read-only section.
957 Instead, allocate space for a dynamic reloc to reference the
958 library symbol directly. Keep track of space we allocate using
959 relocs_entries.
960 (hppa_discard_copies): Delete, and move code to..
961 (allocate_plt_and_got): ..here. Rename to
962 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
963 relocs for non-shared link.
964 (elf32_hppa_size_dynamic_sections): Update calls to above.
965 (elf32_hppa_relocate_section): Write out the dynamic relocs used
966 in lieu of COPY relocs.
967
968 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
969 here..
970 (elf_i386_adjust_dynamic_symbol): ..nor here..
971 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
972 after gc has run.
973 (elf_i386_size_dynamic_sections): Fix a comment.
974 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
975 involved in writing reloc out.
976
977 2001-06-25 Alan Modra <amodra@bigpond.net.au>
978
979 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
980 Ensure syms are dynamic if we might be emitting a reloc.
981 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
982 for undefweak or undefined syms..
983 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
984
985 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
986 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
987 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
988 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
989
990 2001-06-24 H.J. Lu <hjl@gnu.org>
991
992 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
993 strncasecmp/strcasecmp instead of strncmp/strcmp.
994
995 2001-06-23 H.J. Lu <hjl@gnu.org>
996
997 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
998 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
999 in the regular object file and treat the weak definition as
1000 the normal one.
1001
1002 2001-06-23 Alan Modra <amodra@bigpond.net.au>
1003
1004 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
1005 unresolved_reloc test to exclude cases where we use "relocation"
1006 before setting it to point into the .got. Reinstate fudge for
1007 unresolved relocs in debugging sections.
1008
1009 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
1010 complicated tests for unresolvable relocs with a simple direct
1011 scheme using "unresolved_reloc" var.
1012
1013 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
1014 elf_i386_dyn_relocs. Update comment.
1015 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
1016 dyn_relocs.
1017 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
1018 others to aborts.
1019 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
1020 abort.
1021 (elf_i386_size_dynamic_sections): Likewise.
1022 (elf_i386_finish_dynamic_symbol): Likewise.
1023 (elf_i386_finish_dynamic_sections): Likewise.
1024 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
1025 handling code.
1026
1027 Avoid creating COPY relocs if possible.
1028 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
1029 which .got created. Mark symbols used by R_386_32 and R_386_PC32
1030 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
1031 reloc is in a read-only section. Instead, allocate space for a
1032 dynamic reloc to reference the library symbol directly. Keep
1033 track of space we allocate using pcrel_relocs_copied.
1034 (discard_copies): Delete, and move code to ..
1035 (allocate_plt_and_got): ..here. Rename to
1036 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
1037 relocs for non-shared link.
1038 (elf_i386_size_dynamic_sections): Update calls to above functions.
1039 (elf_i386_relocate_section): Write out the dynamic relocs. Add
1040 more ugly logic to avoid "unresolvable relocation" error. Use
1041 htab shortcut in place of elf_hash_table macro.
1042 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
1043 not always be created now.
1044
1045 2001-06-20 Bo Thorsen <bo@suse.co.uk>
1046
1047 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
1048 shared libraries.
1049
1050 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1051
1052 * configure.host (mips64-*-linux): Reformat.
1053
1054 2001-06-21 Alan Modra <amodra@bigpond.net.au>
1055
1056 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
1057 allocate local .got space. Use shortcuts from hash table for .got
1058 and .plt rather than comparing section names.
1059 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
1060 adjusting index into local_got_refcounts to document what we are
1061 really doing.
1062 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
1063 Tidy .got and .plt error checking.
1064
1065 2001-06-20 Catherine Moore <clm@redhat.com>
1066
1067 * elf-bfd.h (struct elf_backend_data):
1068 elf_backend_emit_relocs: New field: Function for emitting
1069 relocs.
1070 elf_backend_count_relocs: New field: Function for determining
1071 the number of relocs to be emitted.
1072 * elfxx-target.h: Provide default (NULL) values for
1073 elf_backend_emit_relocs and elf_backend_count_relocs.
1074 * elflink.h (elf_link_size_reloc_section): Make the hash table
1075 big enough to hold the relocs counted by either reloc_count or
1076 o->reloc_count.
1077 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
1078 should be emitted, either because of a command line option
1079 stored in the info structure or because the target provides a
1080 special reloc emitting function.
1081 If the target provides a reloc counting function use it,
1082 unless performing a relocatable link or emitting all relocs.
1083 Also set the SEC_RELOC flag on any output section which will
1084 contain relocs.
1085 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
1086 should be emitted, either because of a command line option
1087 stored in the info structure or because the target provides a
1088 special reloc emitting function.
1089 If the target provides a reloc emitting function, use it,
1090 unless performing a relocatable link or emitting all relocs.
1091
1092 2001-06-20 H.J. Lu <hjl@gnu.org>
1093
1094 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
1095 allocate local .got space.
1096
1097 2001-06-19 Andreas Jaeger <aj@suse.de>
1098
1099 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
1100 dynamic symbols.
1101
1102 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
1103
1104 * elflink.h (struct elf_assign_sym_version_info): Remove member
1105 export_dynamic. All users changed to use info member.
1106 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
1107 export_dynamic, instead use member in parameter info.
1108 * bfd-in.h (bfd_elf32_size_dynamic_sections,
1109 bfd_elf64_size_dynamic_sections): Update prototype.
1110 * bfd-in2.h: Regenerate.
1111
1112 2001-06-18 H.J. Lu <hjl@gnu.org>
1113
1114 * elflink.h (elf_info_failed): Add a new field, verdefs.
1115 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
1116 elf_export_symbol.
1117 (elf_export_symbol): Check eif->verdefs to decide if a symbol
1118 should be exported.
1119
1120 2001-06-17 H.J. Lu <hjl@gnu.org>
1121
1122 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
1123 readonly_reloc, to record if a relocation in the .rel.dyn
1124 section is against a read-only section.
1125 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
1126 field to false.
1127 (_bfd_mips_elf_check_relocs): Record if there is a relocation
1128 in the .rel.dyn section against a read-only section by setting
1129 DF_TEXTREL or readonly_reloc.
1130 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
1131 it is true.
1132 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
1133 there is a relocation in the .rel.dyn section against a
1134 read-only section.
1135 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
1136 DF_TEXTREL is set.
1137
1138 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
1139
1140 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
1141 function. Move flagword result into parameter list. Remove
1142 comment about setting bfd_error_handler to intercept failure
1143 results.
1144 * coffgen.c (make_a_section_from_file): Examine result of
1145 calling bfd_coff_styp_to_sec_flags and pass a failure back to
1146 caller.
1147 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
1148 function. Move flagword result into parameter list.
1149 * libcoff.h: Regenerate.
1150 * libecoff.h: Regenerate.
1151
1152 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
1153
1154 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
1155 section is going to follow it.
1156
1157 2001-06-12 Catherine Moore <clm@redhat.com>
1158
1159 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
1160 with the file_align entry from elf_backend_data.
1161 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1162 (elf_gc_record_vtentry): Likewise.
1163
1164 2001-06-10 Alan Modra <amodra@bigpond.net.au>
1165
1166 * elflink.h: Whitespace changes.
1167 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
1168 rather than "unsigned char".
1169 (elf_link_output_relocs): Likewise.
1170 (elf_link_input_bfd): Likewise.
1171 (elf_reloc_link_order): LIkewise.
1172 * elf.c: s/CONST/const/. Whitespace changes.
1173 * elf32-mips.c: Formatting fix.
1174
1175 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
1176 * Makefile.in: Regenerate.
1177 * po/Make-in: Remove trailing tab.
1178
1179 2001-06-09 Philip Blundell <philb@gnu.org>
1180
1181 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
1182 change.
1183 (elf32_arm_plt_entry): Likewise.
1184
1185 2001-06-08 H.J. Lu <hjl@gnu.org>
1186
1187 * elf.c (swap_out_syms): Keep names for global section symbols.
1188
1189 2001-06-07 H.J. Lu <hjl@gnu.org>
1190
1191 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
1192 MIPS-based machines need it.
1193
1194 2001-06-07 H.J. Lu <hjl@gnu.org>
1195
1196 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
1197 for SGI only.
1198
1199 * config.bfd: Remove ecoff from Linux/mips.
1200
1201 2001-06-07 Andreas Jaeger <aj@suse.de>
1202
1203 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
1204 assertion.
1205 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
1206 alignment of 8 for .rela sections; handle further relocations.
1207
1208 2001-06-06 Christian Groessler <cpg@aladdin.de>
1209
1210 * coff-z8k.c: Fix formatting.
1211 Fix howtos: howto->size was always 1.
1212
1213 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1214
1215 * configure.host (mips64*-*-linux*): Define.
1216
1217 2001-06-05 Alan Modra <amodra@bigpond.net.au>
1218
1219 * elf32-i386.c (elf_i386_discard_copies): Rename to
1220 discard_copies, and use elf_link_hash_entry arg rather than
1221 elf_i386_link_hash_entry.
1222 (elf_i386_link_hash_traverse): Delete.
1223 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
1224 Tidy sizing of dynamic sections.
1225 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
1226 possible .plt entries.
1227 (elf_i386_gc_sweep_hook): Likewise.
1228 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
1229 everything with plt.refcount <= 0.
1230
1231 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
1232 .relgot space here.
1233 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
1234 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
1235 .rel.plt here..
1236 (allocate_plt_and_got): ..instead do it all here. New function.
1237 (elf_i386_size_dynamic_sections): Allocate local .got space and
1238 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
1239 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
1240 rather than gc variety).
1241 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
1242 (elf_i386_relocate_section): Use it here and correct handling of
1243 R_386_GOT32. Provide section and offset for "unresolvable
1244 relocation" error message.
1245 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
1246
1247 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
1248 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
1249 (elf_i386_link_hash_table_create): Init them.
1250 (create_got_section): New function.
1251 (elf_i386_create_dynamic_sections): New function.
1252 (elf_backend_create_dynamic_sections): Set to above.
1253 (elf_i386_check_relocs): Use shortcuts from hash table rather than
1254 calling bfd_get_section_by_name.
1255 (elf_i386_gc_sweep_hook): Likewise.
1256 (elf_i386_adjust_dynamic_symbol): Likewise.
1257 (elf_i386_size_dynamic_sections): Likewise.
1258 (elf_i386_relocate_section): Likewise.
1259 (elf_i386_finish_dynamic_sections): Likewise.
1260
1261 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
1262
1263 2001-06-02 H.J. Lu <hjl@gnu.org>
1264
1265 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
1266 and ELFOSABI_HPUX.
1267 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
1268
1269 2001-06-02 H.J. Lu <hjl@gnu.org>
1270
1271 * aout-cris.c (MACHTYPE_OK): New. Defined.
1272
1273 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
1274
1275 * section.c (_bfd_strip_section_from_output): Handle NULL
1276 output_section.
1277
1278 2001-06-02 H.J. Lu <hjl@gnu.org>
1279
1280 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
1281 rs6000coff64_vec only if BFD64 is defined.
1282 (powerpc64-*-aix*): Enable only if BFD64 is defined.
1283
1284 2001-06-02 H.J. Lu <hjl@gnu.org>
1285
1286 * coff-ia64.c (ia64coff_object_p): Rewrite with
1287 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
1288
1289 2001-06-01 Andreas Jaeger <aj@suse.de>
1290
1291 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
1292 relocation, small reformatting.
1293
1294 2001-05-29 Andreas Jaeger <aj@suse.de>
1295
1296 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
1297 (elf64_x86_64_relocate_section): Likewise.
1298
1299 2001-05-30 Alan Modra <amodra@one.net.au>
1300
1301 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
1302 millicode. Don't allocate .got and .rela.got space here..
1303 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
1304 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
1305 .rela.plt here..
1306 (hppa_handle_PIC_calls): ..nor here..
1307 (allocate_plt_and_got): ..instead do it all here. New function.
1308 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
1309 call allocate_plt_and_got. No need to zap .got if not dynamic.
1310 (elf32_hppa_final_link): Call regular bfd_final_link instead of
1311 gc_common_final_link.
1312 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
1313 (elf32_hppa_relocate_section): Use it here.
1314 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
1315 dynamic_sections_created.
1316 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
1317
1318 2001-05-28 Andreas Jaeger <aj@suse.de>
1319
1320 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
1321 generic version since we want a hashsize of 4.
1322 (elf_backend_size_info): Likewise.
1323
1324 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1325
1326 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
1327 a zeroing loop.
1328 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
1329 (elf_link_input_bfd): Likewise.
1330 (elf_reloc_link_order): Likewise.
1331 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
1332 relocations correctly.
1333
1334 2001-05-28 Nicolas Pitre <nico@cam.org>
1335
1336 * elf32-arm.h: fix PLT generation for big endian ARM
1337
1338 2001-05-28 Alan Modra <amodra@one.net.au>
1339
1340 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
1341 for symbols forced local that need plabels.
1342 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
1343 .plt.rela for local syms if non-shared.
1344 (hppa_build_one_stub): Mask lsb of plt.offset.
1345 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
1346 (clobber_millicode_symbols): Correct comment.
1347 (elf32_hppa_relocate_section): Likewise.
1348 (elf32_hppa_finish_dynamic_symbol): Likewise.
1349
1350 2001-05-28 Jeff Sturm <jsturm@one-point.com>
1351
1352 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
1353 * bfd-in2.h: Regenerate.
1354 * libbfd.h: Regenerate.
1355 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
1356 and BFD_RELOC_SPARC_UA64 mapping
1357 * elf64-sparc.c: Likewise.
1358
1359 2001-05-25 H.J. Lu <hjl@gnu.org>
1360
1361 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
1362 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
1363 (coff-rs6000.lo): Remove the old dependency.
1364 * Makefile.in: Rebuild.
1365
1366 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
1367 coff-rs6000.lo.
1368
1369 2001-05-25 H.J. Lu <hjl@gnu.org>
1370
1371 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
1372 rs6000coff_core_file_matches_executable_p,
1373 rs6000coff_core_file_failing_command and
1374 rs6000coff_core_file_failing_signal only if AIX_CORE is
1375 defined.
1376 (pmac_xcoff_vec): Likewise.
1377 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
1378
1379 2001-05-25 Timothy Wall <twall@redhat.com>
1380
1381 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
1382 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
1383
1384 2001-05-25 H.J. Lu <hjl@gnu.org>
1385
1386 * bfd-in2.h: Regenerated.
1387 * libcoff.h: Likewise.
1388
1389 2001-05-25 Alan Modra <amodra@one.net.au>
1390
1391 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
1392 undefined millicode syms in shared libs.
1393 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
1394 (elf32_hppa_check_relocs): Likewise.
1395 (elf32_hppa_adjust_dynamic_symbol): Likewise.
1396 (elf32_hppa_size_dynamic_sections): Likewise.
1397 (elf32_hppa_relocate_section): Likewise.
1398 (elf32_hppa_finish_dynamic_symbol): Likewise.
1399 (elf32_hppa_finish_dynamic_sections): Likewise.
1400
1401 2001-05-24 Tom Rix <trix@redhat.com>
1402
1403 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
1404 xcoff-target.h not used to define rs6000 or ppc bfd.
1405 * Makefile.in same
1406
1407 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
1408 to 64 bit.
1409
1410 * coff-rs6000.c : Many changes for 64 bit support. Move common
1411 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
1412 and pmac_xcoff_vec
1413
1414 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
1415 linker now supported. Explictly define the rs6000coff64_vec.
1416
1417 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
1418 (coff_print_aux) same
1419 (coff_write_object_contents) same
1420 (coff_slurp_line_table) same
1421
1422 * coffgen.c : (coff_fix_symbol_name) formatting
1423 (coff_mangle_symbols) xcoff 64 bit support
1424 (coff_write_symbol) same
1425 (coff_write_alien_symbol) same
1426 (coff_write_native_symbol) same
1427 (coff_write_symbols) same
1428 (coff_get_symbol_info) same
1429 (bfd_coff_get_syment) same
1430 (coff_print_symbol) same
1431
1432 * config.bfd : add powerpc64-*-aix* target
1433
1434 * libcoff-in.h : formatting
1435
1436 * libcoff.h : move xcoff extern declarations to libxcoff.h
1437
1438 * libxcoff.h : New file
1439
1440 * xcofflink.c : Many changes for xcoff64 support. Move common
1441 structures to include/coff/xcoff.h. Move specific structure to
1442 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
1443 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
1444
1445 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
1446 aix4.2+ -binitfini.
1447
1448 (xcoff_build_ldsyms) : handle special __rtinit symbol.
1449
1450 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
1451
1452 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
1453 s/ENTIRES/ENTRIES/.
1454
1455 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1456
1457 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
1458 * libbfd.h: Regenerate.
1459 * bfd-in2.h: Regenerate.
1460
1461 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
1462 * archures.c (bfd_mach_mips12000): Define.
1463 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
1464 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
1465 support.
1466 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
1467 * bfd-in2.h: Regenerate.
1468 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
1469
1470 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
1471
1472 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
1473 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
1474 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
1475 that is used by GCC.
1476
1477 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
1478
1479 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
1480 of entries in a structured section.
1481 * elf.c: Use new macro.
1482 * elf32-i386.c: Use new macro.
1483 * elf32-mips.c: Use new macro.
1484 * elf64-alpha.c: Use new macro.
1485 * elf64-sparc.c: Use new macro.
1486 * elfcode.h: Use new macro.
1487 * elflink.h: Use new macro.
1488
1489 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
1490
1491 * bfdint.texi: Replace -oformat with --oformat.
1492
1493 2001-05-21 Andreas Jaeger <aj@suse.de>
1494
1495 * dwarf2.c (decode_line_info): Fix error message.
1496 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
1497 adjust error message.
1498
1499 2001-05-18 H.J. Lu <hjl@gnu.org>
1500
1501 * elflink.h (elf_link_add_object_symbols): Revert the last
1502 change.
1503
1504 2001-05-17 Alan Modra <amodra@one.net.au>
1505
1506 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
1507 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
1508 (hppa_build_one_stub): Add an assert to check plt.offset.
1509
1510 2001-05-17 H.J. Lu <hjl@gnu.org>
1511
1512 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
1513 version definition to basename of the output filename.
1514
1515 2001-05-17 H.J. Lu <hjl@gnu.org>
1516
1517 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
1518 basename of the bfd filename.
1519
1520 2001-05-16 Alan Modra <amodra@one.net.au>
1521
1522 * section.c (asection): Add linker_has_input field.
1523 (STD_SECTION): Adjust initialization to suit.
1524 * ecoff.c (bfd_debug_section): Likewise.
1525 * bfd-in2.h: Regenerate.
1526
1527 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
1528
1529 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
1530 negative 32-bit operands to 16 operands when the operand is
1531 going to be zero-extended by the modified opcode.
1532
1533 2001-05-12 Peter Targett <peter.targett@arccores.com>
1534
1535 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
1536 name for 'arc5' core versions.
1537 (bfd_arc_arch): Make bfd_mach_arc_6 default.
1538
1539 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
1540 architecture.
1541 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
1542
1543 2001-05-11 Jakub Jelinek <jakub@redhat.com>
1544
1545 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
1546 sections as well.
1547 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
1548 to .gnu.linkonce.t.FOO text section.
1549
1550 2001-05-11 Jakub Jelinek <jakub@redhat.com>
1551
1552 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
1553 fields, change sec into secinfo.
1554 (struct sec_merge_info): Add chain, remove last fields.
1555 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
1556 (sec_merge_hash_lookup): If lookup could not use a string only
1557 because it has bad alignment, mark the old string for deletion.
1558 (sec_merge_add): Add secinfo argument. Don't compute entry's
1559 position, instead record the section.
1560 (sec_merge_emit): Update for the sec into secinfo change in
1561 struct sec_merge_hash_entry.
1562 (_bfd_merge_section): Only record the section for merging, defer
1563 putting strings into the hash table.
1564 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
1565 _bfd_merge_sections): New functions.
1566 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
1567 changes.
1568 * libbfd-in.h (_bfd_merge_sections): Add prototype.
1569 (_bfd_nolink_bfd_merge_sections): Define.
1570 * libbfd.h: Likewise.
1571 (bfd_generic_merge_sections): Add prototype.
1572 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
1573 (struct bfd_target): Likewise.
1574 * bfd.c (bfd_merge_sections): Define.
1575 * bfd-in2.h: Rebuilt.
1576 * elf.c (_bfd_elf_merge_sections): New function.
1577 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
1578 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
1579 * reloc.c (bfd_generic_merge_sections): New function.
1580 * vms.c (vms_bfd_merge_sections): New function.
1581 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
1582 * aout-target.h (MY_bfd_merge_sections): Define.
1583 * aout-tic30.c (MY_bfd_merge_sections): Define.
1584 * binary.c (binary_bfd_merge_sections): Define.
1585 * bout.c (b_out_bfd_merge_sections): Define.
1586 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
1587 * coffcode.c (coff_bfd_merge_sections): Define.
1588 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
1589 * i386msdos.c (msdos_bfd_merge_sections): Define.
1590 * i386os9k.c (os9k_bfd_merge_sections): Define.
1591 * ieee.c (ieee_bfd_merge_sections): Define.
1592 * ihex.c (ihex_bfd_merge_sections): Define.
1593 * nlm-target.h (nlm_bfd_merge_sections): Define.
1594 * oasys.c (oasys_bfd_merge_sections): Define.
1595 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
1596 * som.c (som_bfd_merge_sections): Define.
1597 * srec.c (srec_bfd_merge_sections): Define.
1598 * tekhex.c (tekhex_bfd_merge_sections): Define.
1599 * versados.c (versados_bfd_merge_sections): Define.
1600 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
1601
1602 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
1603
1604 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
1605 to be unsigned long, in order to match its use.
1606
1607 2001-05-10 H.J. Lu <hjl@gnu.org>
1608
1609 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
1610 indirect symbols.
1611
1612 2001-05-09 H.J. Lu <hjl@gnu.org>
1613
1614 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
1615 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
1616 Remove the unused veriable `dynver'.
1617
1618 2001-05-08 Ian Lance Taylor <ian@zembu.com>
1619
1620 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
1621 NULL or is not COFF.
1622 (coff_i386_rtype_to_howto): Don't dump core if output section
1623 owner is not COFF.
1624
1625 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1626
1627 * ecoff.c (bfd_debug_section): Fix initialization.
1628 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
1629 is always a positive integer. Cast away sign mismatch.
1630 * elf32-mips.c: Fix misleading comment and typo.
1631 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
1632 correct data type.
1633 * elflink.c: Fix typo.
1634 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
1635 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
1636
1637 2001-05-04 Richard Henderson <rth@redhat.com>
1638
1639 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
1640
1641 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
1642
1643 * elf32-arm.h (elf32_arm_final_link_relocate): Set
1644 EF_ARM_HASENTRY if the start address is set.
1645
1646 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
1647
1648 * targets.c (_bfd_target_vector_entries): Compute value based on
1649 the size of the _bfd_target_vector and not bfd_target_vector.
1650
1651 2001-05-03 H.J. Lu <hjl@gnu.org>
1652
1653 * elfcode.h: Include "libiberty.h".
1654
1655 * elflink.h (elf_link_add_object_symbols): Set
1656 elf_dt_name (abfd) to basename of the bfd filename.
1657 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
1658 of the bfd filename.
1659
1660 2001-05-03 Andreas Jaeger <aj@suse.de>
1661
1662 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
1663 (elf_generic_info_to_howto_rel): Likewise.
1664 * coff-alpha.c (reloc_nil): Likewise.
1665 (alpha_ecoff_bad_format_hook): Likewise.
1666 (alpha_adjust_reloc_out): Likewise.
1667 (alpha_bfd_reloc_type_lookup): Likewise.
1668 (alpha_convert_external_reloc): Likewise.
1669 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
1670 (elf64_alpha_reloc_bad): Likewise.
1671 (elf64_alpha_reloc_gpdisp): Likewise.
1672 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
1673 (elf64_alpha_info_to_howto): Likewise.
1674 (elf64_alpha_add_symbol_hook): Likewise.
1675 (elf64_alpha_create_got_section): Likewise.
1676 (elf64_alpha_is_local_label_name): Likewise.
1677 (elf64_alpha_merge_ind_symbols): Likewise.
1678 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
1679 (mips_elf64_get_reloc_upper_bound): Likewise.
1680 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
1681 (nlm_alpha_get_public_offset): Likewise.
1682
1683 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
1684
1685 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
1686 about overflow in R_OPENRISC_LO_16_IN_INSN and
1687 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
1688
1689 2001-04-30 H.J. Lu <hjl@gnu.org>
1690
1691 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
1692 only for ELF_LINK_FORCED_LOCAL.
1693 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
1694 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
1695 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
1696
1697 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
1698 if the symbol has hidden or internal visibility.
1699
1700 2001-04-30 Alan Modra <amodra@one.net.au>
1701
1702 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
1703 calls to undefined weak symbols.
1704
1705 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
1706
1707 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
1708 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
1709
1710 2001-04-27 Andreas Jaeger <aj@suse.de>
1711
1712 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
1713 out handled entries.
1714 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
1715 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
1716 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
1717 GOT32.
1718
1719 2001-04-27 Sean McNeil <sean@mcneil.com>
1720
1721 * config.bfd: Add arm-vxworks target.
1722 * coff-arm (coff_arm_relocate_section): Add in symbol value to
1723 addend (fro VXworks targets).
1724
1725 2001-04-26 H.J. Lu <hjl@gnu.org>
1726
1727 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
1728 valid.
1729
1730 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
1731
1732 * bfd-in.h (bfd_cache_close): Declare newly exported function.
1733 * bfd-in2.h: Regenerated.
1734
1735 2001-04-24 Jakub Jelinek <jakub@redhat.com>
1736
1737 * merge.c (struct sec_merge_hash_entry): Add alignment field.
1738 (struct sec_merge_hash): Remove alignment_power.
1739 (sec_merge_hash_newfunc): Clear alignment.
1740 (sec_merge_hash_lookup): Pass alignment as argument.
1741 Use hashp->root.next, not hashp->next to walk the hash chain.
1742 If a string already in the hashtable does not have required
1743 alignment, create a new hashtable entry.
1744 (sec_merge_init): Remove alignment_power argument.
1745 (sec_merge_add): Add alignment argument.
1746 (sec_merge_emit): Alignment is now a per-entity thing, not per
1747 section.
1748 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
1749 for proper alignment.
1750 Pass alignment information to sec_merge_add.
1751
1752 2001-04-24 Christian Groessler <cpg@aladdin.de>
1753
1754 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
1755 and R_REL16 reloc types; accept odd values for R_REL16 type
1756
1757 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
1758
1759 * cpu-openrisc.c: New file.
1760 * elf32-openrisc.c: Likewise.
1761
1762 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
1763 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
1764 (BFD32_BACKENDS): Add elf32-openrisc.lo.
1765 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
1766 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
1767 * Makefile.in: Regenerated.
1768 * config.bfd: (openrisc-*-elf): New target.
1769 * configure.in (bfd_elf32_openrisc_vec): New vector.
1770 * configure: Regenerated.
1771 * libbfd.h: Regenerated.
1772 * bfd-in2.h: Regenerated.
1773 * reloc.c: Add OpenRISC relocations.
1774 * targets.c (bfd_elf32_openrisc_vec): Declare.
1775 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
1776 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
1777 (bfd_openrisc_arch): Declare.
1778 (bfd_archures_list): Add bfd_openrisc_arch.
1779 * elf.c (prep_headers): Add bfd_arch_openrisc.
1780
1781 2001-04-23 Bo Thorsen <bo@suse.de>
1782
1783 * elf64-x86-64.c: Add c++ vtable hack.
1784 Small whitespace and comment changes.
1785
1786 2001-04-19 Andreas Jaeger <aj@suse.de>
1787
1788 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
1789 (elf64_x86_64_plt_entry): Likewise.
1790 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
1791 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
1792
1793 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
1794
1795 * elf32-cris.c: Tweak comments related to dynamic linking.
1796 (cris_elf_relocate_section): When not creating shared object, fill
1797 in the .got table for any symbol not in the dynamic symbol table.
1798 (elf_cris_finish_dynamic_symbol): When not creating shared object,
1799 only emit a .got.rela reloc if the symbol is in the dynamic symbol
1800 table.
1801 (cris_elf_check_relocs): Use variable r_type in all places rather
1802 than the original expression. Add default case in switch for
1803 reloc types.
1804 (elf_cris_size_dynamic_sections): Iterate over
1805 elf_cris_discard_excess_program_dynamics when not creating shared
1806 library.
1807 (elf_cris_discard_excess_dso_dynamics): Renamed from
1808 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
1809 (elf_cris_discard_excess_program_dynamics): New.
1810
1811 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
1812
1813 * coffcode.h (coff_write_object_contents): Use
1814 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
1815
1816 2001-04-14 H.J. Lu <hjl@gnu.org>
1817
1818 * bfd-in2.h: Regenerate.
1819
1820 2001-04-14 Jakub Jelinek <jakub@redhat.com>
1821
1822 * section.c (STD_SECTION): Add entsize.
1823
1824 2001-04-13 H.J. Lu <hjl@gnu.org>
1825
1826 * section.c (SEC_MERGE): Define new flag for merging.
1827 (SEC_STRINGS): Likewise.
1828 (entsize): New field.
1829
1830 2001-04-13 Roger Sayle <roger@metaphorics.com>
1831
1832 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
1833 flag on pe-i386 targets.
1834
1835 2001-04-13 Jakub Jelinek <jakub@redhat.com>
1836
1837 * libbfd-in.h (_bfd_merge_section): New.
1838 (_bfd_write_merged_section): New.
1839 (_bfd_merged_section_offset): New.
1840 * libbfd.h: Rebuilt.
1841 * linker.c (_bfd_generic_link_output_symbols): Handle
1842 discard_sec_merge.
1843 * aoutx.h (aout_link_write_symbols): Likewise.
1844 * pdp11.c (aout_link_write_symbols): Likewise.
1845 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
1846 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
1847 sections.
1848 (elf_link_sec_merge_syms): New.
1849 (elf_link_input_bfd): Call _bfd_merged_section_offset
1850 and _bfd_write_merged_section.
1851 Handle discard_sec_merge.
1852 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
1853 field.
1854 (struct bfd_elf_section_data): Likewise.
1855 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
1856 SEC_STRINGS section flags and entsize from their ELF counterparts.
1857 (_bfd_elf_link_hash_table_init): Initialize merge_info.
1858 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
1859 from their BFD counterparts.
1860 * merge.c: New file.
1861 * Makefile.am: Add strtab.lo.
1862 * Makefile.in: Rebuilt.
1863
1864 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
1865
1866 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
1867 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
1868
1869 2001-04-05 Steven J. Hill <sjhill@cotw.com>
1870
1871 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
1872 endian MIPS ELF target.
1873 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
1874 MIPS ELF target.
1875
1876 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
1877 64bit big endian MIPS ELF target.
1878 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
1879 endian MIPS ELF target.
1880 * configure: Regenerated.
1881
1882 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
1883 little endian targets.
1884 (mips_elf_sym_is_global): Handle traditional targets.
1885
1886 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
1887 64bit big endian MIPS ELF target.
1888 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
1889 endian MIPS ELF target.
1890
1891 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
1892 and bfd_elf64_tradlittlemips_vec.
1893
1894 2001-04-05 David Mosberger <davidm@hpl.hp.com>
1895
1896 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
1897 ordinary "progbits" section.
1898
1899 2001-04-04 Alan Modra <alan@linuxcare.com.au>
1900
1901 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
1902 when -Bsymbolic causes a symbol to no longer need a .plt entry.
1903
1904 2001-04-03 David Mosberger <davidm@hpl.hp.com>
1905
1906 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
1907
1908 2001-03-30 H.J. Lu <hjl@gnu.org>
1909
1910 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
1911 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
1912
1913 2001-03-26 H.J. Lu <hjl@gnu.org>
1914
1915 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
1916 if there are any relocations for generic ELF.
1917 (bfd_elf32_bfd_link_add_symbols): Defined to
1918 elf32_generic_link_add_symbols.
1919 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
1920 if there are any relocations for generic ELF.
1921 (bfd_elf64_bfd_link_add_symbols): Defined to
1922 elf64_generic_link_add_symbols.
1923
1924 2001-03-23 Nick Clifton <nickc@redhat.com>
1925
1926 * Makefile.am (BUILD_CFILES): New variable: List of C source
1927 files created in build directory.
1928 (BUILD_HFILES): New variable: List of header files created in
1929 build directory.
1930 (POTFILES): Delete.
1931 (po/POTFILES.in): Replace rule with empty entry.
1932 (po/SRC-POTFILES.in): New rule: Create a list of source files
1933 in the source directory.
1934 (po/BLD-POTFILES.in): New rule: Create a list of source files
1935 in the build directory.
1936 (MOSTLYCLEAN): Do not delete source files created in build
1937 directory.
1938 * Makefile.in: Regenerate.
1939 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
1940 into po/Makefile.
1941 * configure: Regenerate.
1942
1943 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
1944 and BLD_POTFILES.
1945 Add .. to the search path when building bfd.pot.
1946 Delete POTFILES when performing distclean.
1947 Add comment describing why distclean is broken in maintainer mode.
1948 * po/POTFILES.in: Delete.
1949 * po/SRC-POTFILES.in: New file.
1950 * po/BLD-POTFILES.in: New file.
1951 * po/bfd.pot: Regenerate.
1952
1953 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
1954
1955 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
1956 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
1957 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
1958 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
1959 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
1960 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
1961 functions.
1962 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
1963 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
1964 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
1965 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
1966 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
1967 New HOWTO members for new relocs.
1968 (cris_reloc_map): Map new relocs.
1969 (ELF_DYNAMIC_INTERPRETER): Define.
1970 (PLT_ENTRY_SIZE): Define.
1971 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
1972 elf_cris_pic_plt_entry): New, PLT templates.
1973 (struct elf_cris_pcrel_relocs_copied, struct
1974 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
1975 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
1976 (cris_final_link_relocate): Check that 16-bit GOT relocs have
1977 positive values. Adjust PCREL relocs to be relative to location
1978 after relocation.
1979 (cris_elf_relocate_section): Handle relocations to dynamic
1980 objects. Handle new relocations. Call error handler when seeing
1981 non-PIC relocation for read-only sections while generating shared
1982 object.
1983 (cris_elf_check_relocs): Set reference counts for GOT and PLT
1984 entries.
1985 (bfd_elf32_bfd_link_hash_table_create,
1986 elf_backend_adjust_dynamic_symbol,
1987 elf_backend_size_dynamic_sections,
1988 elf_backend_finish_dynamic_symbol,
1989 elf_backend_finish_dynamic_sections,
1990 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
1991 elf_backend_hide_symbol, elf_backend_want_got_plt,
1992 elf_backend_plt_readonly, elf_backend_want_plt_sym,
1993 elf_backend_got_header_size, elf_backend_plt_header_size):
1994 Define.
1995
1996 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
1997 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
1998 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
1999 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
2000 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
2001 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
2002 * bfd-in2.h, libbfd.h: Regenerate.
2003
2004 2001-03-21 Diego Novillo <dnovillo@redhat.com>
2005
2006 (_bfd_mips_elf_relocate_section): Give a better error message when
2007 a relocation is not recognized.
2008
2009 2001-03-21 Alan Modra <alan@linuxcare.com.au>
2010
2011 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
2012 non-NULL before attempting to dereference.
2013
2014 2001-03-20 H.J. Lu <hjl@gnu.org>
2015
2016 * configure.in: Remove the redundent AC_ARG_PROGRAM.
2017 * configure: Rebuild.
2018
2019 2001-03-20 Andreas Schwab <schwab@suse.de>
2020
2021 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
2022 relocation value when resolving a reference from a debugging
2023 section.
2024
2025 2001-03-16 Scott Thomason <SThomaso@hii.com>
2026
2027 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
2028 (xcoff64_swap_sym_out): Fix syntax errors.
2029
2030 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
2031
2032 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
2033
2034 2001-03-15 Alan Modra <alan@linuxcare.com.au>
2035
2036 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
2037 (hppa_link_hash_newfunc): Init it.
2038 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
2039 section appears to be non-PIC.
2040 (final_link_relocate): Likewise.
2041 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
2042 possible candidate function, and set pic_call for those that will
2043 only have a .plt entry for the PIC call stub.
2044 (hppa_handle_PIC_calls): Set maybe_pic_call.
2045
2046 2001-03-12 DJ Delorie <dj@redhat.com>
2047
2048 * elf32-sh.c (sh_elf_relocate_section): Only relocation
2049 R_SH_DIR8WP* relocs if they're against external symbols, else
2050 they're just for relaxing. Validate the reloc values.
2051
2052 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
2053
2054 * binary.c (bfd_external_binary_architecture): Declare.
2055 (binary_object_p): If bfd_external_binary_architecture is defined,
2056 set the architecture to this string.
2057
2058 2001-03-11 Philip Blundell <philb@gnu.org>
2059
2060 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
2061 entries that could serve as a definition for a weak symbol.
2062
2063 2001-03-08 Nick Clifton <nickc@redhat.com>
2064
2065 * Most files: Update copyright notices using Perl script created
2066 by Kevin Buettner <kevinb@redhat.com>.
2067
2068 2001-03-07 Nick Clifton <nickc@redhat.com>
2069
2070 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
2071 prior patch on ! defined OLD_ARM_ABI.
2072
2073 2001-03-07 Andreas Jaeger <aj@suse.de>
2074
2075 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
2076 some relocation values.
2077
2078 2001-03-06 Nick Clifton <nickc@redhat.com>
2079
2080 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
2081 of offset in BLX(1) instruction.
2082 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
2083 offset in BLX(1) instruction.
2084 Fix formatting.
2085
2086 2001-03-06 Nick Clifton <nickc@redhat.com>
2087
2088 * coff-arm.c (coff_arm_reloc_type_lookup): Add
2089 BFD_RELOC_THUMB_PCREL_BLX.
2090
2091 2001-03-06 Igor Shevlyakov <igor@windriver.com>
2092
2093 * archures.c (bfd_default_scan): Add Coldfire CPUs.
2094 * bfd-in2.h: Regenerate.
2095 * cpu-m68k.c: Add Coldfire CPUs for arch table.
2096 * ieee.c (ieee_write_processor): Set proper id for
2097 Coldfire CPUs.
2098
2099 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
2100
2101 * configure.in: Add s390 target.
2102 * configure: Regenerate.
2103
2104 2001-02-28 Andreas Jaeger <aj@suse.de>
2105
2106 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
2107 to addend.
2108
2109 2001-02-28 Philip Blundell <pb@futuretv.com>
2110
2111 * elf32-arm.h: Update mentions of renamed EF_xx constants.
2112 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
2113
2114 2001-02-27 H.J. Lu <hjl@gnu.org>
2115
2116 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
2117 abfd->tdata.aout_data == NULL.
2118
2119 2001-02-27 Alan Modra <alan@linuxcare.com.au>
2120
2121 * elf32-hppa.c: Correct field selector in stub comments.
2122 (clobber_millicode_symbols): Formatting fix.
2123
2124 * configure.in: Bump version to 2.11.90.
2125 * configure: Regenerate.
2126 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
2127 (CFILES): $SOURCE_CFILES + generated C files.
2128 (POTFILES): Include $HFILES not $SOURCE_HFILES.
2129 Run "make dep-am"
2130 * Makefile.in: Regenerate.
2131 * doc/Makefile.in: This too.
2132
2133 2001-02-26 Timothy Wall <twall@cygnus.com>
2134
2135 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
2136 comments.
2137
2138 2001-02-26 Nick Clifton <nickc@redhat.com>
2139
2140 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
2141 up, replacing multiple if statements with a switch.
2142 (handle_COMDAT): New function.
2143
2144 2001-02-26 H.J. Lu <hjl@gnu.org>
2145
2146 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
2147 a warning for section flags we do not handle instead of
2148 aborting.
2149
2150 2001-02-26 Andreas Jaeger <aj@suse.de>
2151
2152 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
2153
2154 2001-02-22 Timothy Wall <twall@cygnus.com>
2155
2156 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
2157 * configure.in: Add objects for elf64_ia64_aix vectors.
2158 * configure: Regenerated.
2159 * configure.host: Recognize ia64-*-aix*.
2160 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
2161 for AIX. AIX5 requires most relocations to be dynamic (*all*
2162 binaries are somewhat similar to shared libraries).
2163 * targets.c: Add elf64_ia64_aix vectors.
2164
2165 2001-02-21 David Mosberger <davidm@hpl.hp.com>
2166
2167 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
2168 C8 said "1" instead of "8". Clarify error string for IMM22:
2169 "signed integer" instead of just "integer".
2170
2171 2001-02-20 Andreas Jaeger <aj@suse.de>
2172
2173 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
2174 PLT entries that could serve as a definition for a weak symbol.
2175
2176 2001-02-19 Jakub Jelinek <jakub@redhat.com>
2177
2178 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
2179 entries that could serve as a definition for a weak symbol.
2180 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
2181
2182 2001-02-18 David O'Brien <obrien@FreeBSD>
2183
2184 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
2185 FreeBSD/i386-CURRENT differently until I can figure out the needed
2186 corefile changes.
2187 * configure: Regenerate.
2188 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
2189 FreeBSD/PowerPC, and FreeBSD/sparc64.
2190
2191 2001-02-18 lars brinkhoff <lars@nocrew.org>
2192
2193 * Makefile.am: Add PDP-11 a.out target.
2194 * config.bfd: Likewise.
2195 * configure.in: Likewise.
2196 * targets.c: Likewise.
2197 * archures.c: Likewise.
2198 * bfd-in2.h: Likewise. Add PDP-11 relocations.
2199 * libbfd.h: Add PDP-11 relocations.
2200 * reloc.c: Likewise.
2201 * cpu-pdp11.c: New file.
2202 * pdp11.c: New file.
2203
2204 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
2205 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
2206 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
2207 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
2208 (GET_MAGIC): New macro.
2209 (PUT_MAGIC): Likewise.
2210 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
2211
2212 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
2213
2214 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
2215 multiarch needs it).
2216
2217 2001-02-18 H.J. Lu <hjl@gnu.org>
2218
2219 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
2220 index.
2221
2222 2001-02-18 Kazu Hirata <kazu@hxi.com>
2223
2224 * vms-misc.c: Fix formatting.
2225
2226 2001-02-16 Kazu Hirata <kazu@hxi.com>
2227
2228 * vms.c: Fix formatting.
2229
2230 2001-02-14 H.J. Lu <hjl@gnu.org>
2231
2232 * elf.c (elf_find_function): New function.
2233 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
2234 the file name and function name.
2235
2236 2001-02-14 Nick Clifton <nickc@redhat.com>
2237
2238 * ecoff.c (bfd_debug_section): Update to initialise new fields in
2239 asection structure.
2240
2241 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
2242 (BFD64_BACKENDS): Add pepigen.c
2243 Add rules to create peigen.c and pepigen.c from peXXigen.c.
2244
2245 * Makefile.in: Regenerate.
2246 * configure: Regenerate.
2247 * po/POTFILES.in: Regenerate.
2248 * po/bfd.pot: Regenerate.
2249
2250 2001-02-14 H.J. Lu <hjl@gnu.org>
2251
2252 * libcoff-in.h (pe_tdata): Add members target_subsystem and
2253 force_minimum_alignment.
2254
2255 2001-02-14 Bo Thorsen <bo@suse.de>
2256
2257 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
2258 (elf64_86_64_size_info): Struct added to fix a problem
2259 with the hashtable string entries.
2260 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
2261 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
2262 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
2263 remove the FIXME for this.
2264 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
2265 section. Also removed the FIXME for it.
2266 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
2267 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
2268 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
2269
2270 2001-02-13 Richard Henderson <rth@redhat.com>
2271
2272 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
2273 and not user provided.
2274
2275 2001-02-13 Kazu Hirata <kazu@hxi.com>
2276
2277 * vms.c (vms_print_symbol): Remove unreachable code.
2278
2279 * rs6000-core.c: Fix formatting.
2280
2281 2001-02-13 David Mosberger <davidm@hpl.hp.com>
2282
2283 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
2284 as _bfd_XXi_only_swap_filehdr_out.
2285 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
2286 pe->force_minimum_alignment to TRUE.
2287 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
2288 PEI_TARGET_SUBSYSTEM.
2289 (pe_print_private_bfd_data): Call
2290 _bfd_XX_print_private_bfd_data_common() instead of
2291 _bfd_pe_print_private_bfd_data_common().
2292 (pe_bfd_copy_private_bfd_data): Call
2293 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
2294 _bfd_pe_bfd_copy_private_bfd_data_common().
2295 (coff_bfd_copy_private_section_data): Define as
2296 _bfd_XX_bfd_copy_private_section_data instead of
2297 _bfd_pe_bfd_copy_private_section_data.
2298 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
2299 of a _bfd_pe_get_symbol_info.
2300
2301 * peigen.c: Delete.
2302
2303 * peXXigen.c: Renamed from peigen.c.
2304 (COFF_WITH_XX): Define this macro (will get expanded into
2305 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
2306 compiled as peigen.c or pepigen.c.
2307 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
2308 define the canonical PEP structures and definitions.
2309 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
2310 effect, enforce minimum file and section alignments. If
2311 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
2312 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
2313 so, by default, this is a no-op).
2314
2315 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
2316 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
2317 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
2318 _bfd_pefoo if it's not defined. Use these macros to define
2319 coff swap macros.
2320
2321 * libcoff.h (pe_tdata): Add members target_subsystem and
2322 force_minimum_alignment.
2323
2324 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
2325 COFF_WITH_pep.
2326 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
2327
2328 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
2329 peigen.lo.
2330
2331 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
2332 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
2333 PEPAOUTHDR.
2334
2335 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
2336 (BFD64_BACKENDS_CFILES): Mention pepigen.c
2337 (peigen.c): Add rule to generate from peXXigen.c.
2338 (pepigen.c): Ditto.
2339 (pepigen.lo): List dependencies for pepigen.lo.
2340
2341 2001-02-13 Alan Modra <alan@linuxcare.com.au>
2342
2343 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
2344 $global$ referenced but not defined, set its value here.
2345
2346 2001-02-09 Bo Thorsen <bo@suse.de>
2347
2348 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
2349 alignment to 3.
2350 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
2351 and relocation.
2352 (elf64_x86_64_relocate_section): Fix formatting.
2353 (elf64_x86_64_relocate_section): Fix addend for relocation of
2354 R_X86_64_(8|16|32|PC8|PC16|PC32).
2355
2356 2001-02-12 Jan Hubicka <jh@suse.cz>
2357
2358 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
2359
2360 2001-02-11 H.J. Lu <hjl@gnu.org>
2361
2362 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
2363 alignment.
2364
2365 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
2366
2367 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
2368 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
2369 relocations against dynsym symbols.
2370
2371 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
2372 the R_MIPS_26 relocation.
2373 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
2374 the R_MIPS_26 relocation.
2375 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
2376 relocation.
2377 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
2378 the R_MIPS_26 relocation.
2379 (mips_elf64_howto_table_rela): Likewise.
2380
2381 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
2382 member to mark symbols that have non-CALL relocations against
2383 them.
2384 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
2385 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
2386 R_MIPS_GOT16.
2387 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
2388 non-CALL relocation against it is encountered.
2389 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
2390 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
2391 no_fn_stub is not set.
2392
2393 * elf32-mips.c (mips_elf_output_extsym): Get the output section
2394 information from the real symbol for indirect ones.
2395 Check no_fn_stub to find out if a symbol has a function stub
2396 indeed.
2397
2398 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
2399
2400 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
2401 * Makefile.in: Regenerate.
2402
2403 2001-02-09 David Mosberger <davidm@hpl.hp.com>
2404
2405 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
2406 true if section name is an unwind table section name.
2407 (elfNN_ia64_additional_program_headers): Count each unwind section
2408 separately.
2409 (elfNN_ia64_modify_segment_map): Install one unwind program header
2410 for each unwind separate section. Note: normally the linker
2411 script merges the unwind sections that go into a single segment,
2412 so this still generates at most one unwind program header per
2413 segment.
2414
2415 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
2416 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
2417 (elfNN_ia64_fake_sections): Mark sections with names that start
2418 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
2419 unwind section.
2420
2421 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
2422 Use it to make sh_info in unwind section point to the text section
2423 it applies to.
2424
2425 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
2426
2427 * Makefile.am: Add linux target for S/390.
2428 * archures.c: Likewise.
2429 * bfd-in2.h: Likewise.
2430 * config.bfd: Likewise.
2431 * configure.in: Likewise.
2432 * elf.c: Likewise.
2433 * libbfd.h: Likewise.
2434 * targets.c: Likewise.
2435 * cpu-s390.c: New file.
2436 * elf32-s390.c: New file.
2437 * elf64-s390.c: New file.
2438
2439 2001-02-09 Nick Clifton <nickc@redhat.com>
2440
2441 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
2442 ImageBase. This has already been done by coff_swap_hdr_in.
2443
2444 2001-02-09 Jakub Jelinek <jakub@redhat.com>
2445
2446 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
2447
2448 2001-02-09 Jakub Jelinek <jakub@redhat.com>
2449
2450 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
2451 (sparc64_elf_relocate_section): Likewise.
2452
2453 2001-02-09 Mark Kettenis <kettenis@gnu.org>
2454
2455 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
2456 similar to R_SPARC_32.
2457 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
2458
2459 2001-02-08 H.J. Lu <hjl@gnu.org>
2460
2461 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
2462 relocation entries for weak definitions when building DSO with
2463 -Bsymbolic.
2464
2465 2001-02-08 Richard Henderson <rth@redhat.com>
2466
2467 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
2468 before visibility. Locally defined protected symbols are not
2469 dynamic.
2470
2471 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
2472
2473 * config.bfd: Enable coff64 for rs6000-*. Patch from
2474 <hzoli@austin.ibm.com>.
2475
2476 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
2477
2478 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
2479 found, do not attempt to find dwarf2 info before returning.
2480
2481 2001-02-07 Jakub Jelinek <jakub@redhat.com>
2482
2483 * elflink.h (is_global_symbol_definition): Rename to
2484 is_global_data_symbol_definition and have it reject function
2485 symbols.
2486 (elf_link_is_defined_archive_symbol): Use renamed function.
2487
2488 2001-02-07 Todd Vierling <tv@wasabisystems.com>
2489
2490 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
2491 * libbfd.h (bfd_target_vector): Likewise.
2492 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
2493 make static; create pointer reference named bfd_target_vector.
2494 (_bfd_target_vector_entries): Calculate this based on the array
2495 typed _bfd_target_vector.
2496
2497 2001-02-06 H.J. Lu <hjl@gnu.org>
2498
2499 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
2500 internal symbols are not dynamic.
2501 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
2502
2503 2001-02-06 Nick Clifton <nickc@redhat.com>
2504
2505 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
2506 that it will not be pulled into the list of files that make up
2507 po/POTFILES.in.
2508 * Makefile.in: Regenerate.
2509 * po/bfd.pot: Regenerate.
2510
2511 2001-02-06 H.J. Lu <hjl@gnu.org>
2512
2513 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
2514 checking.
2515 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
2516 external_PEI_IMAGE_hdr.
2517
2518 2001-02-06 Kazu Hirata <kazu@hxi.com>
2519
2520 * elf-m10200.c: Fix formatting.
2521
2522 2001-02-04 Nick Clifton <nickc@redhat.com>
2523
2524 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
2525 rel, it will be handled later on.
2526
2527 2001-02-02 Fred Fish <fnf@ninemoons.com>
2528
2529 * Makefile.in: Fix typo.
2530
2531 2001-02-01 Kazu Hirata <kazu@hxi.com>
2532
2533 * elf-m10300.c: Fix formatting.
2534
2535 2001-01-30 Alan Modra <alan@linuxcare.com.au>
2536
2537 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
2538 (elf_backend_get_symbol_type): Define.
2539 (elf64_hppa_object_p): Set architecture and machine from elf
2540 header flags.
2541
2542 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
2543
2544 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
2545 before mdebug.
2546
2547 2001-01-26 Richard Henderson <rth@redhat.com>
2548
2549 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
2550 for non-default visibility.
2551 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
2552 delete ugly macro and replace with pretty function.
2553
2554 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
2555
2556 * coff-go32.c: Update copyright.
2557 * coff-stgo32.c: Likewise.
2558 * coff-go32.c (COFF_LONG_FILENAMES): Define.
2559 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
2560 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
2561 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
2562
2563 2001-01-25 Kazu Hirata <kazu@hxi.com>
2564
2565 * bfd-in2.h: Rebuild.
2566 * libbfd.h: Likewise.
2567
2568 2001-01-23 H.J. Lu <hjl@gnu.org>
2569
2570 * bfd-in2.h: Rebuild.
2571
2572 2001-01-23 H.J. Lu <hjl@gnu.org>
2573
2574 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
2575 is NULL or PRIV(vms_rec) is outside of the buffer.
2576
2577 2001-01-23 Kazu Hirata <kazu@hxi.com>
2578
2579 * coff64-rs6000.c: Fix formatting.
2580 * coff-arm.c: Likewise.
2581 * coffgen.c: Likewise.
2582 * cofflink.c: Likewise.
2583 * coff-mcore.c: Likewise.
2584 * coff-mips.c: Likewise.
2585 * coff-pmac.c: Likewise.
2586 * coff-ppc.c: Likewise.
2587 * coff-rs6000.c: Likewise.
2588 * elf32.c: Likewise.
2589 * elf32-fr30.c: Likewise.
2590 * elf32-i370.c: Likewise.
2591 * elf32-i860.c: Likewise.
2592 * elf32-m32r.c: Likewise.
2593 * elf32-m68k.c: Likewise.
2594 * elf32-mcore.c: Likewise.
2595 * elf32-ppc.c: Likewise.
2596 * elf32-sh.c: Likewise.
2597 * elf32-v850.c: Likewise.
2598 * elf64-alpha.c: Likewise.
2599 * elf64-sparc.c: Likewise.
2600 * elflink.c: Likewise.
2601 * elflink.h: Likewise.
2602 * elf-m10200.c: Likewise.
2603 * elf-m10300.c: Likewise.
2604 * elfxx-ia64.c: Likewise.
2605
2606 * aoutx.h: Fix formatting.
2607 * bfd.c: Likewise.
2608 * bfd-in2.h: Likewise.
2609 * bfd-in.h: Likewise.
2610 * cpu-i386.c: Likewise.
2611 * cpu-m68hc11.c: Likewise.
2612 * dwarf2.c: Likewise.
2613 * elf64-x86-64.c: Likewise.
2614 * format.c: Likewise.
2615 * freebsd.h: Likewise.
2616 * hash.c: Likewise.
2617 * hp300hpux.c: Likewise.
2618 * hppabsd-core.c: Likewise.
2619 * hpux-core.c: Likewise.
2620
2621 2001-01-22 Bo Thorsen <bo@suse.de>
2622
2623 * elf64-x86-64.c: Added PIC support for X86-64.
2624 (elf64_x86_64_link_hash_newfunc): Function added.
2625 (elf64_x86_64_link_hash_table_create): Likewise.
2626 (elf64_x86_64_check_relocs): Likewise.
2627 (elf64_x86_64_gc_mark_hook): Likewise.
2628 (elf64_x86_64_gc_sweep_hook): Likewise.
2629 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
2630 (elf64_x86_64_size_dynamic_sections): Likewise.
2631 (elf64_x86_64_discard_copies): Likewise.
2632 (elf64_x86_64_finish_dynamic_symbol): Likewise.
2633 (elf64_x86_64_finish_dynamic_sections): Likewise.
2634 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
2635
2636 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
2637
2638 * Makefile.am (install-data-local): Make use of $(DESTDIR).
2639 * Makefile.in: Regenerate.
2640
2641 2001-01-21 Kazu Hirata <kazu@hxi.com>
2642
2643 * coff-a29k.c: Fix formatting.
2644
2645 2001-01-19 H.J. Lu <hjl@gnu.org>
2646
2647 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
2648 relocation section names.
2649 (elf_i386_relocate_section): Report files with bad relocation
2650 section names and return false.
2651
2652 2001-01-17 Bo Thorsen <bo@suse.de>
2653
2654 * targets.c: Alphabetize list of xvecs.
2655
2656 2001-01-14 Alan Modra <alan@linuxcare.com.au>
2657
2658 * config.bfd: Add linux target variant for elfxx-hppa.
2659 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
2660 bfd_elf64_hppa_linux_vec.
2661 * configure: Regenerate.
2662 * elf64-hppa.c: Include elf64-target.h again to support linux
2663 target variant.
2664 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
2665 * elf32-hppa.c: Include elf32-target.h again to support linux
2666 target variant.
2667 (elf32_hppa_post_process_headers): New function.
2668 (elf_backend_post_process_headers): Define.
2669 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
2670 bfd_elf32_hppa_linux_vec.
2671
2672 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
2673 and data_segment_base fields.
2674 (elf32_hppa_link_hash_table_create ): Init them.
2675 (elf32_hppa_check_relocs): Update comments.
2676 (hppa_record_segment_addr): New function.
2677 (elf32_hppa_relocate_section): Call it.
2678 (final_link_relocate): Handle R_PARISC_SEGREL32.
2679 (elf32_hppa_final_link): New function.
2680 (bfd_elf32_bfd_final_link): Define to call it.
2681 (hppa_unwind_entry_compare): New function.
2682 * cache.c (bfd_open_file): Create files in write+read mode.
2683
2684 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
2685 SEGREL32 and numerous other relocs. Change duplicate
2686 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
2687
2688 * opncls.c (bfd_fdopenr): Add parens like the comment says around
2689 O_ACCMODE.
2690
2691 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
2692 .plt entries for DT_INIT and DT_FINI.
2693 (elf32_hppa_finish_dynamic_sections): Remove special handling of
2694 DT_INIT and DT_FINI.
2695
2696 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
2697 offsets for stub .plt access if wide mode. Check offset in range.
2698
2699 2001-01-13 Nick Clifton <nickc@redhat.com>
2700
2701 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
2702 line.
2703
2704 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
2705 line.
2706
2707 2001-01-12 Alan Modra <alan@linuxcare.com.au>
2708
2709 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
2710 * configure: Regenerate.
2711
2712 2001-01-11 Peter Targett <peter.targett@arccores.com>
2713
2714 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
2715 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
2716 * cpu-arc.c (arch_info_struct): Add entries for variants.
2717 (bfd_arc_arch) Set default to bfd_mach_arc_5.
2718 (arc_get_mach) Don't assume machine names prefixed arc- before
2719 testing.
2720 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
2721 selections.
2722 (arc_elf_final_write_processing) Likewise.
2723 (ELF_MACHINE_CODE) Use EM_ARC.
2724
2725 2001-01-10 Nick Clifton <nickc@redhat.com>
2726
2727 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
2728
2729 2001-01-07 Philip Blundell <philb@gnu.org>
2730
2731 * README: Replace `bug-gnu-utils@gnu.org' with
2732 `bug-binutils@gnu.org'.
2733
2734 2001-01-04 Kazu Hirata <kazu@hxi.com>
2735
2736 * som.c: Fix formatting.
2737
2738 2001-01-03 Kazu Hirata <kazu@hxi.com>
2739
2740 * ecoffswap.h: Fix formatting.
2741 * elf-bfd.h: Likewise.
2742 * elfarm-nabi.c: Likewise.
2743 * elfarm-oabi.c: Likewise.
2744 * elfcode.h: Likewise.
2745 * elfcore.h: Likewise.
2746 * elflink.c: Likewise.
2747 * elflink.h: Likewise.
2748 * elfxx-ia64.c: Likewise.
2749 * elfxx-target.h: Likewise.
2750 * libbfd.c: Likewise
2751 * linker.c: Likewise.
2752 * lynx-core.c: Likewise.
2753
2754 2001-01-02 Kazu Hirata <kazu@hxi.com>
2755
2756 * pc532-mach.c: Fix formatting.
2757 * pe-arm.c: Likewise.
2758 * pe-i386.c: Likewise.
2759 * pe-mips.c: Likewise.
2760 * pe-ppc.c: Likewise.
2761 * pe-sh.c: Likewise.
2762 * pei-mips.c: Likewise.
2763 * pei-sh.c: Likewise.
2764 * peicode.h: Likewise.
2765 * ppcboot.c: Likewise.
2766 * ptrace-core.c: Likewise.
2767
2768 2001-01-01 Kazu Hirata <kazu@hxi.com>
2769
2770 * reloc.c: Fix formatting.
2771 * riscix.c: Likewise.
2772 * rs6000-core.c: Likewise.
2773 * xcoff-target.h: Likewise.
2774
2775 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
2776
2777 * elfcode.h (elf_object_p): Also restore the bfd mach field on
2778 error, by calling bfd_default_set_arch_mach with incoming
2779 values.
2780
2781 2000-12-26 Kazu Hirata <kazu@hxi.com>
2782
2783 * vaxnetbsd.c: Fix formatting.
2784 * versados.c: Likewise.
2785 * vms-gsd.c: Likewise.
2786 * vms-hdr.c: Likewise.
2787 * vms-misc.c: Likewise.
2788
2789 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
2790
2791 * archive.c (coff_write_armap): Don't write more than symbol_count
2792 `archive_member_file_ptr's.
2793
2794 2000-12-25 Kazu Hirata <kazu@hxi.com>
2795
2796 * vms-tir.c: Fix formatting.
2797
2798 2000-12-23 Kazu Hirata <kazu@hxi.com>
2799
2800 * vms.c: Fix formatting.
2801 * vms.h: Likewise.
2802
2803 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
2804
2805 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
2806
2807 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
2808
2809 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
2810 arithmetic.
2811
2812 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
2813
2814 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
2815
2816 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
2817
2818 * libbfd.c (bfd_get_bits): Added
2819 (bfd_put_bits): Likewise
2820 * bfd-in.h: Declared the above.
2821 * bfd-in2.h: Regenerated.
2822
2823 2000-12-20 Kazu Hirata <kazu@hxi.com>
2824
2825 * targets.c: Fix formatting.
2826 * tekhex.c: Likewise.
2827 * trad-core.c: Likewise.
2828
2829 2000-12-19 Kazu Hirata <kazu@hxi.com>
2830
2831 * sco5-core.c: Fix formatting.
2832 * section.c: Likewise.
2833 * sparclinux.c: Likewise.
2834 * sparclynx.c: Likewise.
2835 * sparcnetbsd.c: Likewise.
2836 * srec.c: Likewise.
2837 * stabs.c: Likewise.
2838 * stab-syms.c: Likewise.
2839 * sunos.c: Likewise.
2840 * syms.c: Likewise.
2841 * sysdep.h: Likewise.
2842
2843 2000-12-18 Nick Clifton <nickc@redhat.com>
2844
2845 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
2846 defined.
2847 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
2848 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
2849
2850 2000-12-18 Nick Clifton <nickc@redhat.com>
2851
2852 * vms-misc.c (_bfd_vms_get_record): Add default case to
2853 file_format switch.
2854
2855 2000-12-15 Miloslav Trmac <mitr@volny.cz>
2856
2857 * elfcore.h (elf_core_file_p): Move to the start of the program
2858 headers before attempting to read them.
2859
2860 2000-12-14 Kazu Hirata <kazu@hxi.com>
2861
2862 * peigen.c: Fix formatting.
2863 * som.c: Likewise.
2864 * som.h: Likewise.
2865
2866 2000-12-13 Kazu Hirata <kazu@hxi.com>
2867
2868 * peigen.c: Fix formatting.
2869
2870 2000-12-12 Jim Wilson <wilson@redhat.com>
2871
2872 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
2873
2874 2000-12-08 Mark Salter <msalter@redhat.com>
2875
2876 * binary.c (binary_set_section_contents): Ignore sections
2877 with zero size.
2878
2879 2000-12-12 Kazu Hirata <kazu@hxi.com>
2880
2881 * m68klinux.c: Fix formatting.
2882 * m68knetbsd.c: Likewise.
2883 * mipsbsd.c: Likewise.
2884 * netbsd-core.c: Likewise.
2885 * netbsd.h: Likewise.
2886 * newsos3.c: Likewise.
2887 * nlm32-alpha.c: Likewise.
2888 * nlm32-i386.c: Likewise.
2889 * nlm32-ppc.c: Likewise.
2890 * nlm32-sparc.c: Likewise.
2891 * nlmcode.h: Likewise.
2892 * nlmswap.h: Likewise.
2893 * nlm-target.h: Likewise.
2894 * ns32knetbsd.c: Likewise.
2895
2896 2000-12-10 Fred Fish <fnf@be.com>
2897
2898 * elflink.h (elf_link_output_extsym): Don't complain about undefined
2899 symbols in shared objects if allow_shlib_undefined is true.
2900
2901 2000-12-12 Nick Clifton <nickc@redhat.com>
2902
2903 * cpu-sh.c: Fix formattng.
2904 * elf.c: Fix formattng.
2905 * elf32-mips.c: Fix formattng.
2906 * elf32-sh.c: Fix formattng.
2907 * elf64-alpha.c: Fix formattng.
2908
2909 2000-12-09 Nick Clifton <nickc@redhat.com>
2910
2911 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
2912 dwarf2_find_line_info as last parameter to invocation of
2913 _bfd_dwarf2_find_nearest_line.
2914 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
2915 dwarf2_find_line_info as last parameter to invocation of
2916 _bfd_dwarf2_find_nearest_line.
2917
2918 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
2919
2920 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
2921 (BFD_LIBS): ...to here.
2922 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
2923 (BFD_LIBS_CFILES): ...to here.
2924 * Makefile.in: Regenerate.
2925 * configure.in: Remove dwarf.lo from the elf shell variable.
2926 * configure: Regenerate.
2927 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
2928 * libcoff.h: Regenerate.
2929 * coffgen.c (coff_find_nearest_line): Call
2930 _bfd_dwarf2_find_nearest_line.
2931 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
2932 accordingly.
2933 (read_abbrevs): Likewise
2934 (decode_line_info): Likewise.
2935 (parse_comp_unit): Likewise.
2936 (comp_unit_find_nearest_line): Likewise.
2937 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
2938 * libbfd.h: Regenerate.
2939 * elf.c (_bfd_elf_find_nearest_line): Update call.
2940 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
2941 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
2942 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
2943 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
2944 (styp_to_sec_flags): Handle DWARF2 sections.
2945 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
2946 to _bfd_find_nearest_line.
2947 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
2948 call to _bfd_find_nearest_line.
2949
2950 2000-12-08 Kazu Hirata <kazu@hxi.com>
2951
2952 * coffgen.c: Fix formatting.
2953 * elf-m10300.c: Likewise.
2954 * elf32-i386.c: Likewise.
2955 * elf32-i960.c: Likewise.
2956 * elf32-m68k.c: Likewise.
2957 * elf32-mcore.c: Likewise.
2958 * elf32-ppc.c: Likewise.
2959 * elf32-sh.c: Likewise.
2960 * elf32-sparc.c: Likewise.
2961 * elf32-v850.c: Likewise.
2962 * elf64-alpha.c: Likewise.
2963 * elf64-hppa.c: Likewise.
2964 * elf64-mips.c: Likewise.
2965 * elf64-sparc.c: Likewise.
2966
2967 2000-12-07 Kazu Hirata <kazu@hxi.com>
2968
2969 * elf32-ppc.c: Fix formatting.
2970 * elf64-x86-64.c: Likewise.
2971
2972 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
2973
2974 From Ralf Baechle <ralf@gnu.org>
2975
2976 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
2977 BFDs containing no sections or empty .text, .data or .bss sections
2978 to be merged, regardless of their flags.
2979
2980 2000-12-06 Kazu Hirata <kazu@hxi.com>
2981
2982 * elf32-m32r.c: Fix formatting.
2983 * elf32-m68hc11.c: Likewise.
2984 * elf32-m68hc12.c: Likewise.
2985 * elf32-m68k.c: Likewise.
2986 * elf32-mcore.c: Likewise.
2987 * elf32-pj.c: Likewise.
2988 * elf32-ppc.c: Likewise.
2989
2990 2000-12-05 Kazu Hirata <kazu@hxi.com>
2991
2992 * elf32-fr30.c: Fix formatting.
2993 * elf32-hppa.c: Likewise.
2994 * elf32-i370.c: Likewise.
2995 * elf32-i386.c: Likewise.
2996 * elf32-i860.c: Likewise.
2997 * elf32-i960.c: Likewise.
2998
2999 2000-12-03 Kazu Hirata <kazu@hxi.com>
3000
3001 * elf32-arm.h: Fix formatting.
3002 * elf32-avr.c: Likewise.
3003 * elf32-cris.c: Likewise.
3004 * elf32-d10v.c: Likewise.
3005 * elf32-d30v.c: Likewise.
3006 * elf-hppa.h: Likewise.
3007 * elf-m10200.c: Likewise.
3008 * elf-m10300.c: Likewise.
3009
3010 2000-12-01 Chris Demetriou <cgd@sibyte.com>
3011
3012 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
3013 bfd_mach_mips32_4k. Update FIXME comment.
3014 * archures.c (bfd_mach_mips32): New constant.
3015 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
3016 the latter, renumber it.
3017 * bfd-in2.h (bfd_mach_mips32): New constant.
3018 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
3019 the latter, renumber it.
3020 * cpu-mips.c (I_mips32): New constant.
3021 (I_mips4K, I_mips32_4k): Rename the former to the latter.
3022 (arch_info_struct): Add bfd_mach_mips32 entry, replace
3023 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
3024 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
3025 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
3026 with E_MIPS_MACH_MIPS32_4K.
3027 (_bfd_mips_elf_final_write_processing): Replace
3028 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
3029 bfd_mach_mips32 case.
3030 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
3031 comparison with support for MIPS32.
3032 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
3033 MIPS32.
3034
3035 * aoutx.h (NAME(aout,machine_type)): Add cases for
3036 bfd_mach_mips5 and bfd_mach_mips64.
3037 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
3038 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
3039 * cpu_mips.c (I_mips5, I_mips64): New definitions.
3040 (arch_info_struct): Add entries for bfd_mach_mips5 and
3041 bfd_mach_mips64.
3042 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
3043 _bfd_mips_elf_print_private_bfd_data): Add cases for
3044 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
3045 (_bfd_mips_elf_final_write_processing): Add cases for
3046 bfd_mach_mips5 and bfd_mach_mips64.
3047
3048 * aoutx.h (NAME(aout,machine_type)): Add a
3049 bfd_mach_mips_sb1 case.
3050 * archures.c (bfd_mach_mips_sb1): New constant.
3051 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
3052 * cpu-mips.c (I_sb1): New constant.
3053 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
3054 * elf32-mips.c (elf_mips_mach): Add case for
3055 E_MIPS_MACH_SB1.
3056 (_bfd_mips_elf_final_write_processing): Add case for
3057 bfd_mach_mips_sb1.
3058
3059 2000-12-01 Joel Sherrill <joel@OARcorp.com>
3060
3061 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
3062 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
3063 (sparc*-*-rtems*): Switched from a.out to ELF.
3064
3065 2000-11-30 Jan Hubicka <jh@suse.cz>
3066
3067 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
3068 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
3069 (elf64-x86-64.lo): Add dependencies.
3070 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
3071 bfd_mach_x86_64_intel_syntax.
3072 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
3073 * config.bfd (x86_64): Add.
3074 * configure.in: Add support for bfd_elf64_x86_64_vec.
3075 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
3076 (bfd_i386_arch, i8086_ar): Link in.
3077 * elf64-x86-64.c: New file.
3078 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
3079 * targets.c (bfd_elf64_x86_64_vec): Add.
3080 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
3081
3082 2000-11-30 Kazu Hirata <kazu@hxi.com>
3083
3084 * xcofflink.c: Fix formatting.
3085
3086 2000-11-28 Kazu Hirata <kazu@hxi.com>
3087
3088 * aoutx.h: Fix formatting.
3089 * bfd-in.h: Likewise.
3090 * bfd-in2.h: Likewise.
3091 * cache.c: Likewise.
3092 * cisco-core.c: Likewise.
3093 * coff64-rs6000.c: Likewise.
3094 * coffcode.h: Likewise.
3095 * coffswap.h: Likewise.
3096 * corefile.c: Likewise.
3097 * elf32-mips.c: Likewise.
3098
3099 2000-11-27 Kazu Hirata <kazu@hxi.com>
3100
3101 * aout-adobe.c: Fix formatting.
3102 * coff64-rs6000.c: Likewise.
3103 * coffgen.c: Likewise.
3104 * cofflink.c: Likewise.
3105
3106 2000-11-27 Philip Blundell <pb@futuretv.com>
3107
3108 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
3109 (obj_coff_strings_written): New accessor macro for above.
3110 * libcoff.h: Regenerate.
3111 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
3112 strings.
3113 * coffcode.h (coff_write_object_contents): No need to write out
3114 the string table if it's already been done.
3115
3116 2000-11-22 Philip Blundell <pb@futuretv.com>
3117
3118 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
3119 weak undefined symbols.
3120
3121 2000-11-24 Nick Clifton <nickc@redhat.com>
3122
3123 * archures.c (bfd_mach_arm_5TE): Define.
3124 (bfd_mach_arm+XScale): Define.
3125 * bfd-in2.h: Regenerate.
3126
3127 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
3128 BFD_RELOC_ARM_PCREL_BLX.
3129
3130 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
3131 XScale machine numbers.
3132
3133 * config.bfd (xscale-elf): Add target.
3134 (xscale-coff): Add target.
3135
3136 * cpu-arm.c: Add xscale machine name.
3137 Add v5t, v5te and XScale machine numbers.
3138
3139 2000-11-23 Kazu Hirata <kazu@hxi.com>
3140
3141 * aix386-core.c: Fix formatting.
3142
3143 2000-11-22 Jim Wilson <wilson@redhat.com>
3144
3145 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
3146 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
3147 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
3148 (ins_imms_scaled): Initialize sign_bit at function entry.
3149 (elf64_ia64_operands): Add missing initializers.
3150 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
3151 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
3152 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
3153 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
3154 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
3155 parameters.
3156 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
3157 and free_extsyms at function entry.
3158 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
3159 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
3160 (get_got): Delete unused local srel.
3161 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
3162 (elfNN_ia64_relocate_section): Delete unused local dynindx.
3163
3164 2000-11-21 Kazu Hirata <kazu@hxi.com>
3165
3166 * coff-a29k.c: Fix formatting.
3167 * coff-h8500.c: Likewise.
3168 * coff-i960.c: Likewise.
3169 * coff-ppc.c: Likewise.
3170 * coff-rs6000.c: Likewise.
3171 * coff-stgo32.c: Likewise.
3172 * coff-tic54x.c: Likewise.
3173 * coff-w65.c: Likewise.
3174 * cpu-h8500.c: Likewise.
3175 * cpu-hppa.c: Likewise.
3176 * cpu-ns32k.c: Likewise.
3177 * ecoff.c: Likewise.
3178 * ecofflink.c: Likewise.
3179
3180 2000-11-21 Nick Clifton <nickc@redhat.com>
3181
3182 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
3183 remove possibility of infinite loop.
3184
3185 2000-11-20 Kazu Hirata <kazu@hxi.com>
3186
3187 * aix386-core.c: Fix formatting.
3188 * aout-adobe.c: Likewise.
3189 * aout-arm.c: Likewise.
3190 * aout-encap.c: Likewise.
3191 * aout-ns32k.c: Likewise.
3192 * aout-target.h: Likewise.
3193 * aout-tic30.c: Likewise.
3194 * aoutf1.h: Likewise.
3195 * aoutx.h: Likewise.
3196 * archive.c: Likewise.
3197 * bfd-in.h: Likewise.
3198 * bfd-in2.h: Likewise.
3199 * bfd.c: Likewise.
3200 * bout.c: Likewise.
3201
3202 2000-11-17 H.J. Lu <hjl@gnu.org>
3203
3204 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
3205 pltoff entries for DT_INIT and DT_FINI.
3206 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
3207 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
3208 entries.
3209
3210 2000-11-16 Richard Henderson <rth@redhat.com>
3211
3212 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
3213 (allocate_dynrel_entries): Likewise.
3214 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
3215 (set_pltoff_entry): Likewise.
3216 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
3217 (elfNN_ia64_reloc_type_lookup): Likewise.
3218 (elfNN_ia64_install_value): Likewise.
3219 (elfNN_ia64_relocate_section): Likewise.
3220 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
3221 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
3222
3223 2000-11-16 Kazu Hirata <kazu@hxi.com>
3224
3225 * cpu-a29k.c: Fix formatting.
3226 * cpu-alpha.c: Likewise.
3227 * cpu-arm.c: Likewise.
3228 * cpu-avr.c: Likewise.
3229 * cpu-d10v.c: Likewise.
3230 * cpu-h8500.c: Likewise.
3231 * cpu-hppa.c: Likewise.
3232 * cpu-i370.c: Likewise.
3233 * cpu-i386.c: Likewise.
3234 * cpu-i960.c: Likewise.
3235 * cpu-ia64-opc.c: Likewise.
3236 * cpu-ia64.c: Likewise.
3237 * cpu-m32r.c: Likewise.
3238 * cpu-m68hc11.c: Likewise.
3239 * cpu-m68hc12.c: Likewise.
3240 * cpu-m68k.c: Likewise.
3241 * cpu-m88k.c: Likewise.
3242 * cpu-mips.c: Likewise.
3243 * cpu-ns32k.c: Likewise.
3244 * cpu-pj.c: Likewise.
3245 * cpu-powerpc.c: Likewise.
3246 * cpu-sh.c: Likewise.
3247 * cpu-sparc.c: Likewise.
3248 * cpu-tic54x.c: Likewise.
3249 * cpu-v850.c: Likewise.
3250 * cpu-vax.c: Likewise.
3251 * cpu-w65.c: Likewise.
3252 * cpu-we32k.c: Likewise.
3253 * cpu-z8k.c: Likewise.
3254 * dwarf1.c: Likewise.
3255 * dwarf2.c: Likewise.
3256
3257 2000-11-15 Kazu Hirata <kazu@hxi.com>
3258
3259 * coff-arm.c: Fix formatting.
3260 * coff-ppc.c: Likewise.
3261 * coff-rs6000.c: Likewise.
3262 * coff-sh.c: Likewise.
3263 * coff-sparc.c: Likewise.
3264 * coff-tic30.c: Likewise.
3265 * coff-tic54x.c: Likewise.
3266 * coff-tic80.c: Likewise.
3267 * coff-w65.c: Likewise.
3268 * coff-we32k.c: Likewise.
3269 * coff-z8k.c: Likewise.
3270
3271 2000-11-15 Richard Henderson <rth@redhat.com>
3272
3273 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
3274 section with the same ALLOC|LOAD flags as the source section.
3275
3276 2000-11-14 Jakub Jelinek <jakub@redhat.com>
3277
3278 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
3279 by STO_ALPHA constants.
3280
3281 2000-11-14 Kazu Hirata <kazu@hxi.com>
3282
3283 * coff-pmac.c: Fix formatting.
3284 * coff-ppc.c: Likewise.
3285
3286 2000-11-13 H.J. Lu <hjl@gnu.org>
3287
3288 * elflink.h (elf_link_add_object_symbols): Also add indirect
3289 symbols for common symbols with the default version.
3290
3291 2000-11-09 Philip Blundell <pb@futuretv.com>
3292
3293 * section.c (STD_SECTION): Set gc_mark flag.
3294
3295 2000-11-11 Kazu Hirata <kazu@hxi.com>
3296
3297 * coff-i960.c: Likewise.
3298 * coff-m68k.c: Likewise.
3299 * coff-m88k.c: Likewise.
3300 * coff-mcore.c: Likewise.
3301 * coff-mips.c: Likewise.
3302
3303 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
3304
3305 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
3306
3307 2000-11-10 Kazu Hirata <kazu@hxi.com>
3308
3309 * coff-h8300.c: Fix formatting.
3310 * coff-h8500.c: Likewise.
3311 * coff-i386.c: Likewise.
3312 * coff-i860.c: Likewise.
3313 * coff-i960.c: Likewise.
3314 * coff-ia64.c: Likewise.
3315
3316 2000-11-09 Kazu Hirata <kazu@hxi.com>
3317
3318 * archive.c: Fix formatting.
3319 * archures.c: Likewise.
3320
3321 2000-11-07 Richard Henderson <rth@redhat.com>
3322
3323 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
3324 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
3325 * section.c (bfd_set_section_contents): Call memcpy if
3326 section->contents set and location not equal to contents plus offset.
3327
3328 2000-11-08 Kazu Hirata <kazu@hxi.com>
3329
3330 * bfd-in.h: Fix formatting.
3331 * bfd-in2.h: Likewise.
3332 * bfd.c: Likewise.
3333 * binary.c: Likewise.
3334 * bout.c: Likewise.
3335 * coff-a29k.c: Likewise.
3336 * coff-alpha.c: Likewise.
3337 * coff-apollo.c: Likewise.
3338 * coff-aux.c: Likewise.
3339
3340 2000-11-07 Kazu Hirata <kazu@hxi.com>
3341
3342 * aix386-core.c: Fix formatting.
3343 * aoutf1.h: Likewise.
3344 * aoutx.h: Likewise.
3345 * archures.c: Likewise.
3346 * armnetbsd.c: Likewise.
3347
3348 2000-11-07 Alan Modra <alan@linuxcare.com.au>
3349
3350 * coff-h8300.c (special): Adjust reloc address.
3351
3352 2000-11-06 Steve Ellcey <sje@cup.hp.com>
3353
3354 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
3355 to differentiate elf32 and elf64 on ia64.
3356 * bfd-in2.h: Regenerate.
3357 * config.bfd: Add target for "ia64*-*-hpux*".
3358 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
3359 * configure: Regenerate.
3360 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
3361 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
3362
3363 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
3364 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
3365 * Makefile.in: Regnerate.
3366 * elf64-ia64.c: Deleted.
3367 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
3368
3369 2000-11-06 Kazu Hirata <kazu@hxi.com>
3370
3371 * aout-adobe.c: Fix formatting.
3372 * aout-arm.c: Likewise.
3373 * aout-cris.c: Likewise.
3374 * aout-encap.c: Likewise.
3375 * aout-ns32k.c: Likewise.
3376 * aout-target.h: Likewise.
3377 * aout-tic30.c: Likewise.
3378
3379 2000-11-05 Philip Blundell <philb@gnu.org>
3380
3381 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
3382 BFDs containing no sections to be merged, regardless of their flags.
3383
3384 2000-11-04 Philip Blundell <philb@gnu.org>
3385
3386 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
3387 if a relocation for an undefined symbol also results in an
3388 overflow.
3389
3390 2000-11-06 Christopher Faylor <cgf@cygnus.com>
3391
3392 * config.bfd: Add support for Sun Chorus.
3393
3394 2000-11-05 David O'Brien <obrien@FreeBSD.org>
3395
3396 * configure.in: Recognize alpha-*-freebsd*.
3397 * configure: Regenerate.
3398
3399 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
3400
3401 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
3402 (Chunk): New global variable set by a parameter in objcopy.c.
3403 (S3Forced): New global variable set by a parameter in
3404 objcopy.c.
3405 (srec_set_section_contents): If S3Forced is true, always generate
3406 S3 records.
3407 (srec_write_section): Use 'Chunk' to limit maximum length of S
3408 records.
3409
3410 2000-11-02 Per Lundberg <plundis@chaosdev.org>
3411
3412 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
3413 * Makefile.in: Regenerate.
3414 * bfd-in2.h: Regenerate.
3415 * po/bfd.pot: Regenerate.
3416
3417 2000-10-31 Philip Blundell <philb@gnu.org>
3418
3419 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
3420 EF_SOFT_FLOAT if it is defined.
3421
3422 2000-10-27 Philip Blundell <philb@gnu.org>
3423
3424 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
3425 attempts to mix PIC code with non-PIC, just mark the output as
3426 being position dependent.
3427 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
3428 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
3429 all mismatches, not just the first one.
3430
3431 2000-10-25 Chris Demetriou <cgd@sibyte.com>
3432
3433 * ieee.c (ieee_archive_p): Plug one of many possible
3434 memory leaks in error handling.
3435
3436 2000-10-20 Jakub Jelinek <jakub@redhat.com>
3437
3438 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
3439 elf32_sparc_object_p, elf32_sparc_final_write_processing):
3440 Support v8plusb.
3441 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
3442 sparc64_elf_object_p): Support v9b.
3443 * archures.c: Declare v8plusb and v9b machines.
3444 * bfd-in2.h: Ditto.
3445 * cpu-sparc.c: Ditto.
3446
3447 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
3448
3449 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
3450 of a GOT reloc.
3451
3452 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
3453 (SYMBOL_CALLS_LOCAL): New macro.
3454 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
3455 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
3456 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
3457 (ppc_elf_relocate_section): Use flag variable to determine
3458 whether the relocation refers to a local symbol.
3459 Test whether a PLTREL24 reloc will produce a reloc by looking
3460 to see whether a PLT entry was made.
3461
3462 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
3463
3464 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
3465 entries that could serve as a definition for a weak symbol.
3466
3467 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
3468
3469 From Ralf Baechle <ralf@gnu.org>
3470
3471 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
3472 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
3473 against local symbols.
3474 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
3475
3476 2000-10-12 Alan Modra <alan@linuxcare.com.au>
3477
3478 * section.c (struct sec): Add kept_section.
3479 (struct bfd_comdat_info): Remove sec, we can use above.
3480 (STD_SECTION): Add initializer.
3481 (bfd_make_section_anyway): Init here too.
3482
3483 * bfd-in2.h: Regenerate.
3484
3485 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
3486 zeroing of `flags'.
3487 (elf_link_input_bfd): Set all asection->symbol->value's here, and
3488 fudge values for discarded link-once section symbols.
3489
3490 * elf64-hppa.c: Include alloca-conf.h
3491
3492 2000-10-11 Alan Modra <alan@linuxcare.com.au>
3493
3494 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
3495
3496 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
3497
3498 2000-10-10 Alan Modra <alan@linuxcare.com.au>
3499
3500 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
3501
3502 2000-10-10 Tom Rix <trix@redhat.com>
3503
3504 * section.c (bfd_make_section_anyway): Release newsect ptr when
3505 newsect->symbol fails to alloc. Use bfd_release instead of free.
3506
3507 2000-10-09 Richard Henderson <rth@cygnus.com
3508
3509 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
3510 (elf64_ia64_unwind_entry_compare): New.
3511 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
3512
3513 2000-10-07 Alan Modra <alan@linuxcare.com.au>
3514
3515 * elflink.h (size_dynamic_sections): Don't create various tags if
3516 .dynstr is excluded from the link. Don't set first dynsym entry
3517 if dynsymcount is zero.
3518 (elf_bfd_final_link): Don't try to swap out dynamic syms if
3519 .dynsym excluded from the link. Don't try to write any dynamic
3520 sections excluded from the link.
3521
3522 * elf.c (swap_out_syms): Handle global section symbols.
3523
3524 2000-10-05 DJ Delorie <dj@redhat.com>
3525
3526 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
3527 * coffcode.h (coff_set_alignment_hook): read extended reloc count
3528 (coff_write_relocs): write extended reloc count
3529 (coff_write_object_contents): account for extended relocs
3530
3531 2000-10-05 Jim Wilson <wilson@cygnus.com>
3532
3533 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
3534 field.
3535 * elf.c (_bfd_elf_make_section_from_shdr): Call the
3536 elf_backend_section_flags function.
3537 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
3538 code.
3539 (elf64_ia64_section_flags): New function containing flag conversion
3540 code.
3541 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
3542 * elfxx-target.h (elf_backend_section_flags): Define.
3543 (elfNN_bed): Initialize elf_backend_section_flags field.
3544
3545 2000-10-02 Alan Modra <alan@linuxcare.com.au>
3546
3547 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
3548 _bfd_elf32_gc_record_vtable. Correct a comment.
3549
3550 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
3551
3552 From Ralf Baechle <ralf@gnu.org>
3553
3554 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
3555 produces binaries with got[1] = 0x80000001 to differenciate them
3556 for the dynamic linker from the broken binaries produced by old
3557 versions.
3558
3559 2000-09-30 Petr Sorfa <petrs@sco.com>
3560
3561 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
3562 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
3563 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
3564 * configure: Regenerate.
3565
3566 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
3567
3568 Define two bfd_targets for absence and presence of leading
3569 underscore on symbols. Make sure to only link same kind.
3570 * elf32-cris.c (cris_elf_object_p,
3571 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
3572 cris_elf_merge_private_bfd_data): New.
3573 (elf_backend_object_p, elf_backend_final_write_processing,
3574 bfd_elf32_bfd_print_private_bfd_data,
3575 bfd_elf32_bfd_merge_private_bfd_data): Define.
3576 <Target vector definition>: Include elf32-target.h twice with
3577 different macro settings:
3578 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
3579 bfd_elf32_us_cris_vec.
3580 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
3581 (elf_symbol_leading_char): First as 0, then '_'.
3582 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
3583 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
3584 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
3585 * configure: Regenerate.
3586 * targets.c: Declare bfd_elf32_us_cris_vec.
3587 * po/bfd.pot: Regenerate.
3588
3589 2000-09-29 Momchil Velikov <velco@fadata.bg>
3590
3591 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
3592 R_ARM_THM_PC22 relocations.
3593
3594 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
3595
3596 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
3597
3598 2000-09-29 Momchil Velikov <velco@fadata.bg>
3599
3600 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
3601 is has the SEC_HAS_CONTENTS flag set.
3602
3603 2000-09-28 \81Örjan Friberg <orjanf@axis.com>
3604 Hans-Peter Nilsson <hp@axis.com>
3605
3606 * aout-cris.c (N_TXTADDR): Define.
3607
3608 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
3609
3610 * som.c: Include alloca-conf.h.
3611 * Makefile.am: "make dep-am"
3612 * Makefile.in: Regenerate.
3613
3614 2000-09-27 Alan Modra <alan@linuxcare.com.au>
3615
3616 * elf32-hppa.c (plt_stub): New.
3617 (PLT_STUB_ENTRY): Define.
3618 (elf32_hppa_link_hash_table): Change multi_subspace to packed
3619 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
3620 (elf32_hppa_link_hash_table_create): Init to suit.
3621 (elf32_hppa_check_relocs): Set has_12bit_branch and
3622 has_17bit_branch as appropriate.
3623 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
3624 non-local functions.
3625 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
3626 Add space for plt_stub as needed.
3627 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
3628 functions at plt_stub.
3629 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
3630 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
3631
3632 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
3633 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
3634 of fixed size, and if negative, disable handling of input sections
3635 before stub section. Set up default stub group size depending
3636 on detected branch relocs.
3637 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
3638 ensure different offsets from sym_value aren't rounded to
3639 different 2k blocks. Use lrsel and rrsel for other stubs too for
3640 consistency rather than necessity.
3641 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
3642 (final_link_relocate): Likewise.
3643 (elf32_hppa_relocate_section): Likewise.
3644
3645 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
3646 (_bfd_elf_hppa_gen_reloc_type): Generate them.
3647 (elf_hppa_final_link_relocate): Handle them.
3648 (elf_hppa_relocate_insn): Likewise.
3649 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
3650
3651 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
3652
3653 * elfcode.h (elf_object_p): Preserve and clear abfd section
3654 information. Restore at error.
3655
3656 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
3657
3658 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
3659 is empty, make sure that its rva also 0. NT loader dislikes
3660 having otherwise.
3661
3662 2000-09-26 Steve Ellcey <sje@cup.hp.com>
3663
3664 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
3665 global by default.
3666
3667 2000-09-21 Alan Modra <alan@linuxcare.com.au>
3668
3669 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
3670 currently unused RELATIVE_DYNAMIC_RELOCS code.
3671 (hppa_discard_copies): Likewise.
3672 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
3673 comments. Don't check non-code output sections for stub grouping.
3674
3675 2000-09-20 Alan Modra <alan@linuxcare.com.au>
3676
3677 * section.c (bfd_get_unique_section_name): Return NULL if
3678 bfd_malloc fails.
3679
3680 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3681
3682 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
3683 instruction sequence to actually work.
3684 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
3685 accordingly.
3686
3687 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
3688
3689 * elf32-sh.c (sh_elf_relocate_section): Use
3690 _bfd_final_link_relocate to apply the relocation against a section
3691 symbol, when doing relocatable links.
3692
3693 2000-09-18 Alan Modra <alan@linuxcare.com.au>
3694
3695 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
3696 to id_sec.
3697 (stub_hash_newfunc): Here too.
3698 (hppa_add_stub): And here.
3699 (elf32_hppa_link_hash_table): Remove stub_section_created,
3700 reloc_section_created, first_init_sec and first_fini_sec. Add
3701 stub_group.
3702 (elf32_hppa_link_hash_table_create): Init to suit.
3703 (hppa_get_stub_entry): Add support for grouping stub sections.
3704 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
3705 section code. Index stub vars by section->id.
3706 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
3707 exit paths. Zap allocation of above removed vars. Refine
3708 link-once test.
3709
3710 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
3711 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
3712 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
3713 rather than pointer to bfd_link_info.
3714 (hppa_add_stub): Likewise.
3715 (final_link_relocate): Likewise.
3716
3717 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
3718
3719 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
3720 link-once sections.
3721
3722 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
3723
3724 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
3725 ld/emulparams/shelf.sh.
3726
3727 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3728
3729 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
3730 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
3731 * bfd-in2.h: Regenerate.
3732
3733 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
3734
3735 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
3736 LITUSE relocations incorrectly if -relax is specified on the ld
3737 command line and the displacement field of the load or store
3738 instruction is non-zero. (Patch by paul.winalski@compaq.com)
3739
3740 2000-09-15 Alan Modra <alan@linuxcare.com.au>
3741
3742 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
3743 first_fini_sec here.
3744 (elf32_hppa_size_stubs): Instead correctly find the first .init
3745 and .fini section here.
3746
3747 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
3748
3749 * elf32-hppa.c (clobber_millicode_symbols): New function.
3750 (elf32_hppa_size_dynamic_sections): Call it.
3751
3752 2000-09-14 Alan Modra <alan@linuxcare.com.au>
3753
3754 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
3755 packed. Add plabel, plt_abs packed booleans.
3756 (hppa_link_hash_newfunc): Init new fields.
3757 (PLABEL_PLT_ENTRY_SIZE): Define.
3758 (hppa_stub_name): Use size_t len vars.
3759 (hppa_add_stub): Likewise.
3760 (elf32_hppa_build_stubs): Likewise.
3761 (hppa_build_one_stub): Kill some compiler warnings.
3762 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
3763 if dynamic linking. Munge the local plt offsets into
3764 local_got_refcounts. Set h->plabel for all global PLABELs. Use
3765 size_t len vars. Add assert for plabel addend.
3766 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
3767 (elf32_hppa_hide_symbol): New function.
3768 (elf_backend_hide_symbol): Define.
3769 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
3770 with h->plabel set. Don't make plt entries to have dynamic syms
3771 when they have been forced local. If plt entry is used by a
3772 plabel, make it PLABEL_PLT_ENTRY_SIZE.
3773 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
3774 Set up .plt offsets for local syms.
3775 (elf32_hppa_relocate_section): Initialise plt entries for local
3776 syms. Leave weak undefined plabels zero. Make global plabel
3777 relocs against function symbol, and leave the addend zero.
3778 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
3779 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
3780 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
3781 relocs instead of SEGREL32 for dynamic got relocs.
3782 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
3783 (elf_backend_got_header_size): Adjust.
3784 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
3785
3786 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
3787 (hppa_type_of_stub): Use it instead of #if 0
3788 (hppa_discard_copies): Use it here too.
3789 (elf32_hppa_size_dynamic_sections): And here.
3790
3791 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
3792 (elf32_hppa_link_hash_table_create): And here.
3793 (hppa_build_one_stub): And here. Instead keep track of stub
3794 offset using _raw_size.
3795 (elf32_hppa_size_stubs): Likewise.
3796 (elf32_hppa_build_stubs): Likewise.
3797 (hppa_size_one_stub): Likewise. Resize reloc section too.
3798
3799 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
3800 first_fini_sec handling. Don't search for reloc section or set
3801 hplink->reloc_section_created here.
3802 (elf32_hppa_size_stubs): Instead search for reloc sections, and
3803 set reloc_section_created here.
3804 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
3805 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
3806 and DT_FINI.
3807 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
3808
3809 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
3810 with `hplink->root.'.
3811 (elf32_hppa_check_relocs): Likewise.
3812 (elf32_hppa_gc_sweep_hook): Likewise.
3813 (elf32_hppa_adjust_dynamic_symbol): Likewise.
3814 (hppa_handle_PIC_calls): Likewise.
3815 (elf32_hppa_size_dynamic_sections): Likewise.
3816 (elf32_hppa_set_gp): Likewise.
3817 (elf32_hppa_relocate_section): Likewise.
3818 (elf32_hppa_finish_dynamic_symbol): Likewise.
3819 (elf32_hppa_finish_dynamic_sections): Likewise.
3820
3821 From David Huggins-Daines <dhd@linuxcare.com>
3822 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
3823 defined weak symbols in shared links.
3824 (final_link_relocate): Calls to defined weak symbols in shared
3825 objects must go via import stubs, as the target might not be known
3826 at link time.
3827
3828 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
3829
3830 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
3831 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
3832 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
3833 the original entries with EMPTY_HOWTOs, and added new ones to fill
3834 in the gap.
3835 (sh_elf_info_to_howto): Make sure the new gap isn't used.
3836 (sh_elf_relocate_section): Likewise.
3837
3838 2000-09-13 Anders Norlander <anorland@acc.umu.se>
3839
3840 * cpu-mips.c (arch_info_struct): Add mips:4K
3841 * bfd-in2.h (bfd_mach_mips4K): New define.
3842 * archures.c: Add bfd_mach_mips4K to comment.
3843 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
3844 E_MIPS_ARCH_2 for bfd_mach_mips4K.
3845
3846 2000-09-13 Marco Franzen <marcof@thyron.com>
3847
3848 * som.c (som_write_symbol_strings): Do not used fixed buffers,
3849 use size_t as a counter.
3850 (som_write_space_strings): Similarly.
3851
3852 2000-09-12 Jason Eckhardt <jle@cygnus.com>
3853
3854 * elf32-i860.c (elf32_i860_relocate_pc26): New function
3855 and prototype.
3856 (elf32_i860_relocate_section): Invoke new function from here.
3857
3858 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3859
3860 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
3861 static.
3862
3863 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3864
3865 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
3866 target section name instead of dumping core when the target symbol is
3867 undefined.
3868
3869 2000-09-09 Kazu Hirata <kazu@hxi.com>
3870
3871 * riscix.c: Remove DEFUN.
3872
3873 2000-09-08 Nick Clifton <nickc@redhat.com>
3874
3875 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
3876 initialise flags in output bfd if the input bfd is the default
3877 architecture with the default flags.
3878
3879 2000-09-08 Kazu Hirata <kazu@hxi.com>
3880
3881 * archive.c: Fix formatting.
3882 * coff-arm.c: Likewise.
3883 * doc/chew.c: Likewise.
3884
3885 2000-09-08 Alan Modra <alan@linuxcare.com.au>
3886
3887 * section.c (bfd_get_unique_section_name): Put a dot before the
3888 numeric suffix.
3889
3890 2000-09-07 Kazu Hirata <kazu@hxi.com>
3891
3892 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
3893 * elf.c: Fix formatting.
3894
3895 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
3896
3897 * config.bfd (sh-*-linux*): Added.
3898 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
3899 * targets.c: Declare them.
3900 * elf32-sh-lin.c: New file.
3901 * Makefile.am: Compile it.
3902 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
3903 * configure, Makefile.in: Rebuilt.
3904
3905 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
3906
3907 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
3908 pseduo-section when determining where the TOC ends.
3909
3910 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
3911 output x_tvndx as it is only two bytes wide.
3912
3913 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
3914 reloc is 26 or 32 bits wide.
3915
3916 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
3917 for relocs that don't change anything. Also look at the full
3918 6 bits of bitsize.
3919
3920 2000-09-06 Philip Blundell <philb@gnu.org>
3921
3922 * config.bfd (arm*-*-uclinux*): New target.
3923
3924 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
3925
3926 * configure: Rebuilt with new libtool.m4.
3927
3928 2000-09-06 Alan Modra <alan@linuxcare.com.au>
3929
3930 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
3931 word for variable name.
3932 * bfd-in2.h: Regenerate.
3933
3934 2000-09-05 Nick Clifton <nickc@redhat.com>
3935
3936 * config.in: Regenerate.
3937 * libbfd.h: Regenerate.
3938 * po/bfd.pot: Regenerate.
3939 * doc/bfdint.texi: Remove CVS date string - it foils compares with
3940 local versions.
3941
3942 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
3943
3944 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
3945
3946 2000-09-05 Alan Modra <alan@linuxcare.com.au>
3947
3948 Shared library and PIC support.
3949 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
3950 (GOT_ENTRY_SIZE): New.
3951 (ELF_DYNAMIC_INTERPRETER): New.
3952 (STUB_SUFFIX): Define.
3953 (LONG_BRANCH_PIC_IN_SHLIB): Define.
3954 (RELATIVE_DYNAMIC_RELOCS): Define.
3955 (enum elf32_hppa_stub_type): New.
3956 (struct elf32_hppa_stub_hash_entry): Rename offset to
3957 stub_offset. Add a number of new fields.
3958 (struct elf32_hppa_link_hash_entry): New.
3959 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
3960 global_value.
3961 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
3962 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
3963 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
3964 new fields.
3965 (hppa_link_hash_newfunc): New function.
3966 (elf32_hppa_link_hash_table_create): Use above function. Init new
3967 fields.
3968 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
3969 instead of addend, and remove sym_name from args. Don't use
3970 symbol name for local syms, instead use sym index.
3971 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
3972 stub type rather than size. Pass in hash and handle import stub
3973 case. Also pass in reloc instead of offset so we can calculate
3974 PCREL22F and PCREL12F branches properly.
3975 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
3976 import and export stubs too.
3977 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
3978 import and export stub sizing.
3979 (elf32_hppa_check_relocs): New function.
3980 (elf32_hppa_adjust_dynamic_symbol): New function.
3981 (hppa_discard_copies): New function.
3982 (elf32_hppa_size_dynamic_sections): New function.
3983 (elf_backend_size_dynamic_sections): Define.
3984 (elf32_hppa_finish_dynamic_symbol): New function.
3985 (elf_backend_finish_dynamic_symbol): Define.
3986 (elf32_hppa_size_stubs): Stash params in link hash table, and move
3987 some local vars into the link hash table too. For shared links,
3988 trundle over function syms, generating export stubs. Handle
3989 PCREL22F branches. Break out stub creation code from here..
3990 (hppa_add_stub): .. to here. New function.
3991 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
3992 call the bfd linker. Use elf_gp to record global pointer.
3993 Calculate a value from sections if $global$ is missing.
3994 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
3995 (elf32_hppa_gc_mark_hook): New function.
3996 (elf_backend_gc_mark_hook): Define.
3997 (elf32_hppa_gc_sweep_hook): New function.
3998 (elf_backend_gc_sweep_hook): Define.
3999 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
4000 Add rel to args, and remove howto, input_bfd, offset, addend,
4001 sym_name as we can recalculate these locally. Handle calls to
4002 dynamic objects, extra PIC relocs, PCREL22F branches. Change
4003 handling of undefined weak syms. Check that stubs are in range.
4004 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
4005 message on hitting a DPREL21L reloc that needs fixing. Subtract
4006 off PC for PCREL14F. Break out code that does a stub lookup from
4007 here..
4008 (hppa_get_stub_entry): ..to here. New function.
4009 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
4010 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
4011 relocs, etc. etc.
4012 (elf32_hppa_finish_dynamic_sections): New function.
4013 (elf_backend_finish_dynamic_sections): Define.
4014 (elf_backend_final_write_processing) Define.
4015 (hppa_handle_PIC_calls): New function.
4016 (elf32_hppa_build_stubs): Call it. Pass link_info to
4017 hppa_build_one_stub.
4018 (elf32_hppa_create_dynamic_sections): New function
4019 to create .plt and .got then set .plt flags correctly.
4020 (elf_backend_create_dynamic_sections): Define.
4021 (elf32_hppa_object_p): New function.
4022 (elf_backend_object_p): Define.
4023 (elf32_hppa_elf_get_symbol_type): New function.
4024 (elf_backend_get_symbol_type): Define.
4025 (elf_backend_can_gc_sections): Define.
4026 (elf_backend_want_got_plt): Define.
4027 (elf_backend_plt_alignment): Set to 2.
4028 (elf_backend_plt_readonly): Define.
4029 (elf_backend_want_plt_sym): Define.
4030 (elf_backend_got_header_size): Reserve one entry.
4031
4032 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
4033 (elf32_hppa_size_stubs): Pass in multi_subspace.
4034 (elf32_hppa_set_gp): Declare.
4035
4036 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
4037 (bfd_get_unique_section_name): New function.
4038 * bfd-in2.h: Regenerate.
4039
4040 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
4041 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
4042 comment.
4043
4044 From David Huggins-Daines <dhd@linuxcare.com>
4045 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
4046 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
4047 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
4048 been updated in finish_dynamic_symbol before modifying function
4049 symbol.
4050
4051 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
4052 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
4053 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
4054 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
4055 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
4056 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
4057 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
4058 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
4059
4060 From David Huggins-Daines <dhd@linuxcare.com>
4061 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
4062 style of local labels as well.
4063
4064 2000-09-03 Philip Blundell <philb@gnu.org>
4065
4066 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
4067 references to undefined symbols in debugging sections.
4068
4069 2000-09-02 H.J. Lu <hjl@gnu.org>
4070
4071 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
4072 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
4073 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
4074 section.
4075
4076 2000-09-02 Jason Eckhardt <jle@cygnus.com>
4077
4078 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
4079 (elf32_i860_is_local_label_name): New function and prototype.
4080
4081 2000-09-02 Nick Clifton <nickc@redhat.com>
4082
4083 * configure.in: Increase version number to 2.10.91.
4084 * configure: Regenerate.
4085 * aclocal.m4: Regenerate.
4086 * config.in: Regenerate.
4087 * po/bfd.pot: Regenerate.
4088
4089 2000-09-02 Daniel Berlin <dberlin@redhat.com>
4090
4091 * elf.c (_bfd_elf_make_section_from_shdr): Add
4092 .gnu.linkobce.wi. to the list of debug section names.
4093
4094 2000-09-02 Nick Clifton <nickc@redhat.com>
4095
4096 * dwarf2.c (find_debug_info): New function: Locate a section
4097 containing dwarf2 debug information.
4098 (bfd_dwarf2_find_nearest_line): Find all sections containing
4099 debug information and include them in the stash.
4100
4101 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
4102
4103 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
4104 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
4105 (sh_reloc_map): Add new relocs.
4106 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
4107 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
4108 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
4109 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
4110 functions.
4111 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
4112 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
4113 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
4114 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
4115 New array constants.
4116 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
4117 New variables.
4118 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
4119 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
4120 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
4121 elf_sh_plt_reloc_offset): Define.
4122 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
4123 elf_sh_link_hash_table): New structs.
4124 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
4125 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
4126 relocation types.
4127 (elf_backend_create_dynamic_sections,
4128 bfd_elf32_bfd_link_hash_table_create,
4129 elf_backend_adjust_dynamic_symbol,
4130 elf_backend_size_dynamic_sections,
4131 elf_backend_finish_dynamic_symbol,
4132 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
4133 elf_backend_plt_readonly, elf_backend_want_plt_sym,
4134 elf_backend_got_header_size, elf_backend_plt_header_size):
4135 Define.
4136 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
4137 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
4138 New relocs.
4139 * bfd-in2.h, libbfd.h: Rebuilt.
4140
4141 2000-09-01 Alan Modra <alan@linuxcare.com.au>
4142
4143 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
4144 change.
4145
4146 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
4147
4148 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
4149 not initialized, set them to indicate the SH1 instruction set.
4150
4151 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
4152
4153 * acinclude.m4: Include libtool and gettext macros from the
4154 top level.
4155 * aclocal.m4, configure: Rebuilt.
4156
4157 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
4158
4159 * elf.c: Eliminate references to __sparcv9 macro; replace with
4160 autoconf variables HAVE_PSINFO32_T etc.
4161 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
4162 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
4163 * config.in: Ditto.
4164 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
4165 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
4166 * aclocal.m4: Ditto.
4167 * configure: Regenerate.
4168
4169 2000-08-27 Alan Modra <alan@linuxcare.com.au>
4170
4171 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
4172 for any shared link, not just shared -Bsymbolic.
4173 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
4174 any shared link, and pass link info to it.
4175 (elf_i386_size_dynamic_sections): Update comment.
4176 (elf_i386_discard_copies): Modify to discard relocs for symbols
4177 that have been forced local.
4178 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
4179 that have been forced local.
4180
4181 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
4182
4183 * elflink.h (elf_link_add_object_symbols): Allow common
4184 symbols to have an alignment of 1 if explicitly requested, and
4185 not overridden by other definitions.
4186
4187 2000-08-22 Doug Kwan <dkwan@transmeta.com>
4188
4189 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
4190 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
4191
4192 2000-08-22 H.J. Lu <hjl@gnu.org>
4193
4194 * elf-bfd.h (elf_link_hash_table): Add runpath.
4195
4196 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
4197 * bfd-in2.h: Rebuilt.
4198
4199 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
4200 "runpath" field to NULL.
4201 (bfd_elf_get_runpath_list): New function.
4202
4203 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
4204 DT_RUNPATH entries.
4205
4206 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
4207
4208 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
4209 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
4210 explicitly. Improve validation of r_type.
4211
4212 2000-08-21 H.J. Lu <hjl@gnu.org>
4213
4214 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
4215 dynamic allocated content space. Add a comment to remind us that
4216 one day this ought to be fixed.
4217 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
4218 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
4219 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
4220
4221 2000-08-21 Jason Eckhardt <jle@cygnus.com>
4222
4223 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
4224 field with the newly relocated value instead of adding it to the
4225 existing immediate field.
4226 (elf32_i860_relocate_splitn): Likewise.
4227 (elf32_i860_relocate_highadj): Likewise.
4228
4229 2000-08-16 Jason Eckhardt <jle@cygnus.com>
4230
4231 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
4232 was previously just a stub).
4233
4234 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
4235
4236 * elflink.c (_bfd_elf_create_got_section): Don't abort().
4237 Formatting fixes.
4238 (_bfd_elf_create_dynamic_sections): Likewise.
4239
4240 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
4241
4242 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
4243 for undefined symbols to be the beginning of the section.
4244
4245 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
4246 four extra entries at the beginning of the .rela.plt section.
4247 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
4248 section to account for the four reserved entries in the .plt section.
4249
4250 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
4251
4252 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
4253 to the list of NOPs we recognize after a branch-and-link.
4254 Use the ori NOP when one is needed.
4255
4256 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
4257 for large archives.
4258
4259 2000-08-14 Jim Wilson <wilson@cygnus.com>
4260
4261 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
4262 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
4263 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
4264 EF_IA_64_ABSOLUTE.
4265
4266 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
4267
4268 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
4269
4270 2000-08-10 Jason Eckhardt <jle@cygnus.com>
4271
4272 * elf32-i860.c (elf32_i860_relocate_section): New function.
4273 (i860_final_link_relocate): New function.
4274 (elf32_i860_relocate_splitn): New function.
4275 (elf32_i860_relocate_pc16): New function.
4276 (elf32_i860_relocate_highadj): New function.
4277 (elf32_i860_howto): Minor adjustments to some relocations.
4278 (elf_info_to_howto_rel): Define.
4279 (elf_backend_relocate_section): Define.
4280
4281 2000-08-10 Nick Clifton <nickc@cygnus.com>
4282
4283 * elf32-arm.h: Fix formatting.
4284
4285 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
4286
4287 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
4288
4289 2000-08-08 Jason Eckhardt <jle@cygnus.com>
4290
4291 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
4292
4293 2000-08-07 Kazu Hirata <kazu@hxi.com>
4294
4295 * ieee.c (ieee_write_debug_part): Rewrite a comment.
4296 * elf64-ia64.c: Fix a typo.
4297
4298 2000-08-05 Jason Eckhardt <jle@cygnus.com>
4299
4300 * elf32-i860.c (elf32_i860_howto_table): New structure.
4301 (lookup_howto): New function.
4302 (elf32_i860_reloc_type_lookup): New function.
4303 (elf32_i860_info_to_howto_rela): New function.
4304 (elf_code_to_howto_index): New structure.
4305 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
4306 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
4307 elf32_i860_reloc_type_lookup.
4308
4309 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
4310
4311 * som.c (struct fixup_format): Constify `format'.
4312 (som_hppa_howto_table): Use SOM_HOWTO macro.
4313 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
4314 (som_bfd_reloc_type_lookup): Likewise.
4315 (compare_subspaces): Remove unused `count1', `count2'.
4316 (som_begin_writing): Remove unused `total_reloc_size'.
4317 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
4318 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
4319 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
4320 (som_find_nearest_line): Decorate unused parameter(s).
4321 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
4322 (som_bfd_link_split_section): Likewise.
4323
4324 2000-08-03 Nick Clifton <nickc@cygnus.com>
4325
4326 * section.c: Restore backed out code.
4327 * elf.c: Restore backed out code.
4328 (copy_private_bfd_data): Fix bug preventing stipped dynamic
4329 binaries from working.
4330 * bfd-in2.h: Regenerate.
4331
4332 2000-08-03 H.J. Lu <hjl@gnu.org>
4333
4334 * section.c: Back out the change made by Nick Clifton
4335 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
4336 binaries.
4337 * bfd-in2.h: Likewise.
4338 * elf.c: Likewise.
4339
4340 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
4341
4342 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
4343
4344 2000-07-31 Jason Eckhardt <jle@cygnus.com>
4345
4346 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
4347 * bfd-in2.h, libbfd.h: Regenerate.
4348
4349 2000-07-31 Nick Clifton <nickc@cygnus.com>
4350
4351 * section.c (struct sec): Add new boolean field 'segment_mark'.
4352 (STD_SECTION): Initialise new field to zero.
4353
4354 * bfd-in2.h: Regenerate.
4355
4356 * elf.c (copy_private_bfd_data): Reorganise section to segment
4357 mapping to cope with moved sections requiring new segments,
4358 and overlapping segments.
4359 (SEGMENT_END): New macro: Return the end address of a segment.
4360 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
4361 contains a section by comparing their VMA addresses.
4362 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
4363 contains a section by comparing their LMA addresses.
4364 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
4365 section should be included in a segment.
4366 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
4367 follows another in memory.
4368 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
4369 segments overlap.
4370
4371 2000-07-22 Jason Eckhardt <jle@cygnus.com>
4372
4373 * cpu-i860.c: Added comments.
4374
4375 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
4376 bfd_elf32_i860_little_vec.
4377 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
4378 (ELF_MAXPAGESIZE): Changed to 4096.
4379
4380 * targets.c (bfd_elf32_i860_little_vec): Declaration of
4381 new target.
4382 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
4383
4384 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
4385 config for little endian elf32 i860.
4386 (targ_defvec): Define for the new config above
4387 as "bfd_elf32_i860_little_vec".
4388 (targ_selvecs): Define for the new config above
4389 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
4390
4391 * configure.in (bfd_elf32_i860_little_vec): Added recognition
4392 of new target vec.
4393
4394 * configure: Regenerated.
4395
4396 2000-07-27 H.J. Lu <hjl@gnu.org>
4397
4398 * elflink.h (elf_merge_symbol): Take one more argument,
4399 dt_needed, to indicate if the symbol comes from a DT_NEEDED
4400 entry. Don't overide the existing weak definition if dt_needed
4401 is true.
4402 (elf_link_add_object_symbols): Pass dt_needed to
4403 elf_merge_symbol ().
4404
4405 2000-07-27 Nick Clifton <nickc@cygnus.com>
4406
4407 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
4408 allocated contents.
4409
4410 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
4411
4412 * configure.host (*-*-aix*): AIX has 'long long' always.
4413
4414 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
4415 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
4416 (xcoff_write_archive_contents_big): Don't update the offset
4417 of the symbol table, xcoff_write_armap will do it.
4418
4419 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
4420
4421 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
4422 of dynobj for SGI_COMPAT checks.
4423
4424 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
4425
4426 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
4427 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
4428 * bfd-in2.h: Regenerate.
4429
4430 2000-07-21 Nick Clifton <nickc@cygnus.com>
4431
4432 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
4433 range symbol indices in relocs and issue an error message.
4434
4435 2000-07-20 H.J. Lu <hjl@gnu.org>
4436
4437 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
4438 info->new_dtags when setting DT_FLAGS_1. It will only be set
4439 by the new linker options. It shouldn't break anything.
4440
4441 2000-07-20 H.J. Lu <hjl@gnu.org>
4442
4443 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
4444 only if info->new_dtags is true.
4445
4446 2000-07-20 H.J. Lu <hjl@gnu.org>
4447
4448 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
4449 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
4450
4451 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
4452
4453 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
4454 (ALL_MACHINES_CFILES): Add cpu-cris.c.
4455 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
4456 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
4457 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
4458 * Makefile.in: Rebuild.
4459 * aclocal.m4: Rebuild.
4460 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
4461 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
4462 (bfd_cris_arch): Declare.
4463 (bfd_archures_list): Add bfd_cris_arch.
4464 * bfd-in2.h: Rebuild.
4465 * config.bfd: (cris-*-*): New target.
4466 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
4467 * configure: Rebuild.
4468 * elf.c (prep_headers): Add bfd_arch_cris.
4469 * libbfd.h: Rebuild.
4470 * libaout.h (enum machine_type): Add M_CRIS.
4471 * reloc.c: Add CRIS relocations.
4472 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
4473 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
4474 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
4475 * po/POTFILES.in, po/bfd.pot: Regenerate.
4476
4477 2000-07-19 H.J. Lu <hjl@gnu.org>
4478
4479 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
4480 DF_TEXTREL if DT_TEXTREL is set.
4481 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
4482 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
4483 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
4484 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
4485 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
4486 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
4487 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
4488 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
4489 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
4490 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
4491
4492 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
4493 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
4494 DT_RPATH is set.
4495 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
4496
4497 2000-07-19 H.J. Lu <hjl@gnu.org>
4498
4499 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
4500 * bfd-in2.h: Rebuild.
4501
4502 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
4503 (elf_dt_soname): New.
4504
4505 * elf.c (bfd_elf_set_dt_needed_soname): New.
4506
4507 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
4508 entry if the shared object loaded by DT_NEEDED is used to
4509 resolve the reference in a regular object.
4510
4511 2000-07-19 H.J. Lu <hjl@gnu.org>
4512
4513 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
4514 DT_DEPAUDIT and DT_AUDIT as strings.
4515
4516 2000-07-19 Nick Clifton <nickc@cygnus.com>
4517
4518 * format.c: Fix formatting.
4519
4520 2000-07-19 H.J. Lu <hjl@gnu.org>
4521
4522 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
4523
4524 2000-07-19 H.J. Lu <hjl@gnu.org>
4525
4526 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
4527 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
4528 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
4529 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
4530 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
4531 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
4532 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
4533
4534 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
4535
4536 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
4537 renamed functions from here...
4538 (assign_section_numbers): Use renamed functions.
4539 (prep_headers): Use renamed functions.
4540
4541 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
4542 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
4543 * bfd-in2.h: Regenerate.
4544
4545 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
4546
4547 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
4548 parenthesis in if statement.
4549
4550 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
4551
4552 Enable the support for Traditional MIPS.
4553 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
4554 return ict_none appropriately for traditional mips targets.
4555 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
4556 (STUB_MOVE): Conditionalize for traditonal mips.
4557 (STUB_LI16): Likewise.
4558 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
4559 room for RTPROC header.
4560 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
4561 the permission for the PT_DYNAMIC as read, write and execute.
4562 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
4563 for traditonal mips.
4564 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
4565 _DYNAMIC_LINKING for traditonal mips.
4566 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
4567 in case of traditonal mips.
4568 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
4569 entry is required. For a function if PLT is not required then set the
4570 corresponding hash table entry to 0.
4571 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
4572 traditonal mips.
4573 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
4574 shared object set the value to 0.
4575 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
4576 _DYNAMIC_LINKING for traditonal mips.
4577 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
4578 for traditonal mips.
4579
4580 2000-07-15 H.J. Lu <hjl@gnu.org>
4581
4582 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
4583
4584 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
4585
4586 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
4587 out a structure that is BFD_IN_MEMORY.
4588
4589 2000-07-11 Alan Modra <alan@linuxcare.com.au>
4590
4591 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
4592 bfd pointer. Print section id instead of bfd pointer for local
4593 syms. Prefix addend with `+' for global syms as well as local.
4594 Correct calculation of name component lengths.
4595 (elf64_hppa_check_relocs): Update call to get_dyn_name.
4596
4597 From David Huggins-Daines <dhd@linuxcare.com>
4598 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
4599 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
4600 (elf64_hppa_modify_segment_map): Likewise.
4601
4602 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
4603
4604 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
4605 addresses to be "naturally" sign extended. Return -1 if unknown.
4606 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
4607 * bfd-in2.h: Regenerate.
4608
4609 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
4610
4611 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
4612 and ECOF_SIGNED_64 to list ways to extract an offset.
4613 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
4614 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
4615 Update.
4616 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
4617 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
4618
4619 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
4620
4621 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
4622 bfd_get_start_address.
4623 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
4624 (elf_swap_ehdr_out): Ditto.
4625
4626 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
4627
4628 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
4629 compatibility with older binutils.
4630
4631 2000-07-10 Alan Modra <alan@linuxcare.com.au>
4632
4633 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
4634 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
4635
4636 From Ryan Bradetich <rbradetich@uswest.net>
4637 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
4638 (parse_line_table): Ditto.
4639 (_bfd_dwarf1_find_nearest_line): Ditto.
4640 * syms.c (cmpindexentry): Remove extra `*' from params.
4641
4642 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
4643
4644 * elf32-mips.c (sort_dynamic_relocs): New Function.
4645 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
4646 via qsort to sort the dynamic relocations in increasing r_symndx
4647 value.
4648
4649 2000-07-09 Alan Modra <alan@linuxcare.com.au>
4650
4651 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
4652 ATTRIBUTE_UNUSED to unused args.
4653 (get_opd): Likewise.
4654 (get_plt): Likewise.
4655 (get_dlt): Likewise.
4656 (get_stub): Likewise.
4657 (elf64_hppa_adjust_dynamic_symbol): Likewise.
4658 (elf64_hppa_link_output_symbol_hook): Likewise.
4659 (elf64_hppa_check_relocs): Delete unused var.
4660 (elf64_hppa_size_dynamic_sections): Likewise.
4661 (elf64_hppa_finalize_opd): Likewise.
4662 (elf64_hppa_finalize_dynreloc): Likewise.
4663 (elf64_hppa_modify_segment_map): Likewise.
4664 (elf64_hppa_finish_dynamic_sections): Likewise.
4665
4666 * elf-hppa.h (elf_hppa_final_write_processing): Add
4667 ATTRIBUTE_UNUSED to unused args.
4668 (elf_hppa_final_link_relocate): Likewise.
4669 (elf_hppa_record_segment_addrs): Add paretheses.
4670 (elf_hppa_relocate_section): Constify dyn_name.
4671
4672 From David Huggins-Daines <dhd@linuxcare.com>
4673 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
4674 rearrange case statement so that it gets preferred to 32-bit ones.
4675
4676 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
4677 asection->id instead of address of asection structure.
4678 (elf32_hppa_size_stubs): Likewise.
4679
4680 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
4681 for .init* and .fini*.
4682
4683 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
4684 and addends used in stub names to 32 bits.
4685 (elf32_hppa_size_stubs): Likewise.
4686
4687 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
4688 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
4689 not bfd_put_64. Fix minor comment typo and formatting.
4690
4691 Changes to create multiple linker stubs, positioned immediately
4692 before the section where they are required.
4693 * elf32-hppa.c: Don't include hppa_stubs.h.
4694 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
4695 (elf32_hppa_stub_hash_table): Delete.
4696 (elf32_hppa_link_hash_entry): Delete.
4697 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
4698 stub_hash_table, and store the struct here rather than a pointer.
4699 Delete output_symbol_count. Add offset array. Change
4700 global_value to a bfd_vma.
4701 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
4702 (elf32_hppa_stub_hash_traverse): Delete.
4703 (elf32_hppa_name_of_stub): Delete.
4704 (elf32_hppa_link_hash_lookup): Delete.
4705 (elf32_hppa_link_hash_traverse): Delete.
4706 (elf32_hppa_stub_hash_table_init): Delete.
4707 (elf32_hppa_size_of_stub): Pass input section and offset rather
4708 than location and calculate location here. Don't pass name as all
4709 stubs are now the same size.
4710 (elf32_hppa_stub_hash_newfunc): Init new fields.
4711 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
4712 too.
4713 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
4714 comparing against ints. Rewrite stub handling code.
4715 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
4716 Case enums to int before comparing against ints. Remove
4717 bfd_reloc_dangerous case.
4718 (elf32_hppa_build_one_stub): Rewrite.
4719 (elf32_hppa_size_one_stub): New function.
4720 (elf32_hppa_build_stubs): Rewrite.
4721 (elf32_hppa_size_stubs): Pass in linker call-back functions.
4722 Rewrite stub-handling specific code.
4723
4724 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
4725
4726 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
4727
4728 * hppa_stubs.h: Delete.
4729 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
4730 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
4731 * Makefile.in: Regenerate.
4732
4733 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
4734 e_nlrsel.
4735
4736 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
4737
4738 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
4739 and section name for bfd_reloc_notsupported error message.
4740 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
4741 bfd_reloc_notsupported.
4742 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
4743
4744 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
4745 undefined weak symbols for all relocs.
4746 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
4747 offsets are relative to one past the delay slot.
4748 (elf32_hppa_size_stubs): Account for reloc addend when calculating
4749 branch destination. Put addend into stub name too.
4750 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
4751 adjust by 8 when deciding whether a linker stub is needed. Put
4752 addend into stub name as for above.
4753
4754 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
4755 various args and vars.
4756 (elf32_hppa_bfd_final_link_relocate): Here too.
4757 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
4758 inner block var to avoid shadowing.
4759
4760 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
4761 unsigned.
4762 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
4763 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
4764 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
4765
4766 * libhppa.h: Change practically all unsigned ints to plain ints.
4767 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
4768 prototypes.
4769
4770 From Ryan Bradetich <rbradetich@uswest.net>
4771 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
4772 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
4773 suit above.
4774 From David Huggins-Daines <dhd@linuxcare.com>
4775 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
4776 to the new OP_* ones.
4777
4778 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
4779 error exit. Bail out earlier on plabel relocs that we aren't
4780 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
4781 string, and then don't free our copy.
4782 (elf32_hppa_build_one_stub): Make insn unsigned int.
4783
4784 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
4785 available with BL, not BE and BLE.
4786
4787 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
4788 code for elf arg relocs.
4789 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
4790 argument with elf_link_hash_entry h. Handle undefined weak
4791 symbols. Move $global$ lookup from here...
4792 (elf32_hppa_relocate_section): ...to here. Return correct error
4793 message for non-handled relocs.
4794 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
4795 wrong test was -0x3ffff to +0x40000.
4796
4797 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
4798 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
4799 Handle them as such.
4800 (elf_hppa_relocate_insn): Fix a typo.
4801
4802 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
4803 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
4804 assemble_17, assemble_21): Delete.
4805 Supply defines for all 64 possible opcodes.
4806 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
4807 formats. Handle COMICLR.
4808 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
4809 -10, -16, 16, 22.
4810
4811 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
4812 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
4813 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
4814 to suit.
4815 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
4816 the local syms - did this code get deleted accidentally? Ignore
4817 undefined and undefweak syms.
4818
4819 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
4820 block. Use it instead of elf64_hppa_hash_table (info).
4821 (elf_hppa_final_link_relocate): Use hppa_info instead of
4822 elf64_hppa_hash_table (info).
4823
4824 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
4825 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
4826 (hppa_rebuild_insn): Mask immediate bits here instead.
4827 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
4828
4829 2000-07-08 Alan Modra <alan@linuxcare.com.au>
4830
4831 * section.c (struct sec): Add id field. Tidy comment formatting.
4832 (bfd_make_section_anyway): Set id.
4833 (STD_SECTION): Init id too.
4834 Change CONST to const throughout.
4835 * archures.c (bfd_arch_info): Tidy comment.
4836 (bfd_arch_list): Change a CONST to const.
4837 * libbfd-in.h: Tidy comments and replace CONST with const.
4838 * elf-bfd.h: Likewise.
4839 * libbfd.h: Regenerate.
4840 * bfd-in2.h: Regenerate.
4841 * libcoff.h: Regenerate.
4842
4843 2000-07-07 DJ Delorie <dj@redhat.com>
4844
4845 * archive.c (_bfd_write_archive_contents): Add an informative
4846 comment.
4847
4848 2000-07-06 Kazu Hirata <kazu@hxi.com>
4849
4850 * srec.c: Fix formatting.
4851
4852 2000-06-05 DJ Delorie <dj@redhat.com>
4853
4854 * MAINTAINERS: new
4855
4856 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
4857
4858 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
4859 value of PC-relative offsets.
4860
4861 2000-07-03 Jim Wilson <wilson@cygnus.com>
4862
4863 * elf64-alpha.c (alpha_elf_size_info): New.
4864 (elf_backend_size_info): Define to alpha_elf_size_info.
4865 * elfcode.h (elf_size_info): Change hash bucket size to 4.
4866
4867 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
4868
4869 * elf32-mips.c: Include elf32-target.h again for the traditional
4870 MIPS targets.
4871
4872 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
4873
4874 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
4875 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
4876 (avr_info_to_howto_rela): Likewise.
4877 (elf32_avr_gc_mark_hook): Likewise.
4878 (elf32_avr_gc_sweep_hook): Likewise.
4879 (elf32_avr_relocate_section): Likewise.
4880
4881 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
4882
4883 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
4884 an external symbol for a non-shared, non-relocatable link.
4885
4886 2000-07-03 Nick Clifton <nickc@redhat.com>
4887
4888 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
4889 is an external symbol.
4890 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
4891 external symbol.
4892
4893 2000-07-03 Kazu Hirata <kazu@hxi.com>
4894
4895 * reloc16.c: Fix formatting.
4896
4897 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
4898
4899 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
4900 to add a new target for traditional mips i.e
4901 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
4902 * configure.in: Likewise.
4903 * configure: Rebuild.
4904 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
4905 bfd_target_vector.
4906 (bfd_elf32_tradlittlemips_vec): Likewise.
4907 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
4908 to see that elfNN_bed does not get redefined even if the target file
4909 is included twice for a chip. See elf32-mips.c.
4910
4911 2000-07-01 Alan Modra <alan@linuxcare.com.au>
4912
4913 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
4914 (CLEANFILES): Add DEPA.
4915 * Makefile.in: Regenerate.
4916
4917 2000-06-30 DJ Delorie <dj@cygnus.com>
4918
4919 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
4920 can't assume the PE header is at 0x80.
4921
4922 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
4923
4924 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
4925
4926 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
4927
4928 * go32stub.h: Update stub.
4929
4930 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
4931
4932 * archures.c (bfd_mach_avr5): Define.
4933 * bfd-in2.h (bfd_mach_avr5): Define.
4934 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
4935 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
4936 (compatible): Update comment. Add missing test.
4937 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
4938 for avr2 and avr4. Simplify 8K wrap code.
4939 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
4940 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
4941
4942 2000-06-26 Kazu Hirata <kazu@hxi.com>
4943
4944 * coff-h8300.c: Fix formatting.
4945 * cpu-h8300.c: Likewise.
4946
4947 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
4948
4949 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
4950 for local symbols whose names are unknown.
4951
4952 2000-06-22 Alan Modra <alan@linuxcare.com.au>
4953
4954 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
4955 find one.
4956 * Makefile.in: Regenerate.
4957 * doc/Makefile.in: Regenerate.
4958
4959 2000-06-20 H.J. Lu <hjl@gnu.org>
4960
4961 * Makefile.am: Rebuild dependency.
4962 * Makefile.in: Rebuild.
4963
4964 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4965
4966 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
4967 (elf_backend_copy_indirect_symbol): Map to the new function.
4968
4969 2000-06-20 Alan Modra <alan@linuxcare.com.au>
4970
4971 * archive.c (normalize): Correct pointer comparison when checking
4972 for backslashes.
4973 (bfd_bsd_truncate_arname): Likewise.
4974 (bfd_gnu_truncate_arname): Likewise.
4975
4976 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
4977
4978 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
4979 sections elf_{text,data}_{section,symbol}.
4980 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
4981 (_bfd_mips_elf_hide_symbol): New function.
4982 (elf_backend_hide_symbol): Map to the new function.
4983 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
4984 definitions of mips_elf_{text,data}_{section,symbol}.
4985 (mips_elf_local_relocation_p): Try to find the direct symbol
4986 based on new check_forced argument.
4987 (mips_elf_calculate_relocation): Use new version of
4988 mips_elf_local_relocation_p.
4989 (mips_elf_relocate_section): Likewise.
4990 (_bfd_mips_elf_relocate_section): Likewise.
4991 (mips_elf_sort_hash_table): Only assert that have enough GOT
4992 space.
4993 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
4994 entry if the relocation based on the new external argument.
4995 (mips_elf_create_dynamic_relocation): Assert that we have a
4996 section contents allocated where we can swap out the dynamic
4997 relocations.
4998 (mips_elf_calculate_relocation): Find the real hash-table entry
4999 correctly by using h->root.root.type. Only create a dynamic
5000 relocation entry if the symbol is defined in a shared library.
5001 Create an external GOT entry for the GOT16 relocation if the
5002 symbol was forced local.
5003 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
5004 dynamic index if the symbol was forced local.
5005
5006 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
5007
5008 * elf32-mips.c: Fix typos in comments.
5009
5010 2000-06-19 Mark Kettenis <kettenis@gnu.org>
5011
5012 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
5013 CORE_VERSION_1.
5014
5015 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
5016
5017 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
5018 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
5019 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
5020 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
5021 (bfd_elf32_m68hc11_vec): Likewise.
5022 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
5023 Supports 68hc11 & 68hc12 at the same time.
5024 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
5025 bfd_target_vector.
5026 (bfd_elf32_m68hc11_vec): Likewise.
5027 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
5028 * archures.c (bfd_m68hc12_arch): Define and register in global list
5029 (bfd_m68hc11_arch): Likewise.
5030 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
5031 BFD_RELOC_M68HC11_3B): Define.
5032 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
5033 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
5034
5035 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
5036
5037 * elf_bfd.h (struct elf_backend_data): Add info argument to
5038 elf_backend_hide_symbol.
5039 (_bfd_elf_link_hash_hide_symbol): Likewise.
5040 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
5041 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
5042 * elflink.h (elf_link_add_object_symbols): Likewise.
5043 (elf_link_assign_sym_version): Likewise.
5044
5045 2000-06-18 H.J. Lu <hjl@gnu.org>
5046
5047 * coff-i386.c (coff_i386_reloc): Don't return in case of
5048 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
5049 Compensate PE relocations when linking with non-PE object
5050 files to generate a non-PE executable.
5051
5052 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
5053
5054 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
5055 GOT entries if we're doing a static link or -Bsymbolic link.
5056
5057 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
5058
5059 * elflink.h (elf_link_adjust_relocs): Check for and call backend
5060 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
5061 available.
5062 (elf_link_output_relocs): Likewise.
5063 (elf_reloc_link_order): Likewise.
5064
5065 2000-06-16 Nicholas Duffek <nsd@redhat.com>
5066
5067 * archures.c (enum bfd_architecture): #define constants for
5068 PowerPc and RS6000 machine numbers.
5069 * bfd-in2.h: Regenerate.
5070 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
5071 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
5072 and RS6000 machine numbers using #defined constants from
5073 archures.c.
5074 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
5075 machine numbers using #defined constants from archures.c. Add
5076 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
5077 64-bit words in 620 entry.
5078 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
5079 RSC, and RS2.
5080 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
5081
5082 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
5083
5084 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
5085 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
5086 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
5087
5088 2000-06-16 Nicholas Duffek <nsd@redhat.com>
5089
5090 * bfd-in.h (bfd_family_coff): Define.
5091 * bfd-in2.h: Regenerate.
5092 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
5093 coff_find_nearest_line): Check COFFness using bfd_family_coff()
5094 instead of bfd_target_coff_flavour.
5095 * cofflink.c (_bfd_coff_final_link): Likewise.
5096 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
5097 exclude XCOFF files.
5098 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
5099 Likewise.
5100 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
5101 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
5102 * xcofflink.c (XCOFF_XVECP): Delete.
5103 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
5104 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
5105 bfd_xcoff_record_link_assignment,
5106 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
5107 check for bfd_target_xcoff_flavour.
5108
5109 2000-06-16 Nicholas Duffek <nsd@redhat.com>
5110
5111 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
5112 files on AIX 4.3.
5113 (read_hdr): New function.
5114 (rs6000coff_core_p): Store mstsave or __context64 struct instead
5115 of trying to extract individual registers. Set abfd->arch_info
5116 to match the architecture that created the core file.
5117 (rs6000coff_get_section_contents): Delete.
5118 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
5119
5120 2000-06-14 H.J. Lu <hjl@gnu.org>
5121
5122 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
5123 is NULL.
5124
5125 2000-06-13 H.J. Lu <hjl@gnu.org>
5126
5127 * configure: Regenerate.
5128
5129 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
5130
5131 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
5132 armpei_little_vec.
5133
5134 2000-06-08 David O'Brien <obrien@FreeBSD.org>
5135
5136 * configure.in (VERSION): Update to show this is the CVS mainline.
5137
5138 2000-06-07 Alan Modra <alan@linuxcare.com.au>
5139
5140 * elf32-d10v.c: Include elf/d10v.h
5141 (enum reloc_type): Delete.
5142 * elf32-d30v.c: Include elf/d30v.h
5143 (enum reloc_type): Delete.
5144
5145 * Makefile.am: Run "make dep-am" to regenerate dependencies.
5146 * Makefile.in: Regenerate.
5147
5148 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
5149 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
5150 move HOWTOs into elf_howto_table.
5151 (R_386_standard, R_386_ext_offset): Define.
5152 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
5153 (elf_i386_reloc_type_lookup): Modify calculation of index into
5154 elf_howto_table since we've removed the padding.
5155 (elf_i386_info_to_howto_rel): Likewise.
5156 (elf_i386_relocate_section): Likewise.
5157
5158 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
5159
5160 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
5161
5162 2000-06-05 H.J. Lu <hjl@gnu.org>
5163
5164 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
5165 an error when seeing an undefined symbol with hidden/internal
5166 attribute. It is handled in *_relocate_section ().
5167
5168 2000-06-05 H.J. Lu <hjl@gnu.org>
5169
5170 * elflink.h (elf_fix_symbol_flags): Follow the link for the
5171 indirect symbol for the ELF_LINK_NON_ELF bit.
5172 (elf_link_output_extsym): Don't output the indirect symbol even
5173 if the ELF_LINK_NON_ELF bit is set.
5174
5175 2000-06-01 J.T. Conklin <jtc@redback.com>
5176
5177 * config.bfd (i[3456]86-*-netbsdelf*): New target.
5178 (i[3456]86-*-netbsdaout*): New target.
5179 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
5180 (i[3456]86-*-openbsd*): Likewise.
5181
5182 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
5183
5184 * trad-core.c: From hpux-core.c, include <dirent.h> or
5185 <sys/ndir.h> when possible.
5186
5187 2000-05-31 Ulrich Drepper <drepper@redhat.com>
5188
5189 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
5190 definitions. We must not assume they are sorted in the file
5191 according to their index numbers.
5192
5193 2000-05-31 Alan Modra <alan@linuxcare.com.au>
5194
5195 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
5196 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
5197 R_PARISC_DIR17F are for absolute branches; Handle them as such.
5198
5199 2000-05-30 Nick Clifton <nickc@cygnus.com>
5200
5201 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
5202 80960CA, 80960MC as valid machine names.
5203
5204 2000-05-30 H.J. Lu <hjl@gnu.org>
5205
5206 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
5207 visibility bits if the symbol is undefined. Correctly handle
5208 weak undefined symbols with hidden and internal attributes.
5209
5210 * elflink.h (elf_link_add_object_symbols): Always turn the
5211 symbol into local if it has the hidden or internal attribute.
5212
5213 2000-05-29 Philip Blundell <philb@gnu.org>
5214
5215 * ppcboot.c: Add packed attribute if compiling with GCC.
5216
5217 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
5218
5219 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
5220
5221 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
5222
5223 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
5224 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
5225 corefile on a 64-bit (Sparc Solaris) host. Also clean up
5226 a few old comments.
5227
5228 2000-05-26 Alan Modra <alan@linuxcare.com.au>
5229
5230 * Makefile.am: Update dependencies with "make dep-am"
5231 * Makefile.in: Regenerate.
5232
5233 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
5234 bindtextdomain): Replace defines with those from intl/libgettext.h
5235 to quieten gcc warnings.
5236
5237 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
5238
5239 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
5240
5241 * archive.c (normalize, bfd_bsd_truncate_arname,
5242 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
5243 file names with backslashes.
5244
5245 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
5246 before opening it.
5247
5248 * sysdep.h: Include filenames.h.
5249
5250 2000-05-26 Alan Modra <alan@linuxcare.com.au>
5251
5252 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
5253
5254 2000-05-26 Jakub Jelinek <jakub@redhat.com>
5255
5256 * elf64-sparc.c (sparc64_elf_relax_section): New.
5257 (sparc64_elf_relocate_section): Optimize tail call into branch always
5258 if possible.
5259 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
5260 (elf32_sparc_relax_section): New.
5261
5262 2000-05-26 Jakub Jelinek <jakub@redhat.com>
5263
5264 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
5265 Remove unusued variables.
5266 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
5267 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
5268 previous fix, so that shared libs really don't influence targets
5269 extension mask and memory model.
5270
5271 2000-05-23 H.J. Lu <hjl@gnu.org>
5272
5273 * elf64-alpha.c (elf64_alpha_relocate_section): Check
5274 h->root.other not h->other.
5275 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
5276
5277 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
5278
5279 2000-05-23 H.J. Lu <hjl@gnu.org>
5280
5281 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
5282 undefined symbol with the non-default visibility attributes.
5283 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
5284 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
5285 * elf32-i370.c (i370_elf_relocate_section): Likewise.
5286 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
5287 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
5288 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
5289 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
5290 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
5291 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
5292 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
5293 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
5294
5295 2000-05-22 Richard Henderson <rth@cygnus.com>
5296
5297 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
5298 PCREL22, PCREL64I. Zero size of special relocs.
5299 (elf64_ia64_reloc_type_lookup): Likewise.
5300 (USE_BRL, oor_brl, oor_ip): New.
5301 (elf64_ia64_relax_section): New.
5302 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
5303 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
5304 (elf64_ia64_relocate_section): Likewise.
5305 (bfd_elf64_bfd_relax_section): New.
5306 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
5307 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
5308 * bfd-in2.h, libbfd.h: Regenerate.
5309
5310 2000-05-22 Nick Clifton <nickc@cygnus.com>
5311
5312 * configure.in : Add peigen.lo to MIPS PE targets.
5313 * configure: Regenerate.
5314
5315 2000-05-22 Momchil Velikov <velco@fadata.bg>
5316
5317 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
5318 only if it is known for both input and output bfds. Separate
5319 error message strings as in some languages, it may be necessary
5320 to change more than one place in the string to change between
5321 'big' and 'little'.
5322
5323 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
5324 endianess checks, call _bfd_generic_verify_endian_match() instead.
5325
5326 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
5327
5328 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
5329
5330 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
5331 endianess before checking bfd flavours.
5332
5333 2000-05-22 H.J. Lu <hjl@gnu.org>
5334
5335 * elflink.h (elf_link_output_extsym): Clear the visibility
5336 field for symbols not defined locally.
5337
5338 2000-05-18 Alan Modra <alan@linuxcare.com.au>
5339
5340 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
5341 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
5342 (hppa_rebuild_insn): Mask immediate bits here instead.
5343 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
5344
5345 2000-05-18 Momchil Velikov <velco@fadata.bg>
5346
5347 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
5348 relocs for an executable, ensure that they are virtual addresses.
5349
5350 2000-05-18 Jeffrey A Law (law@cygnus.com)
5351
5352 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
5353
5354 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
5355 Rick Gorton <gorton@scrugs.lkg.dec.com>
5356
5357 * elflink.h: Add emitrelocations support: when enabled, relocation
5358 information and relocation sections are put into final output
5359 executables. If the emitrelocations flag is set, do the following:
5360 (elf_bfd_final_link): Emit relocation sections.
5361 (elf_link_input_bfd): Compute relocation section contents.
5362 (elf_gc_sections): Don't clean relocation sections.
5363
5364 2000-05-16 Catherine Moore <clm@cygnus.com>
5365
5366 * som.c (som_decode_symclass): Recognize weak symbols.
5367
5368 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
5369
5370 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
5371 read idata section only from dataoff.
5372 (pe_print_edata): Correctly check for valid eat_member.
5373
5374 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
5375
5376 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
5377
5378 2000-05-14 Philip Blundell <philb@gnu.org>
5379
5380 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
5381
5382 2000-05-12 Alan Modra <alan@linuxcare.com.au>
5383
5384 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
5385
5386 * peigen.c (pe_print_idata): Look for .idata section and print
5387 info even if data directory has zero entries. Read idata section
5388 starting from dataoff, and adjust all data offsets to suit. Cast
5389 all bfd_vma vars to unsigned long before passing to fprintf.
5390 * peigen.c (pe_print_edata): Similarly, look for .edata section
5391 and print info even if data directory has zero entries. Cast
5392 all bfd_vma vars to unsigned long before passing to fprintf.
5393
5394 From Szabolcs Szakacsits <szaka@F-Secure.com>
5395 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
5396 directory size which may be bogus.
5397 * peigen.c (pe_print_edata): Similarly.
5398
5399 2000-05-09 Alan Modra <alan@linuxcare.com.au>
5400
5401 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
5402 section is empty.
5403 (copy_private_bfd_data): Allow for space possibly taken up by elf
5404 headers when calculating segment physical address from lma.
5405
5406 2000-05-08 Alan Modra <alan@linuxcare.com.au>
5407
5408 * versados.c (versados_scan): Init stringlen and pass_2_done.
5409
5410 * trad-core.c (trad_unix_core_file_p): Return
5411 bfd_error_wrong_format rather than bfd_error_file_truncated.
5412
5413 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
5414 add_data_entry. DataDirectory virtual address is relative.
5415 (pe_print_idata): Account for relative DataDirectory virtual
5416 addresses. Don't trash datasize inside POWERPC_LE_PE code.
5417 (pe_print_edata): Similarly.
5418
5419 From Szabolcs Szakacsits <szaka@F-Secure.com>
5420 * peigen.c (dir_names): Add Delay Import Directory.
5421 (pe_print_idata): Always search for bfd section containing
5422 idata address rather than looking up section name. Print this
5423 section name rather than .idata.
5424 (pe_print_edata): Similarly. Also print some fields as %08lx.
5425 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
5426 Win32Version.
5427
5428 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
5429
5430 * xcoff.h: Rename to xcoff-target.h
5431 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
5432 * coff-rs6000.c: Ditto.
5433 * coff64-rs6000.c: Ditto.
5434 * coff-pmac.c: Ditto.
5435 * Makefile.in: Regenerate.
5436
5437 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
5438
5439 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
5440 Change U802TOC64MAGIC to U803XTOCMAGIC.
5441
5442 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
5443
5444 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
5445 * bfd-in.h: Prototype bfd_elf_get_arch_size.
5446 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
5447
5448 2000-05-04 Alan Modra <alan@linuxcare.com.au>
5449
5450 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
5451
5452 2000-05-03 Martin v. L\81öwis <loewis@informatik.hu-berlin.de>
5453
5454 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
5455 hidden and internal symbols.
5456 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
5457 visibility.
5458 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
5459 assign a PLT or GOT entry to symbols with hidden and
5460 internal visibility.
5461
5462 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
5463
5464 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
5465 the .bss section.
5466 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
5467
5468 2000-05-02 H.J. Lu <hjl@gnu.org>
5469
5470 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
5471 ELFOSABI_SYSV.
5472
5473 2000-05-02 Alan Modra <alan@linuxcare.com.au>
5474
5475 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
5476 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
5477 dependencies.
5478 * Makefile.in: Regenerate.
5479
5480 2000-05-01 Jim Wilson <wilson@cygnus.com>
5481
5482 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
5483 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
5484 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
5485 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
5486 * Makefile.in: Rebuild.
5487
5488 2000-05-02 Alan Modra <alan@linuxcare.com.au>
5489
5490 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
5491 doesn't work very well.
5492
5493 * elf-hppa.h (elf_hppa_internal_shdr): Define.
5494 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
5495 Set hdr->s_type to 1 if ARCH_SIZE == 32.
5496 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
5497 (elf_hppa_info_to_howto): Likewise.
5498 (elf_hppa_info_to_howto_rel): Likewise.
5499 (elf_hppa_reloc_type_lookup): Likewise.
5500 (elf_hppa_is_local_label_name): Likewise.
5501 (elf_hppa_fake_sections): Likewise.
5502 (elf_hppa_final_write_processing): Likewise.
5503 (elf_hppa_howto_table): Fully initialise all entries.
5504 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
5505 (elf_hppa_info_to_howto): Likewise.
5506 (elf_hppa_info_to_howto_rel): Likewise.
5507 (elf_hppa_reloc_type_lookup): Likewise.
5508 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
5509 elf_hppa_unmark_useless_dynamic_symbols,
5510 elf_hppa_remark_useless_dynamic_symbols,
5511 elf_hppa_record_segment_addrs, elf_hppa_final_link,
5512 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
5513 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
5514 elf32-hppa.c mess is cleaned up.
5515 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
5516 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
5517 r_field then call hppa_field_adjust inline func with variable
5518 r_field arg, instead call hppa_field_adjust with fixed arg.
5519 In case R_PARISC_PCREL22F, don't set r_field.
5520 (elf_hppa_relocate_insn): Change args and return type to unsigned
5521 int. Call re_assemble_* funcs to do the work.
5522
5523 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
5524 sign extending.
5525
5526 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
5527 extending.
5528 (sign_extend): Mask first before sign extending.
5529 (low_sign_extend): Rewrite without condition expression.
5530 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
5531 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
5532 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
5533 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
5534 result as function return value rather than through pointer arg.
5535 Accept unsigned int args, and return unsigned int.
5536 (re_assemble_3): New. Combines function of dis_assemble_3 with
5537 re-assembly of opcode and immediate.
5538 (re_assemble_12): Likewise.
5539 (re_assemble_16): Likewise.
5540 (re_assemble_17): Likewise.
5541 (re_assemble_21): Likewise.
5542 (re_assemble_22): Likewise.
5543 (hppa_field_adjust): Rewrite and document, paying attention to
5544 size of types and signed/unsigned issues.
5545 (get_opcode): Shift before masking.
5546 (FDLW): Rename to FLDW.
5547 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
5548 (hppa_rebuild_insn): Change args and return value to unsigned
5549 int. Make use of re_assemble_*. Correct case 11.
5550
5551 * dep-in.sed: Handle ../opcodes/.
5552 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
5553 elf64-hppa.h, hppa_stubs.h, xcoff.h.
5554 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
5555 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
5556 elfarm-nabi.lo dependencies outside of auto-dependency area.
5557 Regenerate dependencies.
5558 * Makefile.in: Regenerate.
5559
5560 * configure.in (TRAD_HEADER): Test non-null before
5561 AC_DEFINE_UNQUOTED.
5562 * configure: Regenerate.
5563
5564 * reloc.c: Fix mis-spelling in comment.
5565
5566 2000-05-01 Alan Modra <alan@linuxcare.com.au>
5567
5568 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
5569 * vms.c (vms_openr_next_archived_file): Return NULL.
5570
5571 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
5572
5573 * coffcode.h Copy changes mistakenly done to libcoff.h in
5574 4/24/2000 patch.
5575
5576 2000-04-29 Andreas Jaeger <aj@suse.de>
5577
5578 * libbfd-in.h: Correctly check GCC version.
5579 * bfd-in.h: Likewise.
5580 * libhppa.h: Likewise.
5581 * libbfd.h: Regenerate.
5582 * bfd-in2.h: Regenerate.
5583
5584 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
5585
5586 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
5587 coffdu-rs6000.{lo,c}.
5588 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
5589 on xcoff.h
5590 * Makefile.in: Regenerate.
5591 * xcoff.h: New file.
5592 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
5593 * coff-rs6000.c: Move all declarations and defines that are
5594 common to the xcoff backends into xcoff.h
5595 * coff64-rs6000.c: Ditto,
5596
5597 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
5598
5599 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
5600 _bfd_coff_force_symnames in strings and
5601 _bfd_coff_debug_string_prefix_length to their default values.
5602 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
5603
5604 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
5605
5606 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
5607 _bfd_coff_force_symnames in strings and
5608 _bfd_coff_debug_string_prefix_length to their default values.
5609
5610 2000-04-27 Alan Modra <alan@linuxcare.com.au>
5611
5612 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
5613 Check local_got_refcounts before dereferencing.
5614
5615 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
5616 before deciding we don't need R_PPC_PLT32 relocation.
5617 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
5618 dereferencing.
5619
5620 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
5621
5622 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
5623 .plt entries.
5624 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
5625 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
5626 (elf_i386_relocate_section): Allow for .plt to go missing.
5627 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
5628 can use a relative reloc for got as elf_i386_relocate_section.
5629 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
5630
5631 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
5632
5633 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
5634
5635 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
5636
5637 * Makefile.am (coff64-rs6000.lo): New rule.
5638 * Makefile.in: Regenerate.
5639 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
5640 xcoff_is_local_label_name, xcoff_rtype2howto,
5641 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
5642 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
5643 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
5644 (NO_COFF_SYMBOLS): Define.
5645 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
5646 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
5647 internally.
5648 (MINUS_ONE): New macro.
5649 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
5650 relocation.
5651 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
5652 coff_SWAP_aux_out): Map to the new functions.
5653 * coff64-rs6000.c: New file.
5654 * libcoff.h (bfd_coff_backend_data): Add new fields
5655 _bfd_coff_force_symnames_in_strings and
5656 _bfd_coff_debug_string_prefix_length.
5657 (bfd_coff_force_symnames_in_strings,
5658 bfd_coff_debug_string_prefix_length): New macros for above fields.
5659 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
5660 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
5661 of using coff_swap_sym_in directly.
5662 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
5663 (coff_set_flags) Set magic for XCOFF64.
5664 (coff_compute_section_file_positions): Add symbol name length to
5665 string section length if bfd_coff_debug_string_prefix_length is
5666 true.
5667 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
5668 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
5669 using coff_swap_lineno_in directly.
5670 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
5671 and _bfd_coff_debug_string_prefix_length fields.
5672 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
5673 symbol names into strings table when
5674 bfd_coff_force_symnames_in_strings is true.
5675 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
5676 SET_RELOC_VADDR): New macros.
5677 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
5678 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
5679 code.
5680 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
5681 changes within RS6000COFF_C specific code.
5682 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
5683 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
5684 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
5685 Extend existing hack on target name.
5686 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
5687 target name.
5688 * coff-tic54x.c (ticof): Keep up to date with new fields
5689 in bfd_coff_backend_data.
5690 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
5691 targ_selvecs to include rs6000coff64_vec for rs6000.
5692 * configure.in: Add rs6000coff64_vec case.
5693 * cpu-powerpc.c: New bfd_arch_info_type.
5694
5695 2000-04-24 Jeffrey A Law (law@cygnus.com)
5696
5697 * config.bfd: Only disable elf32-hppa vectors, not all of the
5698 BSD and OSF configuration support. Provide (disabled) clauses
5699 for PA64 support.
5700 * configure.in: Add clause for PA64 support.
5701 * configure: Rebuilt.
5702
5703 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
5704 (bfd_elf64_hppa_vec): Declare.
5705
5706 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
5707 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
5708 (elf64-hppa.lo): Add dependencies.
5709 * Makefile.in: Rebuilt.
5710
5711 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
5712
5713 2000-04-24 Jason Eckhardt <jle@cygnus.com>
5714
5715 * libhppa.h (dis_assemble_16): New function.
5716 (pa_arch): Added pa20w element.
5717
5718 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
5719
5720 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
5721 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
5722 bfd_elf64_slurp_reloc_table.
5723
5724 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
5725 definitions to get external names.
5726 (elf_write_relocs): Renamed from write_relocs and make global.
5727 (elf_slurp_reloc_table): Make global.
5728 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
5729
5730 * archive.c (hpux_uid_gid_encode): New function.
5731 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
5732 defined and the ID is greater than 99999.
5733 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
5734 special uid/gid fields into 32 bit values.
5735
5736 2000-04-21 Matthew Green <mrg@cygnus.com>
5737
5738 * config.bfd: Add NetBSD/sparc64 support.
5739
5740 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
5741 David Mosberger <davidm@hpl.hp.com>
5742 Timothy Wall <twall@cygnus.com>
5743 Jim Wilson <wilson@cygnus.com>
5744
5745 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
5746 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
5747 (BFD64_BACKENDS): Add elf64-ia64.lo.
5748 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
5749 (cpu-ia64.lo, elf64-ia64.lo): New rules.
5750 * Makefile.in: Rebuild.
5751 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
5752 (bfd_ia64_arch): Declare.
5753 (bfd_archures_list): Add bfd_ia64_arch.
5754 * bfd-in2.h: Rebuild.
5755 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
5756 * configure: Rebuild.
5757 * configure.host: (ia64-*-linux*): New host.
5758 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
5759 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
5760 * elf.c (prep_headers): Add bfd_arch_ia64.
5761 * libbfd.h: Rebuild.
5762 * reloc.c: Add IA-64 relocations.
5763 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
5764 Declare.
5765 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
5766 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
5767
5768 2000-04-21 Richard Henderson <rth@cygnus.com>
5769
5770 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
5771 contents when performing a partial link.
5772 (bfd_elf_d30v_reloc_21): Likewise.
5773
5774 2000-04-20 H.J. Lu <hjl@gnu.org>
5775
5776 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
5777 patch to symbols defined by a shared object.
5778 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
5779
5780 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5781
5782 K&R compiler fixes.
5783 * dwarf2.c (concat_filename): Avoid string literal concatenation.
5784 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
5785
5786 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
5787
5788 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
5789 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
5790 (coff-ia64.lo): Add dependency.
5791 * Makefile.in: Regenerate.
5792 * coff-ia64.c: New file.
5793 * efi-app-ia32.c: Ditto.
5794 * efi-app-ia64.c: Ditto.
5795 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
5796 (coff_set_flags): Ditto.
5797 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
5798 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
5799 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
5800 * configure: Regenerate.
5801 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
5802 (PUT_OPTHDR_IMAGE_BASE): Ditto.
5803 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
5804 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
5805 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
5806 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
5807 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
5808 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
5809 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
5810 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
5811 (GET_PDATA_ENTRY): Ditto.
5812 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
5813 data_start. Use above macros to read fields that are 64 bit wide for
5814 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
5815 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
5816 FileAlignment and SectionAlignment to minimum alignment if they
5817 are zero.
5818 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
5819 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
5820 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
5821 Use above macros to write fields that are 64 bit wide for
5822 COFF_WITH_PEP64.
5823 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
5824 5*4 otherwise. This should be right for IA-32 and IA-64, but may
5825 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
5826 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
5827 begin address, end address, and unwind info address only. Use
5828 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
5829 print addresses.
5830 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
5831 HIGH3ADJ relocation names.
5832 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
5833 * targets.c: Declare bfd_efi_app_ia32_vec and
5834 bfd_efi_app_ia64_vec.
5835 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
5836 bfd_efi_app_ia64_vec.
5837
5838 2000-04-17 Timothy Wall <twall@cygnus.com>
5839
5840 * bfd-in2.h: Add prototypes for tic54x load page access.
5841 * bfd-in.h: Regenerate.
5842 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
5843 in customized _set_arch_mach function.
5844 * coffcode.h (coff_set_alignment_hook): Set section load page if
5845 the appropriate macro is defined.
5846 (write_object_contents): Read section load page.
5847
5848 2000-04-13 Alan Modra <alan@linuxcare.com.au>
5849
5850 * elf32-hppa.h: Update copyright date.
5851
5852 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
5853 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
5854
5855 * elf32-d30v.c (MAX32): Don't use LL suffix.
5856 (MIN32): Define in terms of MAX32.
5857 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
5858
5859 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
5860 expression.
5861
5862 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
5863
5864 2000-04-12 Alan Modra <alan@linuxcare.com.au>
5865
5866 * dep-in.sed: Match space before file name, not after.
5867 * Makefile.am: Regenerate dependencies.
5868 * Makefile.in: Regenerate.
5869
5870 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
5871 case, allow address wrap-around stupidly removed 2000-03-17. Sign
5872 extend without an if statement.
5873
5874 2000-04-11 Alan Modra <alan@linuxcare.com.au>
5875
5876 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
5877 signed quantites.
5878 * elf32-mips.c (gprel16_with_gp): Likewise.
5879 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
5880 here using -0x40000, not (int)0xfffc0000.
5881 (elf32_hppa_size_of_stub): Likewise.
5882
5883 2000-04-11 Timothy Wall <twall@cygnus.com>
5884
5885 * coff-tic54x.c: Now builds with all targets.
5886 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
5887 * Makefile.in: Regenerate.
5888 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
5889 unitialized variable.
5890
5891 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
5892
5893 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
5894 --enable-build-warnings option.
5895 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
5896 * Makefile.in, configure: Re-generate.
5897
5898 2000-04-07 Nick Clifton <nickc@cygnus.com>
5899
5900 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
5901 BFD_RELOC_THUMB_PCREL_BLX.
5902
5903 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
5904 R_ARM_XPC25 and R_ARM_THM_PC22.
5905
5906 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
5907 R_ARM_XPC25 and R_ARM_THM_XPC22.
5908 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
5909 R_ARM_[XPC25|THM_XPC22].
5910
5911 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
5912 elf/arm-oabi.h to elf/arm.h
5913
5914 * Makefile.am: Fix dependency for elfarm-oabi.c
5915 * Makefile.in: Regenerate.
5916
5917 * bfd-in2.h: Regenerate.
5918 * libbfd.h: Regenerate.
5919
5920 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
5921
5922 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
5923 and restore it on failure. Release newly allocated tdata on
5924 failure.
5925
5926 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
5927
5928 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
5929 (decode_line_info): Set it. Report error if unit->line_offset is
5930 equal to or larger than it.
5931
5932 2000-04-07 Timothy Wall <twall@cygnus.com>
5933
5934 * targets.c: Added vecs for tic54x.
5935 * reloc.c: Added relocs for tic54x.
5936 * libbfd.h: Regenerated.
5937 * configure: Add TI COFF vecs for tic54x.
5938 * configure.in: Ditto.
5939 * config.bfd (targ_cpu): Recognize new tic54x target.
5940 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
5941 * bfd-in2.h: Add tic54x target and relocations.
5942 * Makefile.am, Makefile.in: Add tic54x target.
5943 * archures.c (bfd_archures_list): Add tic54x target.
5944 * coff-tic54x.c: New.
5945 * cpu-tic54x.c: New.
5946
5947 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
5948
5949 * elfcore.h (elf_core_file_p): call backend_object_p which
5950 thereby gets an opportunity to update the arch/machine type.
5951
5952 2000-04-06 Timothy Wall <twall@cygnus.com>
5953
5954 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
5955 class. Handle SEC_CLINK and SEC_BLOCK flags.
5956 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
5957 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
5958
5959 2000-04-06 Nick Clifton <nickc@cygnus.com>
5960
5961 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
5962 EF_INTERWORK if this is an unknown EABI.
5963 (elf32_arm_merge_private_bfd_data): Check EABI version
5964 numbers. Only check EF_xxx flags if the EABI version number
5965 is unknown.
5966 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
5967 if the EABI version number is unknown.
5968 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
5969 if the EABI version number is unknown.
5970
5971 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
5972
5973 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
5974 BFD_RELOC_SH_LOOP_END.
5975 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
5976 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
5977 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
5978 (sh_elf_reloc_loop): New function.
5979 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
5980 any more.
5981 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
5982 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
5983 * bfd-in2.h, libbfd.h: Regenerate.
5984
5985 2000-04-04 Alan Modra <alan@linuxcare.com.au>
5986
5987 * po/bfd.pot: Regenerate.
5988
5989 * Makefile.am: Remove extraneous mkdep comment.
5990 (MKDEP): Use gcc -MM rather than mkdep.
5991 (DEP): Quote when passing vars to sub-make. Add warning
5992 message to end.
5993 (DEP1): Rewrite for "gcc -MM".
5994 (CLEANFILES): Add DEP2.
5995 Update dependencies.
5996 * Makefile.in: Regenerate.
5997
5998 2000-04-03 Kevin Buettner <kevinb@redhat.com>
5999
6000 * configure.in: Added corefile support for AIX 4.3. In particular,
6001 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
6002 compiling rs6000-core.c.
6003 * configure: Regenerated.
6004
6005 2000-04-03 H.J. Lu <hjl@gnu.org>
6006
6007 * cache.c (bfd_open_file): Unlink the output file only if
6008 it has non-zero size.
6009
6010 2000-04-01 Ken Block USG <block@zk3.dec.com>
6011
6012 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
6013 relative relocations for non-loaded sections in shared objects.
6014 (elf64_alpha_check_relocs): Similarly.
6015
6016 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
6017
6018 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
6019 BFD_RELOC_16 to switch for extended relocs.
6020 (MY_swap_ext_reloc_in): New.
6021 (MY_swap_ext_reloc_out): New.
6022 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
6023 than NAME(aout,swap_ext_reloc_in) for extended relocs.
6024 (NAME(aout,squirt_out_relocs)): Similarly use
6025 MY_swap_ext_reloc_out.
6026 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
6027
6028 2000-04-03 Kazu Hirata <kazu@hxi.com>
6029
6030 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
6031 the R_PCRWORD_B case.
6032
6033 2000-03-31 Thomas de Lellis <tdel@wrs.com>
6034
6035 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
6036 on some targets.
6037 * ihex.c : Ditto.
6038
6039 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
6040
6041 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
6042 HOWTO references to bfd_elf_generic_reloc, that have
6043 partial_inplace == true, now use the new function. The function
6044 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
6045 extends its fixes to the R_M32R_{16,24,32} relocs.
6046 The new logic in m32r_elf_lo16_reloc() has been removed, and
6047 it instead calls the new routine to obtain that functionality.
6048
6049 2000-03-27 Alan Modra <alan@linuxcare.com.au>
6050
6051 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
6052 elf32_avr_check_relocs, avr_final_link_relocate,
6053 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
6054 elf32_avr_object_p): Add prototypes.
6055 (elf32_avr_gc_mark_hook): Add default for h->root.type.
6056 (bfd_elf_avr_final_write_processing): Make static.
6057
6058 2000-03-27 Denis Chertykov <denisc@overta.ru>
6059
6060 * cpu-avr.c: New file. BFD support routines for AVR architecture.
6061 * archures.c (bfd_architecture): Add AVR architecture.
6062 (bfd_archures_list): Add reference to AVR architecture info.
6063 * elf.c (prep_headers): Handle bfd_arch_avr.
6064 * reloc.c: Add various AVR relocation enums.
6065 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
6066 list.
6067 * Makefile.am: Add support for AVR elf.
6068 * configure.in: Likewise.
6069 * config.bfd: Likewise.
6070 * Makefile.in: Regenerate.
6071 * configure: This too.
6072 * bfd-in2.h: And this.
6073 * libbfd.h: And this.
6074
6075 2000-03-24 H.J. Lu <hjl@gnu.org>
6076
6077 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
6078 (elf64_alpha_find_reloc_at_ofs): Likewise.
6079
6080 2000-03-17 Alan Modra <alan@linuxcare.com.au>
6081
6082 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
6083 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
6084 allowable range used to be -2**(n-1) to 2**n-1.
6085 * reloc.c (_bfd_relocate_contents): Same here. Also replace
6086 "boolean overflow" with "bfd_reloc_status_type flag".
6087
6088 2000-03-14 Doug Evans <dje@casey.transmeta.com>
6089
6090 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
6091
6092 2000-03-14 Kazu Hirata <kazu@hxi.com>
6093
6094 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
6095 of shrinks properly, including the last reloc.
6096
6097 2000-03-13 Kazu Hirata <kazu@hxi.com>
6098
6099 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
6100 check for R_MOVL2.
6101
6102 2000-03-11 Alan Modra <alan@linuxcare.com.au>
6103
6104 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
6105 a format mismatch rather than an "error" from bfd_read such as
6106 bfd_error_file_truncated.
6107
6108 2000-03-10 Geoff Keating <geoffk@cygnus.com>
6109
6110 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
6111 sign-extension and big-endian compensation for
6112 R_MIPS_64 even in ld -r.
6113
6114 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
6115
6116 * elf32-mips.c (mips_elf_next_relocation): Rename from
6117 mips_elf_next_lo16_relocation, and generalize to look
6118 for any relocation type.
6119 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
6120 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
6121 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
6122 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
6123 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
6124 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
6125 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
6126 (mips_rtype_to_howto): Likewise.
6127 (mips_elf_calculate_relocation): Handle new relocs.
6128 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
6129 are paired. The addend for R_MIPS_GNU_REL16_S2
6130 is shifted right two bits.
6131
6132 2000-03-10 Alan Modra <alan@linuxcare.com.au>
6133
6134 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
6135 comment, and ensure it doesn't happen again.
6136 (bfd_install_relocation): Same here.
6137 (_bfd_relocate_contents): Don't bother assigning unused signmask
6138 shift result. Fix typos in comments.
6139 Remove trailing whitespace throughout file.
6140
6141 2000-03-07 Doug Evans <dje@casey.transmeta.com>
6142
6143 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
6144 * bfd-in2.h: Rebuild.
6145
6146 2000-03-06 Nick Clifton <nickc@cygnus.com>
6147
6148 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
6149 sym_ptr_ptr fields.
6150 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
6151 (SIZEOF_ILF_STRINGS): Redefine.
6152 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
6153 relative reloc, as opposed to a section relative reloc.
6154 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
6155 not C_LABEL.
6156 Add length of symbol's prefix to string pointer.
6157 Store a pointer to the symbol in the symbol pointer table.
6158 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
6159 Initialise the symbol pointer table.
6160 Store the hint in the Hint/Name table.
6161 Make the jump reloc be symbol realtive, not section relative.
6162 Create an import symbol for imported code.
6163
6164 2000-03-06 Catherine Moore <clm@cygnus.com>
6165
6166 * elf.c (swap_out_syms): Check for null type_ptr.
6167
6168 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
6169
6170 * aout-target.h (MY(write_object_contents)): Remove unused
6171 and unusable "#if CHOOSE_RELOC_SIZE".
6172 * pc532-mach.c (MY(write_object_contents)): Ditto.
6173 * netbsd.h (MY(write_object_contents)): Ditto.
6174 * hp300hpux.c (MY(write_object_contents)): Ditto.
6175 * freebsd.h (MY(write_object_contents)): Ditto.
6176 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
6177
6178 2000-02-29 H.J. Lu <hjl@gnu.org>
6179
6180 * peicode.h (jtab): Make it static.
6181
6182 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
6183 defined and COFF_IMAGE_WITH_PE is not defined.
6184 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
6185 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
6186
6187 2000-03-01 Nick Clifton <nickc@cygnus.com>
6188
6189 * coff-arm.c (bfd_arm_process_before_allocation): Make
6190 'symndx' signed to prevent compile time warning.
6191
6192 * coff-mcore.c: Remove unused prototype for pe_object_p.
6193
6194 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
6195 functions that are not used when COFF_IMAGE_WITH_PE is
6196 defined.
6197 (struct sh_opcode): Change type of 'flags' field to unsigned
6198 long so that it can hold the USESAS flag.
6199
6200 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
6201
6202 * elf-m10300.c (mn10300_elf_relax_section): Initialise
6203 'sym_sec'.
6204
6205 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
6206 parameters.
6207 Remove unusued variables and code.
6208 (elf_backend_add_symbol_hook): Fix prototype.
6209
6210 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
6211 'srelgot'.
6212
6213 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
6214 'oldinst'.
6215
6216 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
6217 parameters.
6218 Remove unusued variables and code.
6219 (elf_backend_add_symbol_hook): Fix prototype.
6220
6221 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
6222
6223 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
6224 to unused function parameter.
6225
6226 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
6227 parameters.
6228 Use EMPTY_HOWTO to initialise empty howto slots.
6229 Remove unused variables.
6230
6231 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
6232
6233 2000-03-01 H.J. Lu <hjl@gnu.org>
6234
6235 * aoutx.h (aout_link_input_section_std): Pass "true" to
6236 the undefined_symbol callback.
6237 (aout_link_input_section_ext): Likewise.
6238 * bout.c (get_value): Likewise.
6239 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
6240 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
6241 Likewise.
6242 (alpha_relocate_section): Likewise.
6243 * coff-arm.c (coff_arm_relocate_section): Likewise.
6244 * coff-i960.c (coff_i960_relocate_section): Likewise.
6245 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
6246 * coff-mips.c (mips_relocate_section): Likewise.
6247 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
6248 * coff-sh.c (sh_relocate_section): Likewise.
6249 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
6250 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
6251 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
6252 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
6253 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
6254 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
6255 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
6256 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6257 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
6258 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6259 * elf32-sh.c (sh_elf_relocate_section): Likewise.
6260 * elf32-v850.c (v850_elf_relocate_section): Likewise.
6261 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
6262 * elflink.h (elf_link_output_extsym): Likewise.
6263 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
6264 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
6265 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
6266
6267 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
6268 undefined_symbol callback when building shared library with
6269 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
6270 "true".
6271 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6272 * elf32-i386.c (elf_i386_relocate_section): Likewise.
6273 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6274 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6275 (elf32_mips_get_relocated_section_content): Likewise.
6276 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6277 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6278 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6279 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6280
6281 2000-02-28 Nick Clifton <nickc@cygnus.com>
6282
6283 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
6284 * Makefile.in: Regenerate.
6285
6286 * configure.in: Add support for mips and sh pe vectors.
6287 * configure: regenerate.
6288
6289 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
6290 targets.
6291
6292 * targets.c: Add mips and sh pe vectors.
6293
6294 * libpei.h (coff_final_link_postscript): Only define if not
6295 already defined.
6296
6297 * coffcode.h: Add support for WinCE magic numbers.
6298
6299 * peigen.c (pe_print_reloc): Update comment and rearrange
6300 appending of newline character.
6301
6302 * peicode.h: Add support for Image Library Format.
6303 (pe_ILF_vars): Structure containing data used by ILF code.
6304 (pe_ILF_make_a_section): New function. Create a section based
6305 on ILF data.
6306 (pe_ILF_make_a_reloc): New function. Create a reloc based on
6307 ILF data.
6308 (pe_ILF_make_a_symbol): New function. Create a symbol based
6309 on ILF data.
6310 (pe_ILF_save_relocs): New function. Store the relocs created
6311 by pe_ILF_make_a_reloc in a section.
6312 (pe_ILF_build_a_bfd): New function. Create a BFD describing
6313 an ILF object.
6314 (pe_ILF_object_p): New function. Return a bfd_target pointer
6315 for an ILF object.
6316 (pe_bfd_object_p): If an ILF object is detected call
6317 pe_ILF_object_p on it.
6318
6319 * coff-arm.c: Add support for WinCE relocs which are different
6320 from normal ARM COFF relocs.
6321 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
6322
6323 * coff-sh.c: Add support for sh-pe target.
6324 * pe-sh.c: New file. Support code for sh-pe target.
6325 * pei-sh.c: New file. Support code for sh-pe target.
6326
6327 * pe-mips.c: New file. Support code for mips-pe target.
6328 * pei-mips.c: New file. Support code for mips-pe target.
6329
6330 2000-02-27 Jakub Jelinek <jakub@redhat.com>
6331
6332 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
6333 architecture if the object causing the bump is dynamic.
6334 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
6335 and also don't it for memory ordering.
6336 (sparc64_elf_write_relocs): Take src_rela out of the loop.
6337
6338 2000-02-27 Ian Lance Taylor <ian@zembu.com>
6339
6340 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
6341 calling bfd_get_section_size_before_reloc.
6342 (decode_line_info): Likewise.
6343 (_bfd_dwarf2_find_nearest_line): Likewise.
6344
6345 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
6346
6347 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
6348 name of the libtool directory.
6349 * Makefile.in: Rebuild.
6350
6351 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
6352
6353 * som.c (SOM_HOWTO): Define.
6354 (som_hppa_howto_table): Use it.
6355
6356 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
6357
6358 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
6359
6360 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
6361
6362 2000-02-24 Catherine Moore <clm@cygnus.com>
6363
6364 * som.c (som_misc_symbol_info): Add field
6365 secondary_def.
6366 (som_bfd_derive_misc_symbol_info): Initialize
6367 secondary_def.
6368 (som_build_and_write_symbol_table): Keep track
6369 of secondary_def field.
6370 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
6371 if secondary_def field is set.
6372 (som_bfd_ar_write_symbol_stuff): Initialize
6373 secondary_def.
6374
6375 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
6376
6377 * dwarf2.c (read_address): Read 16-bits addresses.
6378 (parse_comp_unit): Accept addr_size == 2.
6379
6380 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
6381
6382 * bfd-in.h: Update copyright date.
6383
6384 2000-02-23 Linas Vepstas <linas@linas.org>
6385
6386 * cpu-i370.c: New file.
6387 * elf32-i370.c: New file.
6388 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
6389 (bfd_i370_arch): New.
6390 (bfd_archures_list): Add bfd_i370_arch.
6391 * elf.c (prep_headers): Add bfd_arch_i370.
6392 * Makefile.am: Add support for IBM 370 elf.
6393 * config.bfd: Likewise.
6394 * configure.in: Likewise.
6395 * libbfd.h (bfd_reloc_code_real_names): Likewise.
6396 * reloc.c (bfd_reloc_code_type): Likewise.
6397 * targets.c: Likewise.
6398
6399 * Makefile.in: Regenerate.
6400 * configure: Regenerate.
6401 * bfd-in2.h: Regenerate.
6402
6403 2000-02-22 Ian Lance Taylor <ian@zembu.com>
6404
6405 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
6406 invalid relocation types, and change them to R_386_NONE.
6407
6408 2000-02-22 H.J. Lu <hjl@gnu.org>
6409
6410 * elflink.h (elf_link_add_object_symbols): If a version symbol is
6411 not defined, don't add a second ELF_VER_CHR.
6412
6413 * elflink.h (elf_bfd_final_link): Call output_extsym for global
6414 symbols converted to local symbols even when stripping all
6415 symbols.
6416 (elf_link_output_extsym): Process global symbols converted to
6417 local symbols even if they are being stripped.
6418
6419 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
6420
6421 * archures.c (bfd_octets_per_byte): Return unsigned int.
6422 (bfd_arch_mach_octets_per_byte): Ditto.
6423 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
6424 comparison warning.
6425 * section.c (bfd_get_section_size_before_reloc): Quell signed
6426 vs. unsigned comparison warning.
6427 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
6428 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
6429 change. What was I thinking?
6430 * bfd-in2.h: Regenerate.
6431
6432 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
6433 (elf_gc_sections): Same here.
6434 (elf_gc_common_finalize_got_offsets): And here.
6435
6436 2000-02-21 Ian Lance Taylor <ian@zembu.com>
6437
6438 ELF HPPA doesn't work at present; remove it until it does.
6439 * config.bfd: Comment out setting targ_defvec to
6440 bfd_elf32_hppa_vec.
6441 * Makefile.am: Rebuild dependencies.
6442 (BFD32_BACKENDS): Remove elf32-hppa.lo.
6443 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
6444 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
6445 * Makefile.in: Rebuild.
6446 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
6447
6448 2000-02-18 Geoff Keating <geoffk@cygnus.com>
6449
6450 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
6451 is no bfd_free(). Revert bfd_free part of previous change.
6452
6453 2000-02-18 Geoff Keating <geoffk@cygnus.com>
6454
6455 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
6456 arrays.
6457 (coff_compute_section_file_positions): Use bfd_free to pair
6458 bfd_malloc.
6459 (coff_write_object_contents): Likewise.
6460
6461 * coff-rs6000.c (xcoff_howto_table_16): New variable.
6462 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
6463
6464 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
6465
6466 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
6467 (xcoff_ar_file_hdr_big): New structure.
6468 (SIZEOF_AR_FILE_HDR_BIG): New macro.
6469 (xcoff_ar_hdr_big): New structure.
6470 (SIZEOF_AR_HDR_BIG): New macro.
6471 (xcoff_big_format_p): New macro.
6472 (xcoff_ardata_big): New macro.
6473 (arch_xhdr_big): New macro.
6474 (xcoff_slurp_armap): Handle large archives.
6475 (xcoff_archive_p): Detect large archives.
6476 (xcoff_read_ar_hdr): Handle large archives.
6477 (xcoff_openr_next_archived_file): Handle large archives.
6478 (xcoff_generic_stat_arch_elt): Handle large archives.
6479 (xcoff_write_armap_old): Rename from xcoff_write_armap.
6480 (xcoff_write_armap_big): New function.
6481 (xcoff_write_armap): New function, dispatch to _old or _big.
6482 (xcoff_write_archive_contents_old): Rename from
6483 xcoff_write_archive_contents.
6484 (xcoff_write_archive_contents_big): New function.
6485 (xcoff_write_archive_contents): New function, dispatch to _old or
6486 _big.
6487
6488 2000-02-18 Richard Henderson <rth@cygnus.com>
6489
6490 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
6491 and hide_symbol members.
6492 (elf_link_hash_copy_indirect): Remove.
6493 (elf_link_hash_hide_symbol): Remove.
6494 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
6495 and elf_backend_hide_symbol.
6496 (_bfd_elf_link_hash_copy_indirect): Declare.
6497 (_bfd_elf_link_hash_hide_symbol): Declare.
6498 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
6499 (_bfd_elf_link_hash_hide_symbol): Likewise.
6500 (_bfd_elf_link_hash_table_init): Don't init killed members.
6501 * elflink.h (elf_link_add_object_symbols): Use the bed function
6502 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
6503 (elf_link_assign_sym_version): Likewise.
6504 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
6505 (elf_backend_hide_symbol): Likewise.
6506 (elfNN_bed): Update for new members.
6507
6508 2000-02-17 Kevin Buettner <kevinb@redhat.com>
6509
6510 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
6511 STACK_END_ADDR): Define for new core file format.
6512 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
6513 for handling the vagaries of the various core file structures used
6514 by AIX over the years.
6515 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
6516 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
6517 core_dumpx structure.
6518
6519 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
6520
6521 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
6522 (bfd_mach_sh3_dsp): Likewise.
6523 (bfd_mach_sh4): Reinstate.
6524 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
6525 * bfd-in2.h: Regenerate.
6526 * coff-sh.c (struct sh_opcode): flags is no longer short.
6527 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
6528 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
6529 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
6530 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
6531 (sh_opcodes): No longer const.
6532 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
6533 (sh_insn_uses_reg): Check for USESAS and USESR8.
6534 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
6535 (_bfd_sh_align_load_span): Return early for SH4.
6536 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
6537 Take into account that field b of a parallel processing insn
6538 could be mistaken for a separate insn.
6539 * cpu-sh.c (arch_info_struct): New array elements for
6540 sh2, sh-dsp and sh3-dsp.
6541 Reinstate element for sh4.
6542 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
6543 (SH4_NEXT): Reinstate.
6544 (SH3_NEXT, SH3E_NEXT): Adjust.
6545 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
6546 * elf32-sh.c (sh_elf_set_private_flags): New function.
6547 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
6548 (sh_elf_merge_private_data): New function.
6549 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
6550 (bfd_elf32_bfd_copy_private_bfd_data): Define.
6551 (bfd_elf32_bfd_merge_private_bfd_data): Change to
6552 sh_elf_merge_private_data.
6553
6554 2000-02-13 Richard Henderson <rth@cygnus.com>
6555
6556 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
6557 hide_symbol members.
6558 (elf_link_hash_copy_indirect): New.
6559 (elf_link_hash_hide_symbol): New.
6560 * elflink.h (elf_link_add_object_symbols): Break out copy from
6561 indirect new new symbol to elf.c.
6562 (elf_link_assign_sym_version): Break out privatization of
6563 non-exported symbol to elf.c.
6564 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
6565 (_bfd_elf_link_hash_hide_symbol): New.
6566 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
6567
6568 2000-02-13 Ian Lance Taylor <ian@zembu.com>
6569
6570 * section.c (_bfd_strip_section_from_output): Add info parameter.
6571 If it passed as non-NULL, use it to check whether any input BFD
6572 has an input section which uses this output section. Change all
6573 callers.
6574 * bfd-in2.h: Rebuild.
6575
6576 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
6577 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
6578 1999-11-29.
6579 * bfd-in2.h: Rebuild.
6580
6581 2000-02-10 Timothy Wall <twall@cygnus.com>
6582
6583 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
6584 allow final modifications of swapped-in symbol.
6585 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
6586 * coffcode.h (coff_write_relocs): Use macro
6587 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
6588 symbol index should be set to -1.
6589
6590 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
6591
6592 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
6593 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
6594 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
6595 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
6596 sh_insns_uses_or_sets_freg): New functions.
6597 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
6598 * (sh_insns_conflict): Use new functions and new macros to
6599 detect conflicts when two instructions both set same integer registers,
6600 both set same fp register, and both set special register.
6601
6602 2000-02-09 Timothy Wall <twall@cygnus.com>
6603
6604 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
6605 swapping in sections, so that the swapping routines have access to
6606 the arch/mach info.
6607
6608 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
6609
6610 * coff-go32.c: Update comment. Update copyright.
6611
6612 2000-01-27 Thomas de Lellis <tdel@windriver.com>
6613
6614 * syms.c (bfd_decode_symclass)
6615 Two new class characters were added - 'V' and 'v'. The
6616 meaning of 'W' is now restricted to just weak non-object
6617 symbols. This allows differentiation between, for example,
6618 weak functions vs weak objects. nm for example now dumps:
6619 'W' = weak global
6620 'w' = weak unresolved
6621 'V' = weak global object
6622 'v' = weak unresolved object
6623
6624 (bfd_is_undefined_symclass): New function. Return true if the
6625 given symbol class represents and undefined/unresolved symbol.
6626
6627 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
6628 unresolved symbols.
6629
6630 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
6631
6632 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
6633 STT_ARM_16BIT flag set, but it is not attached to a data object
6634 return STT_ARM_16BIT so that it will be treated as code by the
6635 disassembler.
6636
6637 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
6638
6639 * coff-i386.c (i3coff_object_p): Remove prototype.
6640 Update copyright.
6641
6642 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
6643 to name. Update copyright.
6644
6645 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
6646 assignment to avoid warning. Update copyright.
6647
6648 2000-01-24 Robert Lipe (robertl@sco.com)
6649
6650 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
6651 instead of using GNU C extension.
6652
6653 2000-01-21 Nick Clifton <nickc@cygnus.com>
6654
6655 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
6656 amount from a bfd_in_memory structure.
6657 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
6658 structure.
6659
6660 2000-01-14 Nick Clifton <nickc@cygnus.com>
6661
6662 * linker.c (default_indirect_link_order): oops - fix incorrectly
6663 applied patch from Tim Wall.
6664
6665 2000-01-13 Timothy Wall (twall@tiac.net>
6666
6667 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
6668 = scnhsz, filhsz, relsz, aoutsz, etc)
6669
6670 * coffswap.h: Ditto.
6671
6672 2000-01-13 Nick Clifton <nickc@cygnus.com>
6673
6674 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
6675 interwork thumb to arm stub.
6676
6677 2000-01-13 Timothy Wall (twall@tiac.net>
6678
6679 * archures.c (bfd_octets_per_byte): New function: Return
6680 target byte size.
6681 (bfd_arch_mach_octets_per_byte): New function: Return target
6682 byte size.
6683
6684 * section.c: Distinguish between octets and bytes for usage of
6685 _cooked_size, _raw_size, and output_offset. Clarify
6686 description of bfd_set_section_contents.
6687
6688 * bfd-in2.h: Regenerate.
6689
6690 * coffgen.c: Indicate that the offset parameter is in bytes, not
6691 octets.
6692
6693 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
6694 where appropriate to get the octet offset when calling
6695 bfd_set_section_contents.
6696 (bfd_coff_reloc_link_order): Ditto.
6697
6698 * linker.c (bfd_generic_reloc_link_order): Ditto.
6699 (_bfd_default_link_order): Ditto.
6700
6701 * reloc.c (bfd_perform_relocation): Distinguish between octets
6702 and bytes. Use octets when indexing into octet data; use bytes
6703 when calculating target addresses.
6704 (bfd_install_relocation): Ditto.
6705
6706 * srec.c (srec_write_section): Ditto.
6707
6708 2000-01-13 Nick Clifton <nickc@cygnus.com>
6709
6710 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
6711 3 to 2. This allows 4 byte sized sections, which is necessary for
6712 dlltool to build functioning DLLs.
6713
6714 2000-01-10 Philip Blundell <pb@futuretv.com>
6715
6716 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
6717 (arm*-*-conix*): New target.
6718
6719 2000-01-10 Egor Duda <deo@logos-m.ru>
6720
6721 * config.bfd: Include elf32_i386 vector to target list for cygwin
6722 and mingw.
6723
6724 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
6725 * configure.in: Test for structure win32_pstatus_t in
6726 <sys/procfs.h>
6727 * configure: Regenerate.
6728
6729 * elf.c (elfcore_grok_win32pstatus): New function: process
6730 win32_pstatus_t notes in elf core file.
6731 (elfcore_grok_note): Detect win32_pstatus notes.
6732
6733 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
6734
6735 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
6736 visibility.
6737 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
6738 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
6739
6740 For older changes see ChangeLog-9899
6741 \f
6742 Local Variables:
6743 mode: change-log
6744 left-margin: 8
6745 fill-column: 74
6746 version-control: never
6747 End:
This page took 0.221775 seconds and 5 git commands to generate.