Add microblazeel target support to bfd, gas and ld.
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2012-11-09 Edgar E. Iglesias <edgar.iglesias@gmail.com>
2
3 * config.bfd: Add microblazeel-*-*
4 * configure.in: Likewise.
5 * configure: Regenerate.
6 * elf32-microblaze.c (microblaze_elf_relocate_section): Add endian awareness.
7 (microblaze_elf_merge_private_bfd_data): New.
8 (microblaze_bfd_write_imm_value_32): New.
9 (microblaze_bfd_write_imm_value_64): New.
10 (microblaze_elf_relax_section): Add endian awareness.
11 (microblaze_elf_add_symbol_hook): Define TARGET_LITTLE_NAME,
12 TARGET_LITTLE_SYM and bfd_elf32_bfd_merge_private_bfd_data.
13 * targets.c: Add bfd target bfd_elf32_microblazeel_vec.
14
15 2012-11-09 H.J. Lu <hongjiu.lu@intel.com>
16
17 * aout-tic30.c (MY_final_link_callback): Remove trailing
18 redundant `;'.
19 * coff-h8500.c (extra_case): Likewise.
20 (bfd_coff_reloc16_get_value): Likewise.
21 * dwarf2.c (_bfd_dwarf2_cleanup_debug_info): Likewise.
22 * elf.c (_bfd_elf_slurp_version_tables): Likewise.
23 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
24 * elf32-v850.c (v850_elf_perform_relocation): Likewise.
25 * opncls.c (bfd_calc_gnu_debuglink_crc32): Likewise.
26 * plugin.c (add_symbols): Likewise.
27 * reloc.c (bfd_check_overflow): Likewise.
28 * vms-lib.c (_bfd_vms_lib_archive_p): Likewise.
29
30 2012-11-08 Tom Tromey <tromey@redhat.com>
31
32 * elf.c (elfcore_grok_note) <NT_SIGINFO>: New case; make
33 pseudosection.
34
35 2012-11-08 Alan Modra <amodra@gmail.com>
36
37 * aclocal.m4: Regenerate.
38 * Makefile.in: Regenerate.
39 * po/SRC-POTFILES.in: Regenerate.
40
41 2012-11-07 H.J. Lu <hongjiu.lu@intel.com>
42
43 * section.c (bfd_get_section_contents): Replace memcpy
44 with memmove.
45
46 2012-11-07 Hans-Peter Nilsson <hp@axis.com>
47
48 PR binutils/14481
49 * aout-target.h (MY_close_and_cleanup): Make local function
50 instead of alias of MY_bfd_free_cached_info. Also call
51 _bfd_generic_close_and_cleanup.
52
53 2012-11-06 H.J. Lu <hongjiu.lu@intel.com>
54
55 PR binutils/14813
56 * bfdio.c (bfd_iovec): Change return type of bclose to
57 bfd_boolean.
58 (memory_bclose): Change return type to bfd_boolean.
59 * cache.c (cache_bclose): Likewise.
60 * opncls.c (opncls_bclose): Likewise. Return TRUE on success.
61 * vms-lib.c (vms_lib_bclose): Likewise. Return TRUE.
62 * libbfd.h: Regenerated.
63
64 2012-11-06 Tristan Gingold <gingold@adacore.com>
65
66 * coff-x86_64.c (_bfd_generic_find_nearest_line_discriminator):
67 Define as coff_find_nearest_line_discriminator.
68
69 2012-11-06 Alan Modra <amodra@gmail.com>
70
71 PR binutils/14567
72 * opncls.c (opncls_iovec): Forward declare.
73 (_bfd_new_bfd_contained_in): If using opncls_iovec, copy iostream
74 to new bfd.
75
76 2012-11-06 Alan Modra <amodra@gmail.com>
77
78 * mach-o.c (bfd_mach_o_close_and_cleanup): Don't call
79 _bfd_generic_close_and_cleanup for mach_o_fat archives.
80
81 2012-11-06 Alan Modra <amodra@gmail.com>
82
83 * coff-tic4x.c (tic4x_coff0_vec, tic4x_coff0_beh_vec,
84 tic4x_coff1_vec, tic4x_coff1_beh_vec, tic4x_coff2_vec,
85 tic4x_coff2_beh_vec): Allow SEC_CODE and SEC_READONLY in
86 section flags.
87 * coff-ppc.c (TARGET_LITTLE_SYM): Likewise.
88 (TARGET_BIG_SYM): Likewise.
89
90 2012-11-06 Alan Modra <amodra@gmail.com>
91
92 * elf64-ppc.c (struct ppc_link_hash_table): Add dot_toc_dot.
93 (ppc64_elf_size_stubs): Lookup ".TOC.".
94 (ppc64_elf_relocate_section): Resolve special symbol ".TOC.".
95
96 2012-11-06 Alan Modra <amodra@gmail.com>
97
98 * elf64-ppc.c (maybe_strip_output): Heed SEC_KEEP.
99
100 2012-11-05 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
101
102 PR target/14788
103 * elf32-s390.c (elf_s390_relocate_section): Set elf.dynobj for
104 local ifunc symbols.
105 * elf64-s390.c (elf_s390_relocate_section): Likewise.
106
107 2012-11-05 Alan Modra <amodra@gmail.com>
108
109 * configure.in: Apply 2012-09-10 change to config.in here.
110
111 2012-11-05 Alan Modra <amodra@gmail.com>
112
113 * elf64-ppc.c (ppc64_elf_edit_toc): Clear "repeat" inside
114 loop. Really mark toc entry referring to another toc entry
115 only if the first is used.
116
117 2012-10-30 H.J. Lu <hongjiu.lu@intel.com>
118
119 * configure.in: Also handle --enable-64-bit-bfd when setting
120 CORE_HEADER for 'i[3-7]86-*-linux-*'.
121
122 2012-10-30 Steve McIntyre <steve.mcintyre@linaro.org>
123
124 * elf32-arm.c (elf32_arm_print_private_bfd_data): Recognise and
125 display the new ARM hard-float/soft-float ABI flags for EABI_VER5
126 (elf32_arm_post_process_headers): Add the hard-float/soft-float
127 ABI flag as appropriate for ET_DYN/ET_EXEC in EABI_VER5.
128
129 2012-10-30 Yao Qi <yao@codesourcery.com>
130 H.J. Lu <hongjiu.lu@intel.com>
131
132 * configure.in: Set CORE_HEADER to hosts/x86-64linux.h for
133 'i[3-7]86-*-linux-*' if x86_64-*linux is enabled.
134 * configure: Regenerated.
135
136 * elf64-x86-64.c (elf_x86_64_write_core_note): Replace type
137 'prpsinfo_t' and 'prstatus_t' with 'prpsinfo64_t' and
138 'prstatus64_t' respectively.
139
140 * hosts/x86-64linux.h (a8_uint64_t): New.
141 (user_regsx32_struct): Renamed to ...
142 (user_regs64_struct): This. Replace uint64_t with a8_uint64_t.
143 (elf_gregx32_t): Renamed to ...
144 (elf_greg64_t): This. Replace uint64_t with a8_uint64_t.
145 (ELF_NGREGX32): Removed.
146 (ELF_NGREG64): New.
147 (elf_gregx32_t): Removed.
148 (elf_greg64_t): New.
149 (struct prstatus64_timeval): New.
150 (elf_prstatusx32): Replace elf_gregsetx32_t with elf_gregset64_t.
151 (elf_prstatus64): New.
152 (elf_prpsinfo64): New.
153 (prstatus64_t, prpsinfo64_t): New typedef.
154
155 2012-10-29 Sean Keys <skeys@ipdatasys.com>
156
157 * elf32-xgate.c(elf_xgate_howto_table): Fix src and dest mask for
158 R_XGATE_16
159
160 2012-10-29 Alan Modra <amodra@gmail.com>
161
162 * elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask in
163 R_PPC_VLE_LO16A, R_PPC_VLE_HI16A, R_PPC_VLE_HA16A,
164 R_PPC_VLE_SDAREL_LO16A, R_PPC_VLE_SDAREL_HI16A,
165 R_PPC_VLE_SDAREL_HA16A reloc howtos.
166
167 2012-10-26 Nick Clifton <nickc@redhat.com>
168
169 * po/uk.po: Updated Ukranian translation.
170
171 2012-10-26 Alan Modra <amodra@gmail.com>
172
173 PR target/14758
174 * elf32-ppc.c (ppc_elf_reloc_type_lookup): Decode ppc64 _DS
175 bfd_reloc values. Map to corresponding D-form relocs.
176 (is_insn_ds_form, is_insn_qs_form): New functions.
177 (ppc_elf_relocate_section): Validate insn with DS-form or DQ-form
178 fields using D-form reloc.
179
180 2012-10-25 H.J. Lu <hongjiu.lu@intel.com>
181
182 * elf32-i386.c (elf_i386_size_dynamic_sections): Replace
183 _GLOBAL_OFFSET_TABLE_ lookup with htab->elf.hgot.
184 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Likewise.
185
186 2012-10-24 H.J. Lu <hongjiu.lu@intel.com>
187
188 * compress.c (bfd_is_section_compressed): Don't decompress the
189 section.
190
191 2012-10-23 Nathan Sidwell <nathan@codesourcery.com>
192
193 * bfd-in.h (bfd_elf_stack_segment_size): Declare.
194 * bfd-in2.h: Rebuilt.
195 * elfxx-target.h (elf_backend_stack_align): New.
196 (elfNN_bed): Add it.
197 * elf-bfd.h (struct elf_backend_data): Add stack_align field.
198 * elf.c (bfd_elf_map_sections_to_segments): Pay attention to
199 stack_align and stacksize for PT_GNU_STACK segment.
200 (assign_file_positions_for_non_load_sections): Set p_memsz for
201 PT_GNU_STACK segment.
202 (copy_elf_program_header): Copy PT_GNU_STACK size.
203 * elflink.c (bfd_elf_stack_segment_size): New function, taken from
204 uclinux backends.
205 (bfd_elf_size_dynamic_sections): Determine
206 PT_GNU_STACK requirements after calling backend. Pay attention to
207 stacksize.
208 * elf32-bfin.c (elf32_bfinfdpic_always_size_sections): Call
209 bfd_elf_stack_segment_size.
210 (elf32_bfinfdpic_modify_program_headers): Delete.
211 (elf32_bfingfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
212 here.
213 (elf_backend_stack_align): Override.
214 (elf_backend_modify_program_headers): Don't override.
215 * elf32-frv.c (frvfdpic_always_size_sections): Call
216 bfd_elf_stack_segment_size.
217 (elf32_frvfdpic_modify_program_headers): Delete.
218 (elf32_frvfdpic_copy_private_bfd_data): Don't copy PT_GNU_STACK
219 here.
220 (elf_backend_stack_align): Override.
221 (elf_backend_modify_program_headers): Don't override.
222 * elf32-lm32.c (lm32_elf_always_size_sections): Leave
223 PT_GNU_STACK creation to underlying elf support. Check
224 __stacksize here for backwards compatibility, and set it if
225 needed.
226 (lm32_elf_modify_segment_map): Delete.
227 (lm32_elf_modify_program_headers): Delete.
228 (elf_backend_stack_align): Override.
229 (elf_backend_modify_segment_map): Don't override.
230 (elf_backend_modify_program_headers): Don't override.
231 * elf32-sh.c (sh_elf_always_size_sections): Call
232 bfd_elf_stack_segment_size.
233 (sh_elf_modify_program_headers): Delete.
234 (sh_elf_copy_private_data): Don't copy PT_GNU_STACK
235 here.
236 (elf_backend_stack_align): Override.
237 (elf_backend_modify_program_headers): Don't override.
238 * elf32-tic6x.c (elf32_tic6x_always_size_sections): Call
239 bfd_elf_stack_segment_size.
240 (elf32_tic6x_modify_program_headers): Delete.
241 (elf32_tic6x_copy_private_data): Delete.
242 (elf_backend_stack_align): Override.
243 (bfd_elf32_bfd_copy_private_bfd_data): Don't override.
244 (elf_backend_modify_program_headers): Don't override.
245
246 2012-10-22 Alan Modra <amodra@gmail.com>
247
248 * cache.c (cache_bmmap): Don't use void* arithmetic.
249
250 2012-10-21 Alan Modra <amodra@gmail.com>
251
252 * compress.c (bfd_cache_section_contents): New function.
253 * bfd-in2.h: Regenerate.
254
255 2012-10-21 Hans-Peter Nilsson <hp@bitrange.com>
256
257 * linker.c (_bfd_generic_link_output_symbols): Handle a
258 no-longer-global symbol entered through a plugin.
259
260 2012-10-20 Alan Modra <amodra@gmail.com>
261
262 * compress.c: Reinstate 2012-10-19 change.
263 (bfd_get_full_section_contents): Don't free unless we alloc.
264 Use proper decompress size. Delete some vars, rename others.
265
266 2012-10-19 Tom Tromey <tromey@redhat.com>
267
268 * compress.c: Revert previous patch.
269
270 2012-10-19 Tom Tromey <tromey@redhat.com>
271
272 * compress.c (bfd_get_full_section_contents): Don't cache
273 decompressed contents.
274
275 2012-10-18 Kai Tietz <ktietz@redhat.com>
276
277 PR binutils/14067
278 * coff-i386.c (bfd_target): Add section flag SEC_EXCLUDE.
279 Allow BFD_COMPRESS and BFD_DECOMPRESS flags.
280 * coff-x86_64.c: Likewise.
281 * coffcode.h (DOT_ZDEBUG): New define.
282 (sec_to_styp_flags): Check for .zdebug.
283 (styp_to_sec_flags): Likewise.
284 * coffgen.c (make_a_section): Handle .debug_* section
285 compression/decompression flags.
286 * cofflink.c (mark_relocs): Ignore relocations
287 for a section, which isn't marked as used.
288 (_bfd_coff_link_input_bfd): Add support of compressed
289 debug sections.
290 * compress.c (decompress_contents): Loop as long
291 as there is input available and there is room for
292 output.
293 * bfd/pe-arm.c: Add .zdebug_ partial match entry.
294 * pe-i386.c: Likewise.
295 * pe-x86_64.c: Likewise.
296 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Don't clear all
297 data-directories as this might destroy content.
298
299 * coff-i386.c (_bfd_generic_find_nearest_line_discriminator):
300 define as coff_find_nearest_line_discriminator.
301 * libcoff-in.h (coff_find_nearest_line_discriminator): New
302 * libcoff.h: Regenerated.
303 * coff-x86_64.c: Likewise.
304 * coffgen.c (coff_find_nearest_line_discriminator): New function.
305 prototype.
306
307 2012-10-16 Joel Brobecker <brobecker@adacore.com>
308
309 * coff64-rs6000.c (rs6000coff64_vec): Set _close_and_cleanup
310 field to _bfd_archive_close_and_cleanup.
311 (aix5coff64_vec): Likewise.
312
313 2012-10-16 Joel Brobecker <brobecker@adacore.com>
314
315 * coff-rs6000.c (rs6000coff_vec): Set _close_and_cleanup
316 field to _bfd_archive_close_and_cleanup.
317 (pmac_xcoff_vec): Likewise.
318
319 2012-10-16 Sofiane Naci <sofiane.naci@arm.com>
320
321 * elf64-aarch64.c (elf64_aarch64_tls_howto_table): Fix shift value for
322 R_AARCH64_TLSIE_LD_GOTTPREL_PREL19, R_AARCH64_TLSLE_MOVW_TPREL_G2,
323 R_AARCH64_TLSLE_MOVW_TPREL_G1, R_AARCH64_TLSLE_MOVW_TPREL_G1_NC,
324 R_AARCH64_TLSLE_ADD_TPREL_HI12.
325 (elf64_aarch64_tlsdesc_howto_table): Fix shift value for
326 R_AARCH64_TLSDESC_LD64_PREL19 and R_AARCH64_TLSDESC_OFF_G1.
327 (elf64_aarch64_final_link_relocate): Add signed_addend when resolving
328 AARCH64_TLSLE_*_TPREL_* relocations.
329
330 2012-10-16 Alan Modra <amodra@gmail.com>
331
332 * elf32-xtensa.c (free_section_cache): Renamed from
333 clear_section_cache. Don't zero cache.
334 (section_cache_section): Remove ineffectual zero of cache.
335 Call init_section_cache instead.
336
337 2012-10-15 Doug Evans <dje@google.com>
338
339 * elf.c (special_sections_d): Add comment.
340
341 2012-10-13 H.J. Lu <hongjiu.lu@intel.com>
342
343 * Makefile.am (LIBDL): Replace -ldl with @lt_cv_dlopen_libs@.
344 * configure.in (lt_cv_dlopen_libs): AC_SUBST.
345 * Makefile.in: Regenerated.
346 * configure: Likewise.
347
348 2012-10-08 Alan Modra <amodra@gmail.com>
349
350 PR binutils/14662
351 * elf.c (_bfd_elf_make_section_from_shdr): Treat .gdb_index as
352 SEC_DEBUGGING.
353
354 2012-09-20 Walter Lee <walt@tilera.com>
355
356 * elf32-tilepro.c (tilepro_elf_relocate_section): Adjust got
357 relocations with value of hgot.
358 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
359
360 2012-09-19 Steve Ellcey <sellcey@mips.com>
361
362 * config.bfd: Add mips*-mti-elf* target.
363
364 2012-09-18 H.J. Lu <hongjiu.lu@intel.com>
365
366 PR ld/14591
367 * elf-bfd.h (_bfd_elf_merge_symbol): Add an argument to return
368 if the old symbol is weak.
369
370 * elf32-sh-symbian.c (sh_symbian_relocate_section): Update
371 _bfd_elf_merge_symbol call.
372
373 * elflink.c (_bfd_elf_merge_symbol): Add an argument to return
374 if the old symbol is weak.
375 (_bfd_elf_add_default_symbol): Update _bfd_elf_merge_symbol
376 call.
377 (elf_link_add_object_symbols): Don't update symbol type from a
378 weak definition. Update symbol type from a common symbol when
379 overriding a weak symbol.
380
381 2012-09-17 H.J. Lu <hongjiu.lu@intel.com>
382
383 * elf32-i386.c (elf_i386_convert_mov_to_lea): Ignore discarded
384 section.
385 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
386
387 2012-09-17 H.J. Lu <hongjiu.lu@intel.com>
388
389 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Replace return
390 FALSE with abort.
391 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
392
393 2012-09-17 Walter Lee <walt@tilera.com>
394
395 * elf32-tilepro.c (tilepro_elf_relocate_section): Remove unused
396 got_base variable.
397 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
398
399 2012-09-17 Walter Lee <walt@tilera.com>
400
401 * elf32-tilepro.c (tilepro_elf_relocate_section): Fix computation
402 of got relocations for when .got.plt section is merged with .got.
403 * elfxx-tilegx.c (tilegx_elf_relocate_section): Ditto.
404
405 2012-09-14 David Edelsohn <dje.gcc@gmail.com>
406
407 * configure: Regenerate.
408
409 2012-09-13 Anthony Green <green@moxielogic.com>
410
411 * targets.c (bfd_elf32_bigmoxie_vec, bfd_elf32_littlemoxie_vec):
412 Define.
413 (bfd_elf32_moxie_vec): Remove.
414 * config.bfd, configure.in: Add bi-endian support for moxie.
415 * configure: Rebuilt.
416 * elf32-moxie.c (TARGET_LITTLE_NAME, TARGET_LITTLE_SYM): Define.
417 (TARGET_BIG_NAME, TARGET_BIG_SYM): Update for bi-endian support.
418
419 2012-09-12 Doug Kwan <dougkwan@google.com>
420
421 * elf64-ppc.c (ppc64_elf_relocate_section): Use pre-adjusted
422 relocation for stub lookup.
423
424 2012-09-12 Chris Schlumberger-Socha <chris.schlumberger-socha@arm.com>
425
426 * bfd-in2.h: Regenerated.
427 * elf64-aarch64.c
428 (elf64_aarch64_howto_table): Add R_AARCH64_GOT_LD_PREL19 reloc to HOWTO.
429 (elf64_aarch64_reloc_map): Add reloc entry.
430 (aarch64_resolve_relocation): Likewise.
431 (bfd_elf_aarch64_put_addend): Likewise.
432 (aarch64_reloc_got_type): Likewise.
433 (elf64_aarch64_final_link_relocate): Likewise.
434 (lf64_aarch64_check_relocs): Likewise.
435 (elf64_aarch64_check_relocs): New case for R_AARCH64_ADR_PREL_LO21
436 reloc.
437 * libbfd.h: Regenerated.
438 * reloc.c (R_AARCH64_GOT_LD_PREL19): New reloc.
439
440 2012-09-10 Matthias Klose <doko@ubuntu.com>
441
442 * config.in: Disable sanity check for kfreebsd.
443
444 2012-09-10 H.J. Lu <hongjiu.lu@intel.com>
445
446 * configure: Regenerated.
447
448 2012-09-04 Sergey A. Guriev <sergey.a.guriev@intel.com>
449
450 * cpu-ia64-opc.c (ins_cnt6a): New function.
451 (ext_cnt6a): Ditto.
452 (ins_strd5b): Ditto.
453 (ext_strd5b): Ditto.
454 (elf64_ia64_operands): Add new operand types.
455
456 2012-09-04 H.J. Lu <hongjiu.lu@intel.com>
457
458 PR binutils/14493
459 * elf.c (ignore_section_sym): Also ignore section symbols without
460 a BFD section.
461
462 2012-09-03 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
463
464 * elf32-s390.c (elf_s390_relocate_section): Handle PLTOFF for
465 local and global ifunc symbols.
466 * elf64-s390.c (elf_s390_relocate_section): Likewise.
467
468 2012-09-02 H.J. Lu <hongjiu.lu@intel.com>
469
470 * elf-bfd.h (elf_link_hash_table): Add hdynamic for the
471 _DYNAMIC symbol.
472
473 * elflink.c (_bfd_elf_link_create_dynamic_sections): Set
474 hdynamic.
475
476 * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_symbol): Check
477 hdynamic instead of "_DYNAMIC".
478 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Likewise.
479 * elf32-cr16.c (elf32_arm_finish_dynamic_symbol): Likewise.
480 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
481 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
482 * elf32-i386.c (elf_i386_convert_mov_to_lea): Likewise.
483 * elf32-lm32.c (lm32_elf_finish_dynamic_symbol): Likewise.
484 * elf32-m32r.c (m32r_elf_finish_dynamic_symbol): Likewise.
485 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
486 * elf32-sh.c (sh_elf_finish_dynamic_symbol): Likewise.
487 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
488 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
489 * elf32-vax.c (elf_vax_finish_dynamic_symbol): Likewise.
490 * elf32-xtensa.c (elf_xtensa_finish_dynamic_symbol): Likewise.
491 * elf64-aarch64.c elf64_aarch64_finish_dynamic_symbol(): Likewise.
492 * elf64-alpha.c (elf64_alpha_finish_dynamic_symbol): Likewise.
493 * elf64-ia64-vms.c (elf64_ia64_finish_dynamic_symbol): Likewise.
494 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
495 * elf64-sh64.c (sh64_elf64_finish_dynamic_symbol): Likewise.
496 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
497 * elfnn-ia64.c (elfNN_ia64_finish_dynamic_symbol): Likewise.
498 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
499 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
500 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
501
502 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Check
503 hdynamic, hgot, hplt instead of _DYNAMIC, _GLOBAL_OFFSET_TABLE_,
504 _PROCEDURE_LINKAGE_TABLE_.
505 * elf32-score.c (s3_bfd_score_elf_finish_dynamic_symbol): Likewise.
506 * elf32-score7.c (s7_bfd_score_elf_finish_dynamic_symbol): Likewise.
507
508 2012-08-31 H.J. Lu <hongjiu.lu@intel.com>
509
510 * elf32-i386.c (elf_i386_convert_mov_to_lea): Don't optimize
511 _DYNAMIC.
512 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise.
513
514 2012-08-31 H.J. Lu <hongjiu.lu@intel.com>
515
516 * elf32-i386.c (elf_i386_convert_mov_to_lea): New.
517 (elf_i386_size_dynamic_sections): Use it on input sections.
518 (elf_i386_relocate_section): Don't convert
519 "mov foo@GOT(%reg), %reg" to "lea foo@GOTOFF(%reg), %reg"
520 for local symbols here.
521
522 * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): New.
523 (elf_x86_64_size_dynamic_sections): Use it on input sections.
524 (elf_x86_64_relocate_section): Don't convert
525 "mov foo@GOTPCREL(%rip), %reg" to "lea foo(%rip), %reg"
526 for local symbols here.
527
528 2012-08-30 H.J. Lu <hongjiu.lu@intel.com>
529
530 * elf32-i386.c (elf_i386_relocate_section): Convert
531 "mov foo@GOT(%reg), %reg" to "lea foo@GOTOFF(%reg), %reg"
532 for local symbols.
533
534 * elf64-x86-64.c (elf_x86_64_relocate_section): Convert
535 "mov foo@GOTPCREL(%rip), %reg" to "lea foo(%rip), %reg"
536 for local symbols.
537
538 2012-08-31 Alan Modra <amodra@gmail.com>
539
540 PR ld/14464
541 * elf64-ppc.c (ppc64_elf_relocate_section): Map symbols defined
542 by a linker script in .opd to corresponding input .opd section.
543
544 2012-08-28 Maciej W. Rozycki <macro@codesourcery.com>
545
546 * elf32-ppc.c (ppc_elf_relocate_section): Assert that dynindx is
547 not minus one.
548 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
549
550 2012-08-28 Maciej W. Rozycki <macro@codesourcery.com>
551
552 * elflink.c (_bfd_elf_merge_symbol): Also override the version
553 a dynamic symbol defaulted to if preempted with a hidden or
554 internal definition.
555
556 2012-08-28 Walter Lee <walt@tilera.com>
557
558 * elf32-tilepro.c (allocate_dynrelocs): Use PLT_ENTRY_SIZE as size
559 of header.
560 (tilepro_plt_entry_build): Account for new header size.
561 (tilepro_elf_finish_dynamic_sections): Ditto.
562 (tilepro_elf_plt_sym_val): Ditto.
563 * elfxx-tilegx.c (allocate_dynrelocs): Use PLT_ENTRY_SIZE as size
564 of header + tail.
565 (tilegx_elf_finish_dynamic_sections): Account for new padding.
566
567 2012-08-27 Walter Lee <walt@tilera.com>
568
569 * reloc.c (Add BFD_RELOC_TILEGX_IMM16_X0_HW0_PLT_PCREL,
570 BFD_RELOC_TILEGX_IMM16_X1_HW0_PLT_PCREL,
571 BFD_RELOC_TILEGX_IMM16_X0_HW1_PLT_PCREL,
572 BFD_RELOC_TILEGX_IMM16_X1_HW1_PLT_PCREL,
573 BFD_RELOC_TILEGX_IMM16_X0_HW2_PLT_PCREL,
574 BFD_RELOC_TILEGX_IMM16_X1_HW2_PLT_PCREL,
575 BFD_RELOC_TILEGX_IMM16_X0_HW3_PLT_PCREL,
576 BFD_RELOC_TILEGX_IMM16_X1_HW3_PLT_PCREL,
577 BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL,
578 BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL,
579 BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL,
580 BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL,
581 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL,
582 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL): new relocations.
583 * elfxx-tilegx.c (tilegx_elf_howto_table): Handle new relocations.
584 (tilegx_reloc_map): Ditto.
585 (reloc_to_create_func): Ditto.
586 (tilegx_elf_check_relocs): Ditto.
587 (tilegx_elf_gc_sweep_hook): Ditto.
588 (tilegx_elf_relocate_section): Ditto.
589 * libbfd.h: Regenerate.
590 * bfd-in2.h: Regenerate.
591
592 2012-08-24 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
593
594 * elf32-arm.c (v8): New array.
595 (tag_cpu_arch_combine): Add support for ARMv8 attributes.
596 (elf32_arm_merge_eabi_attributes): Likewise.
597 (VFP_VERSION_COUNT): New define.
598
599 2012-08-20 Tom Tromey <tromey@redhat.com>
600
601 * vms-lib.c (_bfd_vms_lib_get_module): Use bfd_zmalloc for
602 areltdata.
603 * opncls.c (_bfd_delete_bfd): Free arelt_data.
604 * mach-o.c (bfd_mach_o_fat_member_init): Use bfd_zmalloc for
605 areltdata.
606 * ecoff.c (_bfd_ecoff_slurp_armap): Use free for mapdata.
607 * coff-rs6000.c (_bfd_xcoff_read_ar_hdr): Use bfd_zmalloc for
608 areltdata.
609 (xcoff_write_archive_contents_old): Likewise.
610 (xcoff_write_archive_contents_big): Likewise.
611 * archive64.c (bfd_elf64_archive_slurp_armap): Use free for
612 areltdata.
613 * archive.c (_bfd_generic_read_ar_hdr_mag): Use bfd_zmalloc and
614 free for areltdata.
615 (_bfd_get_elt_at_filepos): Likewise. Clear n_nfd->arelt_data on
616 failure.
617 (do_slurp_bsd_armap): Use bfd_zmalloc and free for areltdata.
618 (do_slurp_coff_armap): Likewise.
619 (_bfd_slurp_extended_name_table): Likewise.
620 (bfd_slurp_bsd_armap_f2): Likewise. Don't leak 'mapdata'.
621
622 2012-08-17 Nick Clifton <nickc@redhat.com>
623
624 * po/vi.po: Updated Vietnamese translation.
625
626 2012-08-17 Yuri Chornoivan <yurchor@ukr.net>
627
628 * elf-bfd.h, * elf32-ppc.c, * elf64-ia64-vms.c, * elfnn-ia64.c,
629 * elfxx-mips.c, * vms-alpha.c: Typo fixes.
630
631 2012-08-17 Alan Modra <amodra@gmail.com>
632
633 PR binutils/14475:
634 * archive.c (bfd_ar_hdr_from_filesystem): Revert last change.
635 Instead malloc areltdata.
636
637 2012-08-16 Tom Tromey <tromey@redhat.com>
638
639 PR binutils/14475:
640 * archive.c (bfd_ar_hdr_from_filesystem): Allocate areltdata on
641 'member' BFD. Don't try to free 'ared'.
642
643 2012-08-14 Nick Clifton <nickc@redhat.com>
644
645 * po/uk.po: Updated Ukranian translation.
646
647 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
648
649 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Look up
650 the options section in the output rather than input BFD to
651 decide if to add a DT_MIPS_OPTIONS tag.
652
653 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
654
655 * config.bfd: Wrap mips*el-*-linux* and mips*-*-linux* into
656 #ifdef BFD64.
657
658 2012-08-13 Ian Bolton <ian.bolton@arm.com>
659 Laurent Desnogues <laurent.desnogues@arm.com>
660 Jim MacArthur <jim.macarthur@arm.com>
661 Marcus Shawcroft <marcus.shawcroft@arm.com>
662 Nigel Stephens <nigel.stephens@arm.com>
663 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
664 Richard Earnshaw <rearnsha@arm.com>
665 Sofiane Naci <sofiane.naci@arm.com>
666 Tejas Belagod <tejas.belagod@arm.com>
667 Yufeng Zhang <yufeng.zhang@arm.com>
668
669 * Makefile.am: Add AArch64 files.
670 * Makefile.in: Regenerate.
671 * archures.c (bfd_aarch64_arch): New declaration.
672 (bfd_archures_list): Use bfd_archures_list.
673 * bfd-in.h (bfd_elf64_aarch64_init_maps): New declaration.
674 (bfd_aarch64_process_before_allocation): New declaration.
675 (bfd_elf64_aarch64_process_before_allocation): New declaration.
676 (bfd_elf64_aarch64_set_options): New declaration.
677 (bfd_elf64_aarch64_add_glue_sections_to_bfd): New declaration.
678 (BFD_AARCH64_SPECIAL_SYM_TYPE_MAP): New definition.
679 (BFD_AARCH64_SPECIAL_SYM_TYPE_TAG): New definition.
680 (BFD_AARCH64_SPECIAL_SYM_TYPE_OTHER): New definition.
681 (BFD_AARCH64_SPECIAL_SYM_TYPE_ANY): New definition.
682 (bfd_is_aarch64_special_symbol_name): New declaration.
683 (bfd_aarch64_merge_machines): New declaration.
684 (bfd_aarch64_update_notes): New declaration.
685 (int bfd_aarch64_get_mach_from_notes): New declaration.
686 (elf64_aarch64_setup_section_lists): New declaration.
687 (elf64_aarch64_next_input_section): New declaration.
688 (elf64_aarch64_size_stubs): New declaration.
689 (elf64_aarch64_build_stubs): New declaration.
690 * config.bfd: Add AArch64.
691 * configure.in: Add AArch64.
692 * configure: Regenerate.
693 * cpu-aarch64.c: New file.
694 * elf-bfd.h: Add AArch64.
695 * bfd-in2.h: Regenerate.
696 * libbfd.h: Regenerate.
697 * elf64-aarch64.c: New file.
698 * reloc.c: Add AArch64 relocations.
699 * targets.c: Add AArch64.
700 * po/SRC-POTFILES.in: Regenerate.
701
702 2012-08-13 Maciej W. Rozycki <macro@codesourcery.com>
703
704 * elfxx-mips.c (mips_elf_calculate_relocation): Fix the handling
705 of protected symbols.
706
707 2012-08-10 Alan Modra <amodra@gmail.com>
708
709 PR binutils/14444
710 * elf.c (IS_VALID_GROUP_SECTION_HEADER) Add minsize param.
711 (setup_group): Adjust uses.
712 (bfd_section_from_shdr): Allow SHT_GROUP sections with just a flag
713 word.
714
715 2012-08-09 Nick Clifton <nickc@redhat.com>
716
717 * po/vi.po: Updated Vietnamese translation.
718
719 2012-08-09 Maciej W. Rozycki <macro@codesourcery.com>
720
721 * elfxx-mips.c (LA25_LUI_MICROMIPS_1, LA25_LUI_MICROMIPS_2):
722 Remove macros, folding them into...
723 (LA25_LUI_MICROMIPS): ... this new macro.
724 (LA25_J_MICROMIPS_1, LA25_J_MICROMIPS_2): Likewise into...
725 (LA25_J_MICROMIPS): ... this new macro.
726 (LA25_ADDIU_MICROMIPS_1, LA25_ADDIU_MICROMIPS_2): Likewise
727 into...
728 (LA25_ADDIU_MICROMIPS): ... this new macro.
729 (bfd_put_micromips_32, bfd_get_micromips_32): New functions.
730 (mips_elf_create_la25_stub): Use them.
731 (check_br32_dslot, check_br32, check_relocated_bzc): Likewise.
732 (_bfd_mips_elf_relax_section): Likewise.
733
734 2012-08-09 Alan Modra <amodra@gmail.com>
735 Tom Tromey <tromey@redhat.com>
736
737 * archive.c (SECTION Archives): Update documentation.
738 (_bfd_delete_archive_data): Remove.
739 (_bfd_add_bfd_to_archive_cache): Set 'parent_cache' and 'key'.
740 (archive_close_worker, _bfd_archive_close_and_cleanup): New
741 functions.
742 * libbfd-in.h (struct areltdata <parent_cache, key>): New fields.
743 (_bfd_delete_archive_data): Don't declare.
744 (_bfd_archive_close_and_cleanup): Declare.
745 (_bfd_generic_close_and_cleanup): Redefine.
746 * libbfd.h: Rebuild.
747 * opncls.c (_bfd_delete_bfd): Don't call _bfd_delete_archive_data.
748 (bfd_close): Don't close nested thin archives here.
749
750 2012-08-07 Tom Tromey <tromey@redhat.com>
751
752 * archive.c (_bfd_delete_archive_data): New function.
753 * libbfd-in.h (_bfd_delete_archive_data): Declare.
754 * libbfd.h: Rebuild.
755 * opncls.c (_bfd_delete_bfd): Call _bfd_delete_archive_data.
756
757 2012-08-07 Nick Clifton <nickc@redhat.com>
758
759 * po/uk.po: Updated Ukranian translation.
760
761 2012-08-06 Maciej W. Rozycki <macro@codesourcery.com>
762
763 * elflink.c (bfd_elf_record_link_assignment): Remove --defsym
764 symbols special case.
765
766 2012-08-05 Maciej W. Rozycki <macro@linux-mips.org>
767
768 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Don't allocate
769 PLT slots for local symbols.
770
771 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
772
773 * elf64-mips.c (mips16_elf64_howto_table_rela): Correct src_mask
774 field initializers throughout.
775 * elfn32-mips.c (elf_mips16_howto_table_rela): Likewise.
776
777 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
778
779 * elfxx-mips.c (mips_elf_perform_relocation): Update the
780 cross-mode jump message.
781
782 2012-08-03 Maciej W. Rozycki <macro@codesourcery.com>
783
784 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Update the
785 comment on DT_MIPS_RLD_MAP.
786
787 2012-08-03 Tom Tromey <tromey@redhat.com>
788
789 * opncls.c (_bfd_delete_bfd): Now static.
790 * libbfd-in.h (_bfd_delete_bfd): Don't declare.
791 * libbfd.h: Rebuild.
792
793 2012-08-02 Sean Keys <skeys@ipdatasys.com>
794
795 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Modified
796 conditional statment to allow suppression of mismatched bank
797 warning.
798
799 2012-08-01 Alan Modra <amodra@gmail.com>
800
801 * dwarf2.c (struct dwarf2_debug): Add close_on_cleanup.
802 (_bfd_dwarf2_slurp_debug_info): Set close_on_cleanup if we open
803 gnu_debuglink bfd.
804 (_bfd_dwarf2_cleanup_debug_info): Act on close_on_cleanup.
805
806 2012-07-30 Nick Clifton <nickc@redhat.com>
807
808 * po/bfd.pot: Updated template.
809 * po/es.po: Updated Spanish translation.
810 * po/fi.po: Updated Finnish translation.
811 * po/fr.po: Updated French translation.
812 * po/ru.po: Updated Russian translation.
813 * po/uk.po: Updated Ukranian translation.
814
815 2012-07-27 Mike Frysinger <vapier@gentoo.org>
816
817 * configure.in (AC_INIT): Call with the args bfd and 2.22.52.
818 (AM_INIT_AUTOMAKE): Remove args.
819 * configure: Regenerate.
820
821 2012-07-27 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
822
823 * cpu-s390.c (bfd_s390_64_arch, bfd_s390_arch): Pick the default
824 arch depending on the target size.
825
826 2012-07-27 Tristan Gingold <gingold@adacore.com>
827
828 * configure.in: Bump version to 2.23.51
829 * configure: Regenerate.
830
831 2012-07-26 Teresa Johnson <tejohnson@google.com>
832
833 * bfd/dwarf2.c (find_line): Initialize discriminator_ptr
834 if it is non-NULL.
835
836 2012-07-26 Meador Inge <meadori@codesourcery.com>
837 Nick Clifton <nickc@redhat.com>
838
839 PR ld/14397
840 * elf32-arm.c (elf32_arm_finish_dynamic_sections): Report an error
841 if a required section is missing from the linker script.
842
843 2012-07-24 Jan Waclawek <konfera@efton.sk>
844 PR 13899
845 * elf32-avr.c (elf32_avr_relax_delete_bytes): Call
846 _bfd_elf_link_read_relocs with keep_memory as TRUE.
847
848 2012-07-24 Teresa Johnson <tejohnson@google.com>
849
850 * bfd.c (bfd_find_nearest_line_discriminator): New macro.
851 * coff-rs6000.c: Init _bfd_find_nearest_line_discriminator.
852 * coff64-rs6000.c: Likewise.
853 * dwarf2.c (struct line_info): Add discriminator field.
854 (add_line_info): Fill in new discriminator field.
855 (decode_line_info): Record discriminator information instead
856 of ignoring it.
857 (lookup_address_in_line_info_table): Return discriminator field if
858 requested.
859 (comp_unit_find_nearest_line): Add discriminator argument.
860 (find_line): Likewise.
861 (_bfd_dwarf2_find_nearest_line): Likewise.
862 (_bfd_dwarf2_find_line): Likewise.
863 * elf-bfd.h (_bfd_elf_find_nearest_line_discriminator): New.
864 (_bfd_elf_find_line_discriminator): Likewise.
865 (_bfd_generic_find_nearest_line_discriminator): Likewise. Defined.
866 * elf.c (_bfd_elf_find_nearest_line): Change to a wrapper
867 that invokes _bfd_elf_find_nearest_line_discriminator with correct
868 arguments.
869 (_bfd_elf_find_nearest_line_discriminator): New.
870 (_bfd_elf_find_line): Change to a wrapper
871 that invokes _bfd_elf_find_line_discriminator with correct
872 arguments.
873 (_bfd_elf_find_line_discriminator): New.
874 * coffgen.c (coff_find_nearest_line_with_names): Handle
875 new discriminator argument.
876 * elf32-arm.c (elf32_arm_find_nearest_line): Likewise.
877 * elf64-alpha.c (elf64_alpha_find_nearest_line): Likewise.
878 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): Likewise.
879 * mach-o.c (bfd_mach_o_find_nearest_line): Likewise.
880 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Add discriminator
881 argument.
882 (_bfd_dwarf2_find_line): Likewise.
883 (_bfd_generic_find_nearest_line_discriminator): New.
884 * libbfd.c (_bfd_generic_find_nearest_line_discriminator): New.
885 * bfd-in2.h: Regenerated.
886 * libbfd.h: Likewise.
887 * targets.c (BFD_JUMP_TABLE_SYMBOLS): Initialize
888 _bfd_find_nearest_line_discriminator with
889 _bfd_generic_find_nearest_line_discriminator.
890 (bfd_target): Add _bfd_find_nearest_line_discriminator.
891
892 2012-07-24 Sean Keys <skeys@ipdatasys.com>
893
894 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Added code
895 that enables the linker to offset addresses, when linking against
896 symbols from the XGATE processor and vice versa.
897
898 2012-07-23 Nick Clifton <nickc@redhat.com>
899
900 * cisco-core.c (cisco_core_file_failing_command): Make static.
901 (cisco_core_file_failing_signal): Make static.
902
903 2012-07-18 H.J. Lu <hongjiu.lu@intel.com>
904
905 * bfd-in2.h: Regenerated.
906
907 2012-07-18 Nicolàs Alejandro Di Risio <sheeva@tiscali.it>
908
909 PR binutils/14335
910 * section.c: Fix a typo in comments.
911
912 2012-07-13 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
913
914 * elf64-s390.c: Include elf-s390-common.c.
915 (R_390_IRELATIVE): New reloc.
916 (elf_s390_reloc_type_lookup): Support R_390_IRELATIVE.
917 (RELA_ENTRY_SIZE): New macro.
918 (elf_s390_link_hash_entry): New fields ifunc_resolver_address and
919 *ifunc_resolver_section.
920 (struct plt_entry): New struct.
921 (struct elf_s390_obj_tdata): New field local_plt.
922 (elf_s390_local_plt): New macro.
923 (struct elf_s390_link_hash_table): New field irelifunc.
924 (ELF64): New macro.
925 (link_hash_newfunc): Initialize new fields.
926 (elf_s390_check_relocs): Handle IFUNC symbols.
927 (elf_s390_adjust_dynamic_symbol): Don't do anything for IFUNC
928 symbols.
929 (allocate_dynrelocs): Call s390_elf_allocate_ifunc_dyn_relocs for
930 IFUNC symbols.
931 (elf_s390_size_dynamic_sections): Handle IFUNC symbols.
932 (elf_s390_relocate_section): Likewise.
933 (elf_s390_finish_dynamic_symbol): Likewise.
934 (elf_s390_finish_dynamic_sections): Handle local IFUNC symbols.
935 (elf_s390_finish_ifunc_symbol): New function.
936 (elf_s390_gc_sweep_hook): Handle local plt entries.
937 (elf_backend_add_symbol_hook): Define.
938 * elf32-s390.c: See elf64-s390.c changes.
939 * elf-s390-common.c: New file.
940 * bfd-in2.h (BFD_RELOC_390_IRELATIVE): New enum field.
941 * libbfd.h (BFD_RELOC_390_IRELATIVE): New entry for
942 BFD_RELOC_390_IRELATIVE.
943 * reloc.c (BFD_RELOC_390_IRELATIVE): Document new relocation.
944
945 2012-07-13 Nick Clifton <nickc@redhat.com>
946
947 * aix386-core.c: Remove use of PTR and PARAMS macros.
948 * archive.c: Likewise.
949 * cache.c: Likewise.
950 * cisco-core.c: Likewise.
951 * coff-alpha.c: Likewise.
952 * coff-apollo.c: Likewise.
953 * coff-aux.c: Likewise.
954 * coff-h8300.c: Likewise.
955 * coff-h8500.c: Likewise.
956 * coff-i386.c: Likewise.
957 * coff-i960.c: Likewise.
958 * coff-ia64.c: Likewise.
959 * coff-m68k.c: Likewise.
960 * coff-m88k.c: Likewise.
961 * coff-mcore.c: Likewise.
962 * coff-mips.c: Likewise.
963 * coff-or32.c: Likewise.
964 * coff-ppc.c: Likewise.
965 * coff-rs6000.c: Likewise.
966 * coff-sh.c: Likewise.
967 * coff-sparc.c: Likewise.
968 * coff-stgo32.c: Likewise.
969 * coff-tic30.c: Likewise.
970 * coff-tic4x.c: Likewise.
971 * coff-tic54x.c: Likewise.
972 * coff-tic80.c: Likewise.
973 * coff-w65.c: Likewise.
974 * cofflink.c: Likewise.
975 * cpu-arc.c: Likewise.
976 * cpu-cris.c: Likewise.
977 * cpu-h8500.c: Likewise.
978 * cpu-i960.c: Likewise.
979 * cpu-msp430.c: Likewise.
980 * cpu-ns32k.c: Likewise.
981 * cpu-powerpc.c: Likewise.
982 * cpu-rs6000.c: Likewise.
983 * cpu-tic4x.c: Likewise.
984 * cpu-w65.c: Likewise.
985 * ecoff.c: Likewise.
986 * ecofflink.c: Likewise.
987 * elf-m10200.c: Likewise.
988 * elf32-bfin.c: Likewise.
989 * elf32-cris.c: Likewise.
990 * elf32-crx.c: Likewise.
991 * elf32-fr30.c: Likewise.
992 * elf32-frv.c: Likewise.
993 * elf32-h8300.c: Likewise.
994 * elf32-i960.c: Likewise.
995 * elf32-m32c.c: Likewise.
996 * elf32-m68hc11.c: Likewise.
997 * elf32-m68hc12.c: Likewise.
998 * elf32-m68hc1x.c: Likewise.
999 * elf32-m68k.c: Likewise.
1000 * elf32-mcore.c: Likewise.
1001 * elf32-rl78.c: Likewise.
1002 * elf32-rx.c: Likewise.
1003 * elf32-s390.c: Likewise.
1004 * elf32-vax.c: Likewise.
1005 * elf64-alpha.c: Likewise.
1006 * elf64-mmix.c: Likewise.
1007 * elf64-s390.c: Likewise.
1008 * elf64-sparc.c: Likewise.
1009 * elfnn-ia64.c: Likewise.
1010 * elfxx-mips.c: Likewise.
1011 * elfxx-sparc.c: Likewise.
1012 * hash.c: Likewise.
1013 * hp300hpux.c: Likewise.
1014 * hppabsd-core.c: Likewise.
1015 * hpux-core.c: Likewise.
1016 * i386dynix.c: Likewise.
1017 * i386linux.c: Likewise.
1018 * i386lynx.c: Likewise.
1019 * i386mach3.c: Likewise.
1020 * i386msdos.c: Likewise.
1021 * i386os9k.c: Likewise.
1022 * irix-core.c: Likewise.
1023 * lynx-core.c: Likewise.
1024 * m68klinux.c: Likewise.
1025 * mach-o.h: Likewise.
1026 * mipsbsd.c: Likewise.
1027 * netbsd-core.c: Likewise.
1028 * nlm32-i386.c: Likewise.
1029 * osf-core.c: Likewise.
1030 * pc532-mach.c: Likewise.
1031 * pef.c: Likewise.
1032 * ppcboot.c: Likewise.
1033 * ptrace-core.c: Likewise.
1034 * reloc16.c: Likewise.
1035 * sco5-core.c: Likewise.
1036 * som.h: Likewise.
1037 * sparclinux.c: Likewise.
1038 * sparclynx.c: Likewise.
1039 * ticoff.h: Likewise.
1040 * trad-core.c: Likewise.
1041 * vms-lib.c: Likewise.
1042 * xsym.h: Likewise.
1043
1044 2012-07-09 Alan Modra <amodra@gmail.com>
1045
1046 PR ld/14323
1047 * elflink.c (elf_sort_symbol): Sort by size too.
1048 (elf_link_add_object_symbols <weakdefs>): Simplify binary search.
1049 Do not depend on ordering of symbol aliases. Match largest size.
1050
1051 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
1052
1053 * elf.c (assign_section_numbers): Check if number of sections
1054 >= SHN_LORESERVE.
1055 * elfcode.h (elf_object_p): Likewise.
1056
1057 2012-07-03 Nick Clifton <nickc@redhat.com>
1058
1059 * archive.c (bsd_write_armap): Catch attempts to create an archive
1060 with indicies bigger than 4Gb.
1061 (coff_write_armap): Likewise.
1062
1063 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
1064
1065 PR binutils/14319
1066 * elf.c (_bfd_elf_make_section_from_shdr): Don't compress empty
1067 debug section.
1068
1069 2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
1070
1071 PR ld/3351
1072 * elflink.c (_bfd_elf_update_dynamic_flags): New.
1073 (_bfd_elf_merge_symbol): Update both real and indirect symbol
1074 dynamic flags.
1075 (_bfd_elf_add_default_symbol): Make the real symbol dynamic if
1076 the indirect symbol is defined in a shared library.
1077 (elf_link_add_object_symbols): Likewise. If the indirect
1078 symbol has been forced local, don't make the real symbol
1079 dynamic.
1080 (elf_link_check_versioned_symbol): Check indirect symbol.
1081 (elf_link_output_extsym): Use real symbol definition when
1082 reporting indirect symbol error. Check version info for
1083 dynamic versioned symbol.
1084
1085 2012-07-03 Alan Modra <amodra@gmail.com>
1086
1087 PR ld/14207
1088 * elf.c (assign_file_positions_for_load_sections): Remove assertions
1089 that only PT_LOAD headers include file header and section headers.
1090 (assign_file_positions_for_non_load_sections): Similarly don't
1091 assert PT_GNU_RELRO header does not include file and section headers.
1092 Compare first section vma rather than PT_LOAD p_vaddr against
1093 relro_start when looking for PT_LOAD covering PT_GNU_RELRO. Replace
1094 abort with assertion.
1095
1096 2012-07-02 Alan Modra <amodra@gmail.com>
1097
1098 * elf32-m32c.c (m32c_elf_check_relocs): Use bfd_make_section
1099 "anyway" variant when creating .plt.
1100 (m32c_elf_relax_plt_section): Remove redundant test and unused param.
1101 (m32c_elf_relax_section): Test SEC_LINKER_CREATED before calling
1102 m32c_elf_relax_plt_section.
1103 * elfxx-mips.c (mips_elf_create_got_section): Use make anyway variant
1104 when creating .got and .got.plt.
1105 (_bfd_mips_elf_final_link): Likewise for .rtproc, and use
1106 bfd_get_linker_section.
1107 * sunos.c: Similarly throughout.
1108
1109 2012-07-01 Andreas Schwab <schwab@linux-m68k.org>
1110
1111 * elf.c (_bfd_elf_make_section_from_shdr): Fix typo in error
1112 message.
1113
1114 2012-06-29 H.J. Lu <hongjiu.lu@intel.com>
1115
1116 * elf64-x86-64.c (elf_x86_64_relocate_section): Return FALSE
1117 on unresolvable relocation.
1118
1119 2012-06-29 H.J. Lu <hongjiu.lu@intel.com>
1120
1121 * archive.c (_bfd_compute_and_write_armap): Simplify global
1122 symbol handling.
1123
1124 2012-06-29 Nick Clifton <nickc@redhat.com>
1125
1126 PR ld/14189
1127 * elf32-arm.c (elf32_arm_check_relocs): Do not increment refcount
1128 for locally bound symbols.
1129
1130 2012-06-29 Alan Modra <amodra@gmail.com>
1131
1132 * section.c (bfd_get_linker_section): New function.
1133 * elf32-arm.c: When retrieving SEC_LINKER_CREATED sections, use
1134 the above throughout rather than bfd_get_section_by_name. Use
1135 bfd_make_section_anyway rather than bfd_make_section when creating
1136 them.
1137 * elf32-bfin.c: Likewise.
1138 * elf32-cr16.c: Likewise.
1139 * elf32-cris.c: Likewise.
1140 * elf32-frv.c: Likewise.
1141 * elf32-hppa.c: Likewise.
1142 * elf32-i370.c: Likewise.
1143 * elf32-i386.c: Likewise.
1144 * elf32-lm32.c: Likewise.
1145 * elf32-m32c.c: Likewise.
1146 * elf32-m32r.c: Likewise.
1147 * elf32-m68k.c: Likewise.
1148 * elf32-microblaze.c: Likewise.
1149 * elf32-ppc.c: Likewise.
1150 * elf32-rl78.c: Likewise.
1151 * elf32-s390.c: Likewise.
1152 * elf32-score.c: Likewise.
1153 * elf32-score7.c: Likewise.
1154 * elf32-sh.c: Likewise.
1155 * elf32-tic6x.c: Likewise.
1156 * elf32-tilepro.c: Likewise.
1157 * elf32-vax.c: Likewise.
1158 * elf32-xstormy16.c: Likewise.
1159 * elf32-xtensa.c: Likewise.
1160 * elf64-alpha.c: Likewise.
1161 * elf64-hppa.c: Likewise.
1162 * elf64-ia64-vms.c: Likewise.
1163 * elf64-ppc.c: Likewise.
1164 * elf64-s390.c: Likewise.
1165 * elf64-sh64.c: Likewise.
1166 * elf64-sparc.c: Likewise.
1167 * elf64-x86-64.c: Likewise.
1168 * elfnn-ia64.c: Likewise.
1169 * elfxx-mips.c: Likewise.
1170 * elfxx-sparc.c: Likewise.
1171 * elfxx-tilegx.c: Likewise.
1172 * elflink.c: Likewise.
1173 * elf-vxworks.c: Likewise.
1174 * elf-m10300.c: Likewise. Also make use of htab plt, got and
1175 gotplt shortcuts.
1176 * bfd-in2.h: Regenerate.
1177 * elf32-lm32.c (lm32_elf_check_relocs): Use the correct bfd when
1178 calling create_rofixup_section.
1179 * elflink.c (bfd_elf_final_link): Simplify test for .dynstr.
1180
1181 2012-06-29 Alan Modra <amodra@gmail.com>
1182
1183 * elf32-sh.c (sh_elf_create_dynamic_sections): Don't create .rela
1184 section for bss type sections, except for .rela.bss.
1185 * elf-m10300.c (_bfd_mn10300_elf_create_dynamic_sections): Likewise.
1186 * elf32-cr16.c (_bfd_cr16_elf_create_dynamic_sections): Likewise.
1187 * elf32-lm32.c (lm32_elf_create_dynamic_sections): Likewise.
1188 * elf32-m32r.c (m32r_elf_create_dynamic_sections): Likewise.
1189 * elf64-sh64.c (sh64_elf64_create_dynamic_sections): Likewise.
1190
1191 2012-06-28 Roland McGrath <mcgrathr@google.com>
1192
1193 * elf32-arm.c (elf32_arm_populate_plt_entry): Use int32_t for
1194 displacement calculation in nacl_p case.
1195
1196 2012-06-28 Nick Clifton <nickc@redhat.com>
1197
1198 * po/uk.po: New Ukranian translation.
1199 * configure.in (ALL_LINGUAS): Add uk.
1200 * configure: Regenerate.
1201
1202 2012-06-26 Alan Modra <amodra@gmail.com>
1203
1204 * elf64-ppc.c (ppc64_elf_next_toc_section): Don't error if input
1205 file has multiple .got/.toc sections and all don't fit in
1206 current toc group.
1207
1208 2012-06-22 Roland McGrath <mcgrathr@google.com>
1209
1210 * elf.c (assign_file_positions_for_non_load_sections): Define
1211 __ehdr_start symbol if it's referenced and there's a PT_LOAD
1212 segment that covers both the file and program headers.
1213
1214 2012-06-22 Andreas Schwab <schwab@linux-m68k.org>
1215
1216 * elf32-m68k.c (elf_m68k_finish_dynamic_symbol): Don't make
1217 _GLOBAL_OFFSET_TABLE_ and _DYNAMIC absolute.
1218
1219 2012-06-22 Alan Modra <amodra@gmail.com>
1220
1221 * elf64-ppc.c (ppc64_elf_func_desc_adjust): Don't emit out-of-line
1222 save/restore functions when relocatable. Make "funcs" static.
1223
1224 2012-06-18 Hans-Peter Nilsson <hp@axis.com>
1225
1226 * elf32-cris.c (cris_elf_plt_sym_val): Rewrite to work in presence
1227 of merged .got and .got.plt entries.
1228
1229 2012-06-18 John Szakmeister <john@szakmeister.net>
1230
1231 * elf32-arm.c (elf32_arm_final_link_relocate): Correct return value.
1232
1233 2012-06-17 Hans-Peter Nilsson <hp@axis.com>
1234
1235 * elf32-cris.c (cris_elf_relocate_section): <R_CRIS_32_IE>
1236 <R_CRIS_32_GOT_TPREL, R_CRIS_16_GOT_TPREL>: Handle references to
1237 thread common symbols.
1238
1239 2012-06-13 Nick Clifton <nickc@redhat.com>
1240
1241 * elf32-arm.c (bfd_arm_get_mach_from_attributes): New function.
1242 (elf32_arm_object_p): If the machine number could not be deduced
1243 from the notes, call bfd_arm_get_mach_from_attributes to get the
1244 number from the attributes.
1245
1246 2012-06-12 H.J. Lu <hongjiu.lu@intel.com>
1247
1248 PR bfd/14207
1249 * elf.c (assign_file_positions_for_non_load_sections): Abort if
1250 PT_GNU_RELRO segment doesn't fit in PT_LOAD segment.
1251
1252 2012-06-12 Alan Modra <amodra@gmail.com>
1253
1254 PR ld/14207
1255 * elf.c (_bfd_elf_map_sections_to_segments): Disregard bss type
1256 sections at end of PT_LOAD segment when searching for segment
1257 that contains end of relro extent.
1258
1259 2012-06-11 H.J. Lu <hongjiu.lu@intel.com>
1260
1261 * elf.c (assign_file_positions_for_non_load_sections): Reindent.
1262
1263 2012-06-11 H.J. Lu <hongjiu.lu@intel.com>
1264
1265 * elf.c (_bfd_elf_map_sections_to_segments): Reindent.
1266
1267 2012-06-06 Alan Modra <amodra@gmail.com>
1268
1269 * elflink.c (elf_link_input_bfd): Provide a file symbol for
1270 each input file with local syms, if the input lacks such.
1271 (bfd_elf_final_link): Add a file symbol to mark end of locals
1272 for which we can associate with input files.
1273 (struct elf_final_link_info): Add filesym_count field.
1274 (struct elf_outext_info): Add need_second_pass and second_pass.
1275 (elf_link_output_extsym): Detect symbols defined in the output
1276 file, emit them on second pass over locals.
1277
1278 2012-06-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1279
1280 * bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
1281 of target_read_memory as bfd_size_type.
1282 * bfd-in2.h: Regenerate.
1283 * elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
1284 argument of target_read_memory as bfd_size_type.
1285 (_bfd_elf32_bfd_from_remote_memory): Likewise.
1286 (_bfd_elf64_bfd_from_remote_memory): Likewise.
1287 * elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
1288 * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
1289
1290 2012-06-03 Alan Modra <amodra@gmail.com>
1291
1292 PR binutils/13897
1293 * elf.c (elf_find_function): Cache last function sym info.
1294 (_bfd_elf_maybe_function_sym): Return function size, pass in
1295 section of interest.
1296 * elf-bfd.h (struct elf_backend_data <maybe_function_sym>): Likewise.
1297 (_bfd_elf_maybe_function_sym): Likewise.
1298 * elf64-ppc.c (ppc64_elf_maybe_function_sym): Likewise.
1299 (opd_entry_value): Add in_code_sec param. Revert caching code.
1300 Return -1 if in_code_sec and function found in wrong section.
1301 Update all calls.
1302
1303 2012-06-01 Siddhesh Poyarekar <siddhesh@redhat.com>
1304
1305 * bfd-in.h (bfd_elf_bfd_from_remote_memory): Make LEN argument
1306 of target_read_memory as size_t.
1307 * bfd-in2.h: Regenerate.
1308 * elf-bfd.h (elf_backend_bfd_from_remote_memory): Make LEN
1309 argument of target_read_memory as size_t.
1310 (_bfd_elf32_bfd_from_remote_memory): Likewise.
1311 (_bfd_elf64_bfd_from_remote_memory): Likewise.
1312 * elf.c (bfd_elf_bfd_from_remote_memory): Likewise.
1313 * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): Likewise.
1314
1315 2012-06-01 Alan Modra <amodra@gmail.com>
1316
1317 PR binutils/13897
1318 * elf64-ppc.c (opd_entry_value): Rewrite cache code.
1319
1320 2012-05-29 Tom Tromey <tromey@redhat.com>
1321
1322 * opncls.c (bfd_fopen): Always close fd on failure.
1323 (bfd_fdopenr): Likewise.
1324
1325 2012-05-27 Alan Modra <amodra@gmail.com>
1326
1327 PR ld/14170
1328 * elflink.c (_bfd_elf_merge_symbol): When a symbol defined in
1329 a dynamic library finds a new instance with non-default
1330 visibility in a regular object, correctly handle symbols
1331 already on the undefs list and undo dynamic symbol state when
1332 the new symbol is hidden or internal.
1333
1334 2012-05-25 H.J. Lu <hongjiu.lu@intel.com>
1335
1336 * elf32-i386.c (elf_i386_create_dynamic_sections): Don't use
1337 dynamic_sec_flags to create PLT .eh_frame section.
1338 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1339
1340 2012-05-25 Alan Modra <amodra@gmail.com>
1341
1342 PR ld/13909
1343 * elf-eh-frame.c (_bfd_elf_eh_frame_present): New function.
1344 (_bfd_elf_maybe_strip_eh_frame_hdr): Use it here.
1345 * elf-bfd.h (_bfd_elf_eh_frame_present): Declare.
1346 * elflink.c (bfd_elf_size_dynamic_sections): Let the backend
1347 size dynamic sections before stripping eh_frame_hdr.
1348 (bfd_elf_gc_sections): Handle multiple .eh_frame sections.
1349 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Drop glink_eh_frame
1350 if no other .eh_frame sections exist.
1351 * elf64-ppc.c (ppc64_elf_size_stubs): Likewise.
1352 * elf32-i386.c (elf_i386_create_dynamic_sections): Don't size
1353 or alloc plt_eh_frame here..
1354 (elf_i386_size_dynamic_sections): ..do it here instead. Don't
1355 specially keep sgotplt, iplt, tgotplt, sdynbss for symbols.
1356 (elf_i386_finish_dynamic_sections): Check plt_eh_frame->contents
1357 before writing plt offset.
1358 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Don't size
1359 or alloc plt_eh_frame here..
1360 (elf_x86_64_size_dynamic_sections): ..do it here instead.
1361 (elf_x86_64_finish_dynamic_sections): Check plt_eh_frame->contents
1362 before writing plt offset.
1363
1364 2012-05-24 Alan Modra <amodra@gmail.com>
1365
1366 PR ld/14158
1367 * elf64-ppc.c (ppc64_elf_size_stubs): Round up glink_eh_frame
1368 size to output section alignment.
1369 (ppc64_elf_build_stubs): Likewise, and extend last FDE to cover.
1370
1371 2012-05-23 Alan Modra <amodra@gmail.com>
1372
1373 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Handle
1374 BFDs with multiple .eh_frame sections.
1375
1376 2012-05-23 Alan Modra <amodra@gmail.com>
1377
1378 PR ld/13909
1379 * elflink.c (bfd_elf_discard_info): Don't ignore dynamic BFDs.
1380
1381 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1382
1383 PR ld/13909
1384 * elf32-i386.c (elf_i386_create_dynamic_sections): Revert the
1385 last change.
1386 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1387
1388 2012-05-22 Alan Modra <amodra@gmail.com>
1389
1390 * elflink.c (bfd_elf_discard_info): Look for next .eh_frame if
1391 first one is zero size or discarded.
1392 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Set most of
1393 glink_eh_frame contents here..
1394 (ppc_elf_finish_dynamic_sections): ..rather than here. Just set
1395 offset to .glink.
1396
1397 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1398
1399 PR ld/13909
1400 * elf32-i386.c (elf_i386_create_dynamic_sections): Create PLT
1401 eh_frame section if there is an input .eh_frame section.
1402 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1403
1404 2012-05-22 H.J. Lu <hongjiu.lu@intel.com>
1405
1406 PR ld/14105
1407 * elf32-i386.c (elf_i386_create_dynamic_sections): Always
1408 create PLT eh_frame section with SEC_LINKER_CREATED.
1409 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Likewise.
1410
1411 2012-05-22 Alan Modra <amodra@gmail.com>
1412
1413 * elflink.c (bfd_elf_discard_info): Handle multiple .eh_frame
1414 sections attached to a BFD.
1415 * section.c (bfd_get_section_by_name): Rewrite description.
1416 (bfd_get_next_section_by_name): New function.
1417 * bfd-in2.h: Regenerate.
1418
1419 2012-05-21 Andreas Schwab <schwab@linux-m68k.org>
1420
1421 * elf32-m68k.c (elf_m68k_grok_prstatus): New function.
1422 (elf_m68k_grok_psinfo): New function.
1423 (elf_backend_grok_prstatus): Define.
1424 (elf_backend_grok_psinfo): Define.
1425
1426 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1427
1428 * elf64-mips.c (elf_backend_got_header_size): Correct definition.
1429 * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Use the ELF
1430 backend's GOT header size instead of hardcoding it.
1431
1432 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1433
1434 * elf32-vax.c (elf_vax_relocate_section)
1435 <R_VAX_8, R_VAX_16, R_VAX_32>: Don't check if info->shared again.
1436
1437 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1438
1439 * elf32-vax.c (elf_vax_relocate_section)
1440 <R_VAX_8, R_VAX_16, R_VAX_32>: Use section flags rather than
1441 its name as the check for text sections.
1442
1443 2012-05-19 Maciej W. Rozycki <macro@linux-mips.org>
1444
1445 * elf64-mips.c (mips_elf64_be_swap_reloc_out): Also make sure
1446 the third reloc offset is the same as the first.
1447
1448 2012-05-19 Alan Modra <amodra@gmail.com>
1449
1450 * elf32-ppc.h (has_vle_insns, is_ppc_vle): Delete.
1451 (has_tls_reloc, has_tls_get_addr_call): Move back to..
1452 * elf32-ppc.c: ..here.
1453 (ppc_elf_section_flags, elf_backend_section_flags): Delete.
1454 (ppc_elf_modify_segment_map): Use ELF sh_flags to detect VLE sections.
1455
1456 2012-05-18 H.J. Lu <hongjiu.lu@intel.com>
1457
1458 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Don't make
1459 _DYNAMIC nor _GLOBAL_OFFSET_TABLE_ absolute.
1460 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
1461
1462 2012-05-18 Roland McGrath <mcgrathr@google.com>
1463
1464 * archive.c (_bfd_generic_read_ar_hdr_mag): Fix last change so as
1465 not to clobber the ar_fmag field stored in ARED->arch_header.
1466
1467 2012-05-18 Pedro Alves <palves@redhat.com>
1468
1469 * mach-o.h: Don't include sysdep.h.
1470
1471 2012-05-18 Nick Clifton <nickc@redhat.com>
1472
1473 PR 14072
1474 * bfd-in.h: Check for PACKAGE or PACKAGE_VERSION before
1475 complaining about config.h not having been included.
1476 * bfd-in2.h: Regenerate.
1477
1478 2012-05-18 Andreas Schwab <schwab@linux-m68k.org>
1479
1480 * aclocal.m4: Regenerate.
1481 * Makefile.in: Regenerate.
1482
1483 2012-05-17 Daniel Richard G. <skunk@iskunk.org>
1484 Nick Clifton <nickc@redhat.com>
1485
1486 PR 14072
1487 * configure.in: Add check that sysdep.h has been included before
1488 any system header files.
1489 * configure: Regenerate.
1490 * config.in: Regenerate.
1491 * aclocal.m4: Regenerate.
1492 * bfd-in.h: Generate an error if included before config.h.
1493 * sysdep.h: Likewise.
1494 * bfd-in2.h: Regenerate.
1495 * compress.c: Remove #include "config.h".
1496 * plugin.c: Likewise.
1497 * elf32-m68hc1x.c: Include sysdep.h before alloca-conf.h.
1498 * elf64-hppa.c: Likewise.
1499 * som.c: Likewise.
1500 * xsymc.c: Likewise.
1501
1502 2012-05-17 Maciej W. Rozycki <macro@linux-mips.org>
1503 Alan Modra <amodra@gmail.com>
1504
1505 * elf.c (ignore_section_sym): Correct comment. Don't return
1506 true for absolute section.
1507 (elf_map_symbols): Move stray comment. Adjust for above change.
1508 Don't discard global section symbols.
1509
1510 2012-05-17 Alan Modra <amodra@gmail.com>
1511
1512 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make _DYNAMIC,
1513 _GLOBAL_OFFSET_TABLE_ or _PROCEDURE_LINKAGE_TABLE_ absolute.
1514 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Don't make _DYNAMIC
1515 absolute.
1516
1517 2012-05-17 Alan Modra <amodra@gmail.com>
1518
1519 * elf32-ppc.c (has_tls_reloc, has_tls_get_addr_call, has_vle_insns,
1520 is_ppc_vle): Move to..
1521 * elf32-ppc.h: ..here, making is_ppc_vle a macro.
1522
1523 2012-05-16 Sergio Durigan Junior <sergiodj@redhat.com>
1524
1525 * bfd-in.h (bfd_get_section_name, bfd_get_section_vma,
1526 bfd_get_section_lma, bfd_get_section_alignment,
1527 bfd_get_section_flags, bfd_get_section_userdata): Rewrite macros
1528 in order to use the `bfd' argument.
1529 * bfd-in2.h: Regenerate.
1530 * elf-vxworks.c (elf_vxworks_finish_dynamic_entry): Pass proper `bfd'
1531 as the first argument for `bfd_get_section_alignment'.
1532 * elf32-arm.c (create_ifunc_sections): Likewise, for
1533 `bfd_set_section_alignment'.
1534 * elf32-m32r.c (m32r_elf_relocate_section): Likewise, for
1535 `bfd_get_section_name'.
1536 * elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
1537 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
1538 (ppc_elf_relocate_section): Likewise.
1539 * elf64-mmix.c (mmix_final_link_relocate): Likewise, for
1540 `bfd_get_section_vma'.
1541 * elf64-ppc.c (create_linkage_sections): Likewise, for
1542 `bfd_set_section_alignment'.
1543
1544 2012-05-16 Georg-Johann Lay <avr@gjlay.de>
1545
1546 PR target/13503
1547 * reloc.c: Rename BFD_RELOC_AVR_8_HHI to BFD_RELOC_AVR_8_HLO.
1548 * bfd-in2.h: Regenerate.
1549 * libbfd.h: Regenerate.
1550 * elf32-avr.c (elf_avr_howto_table): Rename R_AVR_8_HHI8 to
1551 R_AVR_8_HLO8.
1552 (avr_reloc_map): Likewise.
1553
1554 2012-05-16 Daniel Richard G. <skunk@iskunk.org>
1555
1556 PR binutils/13558
1557 * bfd/aout-cris.c: Include sysdep.h before bfd.h.
1558 * bfd/aout-ns32k.c: Likewise.
1559 * bfd/aout-sparcle.c: Likewise.
1560 * bfd/aout0.c: Likewise.
1561 * bfd/bfd-in2.h: Likewise.
1562 * bfd/coff-stgo32.c: Likewise.
1563 * bfd/cpu-lm32.c: Likewise.
1564 * bfd/cpu-microblaze.c: Likewise.
1565 * bfd/cpu-score.c: Likewise.
1566 * bfd/cpu-tilegx.c: Likewise.
1567 * bfd/cpu-tilepro.c: Likewise.
1568 * bfd/elf32-lm32.c: Likewise.
1569 * bfd/elf32-microblaze.c: Likewise.
1570 * bfd/elf32-score7.c: Likewise.
1571 * bfd/elf32-tilepro.c: Likewise.
1572 * bfd/elfxx-tilegx.c: Likewise.
1573 * bfd/mach-o.h: Likewise.
1574 * bfd/nlm32-ppc.c: Likewise.
1575 * bfd/ns32knetbsd.c: Likewise.
1576 * bfd/pef.h: Likewise.
1577 * bfd/plugin.c: Likewise.
1578 * bfd/stab-syms.c: Likewise.
1579 * bfd/sunos.c: Likewise.
1580 * bfd/syms.c: Likewise.
1581 * bfd/xsym.h: Likewise.
1582
1583 2012-05-16 Alan Modra <amodra@gmail.com>
1584
1585 * elflink.c: Rename flaginfo to flinfo throughout, except..
1586 (bfd_elf_lookup_section_flags): ..here, rename finfo to flaginfo.
1587 Formatting, style. Simplify flag match.
1588
1589 2012-05-16 Alan Modra <amodra@gmail.com>
1590
1591 * dwarf2.c: Formatting.
1592 (arange_add): Pass in unit rather than bfd. Update callers.
1593 Ignore empty ranges. Don't ask for cleared memory.
1594 (parse_comp_unit): Only set unit->base_address if processing
1595 DW_TAG_compile_unit.
1596 (find_debug_info): Optimise section lookup.
1597 (place_sections): Use bfd_alloc for stash->adjusted_sections.
1598 (find_line): Match previously parsed comp unit addresses as we
1599 do for newly parsed comp units.
1600
1601 2012-05-16 Alan Modra <amodra@gmail.com>
1602
1603 * archive.c (_bfd_generic_read_ar_hdr_mag): Ensure sscanf
1604 stops at end of ar_size field.
1605
1606 2012-05-16 Alan Modra <amodra@gmail.com>
1607
1608 PR ld/13962
1609 PR ld/7023
1610 * elf.c (bfd_section_from_shdr): Fail when .dynsym sh_info is
1611 out of range. As a special case, fix sh_info for zero sh_size.
1612 Do the same for .symtab.
1613
1614 2012-05-15 James Murray <jsm@jsm-net.demon.co.uk>
1615 Stephane Carrez <stcarrez@nerim.fr>
1616
1617 * archures.c: Add bfd_arch_m9s12x and bfd_arch_m9s12xg.
1618 * config.bfd: Likewise.
1619 * cpu-m9s12x.c: New.
1620 * cpu-m9s12xg.c: New.
1621 * elf32-m68hc12.c: Add S12X and XGATE co-processor support.
1622 Add option to offset S12 addresses into XGATE memory space.
1623 Fix carry bug in IMM16 (IMM8 low/high) relocate.
1624 * Makefile.am (ALL_MACHINES): Add cpu-m9s12x and cpu-m9s12xg.
1625 (ALL_MACHINES_CFILES): Likewise.
1626 * reloc.c: Add S12X relocs.
1627 * Makefile.in: Regenerate.
1628 * bfd-in2.h: Regenerate.
1629 * libbfd.h: Regenerate.
1630
1631 2012-05-14 James Lemke <jwlemke@codesourcery.com>
1632 Catherine Moore <clm@codesourcery.com>
1633
1634 * bfd.c (bfd_lookup_section_flags): Add section parm.
1635 * ecoff.c (bfd_debug_section): Remove flag_info initializer.
1636 * elf-bfd.h (bfd_elf_section_data): Move in section_flag_info.
1637 (bfd_elf_lookup_section_flags): Add section parm.
1638 * elf32-ppc.c (is_ppc_vle): New function.
1639 (ppc_elf_modify_segment_map): New function.
1640 (elf_backend_modify_segment_map): Define.
1641 (has_vle_insns): New define.
1642 * elf32-ppc.h (ppc_elf_modify_segment_map): Declare.
1643 * elflink.c (bfd_elf_lookup_section_flags): Add return value & parm.
1644 Move in logic to omit / include a section.
1645 * libbfd-in.h (bfd_link_info): Add section parm.
1646 (bfd_generic_lookup_section_flags): Likewise.
1647 * reloc.c (bfd_generic_lookup_section_flags): Likewise.
1648 * section.c (bfd_section): Move out section_flag_info.
1649 (BFD_FAKE_SECTION): Remove flag_info initializer.
1650 * targets.c (_bfd_lookup_section_flags): Add section parm.
1651
1652 2012-05-14 Catherine Moore <clm@codesourcery.com>
1653
1654 * archures.c (bfd_mach_ppc_vle): New.
1655 * bfd-in2.h: Regenerated.
1656 * cpu-powerpc.c (bfd_powerpc_archs): New entry for vle.
1657 * elf32-ppc.c (split16_format_type): New enumeration.
1658 (ppc_elf_vle_split16): New function.
1659 (HOWTO): Add entries for R_PPC_VLE relocations.
1660 (ppc_elf_reloc_type_lookup): Handle PPC_VLE relocations.
1661 (ppc_elf_section_flags): New function.
1662 (ppc_elf_lookup_section_flags): New function.
1663 (ppc_elf_section_processing): New function.
1664 (ppc_elf_check_relocs): Handle PPC_VLE relocations.
1665 (ppc_elf_relocation_section): Likewise.
1666 (elf_backend_lookup_section_flags_hook): Define.
1667 (elf_backend_section_flags): Define.
1668 (elf_backend_section_processing): Define.
1669 * elf32-ppc.h (ppc_elf_section_processing): Declare.
1670 * libbfd.h: Regenerated.
1671 * reloc.c (BFD_RELOC_PPC_VLE_REL8, BFD_RELOC_PPC_VLE_REL15,
1672 BFD_RELOC_PPC_VLE_REL24, BFD_RELOC_PPC_VLE_LO16A,
1673 BFD_RELOC_PPC_VLE_LO16D, BFD_RELOC_PPC_VLE_HI16A,
1674 BFD_RELOC_PPC_VLE_HI16D, BFD_RELOC_PPC_VLE_HA16A,
1675 BFD_RELOC_PPC_VLE_HA16D, BFD_RELOC_PPC_VLE_SDA21,
1676 BFD_RELOC_PPC_VLE_SDA21_LO, BFD_RELOC_PPC_VLE_SDAREL_LO16A,
1677 BFD_RELOC_PPC_VLE_SDAREL_LO16D, BFD_RELOC_PPC_VLE_SDAREL_HI16A,
1678 BFD_RELOC_PPC_VLE_SDAREL_HI16D, BFD_RELOC_PPC_VLE_SDAREL_HA16A,
1679 BFD_RELOC_PPC_VLE_SDAREL_HA16D): New bfd relocations.
1680
1681 2012-05-11 Georg-Johann Lay <avr@gjlay.de>
1682
1683 PR target/13503
1684 * reloc.c: Add new ENUM for BFD_RELOC_AVR_8_LO,
1685 BFD_RELOC_AVR_8_HI, BFD_RELOC_AVR_8_HHI.
1686 * bfd-in2.h: Regenerate.
1687 * libbfd.h: Regenerate.
1688 * elf32-avr.c (elf_avr_howto_table): Add entries for
1689 R_AVR_8_LO8, R_AVR_8_HI8, R_AVR_8_HHI8.
1690 (avr_reloc_map): Add RELOC mappings for R_AVR_8_LO8, R_AVR_8_HI8,
1691 R_AVR_8_HHI8.
1692
1693 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1694
1695 * elf64-x86-64.c (elf_x86_64_relocate_section): Use int in x32
1696 addend overflow check.
1697
1698 2012-05-10 DJ Delorie <dj@redhat.com>
1699
1700 * elf32-rx.c (rx_elf_object_p): Ignore empty segments.
1701
1702 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1703
1704 * elf64-x86-64.c (elf_x86_64_relocate_section): Display signed
1705 hex number in x32 addend overflow check.
1706
1707 2012-05-10 H.J. Lu <hongjiu.lu@intel.com>
1708
1709 * elf64-x86-64.c (elf_x86_64_reloc_type_class): Handle
1710 R_X86_64_RELATIVE64.
1711
1712 2012-05-09 H.J. Lu <hongjiu.lu@intel.com>
1713
1714 * elf64-x86-64.c (elf_x86_64_relocate_section): Check addend
1715 overflow for R_X86_64_RELATIVE64.
1716
1717 2012-05-08 Ben Cheng <bccheng@google.com>
1718
1719 * elf.c: Preserve the original p_align and p_flags if they are
1720 valid.
1721
1722 2012-05-07 Alan Modra <amodra@gmail.com>
1723
1724 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Update
1725 RELOC_AGAINST_DISCARDED_SECTION invocation.
1726
1727 2012-05-07 Hans-Peter Nilsson <hp@axis.com>
1728
1729 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Declare and use
1730 local variable i_ instead of assuming and using a variable i.
1731
1732 2012-05-07 Maciej W. Rozycki <macro@linux-mips.org>
1733
1734 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Handle compound
1735 relocations.
1736 * elfxx-mips.c (mips_reloc_against_discarded_section): New
1737 function.
1738 (_bfd_mips_elf_relocate_section): Call it, in place of
1739 RELOC_AGAINST_DISCARDED_SECTION.
1740 * elf-m10200.c (mn10200_elf_relocate_section): Update arguments
1741 to RELOC_AGAINST_DISCARDED_SECTION.
1742 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
1743 * elf32-arm.c (elf32_arm_relocate_section): Likewise.
1744 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
1745 * elf32-bfin.c (bfin_relocate_section): Likewise.
1746 (bfinfdpic_relocate_section): Likewise.
1747 * elf32-cr16.c (elf32_cr16_relocate_section): Likewise.
1748 * elf32-cr16c.c (elf32_cr16c_relocate_section): Likewise.
1749 * elf32-cris.c (cris_elf_relocate_section): Likewise.
1750 * elf32-crx.c (elf32_crx_relocate_section): Likewise.
1751 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
1752 * elf32-epiphany.c (epiphany_elf_relocate_section): Likewise.
1753 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
1754 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
1755 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
1756 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
1757 * elf32-i370.c (i370_elf_relocate_section): Likewise.
1758 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1759 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
1760 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
1761 * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
1762 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1763 * elf32-m32c.c (m32c_elf_relocate_section): Likewise.
1764 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
1765 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1766 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1767 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
1768 * elf32-mep.c (mep_elf_relocate_section): Likewise.
1769 * elf32-moxie.c (moxie_elf_relocate_section): Likewise.
1770 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
1771 * elf32-mt.c (mt_elf_relocate_section): Likewise.
1772 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
1773 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1774 * elf32-rl78.c (rl78_elf_relocate_section): Likewise.
1775 * elf32-rx.c (rx_elf_relocate_section): Likewise.
1776 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1777 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1778 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1779 * elf32-sh.c (sh_elf_relocate_section): Likewise.
1780 * elf32-spu.c (spu_elf_relocate_section): Likewise.
1781 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1782 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
1783 * elf32-v850.c (v850_elf_relocate_section): Likewise.
1784 * elf32-vax.c (elf_vax_relocate_section): Likewise.
1785 * elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
1786 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
1787 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
1788 * elf64-alpha.c (elf64_alpha_relocate_section_r): Likewise.
1789 (elf64_alpha_relocate_section): Likewise.
1790 * elf64-hppa.c (elf64_hppa_relocate_section): Likewise.
1791 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
1792 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1793 * elf64-s390.c (elf_s390_relocate_section): Likewise.
1794 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1795 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
1796 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1797 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1798 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
1799
1800 2012-05-05 Alan Modra <amodra@gmail.com>
1801
1802 PR ld/14052
1803 PR ld/13621
1804 * linker.c (_bfd_nearby_section): Revert 2012-02-13 change.
1805
1806 2012-05-05 Alan Modra <amodra@gmail.com>
1807
1808 * aout-arm.c: Replace all uses of bfd_abs_section, bfd_com_section,
1809 bfd_und_section and bfd_ind_section with their _ptr variants, or
1810 use corresponding bfd_is_* macros.
1811 * aout-ns32k.c: Likewise.
1812 * aout-tic30.c: Likewise.
1813 * coff-arm.c: Likewise.
1814 * coff-tic54x.c: Likewise.
1815 * cpu-ns32k.c: Likewise.
1816 * elf-attrs.c: Likewise.
1817 * elfcode.h: Likewise.
1818 * peicode.h: Likewise.
1819 * reloc.c: Likewise.
1820 * riscix.c: Likewise.
1821 * versados.c: Likewise.
1822 * section.c: Likewise.
1823 (bfd_abs_section, bfd_ind_section, bfd_com_section,
1824 bfd_ind_section): Delete.
1825 (std_section): New array replacing above.
1826 (bfd_abs_section_ptr, bfd_ind_section_ptr, bfd_com_section_ptr,
1827 bfd_ind_section_ptr, STD_SECTION): Update.
1828 (BFD_FAKE_SECTION, GLOBAL_SYM_INIT): Remove unnecessary casts.
1829 * bfd-in2.h: Regenerate.
1830
1831 2012-05-03 Sean Keys <skeys@ipdatasys.com>
1832
1833 * cpu-xgate.c: New file. Added XGATE support.
1834 * archures.c (bfd_architecture): Add XGATE architecture.
1835 (bfd_archures_list): Add reference to XGATE architecture info.
1836 * elf-bfd.h (prep_headers): Handle bfd_arch_xgate.
1837 * reloc.c: Add various XGATE relocation enums.
1838 * targets.c (bfd_elf32_xgate_vec): Declare and add to target vector
1839 list.
1840 * Makefile.am: Add support for XGATE elf.
1841 * configure.in: Ditto.
1842 * config.bfd: Ditto.
1843 * Makefile.in: Regenerate.
1844 * configure: Ditto.
1845 * bfd-in2.h: Ditto.
1846 * libbfd.h: Ditto.
1847 Added files for XGATE relocations.
1848 * elf32-xgate.c: Created minimal relocation file.
1849 * elf32-xgate.h: Created minimal header file for elf32-xgate.
1850
1851 2012-05-03 Tristan Gingold <gingold@adacore.com>
1852
1853 * dwarf2.c (decode_line_info): Ignore
1854 DW_LNE_HP_source_file_correlation.
1855
1856 2012-05-01 Nick Clifton <nickc@redhat.com>
1857
1858 PR binutils/13121
1859 * aoutx.h: Rename 'finfo' to 'flaginfo' to avoid conflicts with
1860 AIX system headers.
1861 * coff-ppc.c: Likewise.
1862 * cofflink.c: Likewise.
1863 * elf32-arm.c: Likewise.
1864 * elf64-sparc.c: Likewise.
1865 * elflink.c: Likewise.
1866 * pdp11.c: Likewise.
1867 * rescoff.c: Likewise.
1868
1869 2012-04-26 Mark Wielaard <mjw@redhat.com>
1870
1871 * dwarf2.c (scan_unit_for_symbols): Account for DW_AT_high_pc
1872 possibly being relative to DW_AT_low_pc.
1873 (parse_comp_unit): Likewise.
1874
1875 2012-04-26 Andreas Schwab <schwab@linux-m68k.org>
1876
1877 * elf32-m68k.c (elf_m68k_check_relocs): Mark non-GOT references
1878 also when generating PIE.
1879 (elf_m68k_discard_copies): Mark undefined weak symbols referenced
1880 by relocations as dynamic.
1881
1882 2012-04-26 Hans-Peter Nilsson <hp@axis.com>
1883
1884 Provide a way for programs to recognize BFD_ASSERT calls.
1885 * bfd.c (bfd_assert_handler_type): New API type.
1886 (bfd_set_assert_handler, bfd_get_assert_handler): New API functions.
1887 (_bfd_assert_handler): New variable.
1888 (_bfd_default_assert_handler): New function.
1889 (bfd_assert): Call _bfd_assert_handler, not _bfd_error_handler.
1890 * libbfd-in.h (_bfd_assert_handler): Declare.
1891 * libbfd.h, bfd-in2.h: Regenerate.
1892
1893 2012-04-24 Hans-Peter Nilsson <hp@axis.com>
1894
1895 PR ld/13990
1896 * elf32-arm.c (elf32_arm_gc_sweep_hook): Handle a forced-local
1897 symbol, where PLT refcount is set to -1.
1898
1899 2012-04-24 Alan Modra <amodra@gmail.com>
1900
1901 PR ld/13991
1902 * elf-bfd.h (_bfd_elf_link_just_syms): Define as
1903 _bfd_generic_link_just_syms.
1904 * elflink.c (_bfd_elf_link_just_syms): Delete.
1905 * linker.c (_bfd_generic_link_just_syms): Set sec_info_type.
1906
1907 * bfd-in.h (discarded_section): Renamed from elf_discarded_section.
1908 * section.c (SEC_INFO_TYPE_NONE, SEC_INFO_TYPE_STABS,
1909 SEC_INFO_TYPE_MERGE, SEC_INFO_TYPE_EH_FRAME,
1910 SEC_INFO_TYPE_JUST_SYMS): Renamed from corresponding ELF_INFO_TYPE.
1911 * elf-eh-frame.c, * elf-m10200.c, * elf-m10300.c,
1912 * elf.c, * elf32-arm.c, * elf32-avr.c, * elf32-bfin.c,
1913 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c,
1914 * elf32-crx.c, * elf32-d10v.c, * elf32-epiphany.c,
1915 * elf32-fr30.c, * elf32-frv.c, * elf32-h8300.c,
1916 * elf32-hppa.c, * elf32-i370.c, * elf32-i386.c,
1917 * elf32-i860.c, * elf32-ip2k.c, * elf32-iq2000.c,
1918 * elf32-lm32.c, * elf32-m32c.c, * elf32-m32r.c,
1919 * elf32-m68hc1x.c, * elf32-m68k.c, * elf32-mcore.c,
1920 * elf32-mep.c, * elf32-moxie.c, * elf32-msp430.c,
1921 * elf32-mt.c, * elf32-openrisc.c, * elf32-ppc.c,
1922 * elf32-rl78.c, * elf32-rx.c, * elf32-s390.c,
1923 * elf32-score.c, * elf32-score7.c, * elf32-sh.c,
1924 * elf32-spu.c, * elf32-tic6x.c, * elf32-tilepro.c,
1925 * elf32-v850.c, * elf32-vax.c, * elf32-xc16x.c,
1926 * elf32-xstormy16.c, * elf32-xtensa.c, * elf64-alpha.c,
1927 * elf64-hppa.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1928 * elf64-ppc.c, * elf64-s390.c, * elf64-sh64.c,
1929 * elf64-x86-64.c, * elflink.c, * elfnn-ia64.c,
1930 * elfxx-mips.c, * elfxx-sparc.c, * elfxx-tilegx.c,
1931 * reloc.c: Update all references.
1932 * bfd-in2.h: Regenerate.
1933
1934 2012-04-20 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
1935
1936 * elf32-s390.c (ELF_DYNAMIC_INTERPRETER): Set to the GCC default.
1937 * elf64-s390.c (ELF_DYNAMIC_INTERPRETER): Set to the GCC default.
1938
1939 2012-04-19 Thomas Schwinge <thomas@codesourcery.com>
1940
1941 * elf32-sh.c (elf_sh_link_hash_entry): Specify an enum identifier for
1942 got_type.
1943 (allocate_dynrelocs, sh_elf_relocate_section, sh_elf_check_relocs): Use
1944 it.
1945
1946 2012-04-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1947
1948 * elf32-sh.c (allocate_dynrelocs): Don't allocate dynamic
1949 relocations when LE conversion happens on the IE tls symbol.
1950
1951 2012-04-17 Roland McGrath <mcgrathr@google.com>
1952
1953 * elf64-x86-64.c (elf_x86_64_nacl_plt0_entry): Fix nop padding
1954 so that 32-byte boundary is a proper instruction boundary.
1955
1956 2012-04-17 Tristan Gingold <gingold@adacore.com>
1957
1958 * vms-lib.c (_bfd_vms_lib_get_module): Append .obj extension to
1959 member of an object archive.<
1960
1961 2012-04-17 Tristan Gingold <gingold@adacore.com>
1962
1963 * vms-lib.c (MAX_EKEYLEN): Define.
1964 (MAX_KEYLEN): Fix value.
1965 (vms_write_index): Add comments and fix indentation.
1966 Adjust comparaison. Add assertions. Free kbn_blk.
1967 (_bfd_vms_lib_write_archive_contents): Use MAX_EKEYLEN.
1968 Compense MAX_KEYLEN adjustment.
1969
1970 2012-04-16 Maciej W. Rozycki <macro@linux-mips.org>
1971
1972 * elfxx-mips.c (mips16_stub_symndx): Handle n64 compound relocs.
1973 (_bfd_mips_elf_check_relocs): Update accordingly.
1974
1975 2012-04-13 Alan Modra <amodra@gmail.com>
1976
1977 PR ld/13947
1978 * elflink.c (bfd_elf_final_link): Set reloc_count to 0 for
1979 reloc sections.
1980
1981 2012-04-12 David S. Miller <davem@davemloft.net>
1982
1983 * reloc.c (BFD_RELOC_SPARC_H34, BFD_RELOC_SPARC_SIZE32,
1984 BFD_RELOC_SPARC_SIZE64, BFD_RELOC_SPARC_WDISP10): New relocs.
1985 * libbfd.h: Regenerate.
1986 * bfd-in2.h: Likewise.
1987 * elfxx-sparc.c (sparc_elf_wdisp10_reloc): New function.
1988 (_bfd_sparc_elf_howto_table): Add entries for R_SPARC_H34,
1989 R_SPARC_SIZE32, R_SPARC_64, and R_SPARC_WDISP10.
1990 (_bfd_sparc_elf_reloc_type_lookup): Handle new relocs.
1991 (_bfd_sparc_elf_check_relocs): Likewise.
1992 (_bfd_sparc_elf_gc_sweep_hook): Likewise.
1993 (_bfd_sparc_elf_relocate_section): Likewise.
1994
1995 2012-04-12 Roland McGrath <mcgrathr@google.com>
1996
1997 * elf32-arm.c (elf32_arm_nacl_plt0_entry, elf32_arm_nacl_plt_entry):
1998 New variables.
1999 (struct elf32_arm_link_hash_table): New member `nacl_p'.
2000 (elf32_arm_link_hash_table_create): Initialize it.
2001 (elf32_arm_nacl_link_hash_table_create): New function.
2002 (arm_movw_immediate, arm_movt_immediate): New functions.
2003 (elf32_arm_populate_plt_entry): Test HTAB->nacl_p.
2004 (elf32_arm_finish_dynamic_sections): Likewise.
2005 (elf32_arm_output_plt_map_1): Likewise.
2006 (bfd_elf32_littlearm_nacl_vec, bfd_elf32_bigarm_nacl_vec):
2007 New backend vector stanza.
2008 (elf32_arm_nacl_modify_segment_map): New function.
2009 * config.bfd: Handle arm-*-nacl*, armeb-*-nacl*.
2010 * targets.c: Support bfd_elf32_{big,little}_nacl_vec.
2011 * configure.in: Likewise.
2012 (bfd_elf32_bigarm_nacl_vec): Add elf-nacl.lo here.
2013 (bfd_elf32_littlearm_nacl_vec): Likewise.
2014 (bfd_elf32_bigarm_vec, bfd_elf32_littlearm_vec): Likewise.
2015 (bfd_elf32_bigarm_symbian_vec): Likewise.
2016 (bfd_elf32_littlearm_symbian_vec): Likewise.
2017 (bfd_elf32_bigarm_vxworks_vec): Likewise.
2018 (bfd_elf32_littlearm_vxworks_vec): Likewise.
2019 * configure: Regenerated.
2020
2021 2012-04-12 Tristan Gingold <gingold@adacore.com>
2022
2023 * elflink.c (elf_link_output_extsym): Add a guard.
2024 (bfd_elf_final_link): Remove assertion.
2025 (bfd_elf_final_link): Add a guard.
2026 * elfnn-ia64.c (INCLUDE_IA64_VMS): Removed.
2027 (elfNN_vms_section_from_shdr, elfNN_vms_object_p)
2028 (elfNN_vms_post_process_headers, elfNN_vms_section_processing)
2029 (elfNN_vms_final_write_processing, elfNN_vms_close_and_cleanup):
2030 Remove.
2031 (elfNN-ia64-vms target): Move to ...
2032 * elf64-ia64-vms.c: New file.
2033 * configure.in (bfd_elf64_ia64_vms_vec): Add elf64-ia64-vms.lo
2034 * Makefile.am (BFD64_BACKENDS): Add elf64-ia64-vms.lo.
2035 (BFD64_BACKENDS_CFILES): Ad elf64-ia64-vms.c.
2036 * configure: Regenerate.
2037 * Makefile.in: Regenerate.
2038
2039 2012-04-11 Nick Clifton <nickc@redhat.com>
2040
2041 PR binutils/13897
2042 * elf64-ppc.c (opd_entry_value): When dealing with sections
2043 without relocs, keep the last section loaded in order to avoid
2044 unnecessary reloads.
2045
2046 2012-04-09 Roland McGrath <mcgrathr@google.com>
2047
2048 * elf.c (_bfd_elf_map_sections_to_segments): Set INFO->user_phdrs.
2049 * elf-nacl.c (nacl_modify_segment_map): Do nothing if INFO->user_phdrs.
2050 (nacl_modify_program_headers): Likewise.
2051
2052 2012-04-03 Roland McGrath <mcgrathr@google.com>
2053
2054 * elf-nacl.c: New file.
2055 * elf-nacl.h: New file.
2056 * elf32-i386.c (elf_backend_modify_segment_map): Define for
2057 bfd_elf32_i386_nacl_vec.
2058 (elf_backend_modify_program_headers): Likewise.
2059 * elf64-x86-64.c (elf_backend_modify_segment_map): Define for
2060 bfd_elf64_x86_64_nacl_vec and bfd_elf32_x86_64_nacl_vec.
2061 (elf_backend_modify_program_headers): Likewise.
2062 * Makefile.am (BFD32_BACKENDS, BFD64_BACKENDS): Add elf-nacl.lo here.
2063 (BFD32_BACKENDS_CFILES, BFD64_BACKENDS_CFILES): Add elf-nacl.c here.
2064 * Makefile.in: Regenerated.
2065 * configure.in (bfd_elf64_x86_64_nacl_vec): Add elf-nacl.o to tb here.
2066 (bfd_elf32_x86_64_nacl_vec): Likewise.
2067 (bfd_elf64_x86_64_vec, bfd_elf32_x86_64_vec): Likewise.
2068 (bfd_elf64_x86_64_freebsd_vec, bfd_elf64_x86_64_sol2_vec): Likewise.
2069 (bfd_elf64_l1om_vec, bfd_elf64_l1om_freebsd_vec): Likewise.
2070 (bfd_elf64_k1om_vec, bfd_elf64_k1om_freebsd_vec): Likewise.
2071 (bfd_elf32_i386_nacl_vec): Likewise.
2072 (bfd_elf32_i386_sol2_vec, bfd_elf32_i386_freebsd_vec): Likewise.
2073 (bfd_elf32_i386_vxworks_vec, bfd_elf32_i386_vec): Likewise.
2074 * configure: Regenerated.
2075
2076 2012-03-31 Andreas Schwab <schwab@linux-m68k.org>
2077
2078 * elf32-m68k.c (elf_m68k_relocate_section): Allow
2079 R_68K_TLS_LE{8,16,32} for PIE.
2080
2081 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2082
2083 * elf64-s390.c: Fix several comments regarding PLT entry
2084 description.
2085 * elf32-s390.c: Likewise.
2086
2087 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2088
2089 * elf64-s390.c: Use the section pointer shortcuts in
2090 elf_link_hash_table and remove them from the target specific
2091 variant.
2092 * elf32-s390.c: Likewise.
2093
2094 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2095
2096 * elf64-s390.c (elf_s390x_plt_entry, elf_s390x_first_plt_entry):
2097 New definitions.
2098 (PLT_PIC_ENTRY_WORD*, PLT_PIC12_ENTRY_WORD*): Remove.
2099 (elf_s390_finish_dynamic_symbol): Use memcpy instead of bfd_put_32.
2100 (elf_s390_finish_dynamic_sections): Likewise.
2101 * elf32-s390.c (elf_s390_plt_entry, elf_s390_plt_pic_entry)
2102 (elf_s390_plt_pic12_entry, elf_s390_plt_pic16_entry)
2103 (elf_s390_plt_first_entry, elf_s390_plt_pic_first_entry): New definitions.
2104 (PLT_PIC16_ENTRY_WORD*, PLT_ENTRY_WORD*)
2105 (PLT_PIC_FIRST_ENTRY_WORD*, PLT_FIRST_ENTRY_WORD*): Remove.
2106
2107 2012-03-30 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2108
2109 * elf32-s390.c (struct elf_s390_dyn_relocs): Remove.
2110 Rename all occurrences in the file to elf_dyn_relocs.
2111 * elf64-s390.c: Likewise.
2112
2113 2012-03-30 Alan Modra <amodra@gmail.com>
2114
2115 * elflink.c (_bfd_elf_gc_mark_reloc): Don't delve into dynamic
2116 libraries.
2117
2118 2012-03-29 Alan Modra <amodra@gmail.com>
2119
2120 * bfd-in.h (bfd_get_arch_size, bfd_get_sign_extend_vma): Delete.
2121 * bfd-in2.h: Regenerate.
2122
2123 2012-03-23 Alan Modra <amodra@gmail.com>
2124
2125 * elf.c (assign_file_positions_for_non_load_sections): Don't warn
2126 on empty alloc sections.
2127
2128 2012-03-23 Alan Modra <amodra@gmail.com>
2129
2130 * linker.c (_bfd_nearby_section): New function, split out from..
2131 (fix_syms): ..here.
2132 * bfd-in.h (_bfd_nearby_section): Declare.
2133 * bfd-in2.h: Regenerate.
2134 * elflink.c (elf_link_input_bfd): Don't use text_index_section or
2135 data_index_section with ld -q or ld -r output relocs against
2136 stripped output sections. Instead use _bfd_nearby_section.
2137
2138 2012-03-23 Alan Modra <amodra@gmail.com>
2139
2140 PR binutils/13894
2141 * elf64-ppc.c (opd_entry_value): Read full symbol table when
2142 sym hashes unavailable.
2143
2144 2012-03-21 Eliot Dresselhaus <eliot@sonic.net>
2145
2146 * elf32-tic6x.c (elf32_tic6x_merge_private_bfd_data): Return TRUE
2147 for non-C6X objects.
2148
2149 2012-03-20 Kai Tietz <ktietz@redhat.com>
2150
2151 PR ld/12742
2152 * configure.in (AC_CHECK_HEADERS): Test for windows.h and dlfcn.h.
2153 * plugin.c: Guard include of dlfcn.h if HAVE_DLFCN_H is defined.
2154 Add windows.h header include if HAVE_WINDOWS_H is defined.
2155 (dlerror): New static function if windows variant is used instead
2156 of dlfcn.h.
2157 (dlclose): Likewise.
2158 (dlopen): Likewise.
2159 (dlsym): Likewise.
2160 * configure: Regenerated.
2161 * config.in: Regenerated.
2162
2163 2012-03-20 H.J. Lu <hongjiu.lu@intel.com>
2164
2165 PR ld/13880
2166 * elf32-i386.c (elf_i386_relocate_section): Don't issue an error
2167 for R_386_GOTOFF relocation against protected function if
2168 SYMBOLIC_BIND is true.
2169
2170 * elf64-x86-64.c (elf_x86_64_relocate_section): Don't issue an
2171 error for R_X86_64_GOTOFF64 relocation against protected function
2172 when building executable or SYMBOLIC_BIND is true.
2173
2174 2012-03-16 Roland McGrath <mcgrathr@google.com>
2175
2176 * config.bfd: Handle x86_64-*-nacl*.
2177 * elf64-x86-64.c (bfd_elf64_x86_64_nacl_vec): New backend vector stanza.
2178 (bfd_elf32_x86_64_nacl_vec): Likewise.
2179 * targets.c: Support them.
2180 * configure.in: Likewise.
2181 * configure: Regenerated.
2182
2183 2012-03-16 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
2184
2185 * elf32-arm.c (elf32_arm_attributes_accept_div): New function.
2186 (elf32_arm_attributes_forbid_div): Likewise.
2187 (elf32_arm_merge_eabi_attributes): Correct handling of
2188 Tag_DIV_use.
2189
2190 2012-03-15 Roland McGrath <mcgrathr@google.com>
2191
2192 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Use
2193 elf_x86_64_backend_data parameters for plt_eh_frame.
2194
2195 * elf64-x86-64.c (struct elf_x86_64_backend_data): New type.
2196 (get_elf_x86_64_backend_data, GET_PLT_ENTRY_SIZE): New macros.
2197 (elf_x86_64_arch_bed): New variable.
2198 (elf_backend_arch_data): New macro.
2199 (elf_x86_64_adjust_dynamic_symbol): Use GET_PLT_ENTRY_SIZE.
2200 (elf_x86_64_allocate_dynrelocs): Likewise.
2201 (elf_x86_64_relocate_section): Likewise.
2202 (elf_x86_64_plt_sym_val): Likewise.
2203 (elf_x86_64_finish_dynamic_symbol): Use elf_x86_64_backend_data
2204 parameters for PLT details.
2205 (elf_x86_64_finish_dynamic_sections): Likewise.
2206
2207 2012-03-14 Roland McGrath <mcgrathr@google.com>
2208
2209 * elf32-i386.c (elf_i386_nacl_pic_plt0_entry): Initialize up
2210 to the full size, padding out with nop instructions.
2211
2212 2012-03-12 Alan Modra <amodra@gmail.com>
2213
2214 * elf-m10300.c (_bfd_mn10300_elf_adjust_dynamic_symbol): Don't warn
2215 on zero size dynbss symbol.
2216 * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Likewise.
2217 * elf32-cr16.c (_bfd_cr16_elf_adjust_dynamic_symbol): Likewise.
2218 * elf32-cris.c (elf_cris_adjust_dynamic_symbol): Likewise.
2219 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
2220 * elf32-i370.c (i370_elf_adjust_dynamic_symbol): Likewise.
2221 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Likewise.
2222 * elf32-lm32.c (lm32_elf_adjust_dynamic_symbol): Likewise.
2223 * elf32-m32r.c (m32r_elf_adjust_dynamic_symbol): Likewise.
2224 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
2225 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
2226 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
2227 * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Likewise.
2228 * elf32-tic6x.c (elf32_tic6x_adjust_dynamic_symbol): Likewise.
2229 * elf32-tilepro.c (tilepro_elf_adjust_dynamic_symbol): Likewise.
2230 * elf32-vax.c (elf_vax_adjust_dynamic_symbol): Likewise.
2231 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
2232 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
2233 * elf64-sh64.c (sh64_elf64_adjust_dynamic_symbol): Likewise.
2234 * elf64-x86-64.c (elf_x86_64_adjust_dynamic_symbol): Likewise.
2235 * elfxx-sparc.c (_bfd_sparc_elf_adjust_dynamic_symbol): Likewise.
2236 * elfxx-tilegx.c (tilegx_elf_adjust_dynamic_symbol): Likewise.
2237
2238 2012-03-10 Edmar Wienskoski <edmar@freescale.com>
2239
2240 * archures.c: Add bfd_mach_ppc_e5500 and bfd_mach_ppc_e6500.
2241 * bfd-in2.h: Regenerate.
2242 * cpu-powerpc.c (bfd_powerpc_archs): Add entries for
2243 bfd_mach_ppc_e5500 and bfd_mach_ppc_e6500.
2244
2245 2012-03-09 H.J. Lu <hongjiu.lu@intel.com>
2246
2247 PR ld/13817
2248 * elf32-i386.c (elf_i386_relocate_section): Restore
2249 R_386_IRELATIVE.
2250
2251 * elf64-x86-64.c (elf_x86_64_relocate_section): Restore
2252 R_X86_64_IRELATIVE.
2253
2254 2012-03-08 Tristan Gingold <gingold@adacore.com>
2255
2256 * vms-lib.c (_bfd_vms_lib_write_archive_contents): Set maximum
2257 keylen according to archive kind. Set nextvbn and nextrfa lhd
2258 fields. Add comments.
2259
2260 2012-03-07 Nick Clifton <nickc@redhat.com>
2261
2262 * elf-m10300.c (elf32_mn10300_link_hash_entry): Add tls_type
2263 field.
2264 (elf32_mn10300_link_hash_table): Add tls_ldm_got entry;
2265 (elf_mn10300_tdata): Define.
2266 (elf_mn10300_local_got_tls_type): Define.
2267 (elf_mn10300_howto_table): Add entries for R_MN10300_TLS_GD,
2268 R_MN10300_TLS_LD, R_MN10300_TLS_LDO, R_MN10300_TLS_GOTIE,
2269 R_MN10300_TLS_IE, R_MN10300_TLS_LE, R_MN10300_TLS_DPTMOD,
2270 R_MN10300_TLS_DTPOFF, R_MN10300_TLS_TPOFF relocs.
2271 (mn10300_reloc_map): Likewise.
2272 (elf_mn10300_tls_transition): New function.
2273 (dtpoff, tpoff, mn10300_do_tls_transition): New functions.
2274 (mn10300_elf_check_relocs): Add TLS support.
2275 (mn10300_elf_final_link_relocate): Likewise.
2276 (mn10300_elf_relocate_section): Likewise.
2277 (mn10300_elf_relax_section): Likewise.
2278 (elf32_mn10300_link_hash_newfunc): Initialise new field.
2279 (_bfd_mn10300_copy_indirect_symbol): New function.
2280 (elf32_mn10300_link_hash_table_create): Initialise new fields.
2281 (_bfd_mn10300_elf_size_dynamic_sections): Add TLS support.
2282 (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
2283 (_bfd_mn10300_elf_reloc_type_class): Allocate an
2284 elf_mn10300_obj_tdata structure.
2285 (elf_backend_copy_indirect_symbol): Define.
2286 * reloc.c (BFD_MN10300_TLS_GD, BFD_MN10300_TLS_LD,
2287 BFD_MN10300_TLS_LDO, BFD_MN10300_TLS_GOTIE, BFD_MN10300_TLS_IE,
2288 BFD_MN10300_TLS_LE, BFD_MN10300_TLS_DPTMOD,
2289 BFD_MN10300_TLS_DTPOFF, BFD_MN10300_TLS_TPOFF): New relocations.
2290 (BFD_RELOC_MN10300_32_PCREL, BFD_RELOC_MN10300_16_PCREL): Move to
2291 alongside other MN10300 relocations.
2292 * bfd-in2.h: Regenerate.
2293 * libbfd.h: Regenerate.
2294
2295 2012-03-06 Jakub Jelinek <jakub@redhat.com>
2296
2297 * elf64-x86-64.c (elf_x86_64_relocate_section): For R_X86_64_RELATIVE
2298 set relocate to TRUE.
2299
2300 2012-03-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2301
2302 PR ld/12152
2303 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Also ignore
2304 overflows for R_SPARC_UA32 in .stab sections.
2305
2306 2012-03-01 Alan Modra <amodra@gmail.com>
2307
2308 * elfxx-tilegx.c (tilegx_elf_relocate_section): Silence bogus warning.
2309
2310 2012-02-27 Alan Modra <amodra@gmail.com>
2311
2312 * elf32-sh.c (sh_elf_osec_to_segment): Check for elf flavour bfd
2313 before calling elf specific function.
2314 (sh_elf_osec_readonly_p): Test for error return from above.
2315
2316 2012-02-27 Alan Modra <amodra@gmail.com>
2317
2318 * elf32-spu.c (build_stub): Fix malloc under-allocation.
2319
2320 2012-02-25 Walter Lee <walt@tilera.com>
2321 * reloc.c: Add BFD_RELOC_TILEPRO_TLS_GD_CALL,
2322 BFD_RELOC_TILEPRO_IMM8_X0_TLS_GD_ADD,
2323 BFD_RELOC_TILEPRO_IMM8_X1_TLS_GD_ADD,
2324 BFD_RELOC_TILEPRO_IMM8_Y0_TLS_GD_ADD,
2325 BFD_RELOC_TILEPRO_IMM8_Y1_TLS_GD_ADD,
2326 BFD_RELOC_TILEPRO_TLS_IE_LOAD, BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE,
2327 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE,
2328 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_LO,
2329 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_LO,
2330 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HI,
2331 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HI,
2332 BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HA,
2333 BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HA,
2334 BFD_RELOC_TILEGX_IMM16_X0_HW0_TLS_LE,
2335 BFD_RELOC_TILEGX_IMM16_X1_HW0_TLS_LE,
2336 BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_TLS_LE,
2337 BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_TLS_LE,
2338 BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_TLS_LE,
2339 BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_TLS_LE,
2340 BFD_RELOC_TILEGX_TLS_GD_CALL, BFD_RELOC_TILEGX_IMM8_X0_TLS_GD_ADD,
2341 BFD_RELOC_TILEGX_IMM8_X1_TLS_GD_ADD,
2342 BFD_RELOC_TILEGX_IMM8_Y0_TLS_GD_ADD,
2343 BFD_RELOC_TILEGX_IMM8_Y1_TLS_GD_ADD, BFD_RELOC_TILEGX_TLS_IE_LOAD,
2344 BFD_RELOC_TILEGX_IMM8_X0_TLS_ADD,
2345 BFD_RELOC_TILEGX_IMM8_X1_TLS_ADD,
2346 BFD_RELOC_TILEGX_IMM8_Y0_TLS_ADD, BFD_RELOC_TILEGX_IMM8_Y1_TLS_ADD.
2347 Delete BFD_RELOC_TILEGX_IMM16_X0_HW1_GOT,
2348 BFD_RELOC_TILEGX_IMM16_X1_HW1_GOT,
2349 BFD_RELOC_TILEGX_IMM16_X0_HW2_GOT,
2350 BFD_RELOC_TILEGX_IMM16_X1_HW2_GOT,
2351 BFD_RELOC_TILEGX_IMM16_X0_HW3_GOT,
2352 BFD_RELOC_TILEGX_IMM16_X1_HW3_GOT,
2353 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_GOT,
2354 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_GOT,
2355 BFD_RELOC_TILEGX_IMM16_X0_HW1_TLS_GD,
2356 BFD_RELOC_TILEGX_IMM16_X1_HW1_TLS_GD,
2357 BFD_RELOC_TILEGX_IMM16_X0_HW2_TLS_GD,
2358 BFD_RELOC_TILEGX_IMM16_X1_HW2_TLS_GD,
2359 BFD_RELOC_TILEGX_IMM16_X0_HW3_TLS_GD,
2360 BFD_RELOC_TILEGX_IMM16_X1_HW3_TLS_GD,
2361 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_TLS_GD,
2362 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_TLS_GD,
2363 BFD_RELOC_TILEGX_IMM16_X0_HW1_TLS_IE,
2364 BFD_RELOC_TILEGX_IMM16_X1_HW1_TLS_IE,
2365 BFD_RELOC_TILEGX_IMM16_X0_HW2_TLS_IE,
2366 BFD_RELOC_TILEGX_IMM16_X1_HW2_TLS_IE,
2367 BFD_RELOC_TILEGX_IMM16_X0_HW3_TLS_IE,
2368 BFD_RELOC_TILEGX_IMM16_X1_HW3_TLS_IE,
2369 BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_TLS_IE,
2370 BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_TLS_IE.
2371 * elf32-tilepro.c (tilepro_elf_howto_table): Update tilepro
2372 relocations.
2373 (tilepro_reloc_map): Ditto.
2374 (tilepro_info_to_howto_rela): Ditto.
2375 (reloc_to_create_func): Ditto.
2376 (tilepro_tls_translate_to_le): New.
2377 (tilepro_tls_translate_to_ie): New.
2378 (tilepro_elf_tls_transition): New.
2379 (tilepro_elf_check_relocs): Handle new tls relocations.
2380 (tilepro_elf_gc_sweep_hook): Ditto.
2381 (allocate_dynrelocs): Ditto.
2382 (tilepro_elf_relocate_section): Ditto.
2383 (tilepro_replace_insn): New.
2384 (insn_mask_X1): New.
2385 (insn_mask_X0_no_dest_no_srca): New
2386 (insn_mask_X1_no_dest_no_srca): New
2387 (insn_mask_Y0_no_dest_no_srca): New
2388 (insn_mask_Y1_no_dest_no_srca): New
2389 (srca_mask_X0): New
2390 (srca_mask_X1): New
2391 (insn_tls_le_move_X1): New
2392 (insn_tls_le_move_zero_X0X1): New
2393 (insn_tls_ie_lw_X1): New
2394 (insn_tls_ie_add_X0X1): New
2395 (insn_tls_ie_add_Y0Y1): New
2396 (insn_tls_gd_add_X0X1): New
2397 (insn_tls_gd_add_Y0Y1): New
2398 * elfxx-tilegx.c (tilegx_elf_howto_table): Update tilegx
2399 relocations.
2400 (tilegx_reloc_map): Ditto.
2401 (tilegx_info_to_howto_rela): Ditto.
2402 (reloc_to_create_func): Ditto.
2403 (tilegx_elf_link_hash_table): New field disable_le_transition.
2404 (tilegx_tls_translate_to_le): New.
2405 (tilegx_tls_translate_to_ie): New.
2406 (tilegx_elf_tls_transition): New.
2407 (tilegx_elf_check_relocs): Handle new tls relocations.
2408 (tilegx_elf_gc_sweep_hook): Ditto.
2409 (allocate_dynrelocs): Ditto.
2410 (tilegx_elf_relocate_section): Ditto.
2411 (tilegx_copy_bits): New.
2412 (tilegx_replace_insn): New.
2413 (insn_mask_X1): New.
2414 (insn_mask_X0_no_dest_no_srca): New.
2415 (insn_mask_X1_no_dest_no_srca): New.
2416 (insn_mask_Y0_no_dest_no_srca): New.
2417 (insn_mask_Y1_no_dest_no_srca): New.
2418 (insn_mask_X0_no_operand): New.
2419 (insn_mask_X1_no_operand): New.
2420 (insn_mask_Y0_no_operand): New.
2421 (insn_mask_Y1_no_operand): New.
2422 (insn_tls_ie_ld_X1): New.
2423 (insn_tls_ie_ld4s_X1): New.
2424 (insn_tls_ie_add_X0X1): New.
2425 (insn_tls_ie_add_Y0Y1): New.
2426 (insn_tls_ie_addx_X0X1): New.
2427 (insn_tls_ie_addx_Y0Y1): New.
2428 (insn_tls_gd_add_X0X1): New.
2429 (insn_tls_gd_add_Y0Y1): New.
2430 (insn_move_X0X1): New.
2431 (insn_move_Y0Y1): New.
2432 (insn_add_X0X1): New.
2433 (insn_add_Y0Y1): New.
2434 (insn_addx_X0X1): New.
2435 (insn_addx_Y0Y1): New.
2436 * libbfd.h: Regenerate.
2437 * bfd-in2.h: Regenerate.
2438
2439 2012-02-25 Walter Lee <walt@tilera.com>
2440
2441 * config.bfd (tilegx-*-*): rename little endian vector; add big
2442 endian vector.
2443 (tilegxbe-*-*): New case.
2444 * configure.in (bfd_elf32_tilegx_vec): Rename...
2445 (bfd_elf32_tilegx_le_vec): ... to this.
2446 (bfd_elf32_tilegx_be_vec): New vector.
2447 (bfd_elf64_tilegx_vec): Rename...
2448 (bfd_elf64_tilegx_le_vec): ... to this.
2449 (bfd_elf64_tilegx_be_vec): New vector.
2450 * configure: Regenerate.
2451 * elf32-tilegx.c (TARGET_LITTLE_SYM): Rename.
2452 (TARGET_LITTLE_NAME): Ditto.
2453 (TARGET_BIG_SYM): Define.
2454 (TARGET_BIG_NAME): Define.
2455 * elf64-tilegx.c (TARGET_LITTLE_SYM): Rename.
2456 (TARGET_LITTLE_NAME): Ditto.
2457 (TARGET_BIG_SYM): Define.
2458 (TARGET_BIG_NAME): Define.
2459 * targets.c (bfd_elf32_tilegx_vec): Rename...
2460 (bfd_elf32_tilegx_le_vec): ... to this.
2461 (bfd_elf32_tilegx_be_vec): Declare.
2462 (bfd_elf64_tilegx_vec): Rename...
2463 (bfd_elf64_tilegx_le_vec): ... to this.
2464 (bfd_elf64_tilegx_be_vec): Declare.
2465 (_bfd_target_vector): Add / rename above vectors.
2466 * arctures.c (bfd_architecture): Define bfd_mach_tilegx32.
2467 * bfd-in2.h: Regenerate.
2468 * cpu-tilegx.c (bfd_tilegx32_arch): define.
2469 (bfd_tilegx_arch): link to bfd_tilegx32_arch.
2470
2471 2012-02-24 Nick Clifton <nickc@redhat.com>
2472
2473 PR ld/13730
2474 * reloc.c (bfd_generic_get_relocated_section_contents): Issue an
2475 error message instead of aborting, when an outofrange reloc is
2476 encountered.
2477
2478 2012-02-23 Iain Sandoe <idsandoe@googlemail.com>
2479
2480 * mach-o.c (bfd_mach_o_swap_in_non_scattered_reloc): New.
2481 (bfd_mach_o_canonicalize_one_reloc): Swap non-scattered reloc
2482 bit-fields when target and host differ in endian-ness. When
2483 PAIRs are non-scattered find the 'symbol' from the preceding
2484 reloc. Add FIXME re. reloc symbols on section boundaries.
2485 (bfd_mach_o_swap_out_non_scattered_reloc): New.
2486 (bfd_mach_o_write_relocs): Use bfd_mach_o_encode_non_scattered_reloc.
2487
2488 2012-02-17 Iain Sandoe <idsandoe@googlemail.com>
2489
2490 * mach-o-i386.c (i386_howto_table): Add support for 16 bit
2491 sect-diffs.
2492 (bfd_mach_o_i386_swap_reloc_in): Handle 16bit sect-diffs.
2493 (bfd_mach_o_i386_swap_reloc_out): Likewise.
2494
2495 2012-02-17 Tristan Gingold <gingold@adacore.com>
2496
2497 * reloc.c (BFD_RELOC_MACH_O_LOCAL_SECTDIFF):
2498 * libbfd.h: Regenerated.
2499 * bfd-in2.h: Likewise.
2500 * mach-o-i386.c (i386_howto_table): Include local sectdiff.
2501 (bfd_mach_o_i386_swap_reloc_in): Update for local sectdiff.
2502 (bfd_mach_o_i386_swap_reloc_out): Likewise.
2503
2504 2012-02-17 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
2505
2506 * elf32-s390.c (elf_s390_relocate_section): Support basr in the
2507 GD->LE and LD->LE optimizations.
2508
2509 2012-02-16 Alan Modra <amodra@gmail.com>
2510
2511 PR binutils/13355
2512 * elf32-rx.c (elf32_rx_relax_section): Correct width check.
2513
2514 2012-02-13 Richard Henderson <rth@redhat.com>
2515
2516 PR ld/13621
2517 * linker.c (fix_syms): Force symbols outside any section into
2518 bfd_abs_section_ptr.
2519
2520 2012-02-13 Alan Modra <amodra@gmail.com>
2521
2522 * elf32-m68hc1x.c (elf32_m68hc11_merge_symbol_attribute): New function.
2523 * elf32-m68hc1x.h (elf32_m68hc11_merge_symbol_attribute): Declare.
2524 * elf32-m68hc11.c (elf_backend_merge_symbol_attribute): Define.
2525 * elf32-m68hc12.c (elf_backend_merge_symbol_attribute): Define.
2526
2527 2012-02-11 Jan Kratochvil <jan.kratochvil@redhat.com>
2528 Nick Clifton <nickc@redhat.com>
2529
2530 * oasys.c (oasys_write_header): Fix compilation warning on zero-sized
2531 memset.
2532
2533 2012-02-10 Iain Sandoe <idsandoe@googlemail.com>
2534
2535 * mach-o.c (bfd_mach_o_build_seg_command): Count zerofill section
2536 vma additions in their logical, rather than physical order.
2537
2538 2012-02-10 Iain Sandoe <idsandoe@googlemail.com>
2539
2540 * mach-o.c (mach_o_section_name_xlat): Correct eh-frame section
2541 parameters.
2542 * mach-o-x86-64.c (text_section_names_xlat): New.
2543 (mach_o_x86_64_segsec_names_xlat): New.
2544 (bfd_mach_o_tgt_seg_table): Define to mach_o_x86_64_segsec_names_xlat.
2545 * mach-o-i386.c (text_section_names_xlat): Correct section parameters.
2546
2547 2012-02-10 Tristan Gingold <gingold@adacore.com>
2548
2549 * elfnn-ia64.c (elfNN_vms_object_p): Change comparison operator
2550 to avoid infinite loop. Add comments.
2551
2552 2012-02-09 H.J. Lu <hongjiu.lu@intel.com>
2553
2554 PR ld/13675
2555 * cpu-i386.c (bfd_arch_i386_fill): Updated to support multi byte
2556 nop instructions.
2557 (bfd_arch_i386_short_nop_fill): New.
2558 (bfd_arch_i386_long_nop_fill): Likewise.
2559 Use bfd_arch_i386_short_nop_fill in 32bit bfd_arch_info
2560 initializers. Use bfd_arch_i386_long_nop_fill on 64bit
2561 bfd_arch_info initializers.
2562
2563 * cpu-k1om.c (bfd_arch_i386_fill): Renamed to ...
2564 (bfd_arch_i386_short_nop_fill): This.
2565 Update bfd_arch_info initializers.
2566 * cpu-l1om.c: Likewise.
2567
2568 2012-02-08 Alan Modra <amodra@gmail.com>
2569
2570 * elflink.c (_bfd_elf_gc_mark_rsec): Mark weakdef syms too.
2571 (_bfd_elf_fix_symbol_flags): When a weakdef is def_regular, clear
2572 the correct h->u.weakdef.
2573
2574 2012-02-07 Alan Modra <amodra@gmail.com>
2575
2576 * elf.c (elf_find_function): Don't use internal_elf_sym.
2577 (_bfd_elf_maybe_function_sym): Likewise. Replace elf_symbol_type
2578 parameter with asymbol.
2579 * elf64-ppc.c (ppc64_elf_maybe_function_sym): Likewise.
2580 * elf-bfd.h (_bfd_elf_maybe_function_sym): Update prototype.
2581 (struct elf_backend_data <maybe_function_sym>): Likewise.
2582
2583 2012-02-02 Vidya Praveen (vidya.praveen@atmel.com)
2584
2585 PR bfd/13410
2586 * elf32-avr.c (elf32_avr_relax_section): Correct the
2587 condition that qualifies the candidates for relaxation.
2588
2589 2012-02-02 Tristan Gingold <gingold@adacore.com>
2590
2591 * bfdio.c (real_fopen): Remove unused vms_modes variable.
2592
2593 2012-02-02 Tristan Gingold <gingold@adacore.com>
2594
2595 * mach-o.c (bfd_mach_o_read_header): Silent uninitialized
2596 variable warning.
2597
2598 2012-02-02 Tristan Gingold <gingold@adacore.com>
2599
2600 * archive.c (bfd_slurp_armap): Fix thinko in cast.
2601
2602 2012-01-31 H.J. Lu <hongjiu.lu@intel.com>
2603
2604 PR ld/13616
2605 * archures.c (bfd_arch_info): Add fill.
2606 (bfd_default_arch_struct): Add bfd_arch_default_fill.
2607 (bfd_arch_default_fill): New.
2608
2609 * configure.in: Set bfd version to 2.22.52.
2610 * configure: Regenerated.
2611
2612 * cpu-alpha.c: Add bfd_arch_default_fill to bfd_arch_info
2613 initializer.
2614 * cpu-arc.c: Likewise.
2615 * cpu-arm.c: Likewise.
2616 * cpu-avr.c: Likewise.
2617 * cpu-bfin.c: Likewise.
2618 * cpu-cr16.c: Likewise.
2619 * cpu-cr16c.c: Likewise.
2620 * cpu-cris.c: Likewise.
2621 * cpu-crx.c: Likewise.
2622 * cpu-d10v.c: Likewise.
2623 * cpu-d30v.c: Likewise.
2624 * cpu-dlx.c: Likewise.
2625 * cpu-epiphany.c: Likewise.
2626 * cpu-fr30.c: Likewise.
2627 * cpu-frv.c: Likewise.
2628 * cpu-h8300.c: Likewise.
2629 * cpu-h8500.c: Likewise.
2630 * cpu-hppa.c: Likewise.
2631 * cpu-i370.c: Likewise.
2632 * cpu-i860.c: Likewise.
2633 * cpu-i960.c: Likewise.
2634 * cpu-ia64.c: Likewise.
2635 * cpu-ip2k.c: Likewise.
2636 * cpu-iq2000.c: Likewise.
2637 * cpu-lm32.c: Likewise.
2638 * cpu-m10200.c: Likewise.
2639 * cpu-m10300.c: Likewise.
2640 * cpu-m32c.c: Likewise.
2641 * cpu-m32r.c: Likewise.
2642 * cpu-m68hc11.c: Likewise.
2643 * cpu-m68hc12.c: Likewise.
2644 * cpu-m68k.c: Likewise.
2645 * cpu-m88k.c: Likewise.
2646 * cpu-mcore.c: Likewise.
2647 * cpu-mep.c: Likewise.
2648 * cpu-microblaze.c: Likewise.
2649 * cpu-mips.c: Likewise.
2650 * cpu-mmix.c: Likewise.
2651 * cpu-moxie.c: Likewise.
2652 * cpu-msp430.c: Likewise.
2653 * cpu-mt.c: Likewise.
2654 * cpu-ns32k.c: Likewise.
2655 * cpu-openrisc.c: Likewise.
2656 * cpu-or32.c: Likewise.
2657 * cpu-pdp11.c: Likewise.
2658 * cpu-pj.c: Likewise.
2659 * cpu-plugin.c: Likewise.
2660 * cpu-powerpc.c: Likewise.
2661 * cpu-rl78.c: Likewise.
2662 * cpu-rs6000.c: Likewise.
2663 * cpu-rx.c: Likewise.
2664 * cpu-s390.c: Likewise.
2665 * cpu-score.c: Likewise.
2666 * cpu-sh.c: Likewise.
2667 * cpu-sparc.c: Likewise.
2668 * cpu-spu.c: Likewise.
2669 * cpu-tic30.c: Likewise.
2670 * cpu-tic4x.c: Likewise.
2671 * cpu-tic54x.c: Likewise.
2672 * cpu-tic6x.c: Likewise.
2673 * cpu-tic80.c: Likewise.
2674 * cpu-tilegx.c: Likewise.
2675 * cpu-tilepro.c: Likewise.
2676 * cpu-v850.c: Likewise.
2677 * cpu-vax.c: Likewise.
2678 * cpu-w65.c: Likewise.
2679 * cpu-we32k.c: Likewise.
2680 * cpu-xc16x.c: Likewise.
2681 * cpu-xstormy16.c: Likewise.
2682 * cpu-xtensa.c: Likewise.
2683 * cpu-z80.c: Likewise.
2684 * cpu-z8k.c: Likewise.
2685
2686 * cpu-i386.c: Include "libiberty.h".
2687 (bfd_arch_i386_fill): New.
2688 Add bfd_arch_i386_fill to bfd_arch_info initializer.
2689
2690 * cpu-k1om.c: Add bfd_arch_i386_fill to bfd_arch_info initializer.
2691 * cpu-l1om.c: Likewise.
2692
2693 * linker.c (default_data_link_order): Call abfd->arch_info->fill
2694 if fill size is 0.
2695
2696 * bfd-in2.h: Regenerated.
2697
2698 2012-01-27 Michael Eager <eager@eagercon.com>
2699
2700 * elf32-microblaze.c (create_got_section):
2701 Reuse existing .rela.got section.
2702
2703 2012-01-23 Alan Modra <amodra@gmail.com>
2704
2705 * elf-bfd.h: Formatting.
2706 (struct elf_backend_data): Add "maybe_function_sym".
2707 (_bfd_elf_maybe_function_sym): Declare.
2708 * elfxx-target.h (elf_backend_maybe_function_sym): Define.
2709 (elfNN_bed): Init new field.
2710 * elf.c (elf_find_function): Use maybe_function_sym.
2711 (_bfd_elf_maybe_function_sym): New function.
2712 * elf64-ppc.c (elf_backend_maybe_function_sym): Define.
2713 (ppc64_elf_maybe_function_sym): New function.
2714
2715 2012-01-20 Francois Gouget <fgouget@codeweavers.com>
2716
2717 PR binutils/13534
2718 * archive.c (_bfd_ar_sizepad): New function. Correctly install and
2719 pad the size field in an archive header.
2720 (_bfd_generic_read_ar_hdr_mag): Use the correct type and scan
2721 function for the archive size field.
2722 (bfd_generic_openr_next_archived_file): Likewise.
2723 (do_slurp_coff_armap): Likewise.
2724 (_bfd_write_archive_contents): Likewise.
2725 (_bfd_bsd44_write_ar_hdr): Use the new function.
2726 (bfd_ar_hdr_from_filesystem): Likewise.
2727 (_bfd_write_archive_contents): Likewise.
2728 (bsd_write_armap): Likewise.
2729 (coff_write_armap): Likewise.
2730 * archive64.c (bfd_elf64_archive_write_armap): Likewise.
2731 * bfdio.c (bfd_bread): Use correct type for archive element
2732 sizes.
2733 * ar.c (open_inarch): Likewise.
2734 (extract_file): Likewise.
2735 * libbfd-in.h (struct areltdata): Use correct types for
2736 parsed_size and extra_size fields.
2737 Prototype _bfd_ar_sizepad function.
2738 * libbfd.h: Regenerate.
2739
2740 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
2741
2742 * elf.c (elfcore_write_prpsinfo): Provide unconditionally.
2743 Return NULL if core file generation is unsupported.
2744 (elfcore_write_prstatus): Likewise.
2745 * elf32-arm.c (elf32_arm_nabi_write_core_note): New function.
2746 (elf_backend_write_core_note): Define.
2747
2748 2012-01-19 Tristan Gingold <gingold@adacore.com>
2749
2750 * pef.c: Add a comment.
2751 * xsym.c: Likewise.
2752
2753 2012-01-17 Alan Modra <amodra@gmail.com>
2754
2755 * elf32-ppc.c (ppc_elf_write_core_note <NT_PRPSINFO>): Don't leave
2756 trailing garbage in the note.
2757 * elf64-ppc.c (ppc64_elf_write_core_note <NT_PRPSINFO>): Likewise.
2758
2759 2012-01-16 Daniel Green <venix1@gmail.com>
2760
2761 PR ld/13491
2762 * coff-i386.c (coff_i386_rtype_to_howto <R_SECREL32>): Test
2763 h->root.type not h->type.
2764 * coff-x86_64.c (coff_amd64_rtype_to_howto <R_AMD64_SECREL>): Likewise.
2765
2766 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
2767
2768 * mach-o.c (bfd_mach_o_build_dysymtab_command): Handle absolute
2769 indirect symbols.
2770
2771 2012-01-13 Iain Sandoe <idsandoe@googlemail.com>
2772
2773 * mach-o.c (bfd_mach_o_write_relocs): Move computation of relocs file
2774 position from here... to (bfd_mach_o_build_seg_command): Here.
2775
2776 2012-01-12 Iain Sandoe <idsandoe@googlemail.com>
2777
2778 * mach-o.c (bfd_mach_o_count_indirect_symbols): New.
2779 (bfd_mach_o_build_dysymtab_command): Populate indirect symbol table.
2780 * mach-o.h (bfd_mach_o_asymbol): Move declaration to start of the
2781 file. (bfd_mach_o_section): Add indirect_syms field.
2782
2783 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
2784
2785 * mach-o.c (bfd_mach_o_build_seg_command): Separate computation of
2786 vmsize from filesize. Don't compute offsets or file sizes for
2787 zerofill sections.
2788
2789 2012-01-11 Iain Sandoe <idsandoe@googlemail.com>
2790
2791 * mach-o.c (bfd_mach_o_build_commands): Make the building of each
2792 command type independent.
2793
2794 2012-01-11 Alan Modra <amodra@gmail.com>
2795
2796 * elf64-ppc.c: Define more insns used in plt call stubs.
2797 (ppc64_elf_brtaken_reloc): Assume isa version 2 or above.
2798 (ppc64_elf_relocate_section): Likewise.
2799 (enum ppc_stub_type): Add ppc_stub_plt_call_r2save.
2800 (struct ppc_link_hash_table): Increase size of stub_count array.
2801 Add plt_stub_align and plt_thread_safe.
2802 (ALWAYS_USE_FAKE_DEP, ALWAYS_EMIT_R2SAVE): Define.
2803 (plt_stub_size, plt_stub_pad): New functions.
2804 (build_plt_stub): Emit barriers for power7 thread safety. Don't
2805 emit needless save of r2.
2806 (build_tls_get_addr_stub): Adjust params.
2807 (ppc_build_one_stub): Handle ppc_stub_plt_call_r2save and aligning
2808 plt stubs. Adjust build_*plt_stub calls.
2809 (ppc_size_one_stub): Similarly.
2810 (ppc64_elf_size_stubs): Accept plt_thread_safe and plt_stub_align
2811 params. Choose default for plt_thread_safe based on existence of
2812 calls to thread creation functions. Modify plt_call to
2813 plt_call_r2save when no tocsave reloc found. Align tail of stub
2814 sections.
2815 (ppc64_elf_build_stubs): Align tail of stub sections. Adjust
2816 output of stub statistics.
2817 (ppc64_elf_relocate_section): Handle ppc_stub_plt_call_r2save.
2818 * elf64-ppc.h (ppc64_elf_size_stubs): Update prototype.
2819
2820 2012-01-10 H.J. Lu <hongjiu.lu@intel.com>
2821
2822 PR ld/13581
2823 * elf64-x86-64.c (elf_x86_64_relocate_section): Remove ABI_64_P
2824 check on R_X86_64_PCXX.
2825
2826 2012-01-10 Tristan Gingold <gingold@adacore.com>
2827
2828 * mach-o.c (bfd_mach_o_build_commands): Avoid uninitialized false
2829 warning.
2830
2831 2012-01-10 Tristan Gingold <gingold@adacore.com>
2832
2833 * bfdio.c (bfd_tell): Handle nested archives.
2834 (bfd_seek): Ditto.
2835 * cache.c (bfd_cache_lookup_worker): Ditto.
2836 * archive.c (_bfd_get_elt_at_filepos): Remove code dealing with
2837 nested archives.
2838 (bfd_generic_openr_next_archived_file): Likewise.
2839
2840 2012-01-09 Iain Sandoe <idsandoe@googlemail.com>
2841
2842 * mach-o.c (bfd_mach_o_bfd_copy_private_symbol_data): Implement.
2843 (bfd_mach_o_write_symtab): Remove handling for indirect syms.
2844 (bfd_mach_o_primary_symbol_sort_key): Likewise.
2845 (bfd_mach_o_cf_symbols): Likewise.
2846 (bfd_mach_o_sort_symbol_table): Remove.
2847 (bfd_mach_o_mangle_symbols): Adjust arguments, remove handling
2848 for indirect and dysymtab counts. Do the symbol sorting here.
2849 (bfd_mach_o_build_dysymtab_command): Count the symbol types here.
2850 Make the indirect symbols a TODO.
2851 (bfd_mach_o_build_commands): Adjust call to bfd_mach_o_mangle_symbols.
2852 (bfd_mach_o_make_empty_symbol): Specifically flag unset symbols with
2853 a non-zero value.
2854 (bfd_mach_o_read_symtab_symbol): Record the symbol index.
2855 (bfd_mach_o_read_symtab_symbol): Adjust recording of global status.
2856 * mach-o.h (mach_o_data_struct): Remove indirect and dysymtab entries.
2857 (IS_MACHO_INDIRECT): Remove.
2858 (SYM_MACHO_FIELDS_UNSET, SYM_MACHO_FIELDS_NOT_VALIDATED): New.
2859
2860 2012-01-06 Nick Clifton <nickc@redhat.com>
2861
2862 PR binutils/13121
2863 * reloc.c (bfd_generic_lookup_section_flags): Rename 'finfo' to
2864 'flaginfo' to avoid conflicts with AIX system headers.
2865
2866 2012-01-06 Tristan Gingold <gingold@adacore.com>
2867
2868 * bfdio.c (bfd_bread): Use arelt_size macro.
2869
2870 2012-01-06 Tristan Gingold <gingold@adacore.com>
2871
2872 * config.bfd (i[3-7]86-*-darwin*): Define targ64_selvecs.
2873
2874 2012-01-05 Nick Clifton <nickc@redhat.com>
2875
2876 PR ld/12161
2877 * elf32-avr.c (elf32_avr_relax_delete_bytes): Read in relocs if
2878 necessary.
2879
2880 2012-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
2881
2882 Fix zero registers core files when built by gcc-4.7.
2883 * elf64-x86-64.c (elf_x86_64_write_core_note): Remove variables p and
2884 size. Call elfcore_write_note for the local variables. Remove the
2885 final elfcore_write_note call. Add NOTREACHED comments.
2886
2887 2012-01-04 Tristan Gingold <gingold@adacore.com>
2888
2889 * mach-o.c (bfd_mach_o_fat_stat_arch_elt): New function.
2890 (bfd_mach_o_generic_stat_arch_elt): Adjust.
2891
2892 2012-01-04 Tristan Gingold <gingold@adacore.com>
2893
2894 * mach-o.c (bfd_mach_o_fat_member_init): New function.
2895 (bfd_mach_o_openr_next_archived_file): Reindent.
2896 Adjust to call bfd_mach_o_fat_member_init.
2897 (bfd_mach_o_fat_extract): Adjust to call bfd_mach_o_fat_member_init.
2898
2899 2012-01-04 Tristan Gingold <gingold@adacore.com>
2900
2901 * mach-o-x86-64.c (bfd_mach_o_x86_64_swap_reloc_out): Handle
2902 BFD_RELOC_32, BFD_RELOC_MACH_O_X86_64_PCREL32_1,
2903 BFD_RELOC_MACH_O_X86_64_PCREL32_2,
2904 BFD_RELOC_MACH_O_X86_64_PCREL32_4,
2905 BFD_RELOC_MACH_O_X86_64_BRANCH32,
2906 BFD_RELOC_MACH_O_X86_64_SUBTRACTOR32,
2907 BFD_RELOC_MACH_O_X86_64_GOT.
2908
2909 2012-01-04 Tristan Gingold <gingold@adacore.com>
2910
2911 * mach-o.h (bfd_mach_o_fvmlib_command): New structure.
2912 (bfd_mach_o_load_command): Add fvmlib field.
2913
2914 * mach-o.c (bfd_mach_o_read_fvmlib): New function.
2915 (bfd_mach_o_read_command): Handle fvmlib.
2916
2917 2012-01-04 Tristan Gingold <gingold@adacore.com>
2918
2919 * mach-o.c (bfd_mach_o_convert_architecture): Reindent.
2920 Decode msubtype for ARM.
2921
2922 2012-01-04 Tristan Gingold <gingold@adacore.com>
2923
2924 * mach-o.c (bfd_mach_o_get_synthetic_symtab): Add comments.
2925
2926 2012-01-04 Tristan Gingold <gingold@adacore.com>
2927
2928 * mach-o.h: Reindent header.
2929 (bfd_mach_o_encryption_info_command): New structure.
2930 (bfd_mach_o_load_command): Add encryption_info field.
2931
2932 * mach-o.c (bfd_mach_o_read_encryption_info): New function.
2933 (bfd_mach_o_read_command): Handle BFD_MACH_O_LC_ENCRYPTION_INFO.
2934 (bfd_mach_o_read_command): Adjust error message.
2935
2936 2012-01-04 Shinichiro Hamaji <shinichiro.hamaji@gmail.com>
2937
2938 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Factor out the part
2939 which reads DWARF2 and stores in stash from find_line.
2940 (find_line) Call _bfd_dwarf2_slurp_debug_info.
2941 * libbfd-in.h (_bfd_dwarf2_slurp_debug_info): Add declaration.
2942 * libbfd.h (_bfd_dwarf2_slurp_debug_info): Regenerate.
2943 * mach-o.c (dsym_subdir): The name of subdir where debug
2944 information may be stored.
2945 (bfd_mach_o_lookup_uuid_command): New. Lookup a load command whose
2946 type is UUID.
2947 (bfd_mach_o_dsym_for_uuid_p): New. Check if the specified BFD is
2948 corresponding to the executable.
2949 (bfd_mach_o_find_dsym): New. Find a debug information BFD in the
2950 specified binary file.
2951 (bfd_mach_o_follow_dsym): New. Find a debug information BFD for
2952 the original BFD.
2953 (bfd_mach_o_find_nearest_line): Check dSYM files for Mach-O
2954 executables, dylibs, and bundles.
2955 (bfd_mach_o_close_and_cleanup): Clean up BFDs for the dSYM file.
2956 * mach-o.h (dsym_bfd): The BFD of the dSYM file.
2957
2958 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2959
2960 * mach-o.c (bfd_mach_o_mangle_symbols): Put in the section index
2961 for stabd symbols.
2962 (bfd_mach_o_primary_symbol_sort_key): Adjust for stabs.
2963 (bfd_mach_o_cf_symbols): Likewise.
2964
2965 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2966
2967 * mach-o.c (bfd_mach_o_mangle_symbols): Correct typo.
2968
2969 2012-01-03 Iain Sandoe <idsandoe@googlemail.com>
2970
2971 * mach-o.c (bfd_mach_o_write_symtab): Fill in the string table index
2972 as the value of an indirect symbol. Keep the string table index in
2973 non-indirect syms for reference.
2974 (bfd_mach_o_write_dysymtab): New.
2975 (bfd_mach_o_primary_symbol_sort_key): New.
2976 (bfd_mach_o_cf_symbols): New.
2977 (bfd_mach_o_sort_symbol_table): New.
2978 (bfd_mach_o_mangle_symbols): Return early if no symbols. Sort symbols.
2979 If we are emitting a dysymtab, process indirect symbols and count the
2980 number of each other kind.
2981 (bfd_mach_o_mangle_sections): New.
2982 (bfd_mach_o_write_contents): Split out some pre-requisite code into
2983 the command builder. Write dysymtab if the command is present.
2984 (bfd_mach_o_count_sections_for_seg): New.
2985 (bfd_mach_o_build_seg_command): New.
2986 (bfd_mach_o_build_dysymtab_command): New.
2987 (bfd_mach_o_build_commands): Reorganize to support the fact that some
2988 commands are optional and should not be emitted if there are no
2989 sections or symbols.
2990 (bfd_mach_o_set_section_contents): Amend comment.
2991 * mach-o.h: Amend and add to comments.
2992 (mach_o_data_struct): Add fields for dysymtab symbols counts and a
2993 pointer to the indirects, when present.
2994 (bfd_mach_o_should_emit_dysymtab): New macro.
2995 (IS_MACHO_INDIRECT): Likewise.
2996
2997 For older changes see ChangeLog-2011
2998 \f
2999 Local Variables:
3000 mode: change-log
3001 left-margin: 8
3002 fill-column: 74
3003 version-control: never
3004 End:
This page took 0.10413 seconds and 5 git commands to generate.