2007-07-26 Michael Snyder <msnyder@access-company.com>
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
b7fd5ce1
MS
12007-07-26 Michael Snyder <msnyder@access-company.com>
2
078c4bfc
MS
3 * aoutx.h (slurp_reloc_table): Return TRUE if reloc_size == zero
4 or count == zero.
5
814b5378
MS
6 * tekhex.c (first_phase): Check return value for null.
7
b7fd5ce1
MS
8 * elf.c (_bfd_elf_get_synthetic_symtab): Remove meaningless
9 pointer increment.
10
b9da616a
AM
112007-07-26 Alan Modra <amodra@bigpond.net.au>
12
33774f08
AM
13 * elflink.c (_bfd_elf_fix_symbol_flags): Remove unnecessary
14 check on dynobj. Remove bed shadow.
15
e62071b6
AM
16 * srec.c (srec_get_section_contents): Return immediately on
17 count zero. Check that offset and count are within section.
18 * libbfd.c (_bfd_generic_get_section_contents): Check that
19 offset + count does not overflow.
20
b9da616a
AM
21 * srec.c (srec_canonicalize_symtab): Don't alloc when symcount
22 is zero. Correct return value on error.
23 * mmo.c (mmo_canonicalize_symtab): Likewise.
24 * binary.c (binary_canonicalize_symtab) Correct return on error.
25
c2c96631
TS
262007-07-26 Thiemo Seufer <ths@mips.com>
27
28 * bfd.c (_bfd_set_gp_value): Use abort instead of BFD_FAIL.
29
d4947150
AM
302007-07-26 Alan Modra <amodra@bigpond.net.au>
31
32 * reloc.c (bfd_generic_get_relocated_section_contents): Avoid
33 bfd_canonicalize_reloc call when bfd_get_reloc_upper_bound
34 says there are no relocs.
35
bd210d54 362007-07-26 Doug Kwan <dougkwan@google.com>
d4947150 37
bd210d54
NC
38 Speed up bfd_dwarf2_find_line.
39 * dwarf2.c (struct dwarf2_debug): Add new fields to support function
40 and variable info hash tables. Add last_comp_unit, info_hash_count,
41 funcinfo_hash_table, varinfo_hash_table, hash_units_head.
42 (struct comp_unit): Add prev_unit, cached.
43 (struct info_list_node, struct info_hash_entry,
44 struct info_hash_table): New.
45 (info_hash_table_newfunc, create_info_hash_table,
46 insert_info_hash_table, lookup_info_hash_table): New functions
47 implementing function and variable info hash tables.
48 (scan_unit_for_symbols): Add checks to make sure hash tables are
49 consistent with compilation units.
50 (comp_unit_maybe_decode_line_info): New function.
51 (comp_unit_find_line): Use comp_unit_maybe_decode_line_info.
52 (reverse_funcinfo_list, reverse_varinfo_list, comp_unit_hash_info,
53 info_hash_lookup_funcinfo, info_hash_lookup_varinfo,
54 stash_maybe_update_info_hash_table, stash_verify_info_hash_table,
55 stash_maybe_enable_info_hash_tables, stash_find_line_fast): New
56 functions. Make use of info hash tables to speed up
57 bfd_dwarf2_find_line.
58 (find_line): Use hash table for faster lookup if it is turned on.
59 Also add code to maintain bi-directional link in comp units.
60
353c5574
MS
612007-07-25 Michael Snyder <msnyder@access-company.com>
62
63 * coffgen.c (_bfd_coff_get_external_symbols): Nothing to be done
64 if size == 0; return and avoid possible null pointer issues.
65
f08c429c
AM
662007-07-25 Alan Modra <amodra@bigpond.net.au>
67
68 * linker.c (generic_link_add_symbol_list): Warning fix.
69
d0f16d5e
MS
702007-07-24 Michael Snyder <msnyder@access-company.com>
71
f6eea5ae
MS
72 * opncls.c (bfd_make_writable): Check return from bfd_malloc.
73
d0f16d5e
MS
74 * elflink.c (bfd_elf_final_link): Avoid redundant frees -- return
75 on bfd_malloc error rather than goto error_return.
76
4d269e42
AM
772007-07-24 Alan Modra <amodra@bigpond.net.au>
78
79 * elflink.c (_bfd_elf_link_just_syms, merge_sections_remove_hook,
80 _bfd_elf_merge_sections, _bfd_elf_link_hash_newfunc,
81 _bfd_elf_link_hash_copy_indirect, _bfd_elf_link_hash_hide_symbol,
82 _bfd_elf_link_hash_table_init, _bfd_elf_link_hash_table_create,
83 bfd_elf_set_dt_needed_name, bfd_elf_get_dyn_lib_class,
84 bfd_elf_set_dyn_lib_class, bfd_elf_get_needed_list,
85 bfd_elf_get_runpath_list, bfd_elf_get_dt_soname,
86 bfd_elf_get_bfd_needed_list, struct elf_symbuf_symbol,
87 struct elf_symbuf_head, struct elf_symbol, elf_sort_elf_symbol,
88 elf_sym_name_compare, elf_create_symbuf,
89 bfd_elf_match_symbols_in_sections,
90 _bfd_elf_match_sections_by_type): Move to here..
91 * elf.c: ..from here.
92
a26587ba
RS
932007-07-23 Richard Sandiford <richard@codesourcery.com>
94
95 * elflink.c (_bfd_elf_fix_symbol_flags): Only assert the type
96 of weakdef->root.type if weakdef has no regular definition.
97
0e53d9da
AN
982007-07-22 Adam Nemet <anemet@caviumnetworks.com>
99
100 * elfxx-mips.c (struct mips_elf_link_hash_table): Add new field
101 small_data_overflow_reported.
102 (_bfd_mips_elf_link_hash_table_create): Initialize it.
103 (_bfd_mips_elf_relocate_section) <bfd_reloc_overflow>: Report
104 small-data section overflow.
105
6b33789f
NC
1062007-07-19 Doug Kwan <dougkwan@google.com>
107
4d269e42
AM
108 PR binutils/4797
109 * dwarf2.c: (find_line) Do not dereference functionname_ptr if
110 do_line is true.
6b33789f 111
13161072 1122007-07-18 Bob Wilson <bob.wilson@acm.org>
4d269e42 113
13161072
BW
114 * elf32-xtensa.c (xtensa_callback_required_dependence): Ignore
115 non-ELF sections.
4d269e42 116
e29297b7 1172007-07-18 Bob Wilson <bob.wilson@acm.org>
4d269e42 118
e29297b7
BW
119 * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Get section
120 vma and size for dynamic tags from the output sections.
4d269e42 121
a5d1b3b5
AM
1222007-07-18 Alan Modra <amodra@bigpond.net.au>
123
124 * elf-bfd.h (struct sym_sec_cache): Delete "sec". Add "shndx".
125 * elf.c (bfd_section_from_r_symndx): Don't cache bfd section of
126 symbol. Instead cache ELF section index. Remove redundant
127 checks of st_shndx.
128
d955dada
MF
1292007-07-15 Mike Frysinger <vapier@gentoo.org>
130
131 * trad-core.c (NBPG): If not defined, set to getpagesize().
132
979dc3bc
RM
1332007-07-13 Roland McGrath <roland@redhat.com>
134
135 * elf-bfd.h (struct elf_obj_tdata): Revert last change.
136 Add after_write_object_contents, after_write_object_contents_info.
137 * elf.c (_bfd_elf_write_object_contents): Revert last change.
138 Instead, call after_write_object_contents if set.
139
d2df793a
NC
1402007-07-12 Kai Tietz <kai.tietz@onevision.com>
141
142 * bfd-in.h: (BFD_HOST_64BIT_LONG_LONG): New.
143 (BFD_HOSTPTR_T): Host pointer type for casting a
144 pointer to an integer type.
145 (bfd_hostptr_t): The typedef of BFD_HOSTPTR_T.
146 (sprintf_vma, fprintf_vma): Add support for long long prints.
147 * bfd-in2.h: Regenerate.
148 * configure.in: (BFD_HOST_64BIT_LONG_LONG): New.
149 (BFD_HOSTPTR_T): Host pointer type for casting a
150 pointer to an integer type. Default is "unsigned long".
151 (AC_CHECK_SIZEOF(void *)): New.
152 (host64): Set it if the pointer size is 8.
153 * configure: Regenerate.
154 * config.in: Add macro SIZEOF_VOID_P.
155 * coffcode.h: Replace host ptr type assuming "long" with
156 bfd_hostptr_t type.
157 * coffgen.c: Likewise.
158 * elf-eh-frame.c: Likewise.
159 * peicode.h: Likewise.
160
a3a4ddad
L
1612007-07-10 H.J. Lu <hongjiu.lu@intel.com>
162
163 * Makefile.in: Regenerated.
164
329b43c4
L
1652007-07-10 H.J. Lu <hongjiu.lu@intel.com>
166
167 PR binutils/4756
168 * simple.c (bfd_simple_get_relocated_section_content): Don't
169 apply relocation on executable and shared library.
170
cfd2c773
NS
1712007-07-10 Nathan Sidwell <nathan@codesourcery.com>
172
173 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't eliminate
174 copy relocs on vxworks.
175
1489a3a0
AM
1762007-07-10 Alan Modra <amodra@bigpond.net.au>
177
178 * elf32-arm.c (elf32_arm_size_info): Init checksum_contents field.
179 * elf64-alpha.c (alpha_elf_size_info): Likewise.
180 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
181 * elf64-mips.c (mips_elf64_size_info): Likewise.
182 * elf64-s390.c (s390_elf64_size_info): Likewise.
183 * elf64-sparc.c (elf64_sparc_size_info): Likewise.
184
00cbee0a
L
1852007-07-09 H.J. Lu <hongjiu.lu@intel.com>
186
187 * elflink.c (bfd_elf_record_link_assignment): Handle indirect
188 symbol.
189 (_bfd_elf_merge_symbol): Properly update normal symbol when
190 overriding the versioned symbol from a dynamic library.
191
fd2f25da
RM
1922007-07-09 Roland McGrath <roland@redhat.com>
193
194 * elf-bfd.h (struct elf_obj_tdata): Add members
195 emit_note_gnu_build_id and note_gnu_build_id_sec.
196 * elf.c (_bfd_id_note_section_size): New global function.
197 (read_hex, _bfd_elf_write_build_id_section): New static functions.
198 (_bfd_elf_write_object_contents): Call _bfd_elf_write_build_id_section
199 if emit_note_gnu_build_id is set.
200 * Makefile.am (elf.lo): Update dependencies.
201
202 * elf-bfd.h (struct elf_size_info): Add checksum_contents hook.
203 (bfd_elf32_checksum_contents, bfd_elf64_checksum_contents): Declare.
204 * elfcode.h (elf_checksum_contents): New macro and function.
205 (NAME(_bfd_elf,size_info)): Initialize checksum_contents hook.
206
9af2a943
AM
2072007-07-06 Michael Snyder <msnyder@access-company.com>
208
209 * elflink.c (elf_link_add_object_symbols): Return via
210 error_free_vers on "notice" failure.
211
a93221e5
L
2122007-07-04 H.J. Lu <hongjiu.lu@intel.com>
213
214 * peicode.h (pe_bfd_object_p): Don't check PE vs. EFI target
215 if arch is unknown.
216
b4928193
NC
2172007-07-04 Nick Clifton <nickc@redhat.com>
218
219 Import this patch from an internal tree:
9af2a943 220
b4928193
NC
221 2001-07-17 Richard Henderson <rth@redhat.com>
222
223 * elf32-mep.c (mep_final_link_relocate) [R_MEP_HI16S]: Correctly
224 compensate for high bit set in R_MEP_LOW16.
225
3cfad14c
JM
2262007-07-03 Joseph Myers <joseph@codesourcery.com>
227
228 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Copy type from
229 input attributes if value has been copied.
230
cd123cb7
NC
2312007-07-03 Nick Clifton <nickc@redhat.com>
232
233 * COPYING: Replace with GPLv3 text.
234 * aix386-core.c: Update copyright notice to refer to GPLv3.
235 * aix5ppc-core.c, aout0.c, aout32.c, aout64.c, aout-adobe.c,
236 aout-arm.c, aout-cris.c, aoutf1.h, aout-ns32k.c, aout-sparcle.c,
237 aout-target.h, aout-tic30.c, aoutx.h, archive64.c, archive.c,
238 archures.c, armnetbsd.c, bfd.c, bfd-in.h, bfdio.c, bfdwin.c,
239 binary.c, bout.c, cache.c, cf-i386lynx.c, cf-sparclynx.c,
240 cisco-core.c, coff64-rs6000.c, coff-alpha.c, coff-apollo.c,
241 coff-arm.c, coff-aux.c, coffcode.h, coffgen.c, coff-go32.c,
242 coff-h8300.c, coff-h8500.c, coff-i386.c, coff-i860.c, coff-i960.c,
243 coff-ia64.c, cofflink.c, coff-m68k.c, coff-m88k.c, coff-maxq.c,
244 coff-mcore.c, coff-mips.c, coff-or32.c, coff-pmac.c, coff-ppc.c,
245 coff-rs6000.c, coff-sh.c, coff-sparc.c, coff-stgo32.c,
246 coff-svm68k.c, coffswap.h, coff-tic30.c, coff-tic4x.c,
247 coff-tic54x.c, coff-tic80.c, coff-u68k.c, coff-w65.c,
248 coff-we32k.c, coff-x86_64.c, coff-z80.c, coff-z8k.c, corefile.c,
249 cpu-alpha.c, cpu-arc.c, cpu-arm.c, cpu-avr.c, cpu-bfin.c,
250 cpu-cr16.c, cpu-cr16c.c, cpu-cris.c, cpu-crx.c, cpu-d10v.c,
251 cpu-d30v.c, cpu-dlx.c, cpu-fr30.c, cpu-frv.c, cpu-h8300.c,
252 cpu-h8500.c, cpu-hppa.c, cpu-i370.c, cpu-i386.c, cpu-i860.c,
253 cpu-i960.c, cpu-ia64.c, cpu-ia64-opc.c, cpu-ip2k.c, cpu-iq2000.c,
254 cpu-m10200.c, cpu-m10300.c, cpu-m32c.c, cpu-m32r.c, cpu-m68hc11.c,
255 cpu-m68hc12.c, cpu-m68k.c, cpu-m88k.c, cpu-maxq.c, cpu-mcore.c,
256 cpu-mep.c, cpu-mips.c, cpu-mmix.c, cpu-msp430.c, cpu-mt.c,
257 cpu-ns32k.c, cpu-openrisc.c, cpu-or32.c, cpu-pdp11.c, cpu-pj.c,
258 cpu-powerpc.c, cpu-rs6000.c, cpu-s390.c, cpu-score.c, cpu-sh.c,
259 cpu-sparc.c, cpu-spu.c, cpu-tic30.c, cpu-tic4x.c, cpu-tic54x.c,
260 cpu-tic80.c, cpu-v850.c, cpu-vax.c, cpu-w65.c, cpu-we32k.c,
261 cpu-xc16x.c, cpu-xstormy16.c, cpu-xtensa.c, cpu-z80.c, cpu-z8k.c,
262 demo64.c, doc/chew.c, dwarf1.c, dwarf2.c, ecoff.c, ecofflink.c,
263 ecoffswap.h, efi-app-ia32.c, efi-app-ia64.c, efi-app-x86_64.c,
264 elf32-am33lin.c, elf32-arc.c, elf32-arm.c, elf32-avr.c,
265 elf32-avr.h, elf32-bfin.c, elf32.c, elf32-cr16.c, elf32-cr16c.c,
266 elf32-cris.c, elf32-crx.c, elf32-d10v.c, elf32-d30v.c,
267 elf32-dlx.c, elf32-fr30.c, elf32-frv.c, elf32-gen.c,
268 elf32-h8300.c, elf32-hppa.c, elf32-hppa.h, elf32-i370.c,
269 elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
270 elf32-iq2000.c, elf32-m32c.c, elf32-m32r.c, elf32-m68hc11.c,
271 elf32-m68hc12.c, elf32-m68hc1x.c, elf32-m68hc1x.h, elf32-m68k.c,
272 elf32-m88k.c, elf32-mcore.c, elf32-mep.c, elf32-mips.c,
273 elf32-msp430.c, elf32-mt.c, elf32-openrisc.c, elf32-or32.c,
274 elf32-pj.c, elf32-ppc.c, elf32-ppc.h, elf32-s390.c, elf32-score.c,
275 elf32-sh64.c, elf32-sh64-com.c, elf32-sh64.h, elf32-sh.c,
276 elf32-sh-symbian.c, elf32-sparc.c, elf32-spu.c, elf32-spu.h,
277 elf32-v850.c, elf32-vax.c, elf32-xc16x.c, elf32-xstormy16.c,
278 elf32-xtensa.c, elf64-alpha.c, elf64.c, elf64-gen.c, elf64-hppa.c,
279 elf64-hppa.h, elf64-mips.c, elf64-mmix.c, elf64-ppc.c,
280 elf64-ppc.h, elf64-s390.c, elf64-sh64.c, elf64-sparc.c,
281 elf64-x86-64.c, elf-attrs.c, elf-bfd.h, elf.c, elfcode.h,
282 elfcore.h, elf-eh-frame.c, elf-hppa.h, elflink.c, elf-m10200.c,
283 elf-m10300.c, elfn32-mips.c, elf-strtab.c, elf-vxworks.c,
284 elf-vxworks.h, elfxx-ia64.c, elfxx-mips.c, elfxx-mips.h,
285 elfxx-sparc.c, elfxx-sparc.h, elfxx-target.h, epoc-pe-arm.c,
286 epoc-pei-arm.c, format.c, freebsd.h, gen-aout.c, genlink.h,
287 hash.c, host-aout.c, hosts/alphavms.h, hp300bsd.c, hp300hpux.c,
288 hppabsd-core.c, hpux-core.c, i386aout.c, i386bsd.c, i386dynix.c,
289 i386freebsd.c, i386linux.c, i386lynx.c, i386mach3.c, i386msdos.c,
290 i386netbsd.c, i386os9k.c, ieee.c, ihex.c, init.c, irix-core.c,
291 libaout.h, libbfd.c, libbfd-in.h, libcoff-in.h, libecoff.h,
292 libhppa.h, libieee.h, libnlm.h, liboasys.h, libpei.h, libxcoff.h,
293 linker.c, lynx-core.c, m68k4knetbsd.c, m68klinux.c, m68knetbsd.c,
294 m88kmach3.c, m88kopenbsd.c, mach-o.c, mach-o.h, mach-o-target.c,
295 mep-relocs.pl, merge.c, mipsbsd.c, mmo.c, netbsd-core.c, netbsd.h,
296 newsos3.c, nlm32-alpha.c, nlm32.c, nlm32-i386.c, nlm32-ppc.c,
297 nlm32-sparc.c, nlm64.c, nlm.c, nlmcode.h, nlmswap.h, nlm-target.h,
298 ns32k.h, ns32knetbsd.c, oasys.c, opncls.c, osf-core.c,
299 pc532-mach.c, pdp11.c, pe-arm.c, pe-arm-wince.c, pef.c, pef.h,
300 pef-traceback.h, pe-i386.c, pei-arm.c, pei-arm-wince.c, peicode.h,
301 pei-i386.c, pei-mcore.c, pei-mips.c, pei-ppc.c, pei-sh.c,
302 pei-x86_64.c, pe-mcore.c, pe-mips.c, pe-ppc.c, pe-sh.c,
303 pe-x86_64.c, peXXigen.c, ppcboot.c, ptrace-core.c, reloc16.c,
304 reloc.c, riscix.c, rs6000-core.c, sco5-core.c, section.c,
305 simple.c, som.c, som.h, sparclinux.c, sparclynx.c, sparcnetbsd.c,
306 srec.c, stabs.c, stab-syms.c, stamp-h.in, sunos.c, syms.c,
307 sysdep.h, targets.c, targmatch.sed, tekhex.c, ticoff.h,
308 trad-core.c, vax1knetbsd.c, vaxbsd.c, vaxnetbsd.c, versados.c,
309 vms.c, vms-gsd.c, vms.h, vms-hdr.c, vms-misc.c, vms-tir.c,
310 xcofflink.c, xcoff-target.h, xsym.c, xsym.h, xtensa-isa.c,
311 xtensa-modules.c: Likewise.
312 * elf32-sh-relocs.h: Add copyright notice.
313 * hosts/alphalinux.h, hosts/decstation.h, hosts/delta68.h,
314 hosts/dpx2.h, hosts/hp300bsd.h, hosts/i386bsd.h,
315 hosts/i386linux.h, hosts/i386mach3.h, hosts/i386sco.h,
316 hosts/i860mach3.h, hosts/m68kaux.h, hosts/m68klinux.h,
317 hosts/m88kmach3.h, hosts/mipsbsd.h, hosts/mipsmach3.h,
318 hosts/news.h, hosts/news-mips.h, hosts/pc532mach.h,
319 hosts/riscos.h, hosts/symmetry.h, hosts/tahoe.h, hosts/vaxbsd.h,
320 hosts/vaxlinux.h, hosts/vaxult2.h, hosts/vaxult.h: Likewise.
321 * bfd-in2.h, libbfd.h, libcoff.h: Regenerate.
322
741d6ea8
JM
3232007-07-02 Joseph Myers <joseph@codesourcery.com>
324
325 * elfxx-mips.c (mips_elf_calculate_relocation): Handle
326 R_MIPS_TLS_DTPREL32 and R_MIPS_TLS_DTPREL64.
327 * elf64-mips.c (mips_elf64_howto_table_rela): Support
328 R_MIPS_TLS_DTPREL64.
329
ae351704
AM
3302007-07-02 Alan Modra <amodra@bigpond.net.au>
331
332 * Makefile.am: Run "make dep-am".
333 * Makefile.in: Regenerate.
334 * aclocal.m4: Regenerate.
335 * config.in: Regenerate.
336 * po/SRC-POTFILES.in: Regenerate.
337 * po/bfd.pot: Regenerate.
338
3e5484db
AM
3392007-07-02 Alan Modra <amodra@bigpond.net.au>
340
341 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Tidy
342 symsec != NULL tests.
343
08a40648
AM
3442007-07-02 Alan Modra <amodra@bigpond.net.au>
345
346 PR 4712
347 * elf.c (assign_file_positions_for_load_sections): Adjust lma
348 by p_vaddr_offset.
349
86b57e31
L
3502007-06-30 H.J. Lu <hongjiu.lu@intel.com>
351
352 * aclocal.m4: Regenerated.
353 * Makefile.in: Likewise.
354
34c8bcba
JM
3552007-06-29 Joseph Myers <joseph@codesourcery.com>
356
357 * elf32-ppc.c (ppc_elf_merge_obj_attributes): New.
358 (ppc_elf_merge_private_bfd_data): Call it.
359
2cf19d5c
JM
3602007-06-29 Joseph Myers <joseph@codesourcery.com>
361
362 * elfxx-mips.c (mips_elf_merge_obj_attributes): New.
363 (_bfd_mips_elf_merge_private_bfd_data): Call it.
364
104d59d1
JM
3652007-06-29 Joseph Myers <joseph@codesourcery.com>
366
367 * elf-attrs.c: New.
368 * Makefile.am (BFD32_BACKENDS): Add elf-attrs.lo.
369 (BFD32_BACKENDS_CFILES): Add elf-attrs.c.
370 (elf-attrs.lo): Generate dependencies.
371 * Makefile.in: Regenerate.
372 * configure.in (elf): Add elf-attrs.lo.
373 * configure: Regenerate.
374 * elf-bfd.h (struct elf_backend_data): Add entries for object
375 attributes.
376 (NUM_KNOWN_OBJ_ATTRIBUTES, obj_attribute, obj_attribute_list,
377 OBJ_ATTR_PROC, OBJ_ATTR_GNU, OBJ_ATTR_FIRST, OBJ_ATTR_LAST,
378 Tag_NULL, Tag_File, Tag_Section, Tag_Symbol, Tag_compatibility):
379 New.
380 (struct elf_obj_tdata): Add entries for object attributes.
381 (elf_known_obj_attributes, elf_other_obj_attributes,
382 elf_known_obj_attributes_proc, elf_other_obj_attributes_proc):
383 New.
384 (bfd_elf_obj_attr_size, bfd_elf_set_obj_attr_contents,
385 bfd_elf_get_obj_attr_int, bfd_elf_add_obj_attr_int,
386 bfd_elf_add_proc_attr_int, bfd_elf_add_obj_attr_string,
387 bfd_elf_add_proc_attr_string, bfd_elf_add_obj_attr_compat,
388 bfd_elf_add_proc_attr_compat, _bfd_elf_attr_strdup,
389 _bfd_elf_copy_obj_attributes, _bfd_elf_obj_attrs_arg_type,
390 _bfd_elf_parse_attributes, _bfd_elf_merge_object_attributes): New.
391 * elf.c (_bfd_elf_copy_private_bfd_data): Copy object attributes.
392 (bfd_section_from_shdr): Handle attributes sections.
393 * elflink.c (bfd_elf_final_link): Handle attributes sections.
394 * elfxx-target.h (elf_backend_obj_attrs_vendor,
395 elf_backend_obj_attrs_section, elf_backend_obj_attrs_arg_type,
396 elf_backend_obj_attrs_section_type): New.
397 (elfNN_bed): Update.
398 * elf32-arm.c (NUM_KNOWN_ATTRIBUTES, aeabi_attribute,
399 aeabi_attribute_list): Remove.
400 (struct elf32_arm_obj_tdata): Remove object attributes fields.
401 (check_use_blx, bfd_elf32_arm_set_vfp11_fix, using_thumb2,
402 elf32_arm_copy_private_bfd_data, elf32_arm_merge_eabi_attributes):
403 Update for new object attributes interfaces.
404 (uleb128_size, is_default_attr, eabi_attr_size,
405 elf32_arm_eabi_attr_size, write_uleb128, write_eabi_attribute,
406 elf32_arm_set_eabi_attr_contents, elf32_arm_bfd_final_link,
407 elf32_arm_new_eabi_attr, elf32_arm_get_eabi_attr_int,
408 elf32_arm_add_eabi_attr_int, attr_strdup,
409 elf32_arm_add_eabi_attr_string, elf32_arm_add_eabi_attr_compat,
410 copy_eabi_attributes, elf32_arm_parse_attributes): Remove. Moved
411 to generic code in elf-attrs.c.
412 (elf32_arm_obj_attrs_arg_type): New.
413 (elf32_arm_fake_sections): Do not handle .ARM.attributes.
414 (elf32_arm_section_from_shdr): Do not handle SHT_ARM_ATTRIBUTES.
415 (bfd_elf32_bfd_final_link): Remove.
416 (elf_backend_obj_attrs_vendor, elf_backend_obj_attrs_section,
417 elf_backend_obj_attrs_arg_type,
418 elf_backend_obj_attrs_section_type): New.
419 * elf32-bfin.c (bfin_elf_copy_private_bfd_data): Copy object
420 attributes.
421 * elf32-frv.c (frv_elf_copy_private_bfd_data): Likewise.
422 * elf32-iq2000.c (iq2000_elf_copy_private_bfd_data): Likewise.
423 * elf32-mep.c (mep_elf_copy_private_bfd_data): Likewise.
424 * elf32-mt.c (mt_elf_copy_private_bfd_data): Likewise.
425 * elf32-sh.c (sh_elf_copy_private_data): Likewise.
426 * elf64-sh64.c (sh_elf64_copy_private_data_internal): Likewise.
427
5ab79981
PB
4282007-06-29 Paul Brook <paul@codesourcery.com>
429
430 * elf32-arm.c (bfd_elf32_arm_process_before_allocation): Suppress
431 call veneers for call relocations against undefined symbols.
432 (elf32_arm_final_link_relocate): Turn call to undefined symbol
433 into a jump to the next instruction.
434
32e8a950
NC
4352007-06-29 Michael Snyder <msnyder@svkmacdonelllnx>
436
437 * bfd.c (bfd_demangle): Plug memory leak (Coverity).
438
3d3d428f
NC
4392007-06-29 M R Swami Reddy <MR.Swami.Reddy@nsc.com>
440
441 * Makefile.am: Add cr16 related entry
442 * Makefile.in: Regenerate
443 * archures.c: Add bfd_cr16_arch
444 * bfd-in2.h: Regenerate
445 * config.bfd: Add cr16-elf
446 * configure.in: Add bfd_elf32_cr16_vec
447 * configure: Regenerate.
448 * targets.c: Added cr16 related information
449 * cpu-cr16.c: New file.
450 * elf32-cr16.c: New file.
451 * reloc.c: Added cr16 relocs.
452
c55fe096
AM
4532007-06-29 Alan Modra <amodra@bigpond.net.au>
454
455 * elflink.c (_bfd_elf_link_assign_sym_version): Improve error
456 message for undefined version nodes.
457 (elf_gc_sweep): Don't warn when zero size sections are
458 removed.
459
375de94a
AM
4602007-06-29 Nathan Froyd <froydnj@codesourcery.com>
461
462 * elf32-ppc.c (ppc_elf_info_to_howto): Check for invalid relocation
463 types.
464
7d3287cb
AM
4652007-06-29 Alan Modra <amodra@bigpond.net.au>
466
467 * elf32-spu.c (spu_elf_fake_sections): New function.
468 (elf_backend_fake_sections): Define.
469
6a3cd2b4
AM
4702007-06-29 Alan Modra <amodra@bigpond.net.au>
471
472 * elf.c (assign_file_positions_for_load_sections): Use elf
473 section header sh_size rather than bfd section size, simplifying
474 .tbss handling.
475
bf988460
AM
4762007-06-29 Alan Modra <amodra@bigpond.net.au>
477
36fc76ae 478 PR ld/4701
bf988460
AM
479 * elf.c (assign_file_positions_for_load_sections): Ensure bss
480 segments meet gABI alignment requirements. Don't allocate
481 file space for bss sections in a segment also containing file
482 or program headers.
483
60b31e8d
AM
4842007-06-27 Alan Modra <amodra@bigpond.net.au>
485
cc481421
AM
486 * bfd.c (struct bfd): Rename "next" to "archive_next".
487 * archive.c: Rename uses throughout file.
488 * archive64.c: Likewise.
489 * coff-rs6000.c: Likewise.
490 * ecoff.c: Likewise.
491 * som.c: Likewise.
492 * bfd-in2.h: Regenerate.
493
60b31e8d
AM
494 * elf32-ppc.c (ppc_elf_select_plt_layout): Properly iterate over
495 input bfds.
58eb693e 496 * elf32-spu.c (spu_elf_create_sections): Likewise.
60b31e8d 497
bec42b15
NC
4982007-06-26 H.J. Lu <hongjiu.lu@intel.com>
499
500 * dwarf2.c (find_line): New. Contains the duplicated code from:
501 (_bfd_dwarf2_find_nearest_line): Use it.
502 (_bfd_dwarf2_find_line): Use it.
503
3d3e6f9a
JM
5042007-06-26 Joseph Myers <joseph@codesourcery.com>
505
506 * elf32-arm.c (copy_eabi_attributes): Copy type of attributes.
507
b314ec0e
RS
5082007-06-25 Richard Sandiford <richard@codesourcery.com>
509
510 * elfxx-mips.c (mips_elf_calculate_relocation): Allow local stubs
511 to be used for calls from MIPS16 code.
512
0d4a1476
AS
5132007-06-23 Andreas Schwab <schwab@suse.de>
514
515 * configure.in (--with-separate-debug-dir): New option.
516 * configure: Regenerate.
517 * Makefile.am (dwarf2.lo): Add rule to pass DEBUGDIR.
518 * Makefile.in: Regenerate.
519 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Pass DEBUGDIR to
520 bfd_follow_gnu_debuglink.
521 (_bfd_dwarf2_find_line): Likewise.
522
0d161102
NC
5232007-06-22 Nick Clifton <nickc@redhat.com>
524
525 * dwarf2.c: Add support for reading in debug information via a
526 .gnu_debuglink section:
527 (struct dwarf2_debug): Add bfd field to record the bfd containing
528 the debug info.
529 (parse_comp_unit): Remove ABFD parameter. Instead use the bfd
530 field in the dwarf2_debug structure.
531 (_bfd_dwarf2_find_nearest_line): If a debug info section could not
532 be found in the current bfd call bfd_follow_gnu_debuglink to see
533 if another file contains the debug information. If it does, open
534 it and continue.
535 (_bfd_dwarf2_find_line): Likewise.
536
293a0124
L
5372007-06-19 H.J. Lu <hongjiu.lu@intel.com>
538
539 PR ld/4590
540 * elfxx-ia64.c (sort_dyn_sym_info): Keep the valid got_offset
541 when removing duplicated entries.
542 (get_dyn_sym_info): Initialize the got_offset field to -1.
543 Update call to sort_dyn_sym_info.
544 (elfNN_ia64_relocate_section): Call sort_dyn_sym_info to sort
545 array of addend and remove duplicates.
546
dc1f3d8a
L
5472007-06-18 H.J. Lu <hongjiu.lu@intel.com>
548
549 * libpei.h (_bfd_XXi_final_link_postscript): Remove
550 duplication.
551 (bfd_target_pei_p): New.
552 (bfd_target_pei_arch): New
553 (bfd_target_efi_p): Likewise.
554 (bfd_target_efi_arch): New
555 (bfd_pe_executable_p): Use bfd_target_pei_p and
556 bfd_target_efi_p.
557
558 * peicode.h (arch_type): New enum.
559 (pe_arch): New function.
560 (pe_bfd_object_p): Don't match PE/EFI target with EFI/PE file
561 if there is an EFI/PE target.
562
79887925
L
5632007-06-14 H.J. Lu <hongjiu.lu@intel.com>
564
565 * Makefile.am (ACLOCAL_AMFLAGS): Add -I . -I ../config.
566
567 * acinclude.m4: Don't include m4 files. Remove libtool
568 kludge.
569
570 * Makefile.in: Regenerated.
79887925
L
571 * aclocal.m4: Likewise.
572 * configure: Likewise.
573
99ded152
BW
5742007-06-11 Sterling Augustine <sterling@tensilica.com>
575 Bob Wilson <bob.wilson@acm.org>
bf988460 576
99ded152
BW
577 * elf32-xtensa.c (extend_ebb_bounds_forward): Use renamed
578 XTENSA_PROP_NO_TRANSFORM flag instead of XTENSA_PROP_INSN_NO_TRANSFORM.
579 (extend_ebb_bounds_backward, compute_text_actions): Likewise.
580 (compute_ebb_proposed_actions, coalesce_shared_literal): Likewise.
581 (xtensa_get_property_predef_flags): Likewise.
582 (compute_removed_literals): Pass new arguments to is_removable_literal.
583 (is_removable_literal): Add sec, prop_table and ptblsize arguments.
584 Do not remove literal if the NO_TRANSFORM property flag is set.
bf988460 585
cbf2cba4
RS
5862007-05-31 Richard Sandiford <rsandifo@nildram.co.uk>
587
588 * elfxx-mips.c (mips_elf_initialize_tls_index): When processing a
589 type (3) single-GOT entry, read tls_type from the hash table entry
590 rather than the GOT entry.
591
a9a4c53e
AM
5922007-06-01 Alan Modra <amodra@bigpond.net.au>
593
594 * simple.c (bfd_simple_get_relocated_section_contents): Init
595 input_bfds_tail.
596
02bf8d82
AM
5972007-05-30 Alan Modra <amodra@bigpond.net.au>
598
42bb2e33
AM
599 * elf.c (elf_fake_sections): Adjust test for SHT_NOBITS sections
600 created by objcopy --only-keep-debug.
601 (_bfd_elf_init_private_section_data): Only change elf_section_type
602 if it is SHT_NULL.
603
02bf8d82
AM
604 * elf.c (assign_file_positions_for_load_sections): Correct sh_type
605 to SHT_NOBITS earlier. Base actions in rest of function on sh_type
606 and sh_flags instead of bfd section flags. Delete voff and code
607 keeping nobits segments aligned.
608
4e591bc1
EC
6092007-05-25 Eric Christopher <echristo@apple.com>
610
611 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame):
612 Check that sym_sec isn't NULL before accessing.
613
37ad9514
SE
6142007-05-24 Steve Ellcey <sje@cup.hp.com>
615
616 * Makefile.in: Regnerate.
617 * configure: Regenerate.
618 * aclocal.m4: Regenerate.
619 * doc/Makefile.in: Regenerate.
620
91a5743d
PB
6212007-05-22 Paul Brook <paul@codesourcery.com>
622
623 * elf32-arm.c (output_arch_syminfo): Replace plt_shndx and plt_offset
624 with sec and sec_shndx.
625 (elf32_arm_ouput_plt_map_sym): Use them.
626 (elf32_arm_output_arch_local_syms): Output mapping symbols for
627 interworking glue.
628
26079076
PB
6292007-05-18 Paul Brook <paul@codesourcery.com>
630
631 * elf32-arm.c (ARM2THUMB_V5_STATIC_GLUE_SIZE): Define.
632 (a2t1v5_ldr_insn, a2t1v5_ldr_insn): New.
633 (record_arm_to_thumb_glue): Add v5t non-pic glue.
634 (elf32_arm_create_thumb_stub): Ditto.
635
91ac5911
L
6362007-05-16 H.J. Lu <hongjiu.lu@intel.com>
637 Alan Modra <amodra@bigpond.net.au>
638
639 * elflink.c (_bfd_elf_adjust_dynamic_copy): Align dynamic bss
640 section to the minimum alignment.
641
027297b7
L
6422007-05-15 H.J. Lu <hongjiu.lu@intel.com>
643 Alan Modra <amodra@bigpond.net.au>
644
645 PR ld/4504
646 * elf-bfd.h (_bfd_elf_adjust_dynamic_copy): New.
647 * elflink.c (_bfd_elf_adjust_dynamic_copy): New.
648
649 * elf-m10300.c (_bfd_mn10300_elf_adjust_dynamic_symbol): Call
650 _bfd_elf_adjust_dynamic_copy to adjust for the copy in dynamic
651 bss section.
652 * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Likewise.
653 * elf32-cris.c (elf_cris_adjust_dynamic_symbol): Likewise.
654 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
655 * elf32-i370.c (i370_elf_adjust_dynamic_symbol): Likewise.
656 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Likewise.
657 * elf32-m32r.c (m32r_elf_adjust_dynamic_symbol): Likewise.
658 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
659 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
660 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
661 * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Likewise.
662 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Likewise.
663 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
664 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
665 * elf64-sh64.c (sh64_elf64_adjust_dynamic_symbol): Likewise.
666 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
667 * elfxx-mips.c (_bfd_mips_vxworks_adjust_dynamic_symbol): Likewise.
668 * elfxx-sparc.c (_bfd_sparc_elf_adjust_dynamic_symbol): Likewise.
669
5c18022e
RS
6702007-05-15 Richard Sandiford <richard@codesourcery.com>
671
672 * elfxx-mips.c (mips_elf_create_local_got_entry): Remove
673 input_section argument. Create .rela.dyn relocations against
674 symbol 0 rather than the section symbol.
675 (mips_elf_local_got_index): Remove input_section argument.
676 Update call to mips_elf_create_local_got_entry.
677 (mips_elf_got_page, mips_elf_got16_entry): Likewise.
678 (mips_elf_calculate_relocation): Update calls to
679 mips_elf_local_got_index, mips_elf_got16_entry and mips_elf_got_page.
680
a00a1f35
MS
6812007-05-15 Mark Shinwell <shinwell@codesourcery.com>
682
683 * elf32-arm.c (elf32_arm_final_link_relocate): Correctly
684 handle the Thumb-2 JUMP19 relocation.
685
0414f35b
AM
6862007-05-15 Alan Modra <amodra@bigpond.net.au>
687
688 PR 4479
689 * elf.c (elf_fake_sections): Don't allow backend to change
690 SHT_NOBITS if called for strip/objcopy --only-keep-debug.
691 * elfxx-mips.c (_bfd_mips_elf_fake_sections): Remove similar
692 fix from here.
693
74f2e02b
AM
6942007-05-14 Alan Modra <amodra@bigpond.net.au>
695
696 * elf.c (bfd_elf_string_from_elf_section): Return NULL on
697 invalid shstrndx.
698 (bfd_elf_get_str_section): Likewise.
699
f137a54e
AM
7002007-05-12 Alan Modra <amodra@bigpond.net.au>
701
702 PR 4497
703 * elf-eh-frame.c (struct cie): Add "local_personality". Make
704 "personality" a union.
705 (cie_eq): Compare local_personality too. Adjust personality
706 comparison.
707 (_bfd_elf_discard_section_eh_frame): Check binding on personality
708 reloc sym to allow for bad symtab. Use stashed local syms rather
709 than reading personality local sym. Handle discarded sections.
710
4f4416b5
AM
7112007-05-12 Alan Modra <amodra@bigpond.net.au>
712
713 * elf32-spu.c (elf_howto_table): Add howto for R_SPU_ADDR16X.
714
016687f8
AM
7152007-05-11 Alan Modra <amodra@bigpond.net.au>
716
717 * elf32-ppc.h (ppc_elf_select_plt_layout): Update prototype.
718 (enum ppc_elf_plt_type): Move from..
719 * elf32-ppc.c: ..here.
720 (struct ppc_elf_obj_tdata): Add makes_plt_call and has_rel16.
721 (struct ppc_elf_link_hash_table): Reorder. Add old_bfd. Delete
722 can_use_new_plt. Make is_vxworks a bitfield.
723 (ppc_elf_link_hash_table_create): Don't clear is_vxworks (again).
724 (ppc_elf_check_relocs): Update setting of reloc flags. Set old_bfd.
725 (ppc_elf_select_plt_layout): Modify parameters. Use bfd reloc
726 flags to better detect object files needing old bss-style plt.
727 Allow secure plt to be used without rel16 relocs being detected.
728 Warn if secure plt request cannot be allowed.
729
ece5ef60
AM
7302007-05-11 Alan Modra <amodra@bigpond.net.au>
731
732 * reloc.c (BFD_RELOC_SPU_PPU32, BFD_RELOC_SPU_PPU64): Define.
733 * elf-bfd.h (struct elf_backend_data): Change return type of
734 elf_backend_relocate_section to int.
735 * elf32-spu.c (elf_howto_table): Add howtos for R_SPU_PPU32 and
736 R_SPU_PPU64.
737 (spu_elf_bfd_to_reloc_type): Convert new relocs.
738 (spu_elf_count_relocs): New function.
739 (elf_backend_count_relocs): Define.
740 (spu_elf_relocate_section): Arrange to emit R_SPU_PPU32 and
741 R_SPU_PPU64 relocs.
742 * elflink.c (elf_link_input_bfd): Emit relocs if relocate_section
743 returns 2.
744 * bfd-in2.h: Regenerate.
745 * libbfd.h: Regenerate.
746
d3753b85
RS
7472007-05-10 Richard Sandiford <richard@codesourcery.com>
748
749 * elf32-arm.c (elf32_arm_check_relocs): Don't create PLT entries
750 for R_ARM_ABS12 relocs.
751 (elf32_arm_finish_dynamic_symbol): Fix the loop that creates
752 non-shared VxWorks PLT entries.
753
ef8c95ad
AM
7542007-05-11 Alan Modra <amodra@bigpond.net.au>
755
756 PR 4454
757 * elf-eh-frame.c (struct cie): Make "personality" a bfd_vma.
758 (_bfd_elf_discard_section_eh_frame): Handle local syms on
759 personality relocation.
760
8c252fd9
RS
7612007-05-10 Richard Sandiford <richard@codesourcery.com>
762
763 * elf.c (assign_file_positions_for_load_sections): Use p_memsz
764 rather than p_filesz to calculate the LMA of the end of a segment.
765
b186458a
JJ
7662007-05-10 Jakub Jelinek <jakub@redhat.com>
767
768 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Don't do copyreloc
769 processing if symbol is defined in the executable.
770
88571279
AO
7712007-05-10 Alexandre Oliva <aoliva@redhat.com>
772
773 * elf32-frv.c (_frvfdpic_check_discarded_relocs): New.
774 (frvfdpic_elf_discard_info): New.
775 (elf_backend_discard_info): Define for FDPIC.
776
2e6030b9
MS
7772007-05-09 Mark Shinwell <shinwell@codesourcery.com>
778
779 * elf32-arm.c (bfd_elf32_arm_vfp11_erratum_scan): Don't
780 attempt to scan if the bfd doesn't correspond to an ELF image.
781 (bfd_elf32_arm_vfp11_fix_veneer_locations): Likewise.
782
0d4cc892
AO
7832007-05-08 Alexandre Oliva <aoliva@redhat.com>
784
785 * elf32-frv.c (elf32_frv_relocate_section): Discard dynamic relocs
786 for which _bfd_elf_section_offset returns -1.
787
d0249648
AM
7882007-05-08 Alan Modra <amodra@bigpond.net.au>
789
790 * elf32-spu.c (spu_elf_size_stubs): Use "void *" for psyms.
791 (mark_functions_via_relocs): Likewise.
792
1182cb93
AM
7932007-05-07 Alan Modra <amodra@bigpond.net.au>
794
795 * elflink.c (bfd_elf_final_link): Correct reloc handling for
796 elf_backend_count_relocs.
797 (bfd_elf_discard_info): Print an error if we can't read syms.
798
b16f296e
AM
7992007-05-07 Alan Modra <amodra@bigpond.net.au>
800
801 * elf32-spu.c (spu_elf_reloc_type_lookup): Return NULL on
802 invalid reloc code.
803 (spu_elf_gc_mark_hook, spu_elf_section_processing): Delete functions.
804 (elf_backend_gc_mark_hook, elf_backend_section_processing): Don't
805 define.
806
7c928300
AM
8072007-05-07 Alan Modra <amodra@bigpond.net.au>
808
809 * elf.c (assign_file_positions_for_load_sections): Don't check
810 core segment.
811
fc66a176
L
8122007-05-04 H.J. Lu <hongjiu.lu@intel.com>
813
814 * elflink.c (elf_link_sort_relocs): Return if both .rela.dyn
815 and .rel.dyn aren't present.
816
3410fea8
NC
8172007-05-04 Nick Clifton <nickc@redhat.com>
818
819 * elflink.c (elf_link_sort_relocs): If both .rela.dyn and .rel.dyn
820 sections are present examine the indirect sections in an attempt
821 to compute the correct relocation size. If there is any
822 ambiguity, produce an error and refuse to sort.
823
7bdca076
SL
8242007-05-03 Sandra Loosemore <sandra@codesourcery.com>
825
826 * elf32-arm.c (allocate_dynrelocs): Fix typo in comment.
827
22184a77
NC
8282007-05-03 Vincent Riviere <vincent.riviere@freesbee.fr>
829 Nick Clifton <nickc@redhat.com>
830
831 PR gas/3041
832 * aoutx.h (swap_std_reloc_out): Treat relocs against weak symbols
833 in the same way as relocs against external symbols.
834
627b32bc
AM
8352007-05-02 Alan Modra <amodra@bigpond.net.au>
836
837 * elf.c (assign_file_positions_for_load_sections): Set sh_offset
838 here. Set sh_type to SHT_NOBITS if we won't be allocating
839 file space. Don't bump p_memsz for non-alloc sections. Adjust
840 section-in-segment check.
841 (assign_file_positions_for_non_load_sections): Don't set sh_offset
842 here for sections that have already been handled above.
843
49fa1e15
AM
8442007-04-30 Alan Modra <amodra@bigpond.net.au>
845
846 * elf32-spu.c (struct spu_link_hash_table): Add stack_analysis
847 and emit_stack_syms bitfields.
848 (get_sym_h): Read all symbols if stack analysis will be done.
849 (spu_elf_create_sections): Add stack_analysis and emit_stack_syms
850 params, and stash in hash table.
851 (is_hint): Split off from..
852 (is_branch): ..here. Adjust callers.
853 (spu_elf_size_stubs): Add stack_analysis param. Arrange to read
854 and keep all syms.
855 (write_one_stub): Fix mem leak.
856 (find_function_stack_adjust): New function.
857 (sort_syms_syms, sort_syms_psecs): New vars.
858 (sort_syms): New function.
859 (struct call_info, struct function_info): New.
860 (struct spu_elf_stack_info): New.
861 (alloc_stack_info, maybe_insert_function, func_name): New functions.
862 (is_nop, insns_at_end, check_function_ranges): Likewise.
863 (find_function, insert_callee, mark_functions_via_relocs): Likewise.
864 (pasted_function, interesting_section, discover_functions): Likewise.
865 (mark_non_root, call_graph_traverse, build_call_tree): Likewise.
866 (sum_stack, spu_elf_stack_analysis, spu_elf_final_link): Likewise.
867 (bfd_elf32_bfd_final_link): Define.
868 * elf32-spu.h (struct _spu_elf_section_data): Add stack_info field.
869 (spu_elf_create_sections, spu_elf_size_stubs): Update prototypes.
870
9ddf8309
TS
8712007-04-28 Sergey Rogozhkin <rogozhkin@niisi.msk.ru>
872
873 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Don't access
874 memory which we might not own.
875
95147441
BW
8762007-04-27 Bob Wilson <bob.wilson@acm.org>
877
878 * elf32-xtensa.c (elf_xtensa_make_sym_local): Restore deleted function.
879 (elf_xtensa_hide_symbol, elf_backend_hide_symbol): Likewise.
880 (elf_xtensa_allocate_dynrelocs): Use elf_xtensa_make_sym_local.
881
bcc2cc8e
BW
8822007-04-27 Bob Wilson <bob.wilson@acm.org>
883
884 * elf32-xtensa.c (xtensa_read_table_entries): Step through table
885 contents and relocs in parallel.
4e591bc1 886
f29f96b6
BW
8872007-04-27 Bob Wilson <bob.wilson@acm.org>
888
889 * elf32-xtensa.c (relax_property_section): Remove extra irel increment.
890
2ce18a16
AM
8912007-04-27 Alan Modra <amodra@bigpond.net.au>
892
893 * cpu-rs6000.c: Write Mimi's name in ASCII.
894 * coff-rs6000.c: Likewise.
895 * rs6000-core.c: Likewise.
896
eddc20ad
AM
8972007-04-27 Alan Modra <amodra@bigpond.net.au>
898
899 * sysdep.h: Include config.h first.
900 Many files: Include sysdep.h before bfd.h.
901 * Makefile.am: Run "make dep-am".
902 * Makefile.in: Regenerate.
903
495443d4
AM
9042007-04-25 Alan Modra <amodra@bigpond.net.au>
905
906 * sysdep.h: Revert last change.
907
40b1c6c5
NC
9082007-04-24 Nick Clifton <nickc@redhat.com>
909
910 * coffcode.h (coff_slurp_reloc_table): Initialise dst.r_offset.
911 * coff-m68k.c (m68kcoff_rtype_to_howto): Initialize relent.howto.
912
64be1553
AM
9132007-04-24 Alan Modra <amodra@bigpond.net.au>
914
915 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Warn if
916 eh_frame_hdr table won't be created.
917
d5efd9fc
AM
9182007-04-24 Alan Modra <amodra@bigpond.net.au>
919
920 * acinclude.m4: Include config/stdint.m4.
921 * configure.in: Invoke GCC_HEADER_STDINT.
922 * sysdep.h: Don't include ansidecl.h here.
923 * configure: Regenerate.
924 * config.in: Regenerate.
925 * Makefile.in: Regenerate.
926
9a2e615a
NS
9272007-04-23 Nathan Sidwell <nathan@codesourcery.com>
928
929 * archures.c (bfd_mach_mcf_isa_c, bfd_mach_mcf_isa_c_mac,
930 bfd_mach_mcf_isa_c_emac): New.
931 * elf32-m68k.c (ISAC_PLT_ENTRY_SIZE, elf_isac_plt0_entry,
932 elf_isac_plt_entry, elf_isac_plt_info): New.
933 (elf32_m68k_object_p): Add ISA_C.
934 (elf32_m68k_print_private_bfd_data): Print ISA_C.
935 (elf32_m68k_get_plt_info): Detect ISA_C.
936 * cpu-m68k.c (arch_info): Add ISAC.
937 (m68k_arch_features): Likewise,
938 (bfd_m68k_compatible): ISAs B & C are not compatible.
939
1b0b5b1b
NC
9402007-04-21 Nick Clifton <nickc@redhat.com>
941
942 * ecoff.c (_bfd_ecoff_write_armap): Initialise rehash.
943 (ecoff_link_add_archive_symbols): Likewise.
944 * coff-m68k.c (m68kcoff_common_addend_rtype_to_howto): Initialise
945 relent.howto.
946 * ieee.c (parse_int): Initialise x.
947 (must_parse_int): Initialise result.
948 (ieee_slurp_external_symbols): Initialise value.
949
bd7803a9
AM
9502007-04-21 Alan Modra <amodra@bigpond.net.au>
951
952 * config.bfd (spu-*-elf): Delete targ_selvecs.
953
964597d0
NC
9542007-04-19 Nick Clifton <nickc@redhat.com>
955
956 * coffcode.h (coff_rtype_to_howto): Initialise genrel.howto.
957
01e76792
AM
9582007-04-19 Alan Modra <amodra@bigpond.net.au>
959
960 * bfd.c (bfd_demangle): New function.
961 * Makefile.am: Run "make dep-am".
962 * Makefile.in: Regenerate.
963 * bfd-in2.h: Regenerate.
964
ee5c21a0
DJ
9652007-04-18 Matthias Klose <doko@ubuntu.com>
966
967 * Makefile.am (libbfd_la_LDFLAGS): Use bfd soversion.
968 (bfdver.h): Use the date in non-release builds for the soversion.
969 * Makefile.in: Regenerate.
970
fcb93ecf
PB
9712007-04-17 Paul Brook <paul@codesourcery.com>
972
973 * elf.c (_bfd_elf_is_function_type): New function.
974 * elflink.c (_bfd_elf_merge_symbol): Use bed->is_function_type.
975 (_bfd_elf_dynamic_symbol_p, _bfd_elf_symbol_refs_local_p,
976 is_global_data_symbol_definition, elf_link_add_object_symbols): Ditto.
977 * elf-bfd.h (elf_backend_data): Add is_function_type.
978 (_bfd_elf_is_function_type): Add prototype.
979 * elfxx-target.h (elf_backend_is_function_type): Add default
980 definition.
981 (elfNN_bed): Add elf_backend_is_function_type.
982 * elf32-arm.c (elf32_arm_is_function_type): New function.
983 (elf_backend_is_function_type): Define.
984
5750dcec
DJ
9852007-04-17 Daniel Jacobowitz <dan@codesourcery.com>
986
987 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Put
988 DT_MIPS_RLD_MAP before DT_DEBUG again.
989
cfbc9945
SE
9902007-04-14 Steve Ellcey <sje@cup.hp.com>
991
992 * Makefile.am: Add ACLOCAL_AMFLAGS.
993 * configure.in: Change macro call order.
994 * Makefile.in: Regnerate.
995 * doc/Makefile.in: Regenerate.
996 * configure: Regenerate.
997
3fcd97f1
JJ
9982007-04-14 Jakub Jelinek <jakub@redhat.com>
999
1000 * elflink.c (bfd_elf_final_link): Don't free symbuf for
1001 non-elf input bfds.
1002 (bfd_elf_size_dynamic_sections): Don't access elf_section_data
1003 for non-elf input bfds.
1004
af5978fb
RS
10052007-04-12 Richard Sandiford <richard@codesourcery.com>
1006
1007 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Don't add
1008 DT_MIPS_RTLD_MAP for PIEs.
1009
9e3313ae
RS
10102007-04-12 Richard Sandiford <richard@codesourcery.com>
1011
1012 * elfxx-mips.c (mips_elf_calculate_relocation): Set DT_TEXTREL
1013 when creating a __GOTT_BASE__ or __GOTT_INDEX__ relocation
1014 in a read-only section.
1015 (_bfd_mips_elf_check_relocs): Likewise.
1016
1d25768e
BW
10172007-04-12 Bob Wilson <bob.wilson@acm.org>
1018
1019 * elf32-xtensa.c (xtensa_is_insntable_section): New.
1020 (xtensa_is_proptable_section): New.
1021 (elf_xtensa_discard_info_for_section): Handle "full" .xt.prop property
1022 tables with 12-byte entries, as well as tables with 8-byte entries.
1023 Sort the relocations before examining them.
1024 (relax_property_section): Use xtensa_is_proptable_section and
1025 xtensa_is_littable_section. Rewrite code for combining table entries
1026 to be more robust in case of unexpected relocations. Do not set offset
1027 of unused relocations to less than zero.
1028 (xtensa_is_property_section): Use other functions instead of
1029 duplicating section name comparisons.
1030 (xtensa_is_littable_section): Use CONST_STRNEQ for ".gnu.linkonce.p.".
1031 (xtensa_get_property_predef_flags): Use xtensa_is_insntable_section.
4e591bc1 1032
e1e5c0b5 10332007-04-12 Bob Wilson <bob.wilson@acm.org>
4e591bc1 1034
e1e5c0b5
BW
1035 * elf32-xtensa.c (elf_xtensa_gc_mark_hook): Don't follow references
1036 from Xtensa property sections.
4e591bc1 1037
2c67c5f3
AM
10382007-04-12 Alan Modra <amodra@bigpond.net.au>
1039
1040 * elf32-spu.c (needs_ovl_stub): Test that spu_elf_section_data
1041 is non-NULL before dereferencing.
1042
8776bb8a
NS
10432007-04-11 Nathan Sidwell <nathan@codesourcery.com>
1044
1045 * elf-vxworks.c (elf_vxworks_emit_relocs): Remap weakdef PLT slot
1046 relocs too.
1047
4a828aab
RH
10482007-04-10 Richard Henderson <rth@redhat.com>
1049
1050 * elf64-alpha.c (struct alpha_elf_link_hash_table): Add relax_trip.
1051 (elf64_alpha_size_got_sections): Remove unused something_changed local.
1052 (elf64_alpha_size_plt_section): Return void.
1053 (elf64_alpha_size_rela_got_section): Likewise.
4e591bc1 1054 (elf64_alpha_relax_section): Only regenerate got+plt if the
4a828aab
RH
1055 relax_trip counter has changed.
1056
91506736
DJ
10572007-04-09 Daniel Jacobowitz <dan@codesourcery.com>
1058
1059 * Makefile.am (bfdver.h): Do not generate doc/bfdver.texi.
1060 * doc/Makefile.am (DOCFILES): Add bfdver.texi.
1061 (bfdver.texi): New rule.
1062 * Makefile.in, doc/Makefile.in: Regenerated.
1063
da6bcfca
MT
10642007-04-03 Matt Thomas <matt@netbsd.org>
1065
4e591bc1 1066 * elf32-vax.c (elf_vax_relocate_section): Do not emit a PCREL reloc
da6bcfca
MT
1067 in a shared object if it is not in a CODE section or if it is against
1068 a section symbol. This allows DWARF2 to use pcrel format.
1069
9267588c
L
10702007-04-05 H.J. Lu <hongjiu.lu@intel.com>
1071
1072 PR ld/4304
1073 * elflink.c (bfd_elf_final_link): Call einfo callback in
1074 bfd_link_info instead of _bfd_error_handler for DT_TEXTREL
1075 warning.
1076
c1b2796f
AM
10772007-04-05 Alan Modra <amodra@bigpond.net.au>
1078
1079 * elf32-spu.c (spu_elf_output_symbol_hook): New function.
1080 (elf_backend_link_output_symbol_hook): Define.
1081
970ccc77
NC
10822007-04-02 Nick Clifton <nickc@redhat.com>
1083
1084 PR binutils/4292
1085 * bfd.c (bfd_fprintf_vma): Do not print addresses of 32-bit
1086 targets as 64-bit values, even if running on a 64-bit host.
1087 * coffgen.c (coff_print_symbol): Likewise.
1088
1783205a
NC
10892007-03-29 Nick Clifton <nickc@redhat.com>
1090
1091 PR binutils/4110
1092 * elf.c (IS_VALID_GROUP_SECTION_HEADER): New macro.
1093 (setup_group): Use it. Report corrupt group section headers.
1094 (bfd_section_from_shdr): Use new macro. Replace constant 4 with
1095 GRP_ENTRY_SIZE. Cope with NULLs in the group section table.
1096 (elf_fake_section): Replace constant 4 with GRP_ENTRY_SIZE.
1097
2ce859a1
AM
10982007-03-29 Alan Modra <amodra@bigpond.net.au>
1099
1100 PR ld/4267
947844a3
AM
1101 * elflink.c (evaluate_complex_relocation_symbols): Use bfd_vma
1102 for rel->r_info values.
1103 (bfd_elf_perform_complex_relocation): Likewise.
2ce859a1
AM
1104 * elf32-ppc.c (allocate_dynrelocs): Set plt.offset to -1 for
1105 unused entries. Don't clear plt.plist in loop.
1106
39817122
RS
11072007-03-28 Richard Sandiford <richard@codesourcery.com>
1108
1109 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Remove append_rela.
1110 * elfxx-sparc.c (sparc_elf_append_rela_64, sparc_elf_append_rela_32):
1111 Merge into...
1112 (sparc_elf_append_rela): ...this new function.
1113 (SPARC_ELF_APPEND_RELA): Delete.
1114 (_bfd_sparc_elf_link_hash_table_create): Don't initialize
1115 the deleted append_rela field.
1116 (_bfd_sparc_elf_relocate_section): Use sparc_elf_append_rela
1117 instead of SPARC_ELF_APPEND_RELA.
1118 (_bfd_sparc_elf_finish_dynamic_symbol): Likewise. Use the
1119 elf_size_info structure to find the size of a RELA entry and
1120 the associated swap-out function.
1121 (sparc64_finish_dyn, sparc64_finish_dyn): Merge into...
1122 (sparc_finish_dyn): ...this new function.
1123 (_bfd_sparc_elf_finish_dynamic_sections): Update calls accordingly.
1124
4ecceb71
RS
11252007-03-28 Richard Sandiford <richard@codesourcery.com>
1126 Phil Edwards <phil@codesourcery.com>
1127
1128 * doc/bfd.texinfo: Put the contents after the title page rather
1129 than at the end of the document.
1130
d4d2b80b
AS
11312007-03-27 Andreas Schwab <schwab@suse.de>
1132
1133 * elfxx-ia64.c (elf_backend_default_execstack): Define to 0.
1134
831480e9 11352007-03-26 H.J. Lu <hongjiu.lu@intel.com>
5bd8253d
L
1136
1137 * configure: Regenerated.
1138
f4b39977
AM
11392007-03-26 Alan Modra <amodra@bigpond.net.au>
1140
1141 * elf32-spu.c (struct stubarr): Add stub_hash_table and err fields.
1142 (allocate_spuear_stubs): New function.
1143 (spu_elf_size_stubs): Call allocate_spuear_stubs.
1144
157090f7
AM
11452007-03-26 Alan Modra <amodra@bigpond.net.au>
1146
1147 * aout-adobe.c (aout_32_bfd_reloc_name_lookup): Define.
1148 * aout-arm.c (MY_bfd_reloc_name_lookup): Define.
1149 (MY (bfd_reloc_name_lookup)): New function.
1150 * aout-ns32k.c (MY (bfd_reloc_name_lookup)): New function.
1151 * aout-target.h (NAME (aout, reloc_name_lookup)): Declare.
1152 (MY_bfd_reloc_name_lookup): Define.
1153 * aout-tic30.c (tic30_aout_reloc_name_lookup): New function.
1154 (MY_bfd_reloc_name_lookup): Define.
1155 * aoutx.h (NAME (aout, reloc_type_lookup)): Don't declare.
1156 (NAME (aout, reloc_name_lookup)): New function.
1157 * bout.c (b_out_bfd_reloc_name_lookup): New function.
1158 * coff-alpha.c (alpha_bfd_reloc_name_lookup): New function.
1159 (_bfd_ecoff_bfd_reloc_name_lookup): Define.
1160 * coff-arm.c (coff_arm_reloc_name_lookup): New function.
1161 (coff_bfd_reloc_name_lookup): Define.
1162 * coff-i386.c (coff_bfd_reloc_name_lookup): Define.
1163 (coff_i386_reloc_name_lookup): New function.
1164 * coff-i860.c (coff_i860_reloc_name_lookup): New function.
1165 (coff_bfd_reloc_name_lookup): Define.
1166 * coff-i960.c (coff_i960_reloc_name_lookup): New function.
1167 (coff_bfd_reloc_name_lookup): Define.
1168 * coff-m68k.c (m68k_reloc_name_lookup): New function.
1169 (coff_bfd_reloc_name_lookup): Define.
1170 * coff-maxq.c (maxq_reloc_name_lookup): New function.
1171 (coff_bfd_reloc_name_lookup): Define.
1172 * coff-mcore.c (mcore_coff_reloc_name_lookup): New function.
1173 (coff_bfd_reloc_name_lookup): Define.
1174 * coff-mips.c (mips_bfd_reloc_name_lookup): New function.
1175 (_bfd_ecoff_bfd_reloc_name_lookup): Define.
1176 * coff-ppc.c (ppc_coff_reloc_name_lookup): New function.
1177 (coff_bfd_reloc_name_lookup): Define.
1178 * coff-rs6000.c (coff_bfd_reloc_name_lookup): Define.
1179 (_bfd_xcoff_reloc_name_lookup): New function.
1180 (rs6000coff_vec, pmac_xcoff_vec): Init new field.
1181 * coff-sh.c (coff_bfd_reloc_name_lookup): Define.
1182 (sh_coff_reloc_name_lookup): New function.
1183 * coff-sparc.c (coff_sparc_reloc_name_lookup): New function.
1184 (coff_bfd_reloc_name_lookup): Define.
1185 * coff-tic30.c (coff_bfd_reloc_name_lookup): Define.
1186 (tic30_coff_reloc_name_lookup): New function.
1187 * coff-tic4x.c (coff_bfd_reloc_name_lookup): Define.
1188 (tic4x_coff_reloc_name_lookup): New function.
1189 * coff-tic54x.c (coff_bfd_reloc_name_lookup): Define.
1190 (tic54x_coff_reloc_name_lookup): New function.
1191 * coff-x86_64.c (coff_bfd_reloc_name_lookup): Define.
1192 (coff_amd64_reloc_name_lookup): New function.
1193 * coff-z80.c (coff_z80_reloc_name_lookup): New function.
1194 (coff_bfd_reloc_name_lookup): Define.
1195 * coff-z8k.c (coff_z8k_reloc_name_lookup): New function.
1196 (coff_bfd_reloc_name_lookup): Define.
1197 * coff64-rs6000.c (coff_bfd_reloc_name_lookup): Define.
1198 (xcoff64_reloc_name_lookup): New function.
1199 (rs6000coff64_vec, aix5coff64_vec): Init new field.
1200 * coffcode.h (coff_bfd_reloc_name_lookup): Define.
1201 * elf-hppa.h (elf_hppa_reloc_name_lookup): New function.
1202 * elf-m10200.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1203 * elf-m10300.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1204 * elf32-arc.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1205 * elf32-arm.c (elf32_arm_reloc_name_lookup): New function.
1206 (bfd_elf32_bfd_reloc_name_lookup): Define.
1207 * elf32-avr.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1208 * elf32-bfin.c (bfin_bfd_reloc_name_lookup): New function.
1209 (bfd_elf32_bfd_reloc_name_lookup): Define.
1210 * elf32-cr16c.c (elf_cr16c_reloc_name_lookup): New function.
1211 (bfd_elf32_bfd_reloc_name_lookup): Define.
1212 * elf32-cris.c (cris_reloc_name_lookup): New function.
1213 (bfd_elf32_bfd_reloc_name_lookup): Define.
1214 * elf32-crx.c (elf_crx_reloc_name_lookup): New function.
1215 (bfd_elf32_bfd_reloc_name_lookup): Define.
1216 * elf32-d10v.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1217 * elf32-d30v.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1218 * elf32-dlx.c (elf32_dlx_reloc_name_lookup): New function.
1219 (bfd_elf32_bfd_reloc_name_lookup): Define.
1220 * elf32-fr30.c (fr30_reloc_name_lookup): New function.
1221 (bfd_elf32_bfd_reloc_name_lookup): Define.
1222 * elf32-frv.c (frv_reloc_name_lookup): New function.
1223 (bfd_elf32_bfd_reloc_name_lookup): Define.
1224 * elf32-gen.c (bfd_elf32_bfd_reloc_name_lookup): Define.
1225 * elf32-h8300.c (elf32_h8_reloc_name_lookup): New function.
1226 (bfd_elf32_bfd_reloc_name_lookup): Define.
1227 * elf32-hppa.c (bfd_elf32_bfd_reloc_name_lookup): Define.
1228 * elf32-i370.c (i370_elf_reloc_name_lookup): New function.
1229 (bfd_elf32_bfd_reloc_name_lookup): Define.
1230 * elf32-i386.c (elf_i386_reloc_name_lookup): New function.
1231 (bfd_elf32_bfd_reloc_name_lookup): Define.
1232 * elf32-i860.c (elf32_i860_reloc_name_lookup): New function.
1233 (bfd_elf32_bfd_reloc_name_lookup): Define.
1234 * elf32-i960.c (elf32_i960_reloc_name_lookup): New function.
1235 (bfd_elf32_bfd_reloc_name_lookup): Define.
1236 * elf32-ip2k.c (ip2k_reloc_name_lookup): New function.
1237 (bfd_elf32_bfd_reloc_name_lookup): Define.
1238 * elf32-iq2000.c (iq2000_reloc_name_lookup): New function.
1239 (bfd_elf32_bfd_reloc_name_lookup): Define.
1240 * elf32-m32c.c (m32c_reloc_name_lookup): New function.
1241 (bfd_elf32_bfd_reloc_name_lookup): Define.
1242 * elf32-m32r.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1243 * elf32-m68hc11.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1244 * elf32-m68hc12.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1245 * elf32-m68k.c (reloc_name_lookup): New function.
1246 (bfd_elf32_bfd_reloc_name_lookup): Define.
1247 * elf32-m88k.c (bfd_elf32_bfd_reloc_name_lookup): Define.
1248 * elf32-mcore.c (mcore_elf_reloc_name_lookup): New function.
1249 (bfd_elf32_bfd_reloc_name_lookup): Define.
1250 * elf32-mep.c (mep_reloc_name_lookup): New function.
1251 (bfd_elf32_bfd_reloc_name_lookup): Define.
1252 * elf32-mips.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1253 (mips_vxworks_bfd_reloc_name_lookup): Likewise.
1254 (bfd_elf32_bfd_reloc_name_lookup): Define.
1255 * elf32-msp430.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1256 * elf32-mt.c (mt_reloc_name_lookup): New function.
1257 (bfd_elf32_bfd_reloc_name_lookup): Define.
1258 * elf32-openrisc.c (openrisc_reloc_name_lookup): New function.
1259 (bfd_elf32_bfd_reloc_name_lookup): Define.
1260 * elf32-or32.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1261 * elf32-pj.c (pj_elf_reloc_name_lookup): New function.
1262 (bfd_elf32_bfd_reloc_name_lookup): Define.
1263 * elf32-ppc.c (ppc_elf_reloc_name_lookup): New function.
1264 (bfd_elf32_bfd_reloc_name_lookup): Define.
1265 * elf32-s390.c (elf_s390_reloc_name_lookup): New function.
1266 (bfd_elf32_bfd_reloc_name_lookup): Define.
1267 * elf32-score.c (elf32_score_reloc_name_lookup): New function.
1268 (bfd_elf32_bfd_reloc_name_lookup): Define.
1269 * elf32-sh.c (sh_elf_reloc_name_lookup): New function.
1270 (bfd_elf32_bfd_reloc_name_lookup): Define.
1271 * elf32-sparc.c (bfd_elf32_bfd_reloc_name_lookup): Define.
1272 * elf32-spu.c (spu_elf_reloc_name_lookup): New function.
1273 (bfd_elf32_bfd_reloc_name_lookup): Define.
1274 * elf32-v850.c (v850_elf_reloc_name_lookup): New function.
1275 (bfd_elf32_bfd_reloc_name_lookup): Define.
1276 * elf32-vax.c (reloc_name_lookup): New function.
1277 (bfd_elf32_bfd_reloc_name_lookup): Define.
1278 * elf32-xc16x.c (xc16x_reloc_name_lookup): New function.
1279 (bfd_elf32_bfd_reloc_name_lookup): Define.
1280 * elf32-xstormy16.c (xstormy16_reloc_name_lookup): New function.
1281 (bfd_elf32_bfd_reloc_name_lookup): Define.
1282 * elf32-xtensa.c (elf_xtensa_reloc_name_lookup): New function.
1283 (bfd_elf32_bfd_reloc_name_lookup): Define.
1284 * elf64-alpha.c (elf64_alpha_bfd_reloc_name_lookup): New function.
1285 (bfd_elf64_bfd_reloc_name_lookup): Define.
1286 * elf64-gen.c (bfd_elf64_bfd_reloc_name_lookup): Define.
1287 * elf64-hppa.c (bfd_elf64_bfd_reloc_name_lookup): Define.
1288 * elf64-mips.c (bfd_elf64_bfd_reloc_name_lookup): New function.
1289 * elf64-mmix.c (bfd_elf64_bfd_reloc_name_lookup): New function.
1290 * elf64-ppc.c (ppc64_elf_reloc_name_lookup): New function.
1291 (bfd_elf64_bfd_reloc_name_lookup): Define.
1292 * elf64-s390.c (elf_s390_reloc_name_lookup): New function.
1293 (bfd_elf64_bfd_reloc_name_lookup): Define.
1294 * elf64-sh64.c (sh_elf64_reloc_name_lookup): New function.
1295 (bfd_elf64_bfd_reloc_name_lookup): Define.
1296 * elf64-sparc.c (bfd_elf64_bfd_reloc_name_lookup): Define.
1297 * elf64-x86-64.c (elf64_x86_64_reloc_name_lookup): New function.
1298 (bfd_elf64_bfd_reloc_name_lookup): Define.
1299 * elfn32-mips.c (bfd_elf32_bfd_reloc_name_lookup): New function.
1300 * elfxx-ia64.c (elfNN_ia64_reloc_name_lookup): New function.
1301 (bfd_elfNN_bfd_reloc_name_lookup): Define.
1302 * elfxx-sparc.c (_bfd_sparc_elf_reloc_name_lookup): New function.
1303 * elfxx-sparc.h (_bfd_sparc_elf_reloc_name_lookup): Declare.
1304 * i386msdos.c (msdos_bfd_reloc_name_lookup): Define.
1305 * i386os9k.c (aout_32_bfd_reloc_name_lookup): Define.
1306 * ieee.c (ieee_bfd_reloc_name_lookup): Define.
1307 * libaout.h (NAME (aout, reloc_name_lookup)): Declare.
1308 * libbfd-in.h (_bfd_norelocs_bfd_reloc_name_lookup): Declare.
1309 * mipsbsd.c (MY_bfd_reloc_name_lookup): Define.
1310 (MY(reloc_type_lookup)): Rename from MY(reloc_howto_type_lookup).
1311 (MY(reloc_name_lookup)): New function.
1312 * nlm-target.h (nlm_bfd_reloc_name_lookup): Define.
1313 * oasys.c (oasys_bfd_reloc_name_lookup): Define.
1314 * pdp11.c (NAME (aout, reloc_name_lookup)): New function.
1315 * pe-mips.c (coff_mips_reloc_name_lookup): New function.
1316 (coff_bfd_reloc_name_lookup): Define.
1317 * reloc.c (bfd_reloc_name_lookup): New function.
1318 * riscix.c (riscix_reloc_name_lookup): New function.
1319 (MY_bfd_reloc_name_lookup): Define.
1320 * som.c (som_bfd_reloc_name_lookup): New function.
1321 * targets.c (struct bfd_target): Add reloc_name_lookup.
1322 (BFD_JUMP_TABLE_RELOCS): Add NAME##_bfd_reloc_name_lookup.
1323 * versados.c (versados_bfd_reloc_name_lookup): Define.
1324 * vms.c (vms_bfd_reloc_name_lookup): New function.
1325 * bfd-in2.h: Regenerate.
1326 * libbfd.h: Regenerate.
1327
2d82d84d
TS
13282007-03-26 Thiemo Seufer <ths@mips.com>
1329
a5cb1fd7 1330 PR ld/4208
2d82d84d
TS
1331 * elfxx-mips.c (mips_elf_next_relocation): Don't signal an error if no
1332 matching relocation is found.
1333 (_bfd_mips_elf_relocate_section): Only warn about missing relocations.
1334
831480e9 13352007-03-23 H.J. Lu <hongjiu.lu@intel.com>
1a27db7d
L
1336
1337 * configure: Regenerated.
1338
a1ac8190
JM
13392007-03-23 Joseph Myers <joseph@codesourcery.com>
1340
1341 * configure.in: Use ACX_PKGVERSION and ACX_BUGURL.
1342 * configure: Regenerate.
1343
aa7a0635
AM
13442007-03-23 Alan Modra <amodra@bigpond.net.au>
1345
1346 * elf32-spu.c (spu_stub_name): Don't put input section in stub name.
1347 Remove input_sec param. Adjust all calls.
1348 (write_one_stub): Adjust stub symbol.
1349 (needs_ovl_stub): New function, extracted from..
1350 (spu_elf_size_stubs): ..here.
1351 (spu_elf_relocate_section): Use needs_ovl_stub.
1352
e49e529d
JM
13532007-03-22 Joseph Myers <joseph@codesourcery.com>
1354
1355 * Makefile.am (bfdver.h): Only set VERSION_PACKAGE in bfdver.texi
1356 if nonempty.
1357 * configure.in (REPORT_BUGS_TO): Do not use "URL:" prefix.
1358 * Makefile.in, configure, doc/Makefile.in: Regenerate.
1359
831480e9 13602007-03-22 H.J. Lu <hongjiu.lu@intel.com>
50572669
L
1361
1362 PR ld/4210
1363 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Use the virtual
1364 address and virtual size of the last section for the image
1365 size.
1366
0920dee7
L
13672007-03-22 H.J. Lu <hongjiu.lu@intel.com>
1368
1369 PR ld/4007
1370 * elf.c (assign_file_positions_for_load_sections): Check if
1371 all sections are in the segment.
1372
831480e9 13732007-03-20 H.J. Lu <hongjiu.lu@intel.com>
749b8d9d
L
1374
1375 PR ld/4208
1376 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Report missing
1377 matching LO16 relocation for HI16 relocation.
1378
27e55c4d
PB
13792007-03-20 Paul Brook <paul@codesourcery.com>
1380
1381 * bfd-in.h (bfd_elf32_arm_set_target_relocs): Update prototype.
1382 * bfd-in2.h: Regenerate.
1383 * elf32-arm.c (elf32_arm_link_hash_table): Add pic_veneer.
1384 (record_arm_to_thumb_glue): Use globals->pic_veneer.
1385 (elf32_arm_create_thumb_stub): Ditto.
1386 (bfd_elf32_arm_set_target_relocs): Set globals->pic_veneer.
1387
bf21ed78
MS
13882007-03-18 Mark Shinwell <shinwell@codesourcery.com>
1389
1390 * bfd-in.h (bfd_elf32_arm_set_target_relocs): Add "bfd *"
1391 argument and extra last argument.
1392 * bfd-in2.h: Regenerate.
1393 * elf32-arm.c (elf32_arm_obj_tdata): Add no_enum_size_warning
1394 member.
1395 (bfd_elf32_arm_set_target_relocs): Add "bfd *" argument and
1396 extra last argument. Set no_enum_size_warning appropriately.
1397 (elf32_arm_merge_eabi_attributes): Improve enum sizes
1398 diagnostic, suppressing it when no_enum_size_warning dictates.
1399
5f6999aa
NC
14002007-03-20 Nick Clifton <nickc@redhat.com>
1401
1402 PR binutils/3535
1403 * elf.c (copy_private_bfd_data): Widen the scope of Solaris
1404 specific conditions that need the program headers to be
1405 rewritten.
1406
831480e9 14072007-03-19 H.J. Lu <hongjiu.lu@intel.com>
d13c9dc6
L
1408
1409 * peXXigen.c (_bfd_XXi_swap_aouthdr_in): Store Magic,
1410 MajorLinkerVersion, MinorLinkerVersion, SizeOfCode,
1411 SizeOfInitializedData, SizeOfUninitializedData,
1412 AddressOfEntryPoint, BaseOfCode and BaseOfData in internal
1413 extra PE a.out header.
1414 (IMAGE_NT_OPTIONAL_HDR_MAGIC): Defined as 0x10b if not defined.
1415 (IMAGE_NT_OPTIONAL_HDR64_MAGIC): Defined as 0x20b if not
1416 defined.
1417 (IMAGE_NT_OPTIONAL_HDRROM_MAGIC): Defined as 0x107 if not
1418 defined.
1419 (_bfd_XX_print_private_bfd_data_common): Also print Magic,
1420 MajorLinkerVersion, MinorLinkerVersion, SizeOfCode,
1421 SizeOfInitializedData, SizeOfUninitializedData,
1422 AddressOfEntryPoint, BaseOfCode and BaseOfData from internal
1423 extra PE a.out header.
1424
831480e9 14252007-03-18 H.J. Lu <hongjiu.lu@intel.com>
739bb57e
L
1426
1427 * targets.c (_bfd_target_vector): Add bfd_efi_app_x86_64_vec
1428 only if BFD64 is defined.
1429
5384511f
AM
14302007-03-17 Alan Modra <amodra@bigpond.net.au>
1431
1432 * elf32-spu.c (spu_elf_size_stubs): Always use an overlay stub
1433 on setjmp calls.
1434
187b3d5d
L
14352007-03-15 H.J. Lu <hongjiu.lu@intel.com>
1436
1437 * doc/Makefile.in: Regenerated.
1438
c428fa83
L
14392007-03-15 H.J. Lu <hongjiu.lu@intel.com>
1440
1441 * Makefile.am (bfdver.h): Substitute report_bugs_to. Also
1442 create doc/bfdver.texi.
1443 * Makefile.in: Regenerated.
1444
1445 * configure.in (--with-bugurl): New option.
1446 * configure: Regenerated.
1447
1448 * version.h (REPORT_BUGS_TO): New.
1449
d1036acb
L
14502007-03-13 H.J. Lu <hongjiu.lu@intel.com>
1451
1452 PR binutils/3826
1453 * elf-bfd.h (elf_backend_data): Add elf_osabi.
1454 (_bfd_elf_set_osabi): New.
1455
1456 * elf.c (_bfd_elf_set_osabi): New.
1457
1458 * elf32-hppa.c (elf32_hppa_post_process_headers): Removed.
1459 (elf_backend_post_process_headers): Defined with
1460 _bfd_elf_set_osabi.
1461 (ELF_OSABI): Properly defined for each target.
1462
1463 * elf32-i370.c (i370_elf_post_process_headers): Removed.
1464 (ELF_OSABI): Defined.
1465 (elf_backend_post_process_headers): Defined with
1466 _bfd_elf_set_osabi.
1467
1468 * elf32-i386.c (ELF_OSABI): Defined to ELFOSABI_FREEBSD for
1469 freebsd.
1470 (elf_i386_post_process_headers): Set EI_OSABI with elf_osabi.
1471
1472 * elf32-msp430.c (elf32_msp430_post_process_headers): Removed.
1473 (ELF_OSABI): Defined.
1474 (elf_backend_post_process_headers): Defined with
1475 _bfd_elf_set_osabi.
1476
1477 * elf64-alpha.c (ELF_OSABI): Defined to ELFOSABI_FREEBSD for
1478 freebsd.
1479 (elf64_alpha_fbsd_post_process_headers): Set EI_OSABI with
1480 elf_osabi.
1481
1482 * elf64-hppa.c (elf64_hppa_post_process_headers): Set EI_OSABI
1483 with elf_osabi.
1484 (ELF_OSABI): Properly defined for each target.
1485 (elf_backend_post_process_headers): Defined with
1486 _bfd_elf_set_osabi for Linux.
1487
1488 * elf64-sparc.c (elf64_sparc_fbsd_post_process_headers): Removed.
1489 (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd.
1490 (elf_backend_post_process_headers): Defined with
1491 _bfd_elf_set_osabi.
1492
1493 * elf64-x86-64.c (elf64_x86_64_fbsd_post_process_headers): Removed.
1494 (ELF_OSABI): Defined to ELFOSABI_FREEBSD for freebsd.
1495 (elf_backend_post_process_headers): Defined with
1496 _bfd_elf_set_osabi.
1497
1498 * elfcode.h (elf_object_p): Match the ELFOSABI_NONE ELF target
1499 with any ELF target of the compatible machine for which we do not
1500 have a specific backend.
1501
1502 * elfxx-ia64.c (elfNN_hpux_post_process_headers): Set EI_OSABI
1503 with elf_osabi.
1504
1505 * elfxx-target.h (ELF_OSABI): Default to ELFOSABI_NONE.
1506 (elfNN_bed): Initialize elf_osabi with ELF_OSABI.
1507
d4c87fc1
AM
15082007-03-08 Alan Modra <amodra@bigpond.net.au>
1509
1510 * elf32-v850.c (v850_elf_link_output_symbol_hook): Clean out
1511 V850_OTHER_* bits.
1512
9c6fc49d
AM
15132007-03-08 Alan Modra <amodra@bigpond.net.au>
1514
1515 * Makefile.am (BFD64_BACKENDS): Add efi-app-x86_64.lo.
1516 (BFD64_BACKENDS_CFILES): Add efi-app-x86_64.c.
1517 Run "make dep-am".
1518 * Makefile.in: Regenerate.
1519 * po/SRC-POTFILES.in: Regenerate.
1520
faed74d6
L
15212007-03-07 H.J. Lu <hongjiu.lu@intel.com>
1522
1523 * config.bfd (x86_64-*-freebsd*): Add bfd_efi_app_x86_64_vec.
1524 (x86_64-*-kfreebsd*-gnu): Likewise.
1525 (x86_64-*-netbsd*): Likewise.
1526 (x86_64-*-openbsd*): Likewise.
1527 (x86_64-*-linux-*): Likewise.
1528
1529 * configure.in: Support bfd_efi_app_x86_64_vec.
1530 * configure: Regenerated.
1531
1532 * efi-app-x86_64.c: New file.
1533
1534 * targets.c (bfd_efi_app_x86_64_vec): New.
1535 (_bfd_target_vector): Add bfd_efi_app_x86_64_vec.
1536
15344ad7
L
15372007-03-07 Kai Tietz <kai.tietz@onevision.com>
1538
1539 * reloc.c (bfd_generic_get_relocated_section_contents): Remove
1540 const for type reloc_howto_type.
1541
ab96bf03
AM
15422007-03-07 Alan Modra <amodra@bigpond.net.au>
1543
1544 PR 3958
1545 * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): No error on relocatable link.
1546 (elf_discarded_section): Move..
1547 * bfd-in.h: ..to here.
1548 * bfd-in2.h: Regenerate.
1549 * elflink.c (elf_link_input_bfd): Don't zap relocs against symbols
1550 from discarded sections before relocate_section has done its job.
1551 * reloc.c (bfd_generic_get_relocated_section_contents): Handle
1552 relocs against symbols from discarded sections.
1553 * elf-hppa.h (elf_hppa_howto_table): Set size. Set dst_mask on
1554 SECREL32.
1555 (elf_hppa_relocate_section): Handle relocatable link after setting
1556 sec, sym, h etc. for final link. Squash error messages for
1557 relocatable link. Clear section contents for relocs against
1558 symbols in discarded sections, and zero reloc. Remove existing
1559 zero r_symndx code.
1560 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
1561 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
1562 * elf32-arm.c (elf32_arm_relocate_section): Likewise.
1563 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
1564 * elf32-bfin.c (bfinfdpic_relocate_section): Likewise.
1565 (bfin_relocate_section): Likewise.
1566 * elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
1567 * elf32-cris.c (cris_elf_relocate_section): Likewise.
1568 * elf32-crx.c (elf32_crx_relocate_section): Likewise.
1569 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
1570 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
1571 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
1572 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
1573 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
1574 * elf32-i370.c (i370_elf_relocate_section): Likewise.
1575 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1576 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
1577 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
1578 * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
1579 * elf32-m32c.c (m32c_elf_relocate_section): Likewise.
1580 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
1581 * elf32-m68hc1x.c (elf32_m68hc11_check_relocs): Likewise.
1582 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1583 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
1584 * elf32-mep.c (mep_elf_relocate_section): Likewise.
1585 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
1586 * elf32-mt.c (mt_elf_relocate_section): Likewise.
1587 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
1588 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1589 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1590 * elf32-score.c (_bfd_score_elf_relocate_section): Likewise.
1591 * elf32-sh.c (sh_elf_relocate_section): Likewise.
1592 * elf32-spu.c (spu_elf_relocate_section): Likewise.
1593 * elf32-v850.c (v850_elf_relocate_section): Likewise.
1594 * elf32-vax.c (elf_vax_relocate_section): Likewise.
1595 * elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
1596 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
1597 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
1598 * elf64-alpha.c (elf64_alpha_relocate_section_r): Likewise.
1599 (elf64_alpha_relocate_section): Likewise.
1600 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
1601 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1602 * elf64-s390.c (elf_s390_relocate_section): Likewise.
1603 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1604 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1605 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
1606 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Likewise.
1607 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1608
1609 * elf32-arm.c (elf32_arm_relocate_section): Always adjust section
1610 symbols for relocatable link. Don't use always-zero st_value.
1611 (elf_backend_rela_normal): Don't define.
1612 * elf32-bfin.c (bfinfdpic_relocate_section): Use
1613 RELOC_FOR_GLOBAL_SYMBOL.
1614 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
1615 * elf32-d10v.c (elf32_d10v_relocate_section): Combine SEC_MERGE
1616 section symbol adjustments with same for relocatable link.
1617 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1618 * elf32-m68hc1x.c (m68hc11_get_relocation_value): Move..
1619 (elf32_m68hc11_check_relocs): ..to here.
1620 * elf32-score.c (score_elf_final_link_relocate): Remove zero
1621 r_symndx code.
1622 * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
1623
0e922b77
AM
16242007-03-07 Alan Modra <amodra@bigpond.net.au>
1625
1626 PR 4144
1627 * elf.c (assign_file_positions_for_load_sections): Don't
1628 adjust p_memsz for !SEC_LOAD section vma modulo page size.
1629 Instead, use the same lma based adjustment for SEC_LOAD
1630 sections.
1631
25c6282a
BW
16322007-03-01 Bob Wilson <bob.wilson@acm.org>
1633
1634 * elf32-xtensa.c (analyze_relocations): Zero src_count if not relaxing.
1635 (find_relaxable_sections): Do not increment src_count for unknown
1636 opcodes. Decode only once instead of calling is_l32r_relocation.
1637 (compute_text_actions): Remove unused no_insn_move flag. Assert that
1638 src_next matches src_count in relax_info.
1639
066c2a57
JM
16402007-03-01 Joseph Myers <joseph@codesourcery.com>
1641
1642 * Makefile.am (bfdver.h): Use "." not " " between version number
1643 and date.
1644 * Makefile.in: Regenerate.
1645 * configure.in (PKGVERSION): Default to "(GNU Binutils) ".
1646 * configure: Regenerate.
1647
ed6ba298
NS
16482007-02-28 Nathan Sidwell <nathan@codesourcery.com>
1649
1650 * config.bfd (sh-*-uclinux, sh[12]-*-uclinux): New stanza.
1651
7a8757b3
AM
16522007-02-27 Alan Modra <amodra@bigpond.net.au>
1653
1654 * elf32-spu.h (struct _ovl_stream): Make "start" and "end" const.
1655 * elf32-spu.c (ovl_mgr_pread): Add const to casts.
1656
024b2372
CD
16572007-02-23 Carlos O'Donell <carlos@codesourcery.com>
1658
1659 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Assume 32-bit
1660 DWARF even with 64-bit addresses.
1661 (_bfd_dwarf2_find_nearest_line): Likewise.
1662
cb3ff1e5
NC
16632007-02-23 Nick Clifton <nickc@redhat.com>
1664
1665 PR binutils/3535
1666 * elf.c (copy_private_bfd_data): Always rewrite the program
1667 headers when a Solaris interpreter segment is involved.
1668
6a5bb875
PB
16692007-02-22 Paul Brook <paul@codesourcery.com>
1670
1671 * elflink.c (gc_mark_hook_fn): Remove.
1672 (_bfd_elf_gc_mark): Rename gc_mark_hook_fn to elf_gc_mark_hook_fn.
1673 (bfd_elf_gc_sections): Ditto. Call gc_mark_extra_sections.
1674 * elf-bfd.h (elf_gc_mark_hook_fn): Define.
1675 (elf_backend_data): Add gc_mark_extra_sections.
1676 * elfxx-target.h (elf_backend_gc_mark_extra_sections): Provide default
1677 definition.
1678 (elfNN_bed): Add elf_backend_gc_mark_extra_sections.
1679 * elf32-arm.c (elf32_arm_gc_mark_extra_sections): New function.
1680 (elf_backend_gc_mark_extra_sections): Define.
1681
2889e75b
NC
16822007-02-21 Nick Clifton <nickc@redhat.com>
1683
1684 * elf.c (_bfd_elf_map_sections_to_segments): If the
1685 override_segment_assignment callback is defined then call it.
1686
78859468
AM
16872007-02-21 Alan Modra <amodra@bigpond.net.au>
1688
1689 * elf32-spu.c (spu_elf_size_stubs): Correct order of warning args.
1690
ae0d2616
TS
16912007-02-19 Thiemo Seufer <ths@mips.com>
1692
1693 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): Remove
1694 translation marker from untranslatable strings.
1695
6bfdb61b
AM
16962007-02-19 Alan Modra <amodra@bigpond.net.au>
1697
1698 * elf-bfd.h (struct elf_backend_data): Add default_execstack.
1699 * elflink.c (bfd_elf_size_dynamic_sections): Heed default_execstack.
1700 * elfxx-target.h (elf_backend_default_execstack): Define to 1.
1701 (elfNN_bed): Init new field.
1702 * elf64-ppc.c (elf_backend_default_execstack): Define to 0.
1703
92f01d61
JM
17042007-02-17 Mark Mitchell <mark@codesourcery.com>
1705 Nathan Sidwell <nathan@codesourcery.com>
1706 Vladimir Prus <vladimir@codesourcery.com
1707 Joseph Myers <joseph@codesourcery.com>
1708
1709 * configure.in (--with-pkgversion): New option.
1710 * configure: Regenerate.
1711 * Makefile.am (bfdver.h): Substitute for @bfd_version_package@.
1712 * Makefile.in: Regenerate.
1713 * version.h (BFD_VERSION_STRING): Define using
1714 @bfd_version_package@.
1715
c0e3f241
CD
17162007-02-16 Carlos O'Donell <carlos@codesourcery.com>
1717
1718 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data):
1719 Print EF_MIPS_NOREORDER, EF_MIPS_PIC, EF_MIPS_CPIC, EF_MIPS_XGOT
1720 and EF_MIPS_UCODE.
1721
72f6ea61
AM
17222007-02-15 Alan Modra <amodra@bigpond.net.au>
1723
1724 * libbfd-in.h (_bfd_norelocs_get_reloc_upper_bound): Don't define,
1725 declare.
1726 (_bfd_norelocs_canonicalize_reloc): Likewise.
1727 * libbfd.h: Regenerate.
1728 * libbfd.c (_bfd_norelocs_get_reloc_upper_bound): New function.
1729 (_bfd_norelocs_canonicalize_reloc): Likewise.
1730 * binary.c (binary_bfd_reloc_type_lookup): Don't define.
1731 (binary_get_reloc_upper_bound, binary_canonicalize_reloc): Likewise.
1732 (binary_vec): Use _bfd_norelocs in BFD_JUMP_TABLE_RELOCS.
1733 * ihex.c: Similarly.
1734 * mach-o-target.c: Similarly.
1735 * mach-o.c: Similarly.
1736 * mmo.c: Similarly.
1737 * pef.c: Similarly.
1738 * ppcboot.c: Similarly.
1739 * srec.c: Similarly.
1740 * xsym.c: Similarly.
1741
fab4a87f
L
17422007-02-14 H.J. Lu <hongjiu.lu@intel.com>
1743
1744 PR ld/3953
1745 * elflink.c (_bfd_elf_add_default_symbol): Check warning symbol
1746 when adding default symbol.
1747
e4e0193e
AM
17482007-02-13 Alan Modra <amodra@bigpond.net.au>
1749
1750 * elf64-ppc.c (create_linkage_sections): Use section ".branch_lt"
1751 for branch lookup table.
1752
84f5d08e
AM
17532007-02-12 Alan Modra <amodra@bigpond.net.au>
1754
1755 * elf64-ppc.c (create_linkage_sections): Don't create
1756 .rela.rodata.brlt for --emit-relocs.
1757 (ppc_build_one_stub): Create relocs for brlt --emit-relocs here.
1758 (ppc_size_one_stub): Count them. Simplify test of stub type
1759 when counting stub relocs. Set SEC_RELOC too.
1760 (ppc64_elf_size_stubs): Clear reloc_count and SEC_RELOC.
1761 (ppc64_elf_finish_dynamic_sections): Output brlt relocs.
1762
4aac632e
AM
17632007-02-12 Alan Modra <amodra@bigpond.net.au>
1764
1765 * elflink.c (evaluate_complex_relocation_symbols): Ignore relocs
1766 with a zero symbol index.
1767
8da3dbc5
AM
17682007-02-12 Alan Modra <amodra@bigpond.net.au>
1769
1770 * elflink.c (bfd_elf_discard_info): Tidy setting of "eh".
1771
b31847af
DB
17722007-02-05 Dave Brolley <brolley@redhat.com>
1773 Stan Cox <scox@redhat.com>
1774
1775 PR ld/3972
1776 * elflink.c (elf_link_input_bfd): Always setup finfo->internal_syms.
1777
722b0ff7 17782007-02-05 Dave Brolley <brolley@redhat.com>
e382d174
DB
1779 Richard Sandiford <rsandifo@redhat.com>
1780 Stan Cox <scox@redhat.com>
1781 Nick Clifton <nickc@redhat.com>
1782 DJ Delorie <dj@redhat.com>
1783 Frank Ch. Eigler <fche@redhat.com>
1784 Ben Elliston <bje@redhat.com>
1785 Richard Henderson <rth@redhat.com>
1786
1787 * Makefile.am (ALL_MACHINES): Add cpu-mep.lo.
1788 (ALL_MACHINES_CFILES): Add CPU_MEP.c.
1789 (BFD32_BACKENDS): Add elf32-mep.lo.
1790 (BFD32_BACKENDS_CFILES): Add elf32-mep.c.
1791 (cpu-mep.lo,elf32-mep.lo): New targets.
1792 * archures.c (bfd_arch_mep): New enumerator.
1793 (bfd_mach_mep, bfd_mach_mep_h1): New macros.
1794 (bfd_mep_arch): New external variable.
1795 (bfd_archures_list): Add bfd_mep_arch.
1796 * config.bfd: Support mep-*-elf.
1797 * configure.in: Support bfd_elf32_mep_vec and bfd_elf32_mep_little_vec.
1798 * reloc.c (BFD_RELOC_MEP_*): New relocation numbers.
1799 * targets.c (bfd_elf32_mep_vec,bfd_elf32_mep_little_vec): New extern
1800 declarations.
1801 (_bfd_target_vector): Add bfd_elf32_mep_vec and
1802 bfd_elf32_mep_little_vec.
722b0ff7
DB
1803 * mep-relocs.pl: New file.
1804 * cpu-mep.c: New file.
1805 * elf32-mep.c: New file.
1806 * bfd-in2.h: Regenerate.
e382d174 1807 * po/POTFILES.in: Regenerate.
722b0ff7
DB
1808 * libbfd.h: Regenerate.
1809 * Makefile.in: Regenerate.
1810 * configure: Regenerate.
1811
d9352518
DB
18122007-02-05 Dave Brolley <brolley@redhat.com>
1813
1814 * elflink.c (evaluate_complex_relocation_symbols): Check for
1815 STT_SRELC for global symbols.
1816 (perform_complex_relocations): Renamed to
1817 perform_complex_relocation and now examines only one relocation.
1818 (elf_link_input_bfd): Don't call perform_complex_relocations.
74e880a7 1819 * elf-bfd.h (bfd_elf_perform_complex_relocation_: New prototype.
d9352518
DB
1820 * elf32-mep.c (mep_elf_howto_table): Add R_RELC.
1821 (OD,OS,OU): #undefs corrected to N, S and U repectively.
1822 (mep_reloc_type_lookup): Handle BFD_RELOC_RELC.
1823 (complex_reloc_installation_howto): Removed.
1824 (mep_info_to_howto_rela): Remove special case for r_type==0xff.
1825 (mep_elf_relocate_section): Call bfd_elf_perform_complex_relocation.
1826
d9352518 18272007-02-05 Dave Brolley <brolley@redhat.com>
e382d174
DB
1828 Richard Sandiford <rsandifo@redhat.com>
1829 DJ Delorie <dj@redhat.com>
1830 Graydon Hoare <graydon@redhat.com>
1831 Nick Clifton <nickc@cambridge.redhat.com>
1832 Jeff Holcomb <jeffh@redhat.com>
1833 Frank Ch. Eigler <fche@redhat.com>
1834
1835 * elf-bfd.h (bfd_elf_perform_complex_relocations): New prototype.
1836 * elf.c (swap_out_syms): Handle BSF_RELC and BSF_SRELC.
1837 * elfcode.h (elf_slurp_symbol_table): Handle STT_RELC and STT_SRELC.
1838 * elflink.c (set_symbolValue): New static function.
d9352518
DB
1839 (resolve_symbol): Likewise.
1840 (resolve_section): Likewise.
1841 (undefined_reference): Likewise.
1842 (eval_symbol): Likewise.
1843 (evaluate_complex_relocation_symbols): Likewise.
1844 (put_value): Likewise.
1845 (get_value): Likewise.
e382d174
DB
1846 (decode_complex_addend):
1847 (bfd_elf_perform_complex_relocation): New function.
1848 (elf_link_input_bfd): Call evaluate_complex_relocation_symbols.
1849 * reloc.c (BFD_RELOC_RELC): New relocation number.
1850 * syms.c (BSF_RELC,BSF_SRELC): New macros.
d9352518 1851
f1ab2340 18522007-02-05 Bob Wilson <bob.wilson@acm.org>
74e880a7 1853
f1ab2340
BW
1854 * elf32-xtensa.c (elf_xtensa_make_sym_local): Delete.
1855 (elf_xtensa_hide_symbol, elf_backend_hide_symbol): Delete.
1856 (elf_xtensa_fix_refcounts, elf_xtensa_allocate_plt_size)
1857 (elf_xtensa_allocate_got_size): Replace these with...
1858 (elf_xtensa_allocate_dynrelocs): ...this new function.
1859 (elf_xtensa_size_dynamic_sections): Use it.
74e880a7 1860
e5f131d1 18612007-02-05 Bob Wilson <bob.wilson@acm.org>
74e880a7 1862
e5f131d1
BW
1863 * elf32-xtensa.c (elf_howto_table) <R_XTENSA_GLOB_DAT>
1864 <R_XTENSA_JMP_SLOT, R_XTENSA_RELATIVE, R_XTENSA_PLT, R_XTENSA_DIFF32>:
1865 Set src_mask to zero.
1866 <R_XTENSA_DIFF8, R_XTENSA_DIFF16>: Likewise. Also fix dst_mask.
1867 <R_XTENSA_ASM_EXPAND>: Set pcrel_offset to TRUE.
74e880a7 1868
4608f3d9
BW
18692007-02-02 Bob Wilson <bob.wilson@acm.org>
1870
1871 * elf32-xtensa.c (xtensa_elf_dynamic_symbol_p): Renamed to...
1872 (elf_xtensa_dynamic_symbol_p): ...this.
1873
f0e6fdb2
BW
18742007-02-02 Bob Wilson <bob.wilson@acm.org>
1875
1876 * elf32-xtensa.c (plt_reloc_count): Move into link hash table.
1877 (struct elf_xtensa_link_hash_table): New.
1878 (elf_xtensa_hash_table): New.
1879 (elf_xtensa_link_hash_table_create): New.
1880 (elf_xtensa_check_relocs): Update plt_reloc_count references.
1881 Update arguments to add_extra_plt_sections.
1882 (elf_xtensa_create_dynamic_sections): Record new sections in the hash
1883 table. Update for plt_reloc_count and add_extra_plt_sections.
1884 (add_extra_plt_sections, elf_xtensa_create_plt_entry): Replace dynobj
1885 argument with link info. Update calls to elf_xtensa_get_plt_section
1886 and elf_xtensa_get_gotplt_section.
1887 (elf_xtensa_allocate_local_got_size, elf_xtensa_size_dynamic_sections)
1888 (elf_xtensa_relocate_section, elf_xtensa_finish_dynamic_sections)
1889 (elf_xtensa_discard_info_for_section, shrink_dynamic_reloc_sections)
1890 (relax_property_section): Get sections from the hash table and update
1891 function calls.
1892 (elf_xtensa_get_plt_section, elf_xtensa_get_gotplt_section): Replace
1893 dynobj argument with link info. Get sections for first plt chunk from
1894 the hash table.
1895 (bfd_elf32_bfd_link_hash_table_create): Define.
1896
c15f73f9
JJ
18972007-02-02 Jakub Jelinek <jakub@redhat.com>
1898
1899 * elf-bfd.h (struct elf_obj_tdata): Change symbuf type to void *.
1900 * elf.c (struct elf_symbuf_symbol, struct elf_symbuf_head): New types.
1901 (struct elf_symbol): Change first member into union.
1902 (elf_sort_elf_symbol): Compare pointers to internal syms rather than
1903 internal syms. Only compare st_shndx fields.
1904 (elf_create_symbuf): New function.
1905 (bfd_elf_match_symbols_in_sections): Use it. If symbufs are available
1906 for bfds, use a binary search, otherwise don't qsort symbols
1907 unnecessarily only to select which symbols are for the particular
1908 shndx.
1909
effdf42a
NC
19102007-02-01 Nick Clifton <nickc@redhat.com>
1911
1912 PR ld/3852
1913 * elf.c (_bfd_elf_link_hash_table_init): Initialize all the fields
1914 in the elf_link_hash_table structure.
1915
183e98be
AM
19162007-02-01 Alan Modra <amodra@bigpond.net.au>
1917
1918 * elf-bfd.h (struct elf_backend_data): Add elf_backend_write_core_note.
1919 * elfxx-target.h (elf_backend_write_core_note): Define and use.
1920 * elf.c (elfcore_write_prpsinfo): Call the above. Add support for
1921 32-bit core note on 64-bit target.
1922 (elfcore_write_prstatus): Likewise.
1923 (elfcore_write_lwpstatus): Make note_name const.
1924 (elfcore_write_prfpreg): Likewise.
1925 (elfcore_write_pstatus): Add support for 32-bit core note on 64-bit
1926 target.
1927 * elf32-ppc.c (ppc_elf_write_core_note): New function.
1928 (elf_backend_write_core_note): Define.
1929 * elf64-ppc.c (ppc64_elf_write_core_note): New function.
1930 (elf_backend_write_core_note): Define.
1931
fc523535 19322007-01-31 H.J. Lu <hongjiu.lu@intel.com>
16cecee5
L
1933
1934 * elf32-cris.c (INCLUDED_TARGET_FILE): Removed.
1935 (elf32_bed): Defined for elf32-us-cris.
1936
1937 * elf64-sh64.c (elf64_bed): Defined for Linux.
1938 (INCLUDED_TARGET_FILE): Removed.
1939
1940 * elfxx-target.h (elfNN_bed): Always define. Don't check
1941 INCLUDED_TARGET_FILE.
1942
c9b57b7e
DD
19432007-01-31 DJ Delorie <dj@redhat.com>
1944
1945 * elf-m10300.c (mn10300_elf_relocate_section): Clarify the warning
1946 message for dangerous relocs, special case the common user error.
1947
53020534
L
19482007-01-30 H.J. Lu <hongjiu.lu@intel.com>
1949
1950 * elf.c (copy_elf_program_header): Start from the first section
1951 in a segment and stop when all sections in a segment are
1952 accounted for.
1953
c7b8f16e
JB
19542007-01-29 Julian Brown <julian@codesourcery.com>
1955
1956 * bfd-in2.h: Regenerate.
1957 * bfd-in.h (bfd_arm_vfp11_fix): New enum. Specify how VFP11
1958 instruction scanning should be done.
1959 (bfd_elf32_arm_init_maps, bfd_elf32_arm_vfp11_erratum_scan)
1960 (bfd_elf32_arm_vfp11_fix_veneer_locations): Add prototypes.
1961 (bfd_elf32_arm_set_target_relocs): Add vfp11 fix type argument to
1962 prototype.
1963 * elf-bfd.h (elf_backend_write_section): Add struct bfd_link_info
1964 argument.
1965 * elf32-arm.c (VFP11_ERRATUM_VENEER_SECTION_NAME)
1966 (VFP11_ERRATUM_VENEER_ENTRY_NAME): Define macros.
1967 (elf32_vfp11_erratum_type): New enum.
1968 (elf32_vfp11_erratum_list): New struct. List of veneers or jumps to
1969 veneers.
1970 (_arm_elf_section_data): Add mapsize, erratumcount, erratumlist.
1971 (elf32_arm_link_hash_table): Add vfp11_erratum_glue_size,
1972 vfp11_fix and num_vfp11_fixes fields.
1973 (elf32_arm_link_hash_table_create): Initialise vfp11_fix,
1974 vfp11_erratum_glue_size, num_vfp11_fixes fields.
1975 (VFP11_ERRATUM_VENEER_SIZE): Define. Size of an (ARM) veneer.
1976 (bfd_elf32_arm_allocate_interworking_sections): Initialise erratum
1977 glue section.
1978 (elf32_arm_section_map_add): Add an code/data mapping symbol entry
1979 to a section's map.
1980 (record_vfp11_erratum_veneer): Create a single veneer, and its
1981 associated symbols.
1982 (bfd_elf32_arm_add_glue_sections_to_bfd): Add vfp11 erratum glue.
1983 (bfd_elf32_arm_init_maps): Initialise mapping symbol table for input
1984 BFDs.
1985 (bfd_elf32_arm_set_vfp11_fix): Set the type of erratum workaround
1986 required.
1987 (bfd_arm_vfp11_pipe): Define VFP11 instruction pipes.
1988 (bfd_arm_vfp11_regno): Recode a register number from a VFP11 insn.
1989 (bfd_arm_vfp11_write_mask): Update write mask according to coded
1990 register number.
1991 (bfd_arm_vfp11_antidependency): New function.
1992 (bfd_arm_vfp11_insn_decode): Decode a VFP11 insn.
1993 (elf32_arm_compare_mapping): Declare.
1994 (bfd_elf32_arm_vfp11_erratum_scan): Scan the sections of an input
1995 BFD for potential erratum-triggering insns. Record results.
1996 (bfd_elf32_arm_vfp11_fix_veneer_locations): Find out where veneers
1997 and branches to veneers have been placed in virtual memory after
1998 layout.
1999 (bfd_elf32_arm_set_target_relocs): Set vfp11_fix field in global
2000 hash table.
2001 (elf32_arm_output_symbol_hook): Remove.
2002 (elf32_arm_write_section): Output veneers, and branches to veneers.
2003 Use maps from input sections, not output sections, for code
2004 byte-swapping.
2005 * elf32-ppc.c (ppc_elf_write_section): Add dummy link_info argument.
2006 * elf32-score.c (_bfd_score_elf_write_section): Likewise.
2007 * elfxx-mips.c (_bfd_mips_elf_write_section): Likewise.
2008 * elfxx-mips.h (_bfd_mips_elf_write_section): Likewise.
2009
20102007-01-27 H.J. Lu <hongjiu.lu@intel.com>
83d1651b
L
2011
2012 * elf64-hppa.c (elf64_bed): Defined for HPUX and Linux.
b8210914 2013 (INCLUDED_TARGET_FILE): Removed.
83d1651b 2014
914dfb0f
DA
20152007-01-27 Mike Frysinger <vapier@gentoo.org>
2016
2017 * elf32-hppa.c (elf32_bed): Define for hpux, linux and netbsd.
2018 (INCLUDED_TARGET_FILE): Remove.
2019
78eba9b6
DD
20202007-01-25 DJ Delorie <dj@redhat.com>
2021
2022 * elf32-m32c.c (m32c_elf_howto_table): Don't complain about
2023 R_M32C_16 or R_M32C_24 relocs.
2024
64ee10b6
NC
20252007-01-25 Nick Clifton <nickc@redhat.com>
2026
2027 PR binutils/3874
2028 * elf32-avr.c (avr_link_hash_table): Check to make sure that the
2029 hash table was created by elf32_avr_link_hash_table_create before
2030 using it.
2031 (elf32_avr_link_hash_newfunc): New function. Just pass the call
2032 through to _bfd_elf_link_hash_newfunc.
2033 (elf32_avr_link_hash_table_create): Use
2034 elf32_avr_link_hash_newfunc instead of
2035 _bfd_elf_link_hash_newfunc.
2036 (elf32_avr_relocate_section): Check for the hash table pointer
2037 being NULL.
2038 (elf32_avr_relax_section, avr_build_one_stub,
2039 elf32_avr_setup_params, get_local_syms, elf32_avr_size_stubs,
2040 elf32_avr_build_stubs): Likewise.
2041
40b36307
L
20422007-01-16 H.J. Lu <hongjiu.lu@intel.com>
2043
2044 PR ld/3831
2045 * elf-bfd.h (bfd_elf_link_mark_dynamic_symbol): Add an
2046 argument, Elf_Internal_Sym *.
2047
2048 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Mark a data
2049 symbol dynamic if info->dynamic_data is TRUE.
2050 (bfd_elf_record_link_assignment): Updated call to
2051 bfd_elf_record_link_assignment.
2052 (_bfd_elf_merge_symbol): Likewise. Always call
2053 bfd_elf_link_mark_dynamic_symbol.
2054
fc523535 20552007-01-12 H.J. Lu <hongjiu.lu@intel.com>
a454209d
L
2056
2057 * Makefile.am (BFD_LIBS): Removed.
2058 * Makefile.in: Regenerated.
2059
fc523535 20602007-01-11 H.J. Lu <hongjiu.lu@intel.com>
21e40a48
L
2061
2062 PR binutils/3631
2063 * Makefile.am (OFILES): Add @bfd64_libs@.
2064 (libbfd_la_SOURCES): Remove $(BFD64_LIBS_CFILES).
2065 * Makefile.in: Regenerated.
2066
2067 * configure.in (bfd_libs): Replaced by ...
2068 (bfd64_libs): This.
2069 * configure: Regenerated.
2070
59e0647f
NS
20712007-01-11 Nathan Sidwell <nathan@codesourcery.com>
2072
2073 * elf.c (assign_file_positions_for_load_sections): We can
2074 require fewer phdrs than expected.
2075
3bdcfdf4
KH
20762007-01-08 Kazu Hirata <kazu@codesourcery.com>
2077
2078 * archures.c (bfd_mach_cpu32_fido): Rename to bfd_mach_fido.
2079 * bfd-in2.h: Regenerate.
2080 * cpu-m68k.c (arch_info_struct): Use bfd_mach_fido instead of
2081 bfd_mach_cpu32_fido.
2082 (m68k_arch_features): Use fido_a instead of cpu32.
2083 (bfd_m68k_compatible): Reject the combination of Fido and
2084 ColdFire. Accept the combination of CPU32 and Fido with a
2085 warning.
2086 * elf32-m68k.c (elf32_m68k_object_p,
2087 elf32_m68k_merge_private_bfd_data,
2088 elf32_m68k_print_private_bfd_data): Treat Fido as an
2089 architecture by itself.
2090
42037fe5
NC
20912007-01-08 Kai Tietz <kai.tietz@onevision.com>
2092
2093 * config.bfd: Renamed target x86_64-*-mingw64 to x86_64-*-mingw*.
2094
ebe8b991
JJ
20952007-01-05 Jakub Jelinek <jakub@redhat.com>
2096
2097 * texhex.c (first_phase): Don't fall through into the default
2098 case.
2099 (pass_over): Replace abort () calls with return FALSE. Fix
2100 buffer overflow.
2101
b327f31f
AM
21022007-01-04 Jie Zhang <jie.zhang@analog.com>
2103
2104 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't set
2105 SEC_EXCLUDE on zero size .eh_frame.
2106
10a2343e 2107For older changes see ChangeLog-2006
56882138
AM
2108\f
2109Local Variables:
2110mode: change-log
2111left-margin: 8
2112fill-column: 74
2113version-control: never
2114End:
This page took 0.493546 seconds and 4 git commands to generate.