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