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