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