Commit | Line | Data |
---|---|---|
4d430725 AM |
1 | 2020-08-26 Alan Modra <amodra@gmail.com> |
2 | ||
3 | PR 26507 | |
4 | * elf32-xtensa.c (find_removed_literal): Don't bsearch empty map. | |
5 | ||
252e57fd AM |
6 | 2020-08-26 Alan Modra <amodra@gmail.com> |
7 | ||
8 | PR 26506 | |
9 | * elf32-xtensa.c (elf_xtensa_combine_prop_entries): Return early | |
10 | when section is empty. | |
11 | ||
2d0ce677 AM |
12 | 2020-08-26 Alan Modra <amodra@gmail.com> |
13 | ||
14 | PR 26498 | |
15 | * elf32-spu.c (find_function_stack_adjust): Use unsigned vars to | |
16 | avoid UB left shift. | |
17 | ||
9e51d549 AM |
18 | 2020-08-26 Alan Modra <amodra@gmail.com> |
19 | ||
20 | PR 26484 | |
21 | PR 26485 | |
22 | PR 26486 | |
23 | PR 26487 | |
24 | PR 26488 | |
25 | PR 26490 | |
26 | * elf64-ppc.c (is_tls_get_addr): Avoid UB &h->elf when h is NULL. | |
27 | (ppc64_elf_tls_setup): Likewise. | |
28 | (branch_reloc_hash_match): Likewise. | |
29 | (build_plt_stub): Likewise. | |
30 | (ppc64_elf_relocate_section): Likewise. | |
31 | ||
00bc5e68 AM |
32 | 2020-08-26 Alan Modra <amodra@gmail.com> |
33 | ||
34 | PR 26478 | |
35 | * mmo.c (mmo_write_symbols_and_terminator): Don't memcpy empty table. | |
36 | ||
55e61b8a AM |
37 | 2020-08-26 Alan Modra <amodra@gmail.com> |
38 | ||
39 | PR 26475 | |
40 | * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Check | |
41 | sstubs->contents != NULL. | |
42 | ||
66ad6b44 AM |
43 | 2020-08-26 Alan Modra <amodra@gmail.com> |
44 | ||
45 | PR 26453 | |
46 | * som.c (som_prep_for_fixups): Return early when no symbols. | |
47 | ||
9863cbb7 AM |
48 | 2020-08-26 Alan Modra <amodra@gmail.com> |
49 | ||
50 | PR 26418 | |
51 | * ecofflink.c (WRITE): Don't write size 0 chunks. | |
52 | ||
c01de193 AM |
53 | 2020-08-26 Alan Modra <amodra@gmail.com> |
54 | ||
55 | * bfdio.c (bfd_get_file_size): Don't segv on NULL adata. | |
56 | ||
b4e125d9 AM |
57 | 2020-08-26 Alan Modra <amodra@gmail.com> |
58 | ||
59 | PR 26415 | |
60 | * vms-misc.c (vms_time_t_to_vms_time): Don't use unsigned short vars. | |
61 | ||
4449c81a DF |
62 | 2020-08-26 David Faust <david.faust@oracle.com> |
63 | ||
64 | * archures.c (bfd_mach_xbpf): Define. | |
65 | * bfd-in2.h: Regenerate. | |
66 | * cpu-bpf.c (bfd_xbpf_arch) New. | |
67 | (bfd_bpf_arch) Update next in list field to point to xbpf arch. | |
68 | ||
13f8a246 AM |
69 | 2020-08-26 Alan Modra <amodra@gmail.com> |
70 | ||
71 | * archures.c (bfd_mach_ck860): Define. | |
72 | ||
c3757b58 MW |
73 | 2020-08-25 Mark Wielaard <mark@klomp.org> |
74 | ||
75 | * dwarf2.c (struct dwarf2_debug_file): Add dwarf_rnglists_buffer | |
76 | and dwarf_rnglists_size fields. | |
77 | (dwarf_debug_sections): Add debug_rnglists. | |
78 | (dwarf_debug_section_enum): Likewise. | |
79 | (read_debug_rnglists): New function. | |
80 | (read_rangelist): New function to call either read_ranges or | |
81 | read_rnglists. Rename original function to... | |
82 | (read_ranges): ...this. | |
83 | (read_rnglists): New function. | |
84 | ||
1ab8d928 AM |
85 | 2020-08-25 Alan Modra <amodra@gmail.com> |
86 | ||
87 | PR 26505 | |
88 | * elf32-xstormy16.c (xstormy16_elf_relax_section): Check | |
89 | is_elf_hash_table before accessing elf fields. | |
90 | ||
a93ba4c0 AM |
91 | 2020-08-25 Alan Modra <amodra@gmail.com> |
92 | ||
93 | PR 26482 | |
94 | * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Ignore sections that | |
95 | won't be output. | |
96 | ||
1438dd86 AM |
97 | 2020-08-25 Alan Modra <amodra@gmail.com> |
98 | ||
99 | PR 26463 | |
100 | * elf32-m32c.c (m32c_elf_relax_section): Check is_elf_hash_table | |
101 | before accessing elf fields. | |
102 | ||
2186273a AM |
103 | 2020-08-25 Alan Modra <amodra@gmail.com> |
104 | ||
105 | PR 26452 | |
106 | * som.c (som_compute_checksum): XOR 32-bit words in header, | |
107 | not unsigned long sized words. | |
108 | ||
0c1438eb AM |
109 | 2020-08-25 Alan Modra <amodra@gmail.com> |
110 | ||
111 | PR 26430 | |
112 | * elf-nacl.c (nacl_modify_segment_map): Correct alloc size and | |
113 | amount copied for elf_segment_map defined with one element | |
114 | sections array. | |
115 | ||
d2327e47 AM |
116 | 2020-08-25 Alan Modra <amodra@gmail.com> |
117 | ||
118 | PR 26422 | |
119 | * elf32-arm.c (elf32_arm_final_link_relocate): Use the appropriate | |
120 | bfd_get_x size function to read addends out of fields. Apply | |
121 | rightshift adjustment too. Don't apply the now unnecessary | |
122 | howto->size shift to branch REL addends. Don't refetch R_ARM_ABS8 | |
123 | and R_ARM_ABS16 addends. Don't refetch thumb branch addends. | |
124 | Correct R_ARM_THM_JUMP6 addend. | |
125 | ||
b8ff233b AM |
126 | 2020-08-25 Alan Modra <amodra@gmail.com> |
127 | ||
128 | PR 26419 | |
129 | * elf-m10300.c (mn10300_elf_relax_section): Don't attempt access | |
130 | before start of section. | |
131 | ||
0f55320b AM |
132 | 2020-08-25 Alan Modra <amodra@gmail.com> |
133 | ||
134 | * elf-m10300.c (elf32_mn10300_hash_table): Test is_elf_hash_table | |
135 | before accessing elf_hash_table_id. | |
136 | * elf32-arc.c (elf_arc_hash_table): Likewise. | |
137 | * elf32-arm.c (elf32_arm_hash_table): Likewise. | |
138 | * elf32-avr.c (avr_link_hash_table): Likewise. | |
139 | * elf32-bfin.c (bfinfdpic_hash_table): Likewise. | |
140 | * elf32-cris.c (elf_cris_hash_table): Likewise. | |
141 | * elf32-csky.c (csky_elf_hash_table): Likewise. | |
142 | * elf32-frv.c (frvfdpic_hash_table): Likewise. | |
143 | * elf32-hppa.c (hppa_link_hash_table): Likewise. | |
144 | * elf32-lm32.c (lm32_elf_hash_table): Likewise. | |
145 | * elf32-m32r.c (m32r_elf_hash_table): Likewise. | |
146 | * elf32-m68hc1x.h (m68hc11_elf_hash_table): Likewise. | |
147 | * elf32-m68k.c (elf_m68k_hash_table): Likewise. | |
148 | * elf32-metag.c (metag_link_hash_table): Likewise. | |
149 | * elf32-microblaze.c (elf32_mb_hash_table): Likewise. | |
150 | * elf32-nds32.h (nds32_elf_hash_table): Likewise. | |
151 | * elf32-or1k.c (or1k_elf_hash_table): Likewise. | |
152 | * elf32-s390.c (elf_s390_hash_table): Likewise. | |
153 | * elf32-sh.c (sh_elf_hash_table): Likewise. | |
154 | * elf32-spu.c (spu_hash_table): Likewise. | |
155 | * elf32-tilepro.c (tilepro_elf_hash_table): Likewise. | |
156 | * elf32-xtensa.c (elf_xtensa_hash_table): Likewise. | |
157 | * elf64-alpha.c (alpha_elf_hash_table): Likewise. | |
158 | * elf64-hppa.c (hppa_link_hash_table): Likewise. | |
159 | * elf64-ia64-vms.c (elf64_ia64_hash_table): Likewise. | |
160 | * elf64-s390.c (elf_s390_hash_table): Likewise. | |
161 | * elfnn-ia64.c (elfNN_ia64_hash_table): Likewise. | |
162 | * elfnn-riscv.c (riscv_elf_hash_table): Likewise. | |
163 | * elfxx-mips.c (mips_elf_hash_table): Likewise. | |
164 | * elfxx-sparc.h (_bfd_sparc_elf_hash_table): Likewise. | |
165 | * elfxx-tilegx.c (tilegx_elf_hash_table): Likewise. | |
166 | ||
3cdad084 JT |
167 | 2020-08-21 Jon Turney <jon.turney@dronecode.org.uk> |
168 | ||
169 | * elf.c (elfcore_grok_win32pstatus): Change name_size to unsigned | |
170 | int. Use '%u' format with _bfd_error_handler to render it. | |
171 | ||
918dc783 AM |
172 | 2020-08-25 Alan Modra <amodra@gmail.com> |
173 | ||
174 | PR 26489 | |
175 | * elf64-ppc.c (ppc64_elf_size_stubs): Test code_sec->has_toc_reloc | |
176 | and code_sec->makes_toc_func_call before sec_info[code_sec->id]. | |
177 | ||
573eb292 AM |
178 | 2020-08-25 Alan Modra <amodra@gmail.com> |
179 | ||
180 | PR 26492 | |
181 | * elf64-ppc.c (ppc_hash_table): Test is_elf_hash_table before | |
182 | accessing elf_hash_table_id. | |
183 | ||
a8d549c0 AM |
184 | 2020-08-25 Alan Modra <amodra@gmail.com> |
185 | ||
186 | PR 26483 | |
187 | * elf32-ppc.c (ppc_elf_hash_table): Test is_elf_hash_table before | |
188 | accessing elf_hash_table_id. | |
189 | ||
19d80e5f MW |
190 | 2020-08-24 Mark Wielaard <mark@klomp.org> |
191 | ||
192 | * dwarf2.c (read_attribute_value): Handle DW_FORM_data16. | |
193 | (read_formatted_entries): Likewise. And skip zero entry. | |
194 | ||
531c73a3 CQ |
195 | 2020-08-24 Cooper Qu <cooper.qu@linux.alibaba.com> |
196 | ||
197 | * bfd-in2.h (bfd_mach_ck860): New. | |
198 | * cpu-csky.c (arch_info_struct): Add item for CK860. | |
199 | ||
252dcdf4 AM |
200 | 2020-08-24 Alan Modra <amodra@gmail.com> |
201 | ||
202 | * elf32-ppc.c (ppc_elf_check_relocs): Set has_tls_reloc for | |
203 | high part tprel16 relocs. | |
204 | (ppc_elf_tls_optimize): Sanity check high part tprel16 relocs. | |
205 | Clear do_tls_opt on odd instructions. | |
206 | (ppc_elf_relocate_section): Move TPREL16_HA/LO optimisation later. | |
207 | Don't sanity check them here. | |
208 | * elf64-ppc.c (ppc64_elf_check_relocs): Set has_tls_reloc for | |
209 | high part tprel16 relocs. | |
210 | (ppc64_elf_tls_optimize): Sanity check high part tprel16 relocs. | |
211 | Clear do_tls_opt on odd instructions. | |
212 | (ppc64_elf_relocate_section): Don't sanity check TPREL16_HA. | |
213 | ||
c40e6650 JDA |
214 | 2020-08-23 John David Anglin <danglin@gcc.gnu.org> |
215 | ||
216 | PR binutils/26357 | |
217 | * configure.ac: Disable plugins by default on 32-bit hppa*-*-hpux*. | |
218 | * configure: Regenerate. | |
219 | ||
3f2e9699 L |
220 | 2020-08-22 H.J. Lu <hongjiu.lu@intel.com> |
221 | ||
222 | PR ld/26382 | |
223 | * elflink.c (elf_link_output_symstrtab): Keep only one '@' for | |
224 | versioned symbols, which are defined in shared objects, in | |
225 | symbol string table. | |
226 | ||
ccf61261 NC |
227 | 2020-08-21 Nick Clifton <nickc@redhat.com> |
228 | ||
229 | * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_scan): Only sort | |
230 | the data map if there are entries in it. | |
231 | (_bfd_aarch64_erratum_843419_scan): Likewise. | |
232 | ||
610ed3e0 JB |
233 | 2020-08-21 Jan Beulich <jbeulich@suse.com> |
234 | ||
235 | * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check | |
236 | last byte of debug dir, not first. | |
237 | ||
01147b20 NC |
238 | 2020-08-20 Nick Clifton <nickc@redhat.com> |
239 | ||
240 | PR 26428 | |
241 | * bfd.c (bfd_update_compression_header): Also set the sh_addralign | |
242 | field in the ELF header of the compressed sections. | |
243 | ||
44466e45 NC |
244 | 2020-08-20 Nick Clifton <nickc@redhat.com> |
245 | ||
246 | PR 26406 | |
247 | * elf-bfd.h (struct bfd_elf_section_data): Add | |
248 | has_secondary_relocs field. | |
249 | * elf.c (_bfd_elf_copy_special_section_fields): Set the | |
250 | has_secondary_relocs field for sections which have associated | |
251 | secondary relocs. | |
252 | * elfcode.h (elf_write_relocs): Only call write_secondary_relocs | |
253 | on sections which have associated secondary relocs. | |
254 | ||
10885e24 AM |
255 | 2020-08-15 Alan Modra <amodra@gmail.com> |
256 | ||
257 | * elf32-frv.c (elf32_frv_add_symbol_hook): Set SEC_SMALL_DATA on | |
258 | small common section. | |
259 | * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise. | |
260 | * elf32-microblaze.c (microblaze_elf_add_symbol_hook): Likewise. | |
261 | * elf32-nds32.c (nds32_elf_add_symbol_hook): Likewise. | |
262 | * elf32-nios2.c (nios2_elf_add_symbol_hook): Likewise. | |
263 | * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise. | |
264 | * elf32-score.c (s3_bfd_score_elf_add_symbol_hook): Likewise. | |
265 | * elf32-score7.c (s7_bfd_score_elf_add_symbol_hook): Likewise. | |
266 | * elf32-tic6x.c (elf32_tic6x_add_symbol_hook): Likewise. | |
267 | * elf32-v850.c (v850_elf_check_relocs): Likewise. | |
268 | (v850_elf_add_symbol_hook): Likewise. | |
269 | * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise. | |
270 | * elf64-ia64-vms.c (elf64_ia64_add_symbol_hook): Likewise. | |
271 | * elfnn-ia64.c (elfNN_ia64_add_symbol_hook): Likewise. | |
272 | * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Likewise. | |
273 | ||
4d182367 AM |
274 | 2020-08-15 Alan Modra <amodra@gmail.com> |
275 | ||
276 | PR 26389 | |
277 | * syms.c (bfd_decode_symclass): Choose 'c' for commons only when | |
278 | SEC_SMALL_DATA. | |
279 | * elf32-m32r.c (_bfd_m32r_elf_symbol_processing): Set SEC_SMALL_DATA | |
280 | on small common section. | |
281 | * elf32-score.c (s3_bfd_score_elf_symbol_processing): Likewise. | |
282 | * elf32-score7.c (s7_bfd_score_elf_symbol_processing): Likewise. | |
283 | * elf32-tic6x.c (elf32_tic6x_symbol_processing): Likewise. | |
284 | * elf32-v850.c (v850_elf_symbol_processing): Likewise. | |
285 | * elfxx-mips.c (_bfd_mips_elf_symbol_processing): Likewise. | |
286 | * ecoff.c (ecoff_set_symbol_info, ecoff_link_add_externals): Likewise. | |
287 | ||
19bddbe9 AM |
288 | 2020-08-14 Alan Modra <amodra@gmail.com> |
289 | ||
290 | * hash.c (bfd_hash_set_default_size): Use higher_prime_number | |
291 | rather than another copy of primes. Increase maximum default | |
292 | size allowed. | |
293 | ||
2b6ba032 AM |
294 | 2020-08-13 Alan Modra <amodra@gmail.com> |
295 | ||
73d0dc16 | 296 | * config.bfd: Obsolete arm*-*-symbianelf*, and ia64*-*-*. |
2b6ba032 | 297 | |
6738c8a7 AM |
298 | 2020-08-13 Alan Modra <amodra@gmail.com> |
299 | ||
300 | * elf64-ppc.h (struct ppc64_elf_params): Add no_pcrel_opt. | |
301 | * elf64-ppc.c (ppc64_elf_relocate_section): Disable GOT reloc | |
302 | optimizations when --no-toc-optimize. Disable R_PPC64_PCREL_OPT | |
303 | optimization when --no-pcrel-optimize. | |
304 | ||
75e100a3 AM |
305 | 2020-08-13 Alan Modra <amodra@gmail.com> |
306 | ||
307 | PR 26348 | |
308 | * bfd.c (struct bfd): Add read_only. | |
309 | * elfcode.h (elf_swap_shdr_in): Test both sh_offset and sh_size. | |
310 | Set read_only on warning. | |
311 | (elf_object_p): Sanity check program header alignment. Set | |
312 | read_only on warning. | |
313 | * bfd-in2.h: Regenerate. | |
314 | ||
2fef9373 JT |
315 | 2020-08-12 Jon Turney <jon.turney@dronecode.org.uk> |
316 | ||
317 | * elf.c (elfcore_grok_win32pstatus): Use unsigned int for | |
318 | win32pstatus note type to avoid signedness comparison warning. | |
319 | ||
404ec933 JT |
320 | 2020-07-21 Jon Turney <jon.turney@dronecode.org.uk> |
321 | ||
322 | * elf.c (elfcore_grok_win32pstatus): Warn on malformed | |
323 | win32pstatus notes, and return TRUE so we continue rather than | |
324 | stopping as if it was an error. | |
325 | ||
d61f3d03 JT |
326 | 2020-07-01 Jon Turney <jon.turney@dronecode.org.uk> |
327 | ||
328 | * elf.c (elfcore_grok_win32pstatus): Handle NOTE_INFO_MODULE64. | |
329 | ||
04ec0fa2 JT |
330 | 2020-07-11 Jon Turney <jon.turney@dronecode.org.uk> |
331 | ||
332 | * elf.c (elfcore_grok_win32pstatus): Don't apply size constraint | |
333 | for NOTE_INFO_THREAD to all win32pstatus ELF notes, instead apply | |
334 | appropriate size constraint for each win32pstatus note type. | |
335 | ||
03c29a6f JT |
336 | 2020-07-01 Jon Turney <jon.turney@dronecode.org.uk> |
337 | ||
338 | * elf.c (elfcore_grok_win32pstatus): Don't hardcode the size of | |
339 | the Win32 API thread CONTEXT type read from a NOTE_INFO_THREAD | |
340 | win32pstatus note. | |
341 | ||
8fbac78b JT |
342 | 2020-07-11 Jon Turney <jon.turney@dronecode.org.uk> |
343 | ||
344 | * elf.c (NOTE_INFO{_PROCESS,_THREAD,_MODULE}): Define. | |
345 | (elfcore_grok_win32pstatus): Use. | |
346 | ||
ff2084b9 JT |
347 | 2020-07-01 Jon Turney <jon.turney@dronecode.org.uk> |
348 | ||
349 | * elf.c (elfcore_grok_win32pstatus): Fix the offset used to read | |
350 | the tid from a win32pstatus NOTE_INFO_THREAD ELF note. Fix | |
351 | offsets used to read NOTE_INFO_PROCESS. | |
352 | ||
79ddc884 NC |
353 | 2020-08-12 Nick Clifton <nickc@redhat.com> |
354 | ||
355 | * po/ru.po: Updated Russian translation. | |
356 | * po/sr.po: Updated Serbian translation. | |
357 | ||
d844f10a DF |
358 | 2020-08-07 David Faust <david.faust@oracle.com> |
359 | ||
360 | * elf64-bpf.c (bpf_elf_relocate_section): Ensure signed division for | |
361 | DISP16 and DISP32 relocations. | |
362 | ||
3ee9565c DF |
363 | 2020-08-05 David Faust <david.faust@oracle.com> |
364 | ||
365 | * elf64-bpf.c (bpf_elf_generic_reloc): New function. | |
366 | (bpf_elf_howto_table): Use it here. | |
367 | (bpf_elf_relocate_section): Use addends recorded in input_bfd for | |
368 | instruction and data relocations. | |
369 | ||
e44a1d7b AM |
370 | 2020-08-03 Alan Modra <amodra@gmail.com> |
371 | ||
372 | * vms-lib.c (vms_traverse_index): Sanity check size remaining | |
373 | before accessing vms_idx or vms_elfidx. | |
374 | ||
b5f386d5 AM |
375 | 2020-08-03 Alan Modra <amodra@gmail.com> |
376 | ||
377 | PR 26330 | |
378 | * elf.c (_bfd_elf_get_symtab_upper_bound): Sanity check symbol table | |
379 | size against file size. Correct LONG_MAX limit check. | |
380 | (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise. | |
381 | (_bfd_elf_get_reloc_upper_bound): Don't check file size if writing. | |
382 | (_bfd_elf_get_dynamic_reloc_upper_bound): Likewise. | |
383 | * elf64-x86-64-.c (elf_x86_64_get_synthetic_symtab): Use | |
384 | bfd_malloc_and_get_section. | |
385 | ||
a896df97 AM |
386 | 2020-07-31 Alan Modra <amodra@gmail.com> |
387 | ||
388 | PR 26314 | |
389 | * elflink.c (bfd_elf_link_record_dynamic_symbol): Don't allow | |
390 | IR symbols to become dynamic. | |
391 | (elf_link_add_object_symbols): Don't exclude IR symbols when | |
392 | deciding whether an as-needed shared library is needed. | |
393 | ||
4d3bb356 SN |
394 | 2020-07-30 Szabolcs Nagy <szabolcs.nagy@arm.com> |
395 | ||
396 | PR ld/26312 | |
397 | * elfnn-aarch64.c (elfNN_aarch64_init_small_plt0_entry): Set sh_entsize | |
398 | to 0. | |
399 | (elfNN_aarch64_finish_dynamic_sections): Remove sh_entsize setting. | |
400 | ||
c8693053 RO |
401 | 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> |
402 | ||
403 | * bfd.m4 (BFD_SYS_PROCFS_H): New macro. | |
404 | (BFD_HAVE_SYS_PROCFS_TYPE): Require BFD_SYS_PROCFS_H. | |
405 | Don't define _STRUCTURED_PROC. | |
406 | (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Likewise. | |
407 | * elf.c [HAVE_SYS_PROCFS_H] (_STRUCTURED_PROC): Don't define. | |
408 | * configure.ac: Use BFD_SYS_PROCFS_H to check for <sys/procfs.h>. | |
409 | * configure, config.in: Regenerate. | |
410 | * Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS. | |
411 | * Makefile.in, doc/Makefile.in: Regenerate. | |
412 | ||
f1dfbfdb L |
413 | 2020-07-30 H.J. Lu <hongjiu.lu@intel.com> |
414 | ||
415 | * elf-bfd.h (sym_cache): Moved before elf_link_hash_table. | |
416 | (elf_link_hash_table): Add sym_cache. | |
417 | * elf32-arm.c (elf32_arm_link_hash_table): Remove sym_cache. | |
418 | (elf32_arm_check_relocs): Updated. | |
419 | (elf32_arm_size_dynamic_sections): Likewise. | |
420 | * elf32-bfin.c (bfin_link_hash_table): Removed. | |
421 | (bfin_link_hash_newfunc): Updated. | |
422 | (bfin_hash_table): Removed. | |
423 | * elf32-csky.c (csky_elf_link_hash_table): Remove sym_cache. | |
424 | (csky_elf_check_relocs): Updated. | |
425 | * elf32-hppa.c (elf32_hppa_link_hash_table): Remove sym_cache. | |
426 | (elf32_hppa_check_relocs): Updated. | |
427 | * elf32-i386.c (elf_i386_tls_transition): Updated. | |
428 | (elf_i386_convert_load_reloc): Likewise. | |
429 | (elf_i386_check_relocs): Likewise. | |
430 | * elf32-m32r.c (elf_m32r_link_hash_table): Removed. | |
431 | (m32r_elf_hash_table): Updated. | |
432 | (m32r_elf_link_hash_table_create): Likewise. | |
433 | (m32r_elf_create_dynamic_sections): Likewise. | |
434 | (m32r_elf_adjust_dynamic_symbol): Likewise. | |
435 | (allocate_dynrelocs): Likewise. | |
436 | (m32r_elf_size_dynamic_sections): Likewise. | |
437 | (m32r_elf_relocate_section): Likewise. | |
438 | (m32r_elf_finish_dynamic_symbol): Likewise. | |
439 | (m32r_elf_check_relocs): Likewise. | |
440 | * elf32-m68hc1x.h (m68hc11_elf_link_hash_table): Remove | |
441 | sym_cache. | |
442 | * elf32-m68k.c (elf_m68k_link_hash_table): Likewise. | |
443 | (elf_m68k_check_relocs): Updated. | |
444 | * elf32-metag.c (elf_metag_link_hash_table): Remove sym_cache. | |
445 | (elf_metag_check_relocs): Updated. | |
446 | * elf32-microblaze.c (elf32_mb_link_hash_table): Remove sym_sec. | |
447 | (microblaze_elf_check_relocs): Updated. | |
448 | * elf32-nds32.c (nds32_elf_link_hash_table_create): Likewise. | |
449 | (nds32_elf_create_dynamic_sections): Likewise. | |
450 | (nds32_elf_adjust_dynamic_symbol): Likewise. | |
451 | (nds32_elf_check_relocs): Likewise. | |
452 | * elf32-nds32.h (elf_nds32_link_hash_table): Remove sdynbss, | |
453 | srelbss and aym_cache. | |
454 | * elf32-nios2.c (elf32_nios2_link_hash_table): Remove sym_cache. | |
455 | (nios2_elf32_check_relocs): Updated. | |
456 | * elf32-or1k.c (elf_or1k_link_hash_table): Remove sym_sec. | |
457 | (or1k_elf_check_relocs): Updated. | |
458 | * elf32-ppc.c (ppc_elf_check_relocs): Remove sym_cache. | |
459 | (ppc_elf_check_relocs): Updated. | |
460 | * elf32-s390.c (elf_s390_link_hash_table): Remove sym_cache. | |
461 | (elf_s390_check_relocs): Updated. | |
462 | (elf_s390_finish_dynamic_sections): Likewise. | |
463 | * elf32-sh.c (elf_sh_link_hash_table): Remove sdynbss, srelbss | |
464 | and aym_cache. | |
465 | (sh_elf_create_dynamic_sections): Updated. | |
466 | (sh_elf_adjust_dynamic_symbol): Likewise. | |
467 | (sh_elf_size_dynamic_sections): Likewise. | |
468 | (sh_elf_check_relocs): Likewise. | |
469 | * elf32-tic6x.c (elf32_tic6x_link_hash_table): Remove sym_cache. | |
470 | (elf32_tic6x_check_relocs): Updated. | |
471 | * elf32-tilepro.c (tilepro_elf_link_hash_table): Removed. | |
472 | (tilepro_elf_hash_table): Updated. | |
473 | (tilepro_elf_link_hash_table_create): Likewise. | |
474 | (tilepro_elf_check_relocs): Likewise. | |
475 | (tilepro_elf_adjust_dynamic_symbol): Likewise. | |
476 | (allocate_dynrelocs): Likewise. | |
477 | (tilepro_elf_size_dynamic_sections): Likewise. | |
478 | (tilepro_elf_relocate_section): Likewise. | |
479 | (tilepro_elf_finish_dynamic_symbol): Likewise. | |
480 | (tilepro_finish_dyn): Likewise. | |
481 | (tilepro_elf_finish_dynamic_sections): Likewise. | |
482 | * elf64-ppc.c (ppc_link_hash_table): Remove sym_cache. | |
483 | (ppc64_elf_before_check_relocs): Updated. | |
484 | (ppc64_elf_check_relocs): Likewise. | |
485 | * elf64-s390.c (elf_s390_link_hash_table): Remove sym_cache. | |
486 | (elf_s390_check_relocs): Updated. | |
487 | (elf_s390_relocate_section): Likewise. | |
488 | (elf_s390_finish_dynamic_sections): Likewise. | |
489 | * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise. | |
490 | (elf_x86_64_check_relocs): Likewise. | |
491 | * elfnn-aarch64.c (elf_aarch64_link_hash_table): Remove | |
492 | sym_cache. | |
493 | (elfNN_aarch64_check_relocs): Updated. | |
494 | * elfnn-riscv.c (riscv_elf_link_hash_table): Remove sym_cache. | |
495 | (riscv_elf_check_relocs): Updated. | |
496 | * elfxx-mips.c (mips_elf_link_hash_table): Remove sym_cache. | |
497 | (mips_elf_resolve_got_page_ref): Updated. | |
498 | * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise. | |
499 | * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Remove | |
500 | sym_cache. | |
501 | * elfxx-tilegx.c (tilegx_elf_link_hash_table): Likewise. | |
502 | (tilegx_elf_check_relocs): Updated. | |
503 | * elfxx-x86.h (elf_x86_link_hash_table): Remove sym_cache. | |
504 | ||
c77cb2a0 MR |
505 | 2020-07-29 Maciej W. Rozycki <macro@linux-mips.org> |
506 | ||
507 | * elflink.c (bfd_elf_final_link): Give local symbols a name if | |
508 | so requested. | |
509 | * elfxx-mips.c (_bfd_mips_elf_name_local_section_symbols): Only | |
510 | return TRUE if making ET_REL output. | |
511 | ||
3f1b17bb MR |
512 | 2020-07-29 Maciej W. Rozycki <macro@linux-mips.org> |
513 | ||
514 | * elf-bfd.h (elf_backend_data): Add | |
515 | `elf_backend_elfsym_local_is_section' member. | |
516 | * elfxx-target.h (elf_backend_elfsym_local_is_section): New | |
517 | macro. | |
518 | (elfNN_bed): Add `elf_backend_elfsym_local_is_section' member. | |
519 | * elflink.c (bfd_elf_final_link): Use it to determine whether | |
520 | set the `.symtab' section's `sh_info' value to the index of the | |
521 | first non-local or non-section symbol. | |
522 | * elf32-mips.c (mips_elf32_elfsym_local_is_section): New | |
523 | function. | |
524 | (elf_backend_elfsym_local_is_section): New macro. | |
525 | * elfn32-mips.c (mips_elf_n32_elfsym_local_is_section): New | |
526 | function. | |
527 | (elf_backend_elfsym_local_is_section): New macro. | |
528 | ||
4d68fd75 AM |
529 | 2020-07-29 Alan Modra <amodra@gmail.com> |
530 | ||
531 | * elflink.c (bfd_elf_final_link): Don't segfault on local dynsyms | |
532 | defined in excluded sections. | |
533 | ||
67411cbf AM |
534 | 2020-07-28 Alan Modra <amodra@gmail.com> |
535 | ||
536 | * elf.c (assign_section_numbers): Comment. Don't segfault on | |
537 | discarded sections when setting linked-to section for generic | |
538 | ELF linker. | |
539 | * elflink.c (bfd_elf_match_symbols_in_sections): Allow NULL info. | |
540 | ||
93fd13c7 AM |
541 | 2020-07-27 Alan Modra <amodra@gmail.com> |
542 | ||
543 | * xcofflink.c (xcoff_need_ldrel_p): Accept --just-symbols symbols and | |
544 | similar as absolute. | |
545 | (bfd_xcoff_import_symbol): Don't fuss over absolute symbol | |
546 | redefinitions here. | |
547 | ||
04f096fb NC |
548 | 2020-07-24 Nick Clifton <nickc@redhat.com> |
549 | ||
550 | * config.bfd: Move xc16x target to the obsolete list. | |
551 | ||
5efb6779 KB |
552 | 2020-07-22 Kevin Buettner <kevinb@redhat.com> |
553 | ||
554 | * binary.c (binary_get_section_contents): Seek using offset | |
555 | from section's file position. | |
556 | ||
ea57e509 KB |
557 | 2020-07-22 Kevin Buettner <kevinb@redhat.com> |
558 | ||
559 | * elf.c (_bfd_elf_make_section_from_phdr): Remove hack for GDB. | |
04f096fb | 560 | |
1ad2776d MF |
561 | 2020-07-22 Max Filippov <jcmvbkbc@gmail.com> |
562 | ||
563 | PR 26246 | |
564 | * elf32-xtensa.c (removed_literal_compare): Use correct pointer | |
565 | type for the first function argument. Rename pointers to reflect | |
566 | that they have distinct types. | |
567 | ||
2f5541f3 AM |
568 | 2020-07-20 Alan Modra <amodra@gmail.com> |
569 | ||
570 | * elflink.c (_bfd_elf_gc_keep): Use bfd_is_const_section. | |
571 | ||
e10a07b3 AM |
572 | 2020-07-19 Alan Modra <amodra@gmail.com> |
573 | ||
574 | * elf64-ppc.c (struct ppc_link_hash_table): Add has_power10_relocs. | |
575 | (select_alt_stub): New function. | |
576 | (ppc_get_stub_entry): Use it here. | |
577 | (ppc64_elf_check_relocs): Set had_power10_relocs rather than | |
578 | power10_stubs. | |
579 | (ppc64_elf_size_stubs): Clear power10_stubs here instead. Don't | |
580 | merge notoc stubs with other varieties when power10_stubs is "auto". | |
581 | Instead dup the stub hash table entry. | |
582 | (plt_stub_size, ppc_build_one_stub, ppc_size_one_stub): Adjust | |
583 | tests of power10_stubs. | |
584 | ||
28b80303 AM |
585 | 2020-07-15 Alan Modra <amodra@gmail.com> |
586 | ||
587 | PR 26239 | |
588 | * coffgen.c (_bfd_coff_close_and_cleanup): Free dwarf2 info. | |
589 | ||
4fd8d585 NC |
590 | 2020-07-15 Nick Clifton <nickc@redhat.com> |
591 | ||
592 | PR26240 | |
593 | * coffgen.c (coff_get_normalized_symtab): Fix off-by-one error in | |
594 | check for aux entries that overflow the buufer. | |
595 | ||
a8a48c75 HPN |
596 | 2020-07-15 Hans-Peter Nilsson <hp@bitrange.com> |
597 | ||
598 | * elf64-mmix.c (mmix_elf_relax_section): Improve accounting for | |
599 | R_MMIX_PUSHJ_STUBBABLE relocs against undefined symbols. | |
600 | ||
e8a83e93 MB |
601 | 2020-07-15 Markus Böck <markus.boeck02@gmail.com> |
602 | Alan Modra <amodra@gmail.com> | |
603 | ||
604 | PR 26198 | |
605 | * coffgen.c (_bfd_coff_section_already_linked): Allow for plugin | |
606 | objects both before and after normal object files. | |
607 | * elflink.c (_bfd_elf_section_already_linked): Likewise. | |
608 | ||
d3b10ee7 AM |
609 | 2020-07-10 Alan Modra <amodra@gmail.com> |
610 | ||
611 | * elf64-ppc.h (struct ppc64_elf_params): Add power10_stubs. | |
612 | * elf64-ppc.c (struct ppc_link_hash_table): Delete | |
613 | power10_stubs. | |
614 | (ppc64_elf_check_relocs): Adjust setting of power10_stubs. | |
615 | (plt_stub_size, ppc_build_one_stub, ppc_size_one_stub): Adjust | |
616 | uses of power10_stubs. | |
617 | ||
fe49679d AM |
618 | 2020-07-09 Alan Modra <amodra@gmail.com> |
619 | ||
620 | * coff-ppc.c: Delete. | |
621 | * pe-ppc.c: Delete. | |
622 | * pei-ppc.c: Delete. | |
623 | * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Remove PE PPC. | |
624 | * coffcode.h (coff_set_arch_mach_hook, coff_set_flags): Remove | |
625 | PPCMAGIC code. | |
626 | (coff_write_object_contents): Remove PPC_PE code. | |
627 | * config.bfd: Move powerpcle-pe to removed targets. | |
628 | * configure.ac: Remove powerpc PE entries. | |
629 | * libcoff-in.h (ppc_allocate_toc_section): Delete. | |
630 | (ppc_process_before_allocation): Delete. | |
631 | * peXXigen.c: Remove POWERPC_LE_PE code and comments. | |
632 | * targets.c: Remove powerpc PE vectors. | |
633 | * po/SRC-POTFILES.in: Regenerate. | |
634 | * libcoff.h: Regenerate. | |
635 | * Makefile.in: Regenerate. | |
636 | * configure: Regenerate. | |
637 | ||
7646efdf NC |
638 | 2020-07-09 Nick Clifton <nickc@redhat.com> |
639 | ||
640 | * po/fr.po: Updated French translation. | |
641 | ||
23f5e55e AM |
642 | 2020-07-07 Alan Modra <amodra@gmail.com> |
643 | ||
644 | * xcofflink.c (xcoff_mark): Don't mark const sections. | |
645 | (bfd_xcoff_record_link_assignment): Add FIXME. | |
646 | (_bfd_xcoff_bfd_final_link): Don't segfault on assorted magic | |
647 | sections being discarded by linker script. | |
648 | ||
c8001886 AM |
649 | 2020-07-07 Alan Modra <amodra@gmail.com> |
650 | ||
651 | * coff-rs6000.c (xcoff_write_archive_contents_old): Set default | |
652 | time, uid, gid and mode for deterministic archive. | |
653 | (xcoff_write_archive_contents_big): Likewise. | |
654 | ||
8af7926f AM |
655 | 2020-07-07 Alan Modra <amodra@gmail.com> |
656 | ||
657 | * coffcode.h (coff_classify_symbol): Handle C_HIDEXT and | |
658 | C_AIX_WEAKEXT. | |
659 | ||
17550be7 NC |
660 | 2020-07-06 Nick Clifton <nickc@redhat.com> |
661 | ||
662 | * po/pt.po: Updated Portuguese translation. | |
663 | * po/uk.po: Updated Ukranian translation. | |
664 | ||
b4396c5e NC |
665 | 2020-07-04 Nick Clifton <nickc@redhat.com> |
666 | ||
667 | * version.m4: Set version to 2.35.50. | |
668 | * configure: Regenerate. | |
669 | * po/bbfd.pot: Regenerate. | |
670 | ||
b115b9fd NC |
671 | 2020-07-04 Nick Clifton <nickc@redhat.com> |
672 | ||
673 | Binutils 2.35 branch created. | |
674 | ||
33d1369f AM |
675 | 2020-07-01 Alan Modra <amodra@gmail.com> |
676 | ||
677 | PR 26188 | |
678 | * coffgen.c (coff_find_nearest_line_with_names): Sanity check | |
679 | raw syment index before dereferencing. | |
680 | ||
cc574a35 AM |
681 | 2020-07-01 Alan Modra <amodra@gmail.com> |
682 | ||
683 | * elf32-i386.c (elf_backend_object_p): Undef for vxworks. | |
684 | ||
3443489c AM |
685 | 2020-07-01 Alan Modra <amodra@gmail.com> |
686 | ||
687 | * config.bfd: Obsolete xc16x. | |
688 | ||
bbd19b19 L |
689 | 2020-06-30 H.J. Lu <hongjiu.lu@intel.com> |
690 | ||
691 | * archures.c (bfd_mach_i386_nacl): Removed. | |
692 | (bfd_mach_i386_i386_nacl): Likewise. | |
693 | (bfd_mach_x86_64_nacl): Likewise. | |
694 | (bfd_mach_x64_32_nacl): Likewise. | |
695 | * config.bfd: Remove *-*-nacl* targets. | |
696 | * configure.ac: Remove x86 NaCl target vectors. | |
697 | * cpu-i386.c (bfd_arch_i386_onebyte_nop_fill): Removed. | |
698 | (bfd_x64_32_nacl_arch): Likewise. | |
699 | (bfd_x86_64_nacl_arch): Likewise. | |
700 | (bfd_i386_nacl_arch): Likewise. | |
701 | (bfd_x64_32_arch_intel_syntax): Updated. | |
702 | * elf32-i386.c: Don't include "elf-nacl.h". | |
703 | (elf_i386_nacl_plt): Removed. | |
704 | (elf_i386_nacl_plt0_entry): Likewise. | |
705 | (elf_i386_nacl_plt_entry): Likewise. | |
706 | (elf_i386_nacl_pic_plt0_entry): Likewise. | |
707 | (elf_i386_nacl_pic_plt_entry): Likewise. | |
708 | (elf_i386_nacl_eh_frame_plt): Likewise. | |
709 | (elf_i386_nacl_plt): Likewise. | |
710 | (elf32_i386_nacl_elf_object_p): Likewise. | |
711 | (elf_i386_get_synthetic_symtab): Updated. | |
712 | (elf_i386_link_setup_gnu_properties): Likewise. | |
713 | * elf64-x86-64.c: Don't include "elf-nacl.h". | |
714 | (elf_x86_64_nacl_plt): Removed. | |
715 | (elf64_x86_64_nacl_elf_object_p): Likewise. | |
716 | (elf_x86_64_nacl_plt0_entry): Likewise. | |
717 | (elf_x86_64_nacl_plt_entry): Likewise. | |
718 | (elf_x86_64_nacl_eh_frame_plt): Likewise. | |
719 | (elf_x86_64_nacl_plt): Likewise. | |
720 | (elf32_x86_64_nacl_elf_object_p): Likewise. | |
721 | (elf_x86_64_get_synthetic_symtab): Updated. | |
722 | (elf_x86_64_link_setup_gnu_properties): Likewise. | |
723 | * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Likewise. | |
724 | * targets.c: Remove x86 NaCl target vectors. | |
725 | * bfd-in2.h: Regenerated. | |
726 | * configure: Likewise. | |
727 | ||
a57f74bb L |
728 | 2020-06-29 H.J. Lu <hongjiu.lu@intel.com> |
729 | ||
730 | * elf32-tic6x.c (elf32_tic6x_size_dynamic_sections): Call | |
731 | _bfd_elf_add_dynamic_tags. | |
732 | ||
07d22f64 AM |
733 | 2020-06-29 Alan Modra <amodra@gmail.com> |
734 | ||
735 | * peXXigen.c (_bfd_XXi_slurp_codeview_record): Properly check | |
736 | return value of bfd_bread. Don't read more than requested length. | |
737 | Sanity check length. Properly terminate file name. | |
738 | ||
279edac5 AM |
739 | 2020-06-29 Alan Modra <amodra@gmail.com> |
740 | ||
741 | * arc-got.h: Use C style comments. | |
742 | * coff-z80.c: Likewise. | |
743 | * elf32-csky.c: Likewise. | |
744 | * peXXigen.c: Likewise. | |
745 | * elf32-m32c.c (m32c_elf_relax_delete_bytes): Remove commented out | |
746 | code. | |
747 | ||
85f7484a PB |
748 | 2020-06-26 Pat Bernardi <bernardi@adacore.com> |
749 | ||
750 | * elf32-m68k.c (m68k_elf_merge_obj_attributes): New function. | |
751 | (elf32_m68k_merge_private_bfd_data): Merge GNU attributes. | |
752 | ||
ba9b3ef5 AM |
753 | 2020-06-26 Alan Modra <amodra@gmail.com> |
754 | ||
755 | * elfxx-riscv.c (struct priv_spec_t, priv_specs), | |
756 | (riscv_get_priv_spec_class, riscv_get_priv_spec_class_from_numbers), | |
757 | (riscv_get_priv_spec_name): Move to.. | |
758 | * cpu-riscv.c: ..here. | |
759 | (riscv_get_priv_spec_class_from_numbers): Don't xmalloc temp buffer. | |
760 | Use %u to print unsigned numbers. | |
761 | ||
069057bf AB |
762 | 2020-06-24 Andrew Burgess <andrew.burgess@embecosm.com> |
763 | ||
764 | * cpu-riscv.c (riscv_scan): Don't allow shorter matches using the | |
765 | default architecture. | |
766 | ||
2c8e3708 L |
767 | 2020-06-24 H.J. Lu <hongjiu.lu@intel.com> |
768 | ||
769 | PR ld/26083 | |
770 | * elf32-csky.c (csky_elf_size_dynamic_sections): Call | |
771 | _bfd_elf_add_dynamic_tags. | |
772 | ||
c679ec98 L |
773 | 2020-06-24 H.J. Lu <hongjiu.lu@intel.com> |
774 | ||
775 | PR ld/26083 | |
776 | * elf32-cris.c (elf_cris_size_dynamic_sections): Call | |
777 | _bfd_elf_add_dynamic_tags. | |
778 | ||
f8b1e5f6 AM |
779 | 2020-06-24 Alan Modra <amodra@gmail.com> |
780 | ||
781 | * vms-alpha.c (_bfd_vms_slurp_etir <ETIR__C_OPR_ASH>): Implement | |
782 | shifts without undefined behaviour. | |
783 | ||
3084d7a2 L |
784 | 2020-06-23 H.J. Lu <hongjiu.lu@intel.com> |
785 | ||
786 | * elf-bfd.h (elf_link_hash_table): Add dt_pltgot_required and | |
787 | dt_jmprel_required. | |
788 | (_bfd_elf_add_dynamic_tags): New. | |
789 | * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Call | |
790 | _bfd_elf_add_dynamic_tags. | |
791 | * elf32-arc.c (elf_arc_size_dynamic_sections): Likewise. | |
792 | * elf32-bfin.c (elf32_bfinfdpic_size_dynamic_sections): Likewise. | |
793 | * elf32-cr16.c (_bfd_cr16_elf_size_dynamic_sections): Likewise. | |
794 | * elf32-frv.c (elf32_frvfdpic_size_dynamic_sections): Likewise. | |
795 | * elf32-lm32.c (lm32_elf_size_dynamic_sections): Likewise. | |
796 | * elf32-m32r.c (m32r_elf_size_dynamic_sections): Likewise. | |
797 | * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise. | |
798 | * elf32-microblaze.c (microblaze_elf_size_dynamic_sections): | |
799 | Likewise. | |
800 | * elf32-nds32.c (nds32_elf_size_dynamic_sections): Likewise. | |
801 | * elf32-nios2.c (nios2_elf32_size_dynamic_sections): Likewise. | |
802 | * elf32-or1k.c (or1k_elf_size_dynamic_sections): Likewise. | |
803 | * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise. | |
804 | * elf32-tilepro.c (tilepro_elf_size_dynamic_sections): Likewise. | |
805 | * elf32-vax.c (elf_vax_size_dynamic_sections): Likewise. | |
806 | * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise. | |
807 | * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise. | |
808 | * elfnn-aarch64.c (elfNN_aarch64_size_dynamic_sections): | |
809 | Likewise. | |
810 | * elfnn-riscv.c (riscv_elf_size_dynamic_sections): Likewise. | |
811 | * elfxx-tilegx.c (tilegx_elf_size_dynamic_sections): Likewise. | |
812 | * elf32-arm.c (elf32_arm_size_dynamic_sections): Call | |
813 | _bfd_elf_maybe_vxworks_add_dynamic_tags. | |
814 | * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise. | |
815 | * elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): | |
816 | Likewise. | |
817 | * elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Likewise. | |
818 | (_bfd_x86_elf_size_dynamic_sections): Likewise. | |
819 | * elfxx-x86.h (elf_x86_link_hash_table): Remove dt_reloc, | |
820 | dt_reloc_sz and dt_reloc_ent. | |
821 | * elf-vxworks.c (_bfd_elf_maybe_vxworks_add_dynamic_tags): New. | |
822 | * elf-vxworks.h (_bfd_elf_maybe_vxworks_add_dynamic_tags): | |
823 | Likewise. | |
824 | * elf32-hppa.c (elf32_hppa_link_hash_table_create): Set | |
825 | etab.dt_pltgot_required. | |
826 | (elf32_hppa_size_dynamic_sections): Call | |
827 | _bfd_elf_add_dynamic_tags. | |
828 | * elf32-metag.c (elf_metag_link_hash_table_create): Set | |
829 | etab.dt_pltgot_required. | |
830 | (elf_metag_size_dynamic_sections): Call _bfd_elf_add_dynamic_tags. | |
831 | * elf32-sh.c (sh_elf_link_hash_table_create): Set | |
832 | root.dt_pltgot_required for FDPIC output. | |
833 | (sh_elf_size_dynamic_sections): Call | |
834 | _bfd_elf_maybe_vxworks_add_dynamic_tags. | |
835 | * elf32-xtensa.c (elf_xtensa_link_hash_table_create): Set | |
836 | elf.dt_pltgot_required. | |
837 | (elf_xtensa_size_dynamic_sections): Call | |
838 | _bfd_elf_add_dynamic_tags. | |
839 | * elf64-hppa.c (elf64_hppa_hash_table_create): Set | |
840 | root.dt_pltgot_required. | |
841 | (elf64_hppa_size_dynamic_sections): Call | |
842 | _bfd_elf_add_dynamic_tags. | |
843 | * elfnn-ia64.c (elfNN_ia64_hash_table_create): Set | |
844 | root.dt_pltgot_required. | |
845 | (elfNN_ia64_size_dynamic_sections): Set root.dt_jmprel_required | |
846 | for rel_pltoff_sec. Call _bfd_elf_add_dynamic_tags. | |
847 | * elflink.c (_bfd_elf_add_dynamic_tags): New. | |
848 | ||
d768f160 SJ |
849 | 2020-06-22 Saagar Jha <saagar@saagarjha.com> |
850 | ||
851 | * mach-o.c: Support the new load commands by reading a linkedit | |
852 | data command for them. | |
853 | ||
39ff0b81 NC |
854 | 2020-06-22 Nelson Chu <nelson.chu@sifive.com> |
855 | ||
856 | * elfxx-riscv.c (struct priv_spec_t priv_specs[]): Move them from | |
857 | opcodes/riscv-opc.c to bfd/elfxx-riscv.c, since we need it in linker. | |
858 | (riscv_get_priv_spec_class): Likewise. | |
859 | (riscv_get_priv_spec_name): Likewise. | |
860 | (riscv_get_priv_spec_class_from_numbers): New function, convert | |
861 | the version numbers into string, then call riscv_get_priv_spec_class | |
862 | to get the priv spec class. | |
863 | * elfxx-riscv.h (riscv_get_priv_spec_class): Move forward declaration | |
864 | from include/opcode/riscv.h to bfd/elfxx-riscv.h. | |
865 | (riscv_get_priv_spec_name): Likewise. | |
866 | (riscv_get_priv_spec_class_from_numbers): New forward declaration. | |
867 | (opcode/riscv.h): Include it in the header rather than elfxx-riscv.c. | |
868 | * elfnn-riscv.c (riscv_merge_attributes): Get the priv spec classes | |
869 | of input and output objects form their priv spec attributes by | |
870 | riscv_get_priv_spec_class_from_numbers. Report warning rather than | |
871 | errors when linking objects with differnet priv spec versions. We do | |
872 | know v1.9.1 may have conflicts to other versions, so report the | |
873 | warning, too. After that, update the output priv spec version to the | |
874 | newest one so far. | |
875 | ||
cbd7581f NC |
876 | 2020-06-22 Nelson Chu <nelson.chu@sifive.com> |
877 | ||
878 | * elfnn-riscv.c (riscv_merge_attributes): Once we meet one of the | |
879 | priv attributes, we will check the conflicts for all of them (major, | |
880 | minor and revision), and then set the priv_attrs_merged to TRUE to | |
881 | indicate that we have handled all of the priv attributes. Remove | |
882 | the unused boolean priv_may_conflict, in_priv_zero and out_priv_zero. | |
883 | ||
1e927850 AM |
884 | 2020-06-21 Alan Modra <amodra@gmail.com> |
885 | ||
886 | PR 26132 | |
887 | * configure.ac: Disable plugins by default for some targets. | |
888 | * plugin.c: Comment typo fix. | |
889 | * configure: Regenerate. | |
890 | ||
13aa5ceb NC |
891 | 2020-06-19 Nick Clifton <nickc@redhat.com> |
892 | ||
893 | * plugin.c (try_load_plugin): Suppress the error message about | |
894 | being unable to open a plugin if creating a list of viable | |
895 | plugins. | |
896 | ||
a435742a AM |
897 | 2020-06-16 Alan Modra <amodra@gmail.com> |
898 | ||
899 | * aout-tic30.c: Delete file. | |
900 | * Makefile.am (BFD32_BACKENDS): Remove aout-tic30.lo. | |
901 | (BFD32_BACKENDS_CFILES): Remove aout-tic30.c. | |
902 | * config.bfd (c30-*-*aout*, tic30-*-*aout*): Remove entry. | |
903 | (xc16x-*-elf): Sort properly. | |
904 | * configure.ac: Remove tic30_aout_vec. | |
905 | * targets.c: Likewise. | |
906 | * Makefile.in: Regenerate. | |
907 | * configure: Regenerate. | |
908 | * po/SRC-POTFILES.in: Regenerate. | |
909 | ||
7a77f1ac MF |
910 | 2020-06-15 Max Filippov <jcmvbkbc@gmail.com> |
911 | ||
912 | * elf32-xtensa.c (XSHAL_ABI, XTHAL_ABI_UNDEFINED) | |
913 | (XTHAL_ABI_WINDOWED, XTHAL_ABI_CALL0): New macros. | |
914 | (elf32xtensa_abi): New global variable. | |
915 | (xtensa_abi_choice): New function. | |
916 | (elf_xtensa_create_plt_entry): Use xtensa_abi_choice instead of | |
917 | XSHAL_ABI to select PLT code. | |
918 | ||
cae64165 RM |
919 | 2020-06-15 Roland McGrath <mcgrathr@google.com> |
920 | ||
921 | * elflink.c (bfd_elf_define_start_stop): Use start_stop_visibility | |
922 | field of bfd_link_info. | |
923 | ||
40be168c AM |
924 | 2020-06-15 Alan Modra <amodra@gmail.com> |
925 | ||
926 | * config.bfd: Obsolete powerpcle-*-pe targets. | |
927 | ||
75cfe082 AM |
928 | 2020-06-15 Alan Modra <amodra@gmail.com> |
929 | ||
930 | PR 26103 | |
931 | * elflink.c (elf_link_add_archive_symbols): Exclude undefined | |
932 | symbols that were defined in discarded sections. | |
933 | * cofflink.c (coff_link_check_archive_element): Likewise. | |
934 | (coff_link_add_symbols): Set indx to -3 for symbols defined in | |
935 | discarded sections. | |
936 | (_bfd_coff_write_global_sym): Don't emit such symbols. | |
937 | libcoff-in.h (struct coff_link_hash_entry): Update indx comment. | |
938 | libcoff.h: Regenerate. | |
939 | ||
f0aa3025 AM |
940 | 2020-06-11 Alan Modra <amodra@gmail.com> |
941 | ||
942 | PR 26107 | |
943 | * pdp11.c (is_stab): Replace legacy "index" function with "strchr". | |
944 | ||
447f6d86 L |
945 | 2020-06-10 H.J. Lu <hongjiu.lu@intel.com> |
946 | ||
947 | * elfnn-ia64.c (elfNN_ia64_link_hash_table): Remove reltext. | |
948 | (allocate_dynrel_entries): Set DF_TEXTREL instead of reltext. | |
949 | (elfNN_ia64_size_dynamic_sections): Check DF_TEXTREL instead | |
950 | of reltext. | |
951 | ||
e1b5d517 L |
952 | 2020-06-10 H.J. Lu <hongjiu.lu@intel.com> |
953 | ||
954 | PR ld/26094 | |
955 | * elflink.c (bfd_elf_define_start_stop): Handle common symbols. | |
956 | Clear verinfo.verdef. | |
957 | ||
cebd6b8a L |
958 | 2020-06-09 H.J. Lu <hongjiu.lu@intel.com> |
959 | ||
960 | PR ld/18801 | |
961 | * elf-bfd.h (elf_link_hash_table): Add ifunc_resolvers. | |
962 | (_bfd_elf_allocate_ifunc_dyn_relocs): Remove the | |
963 | bfd_boolean * argument. Set ifunc_resolvers if there are IFUNC | |
964 | resolvers. | |
965 | * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Updated. | |
966 | Set ifunc_resolvers if there are FUNC resolvers. | |
967 | * elf64-ppc.c (ppc_link_hash_table): Remove local_ifunc_resolver. | |
968 | (build_global_entry_stubs_and_plt): Replace local_ifunc_resolver | |
969 | with elf.ifunc_resolvers. | |
970 | (write_plt_relocs_for_local_syms): Likewise. | |
971 | (ppc64_elf_relocate_section): Likewise. | |
972 | (ppc64_elf_finish_dynamic_sections): Likewise. | |
973 | * elfnn-aarch64.c (elfNN_aarch64_allocate_ifunc_dynrelocs): | |
974 | Updated. | |
975 | * elfxx-x86.c (elf_x86_allocate_dynrelocs): Likewise. | |
976 | (_bfd_x86_elf_size_dynamic_sections): Check elf.ifunc_resolvers | |
977 | instead of readonly_dynrelocs_against_ifunc. | |
978 | * elfxx-x86.h (elf_x86_link_hash_table): Remove | |
979 | readonly_dynrelocs_against_ifunc. | |
980 | ||
efb2a7b4 AM |
981 | 2020-06-09 Alan Modra <amodra@gmail.com> |
982 | ||
983 | * elf64-ppc.c (struct ppc_link_hash_table): Delete | |
984 | maybe_local_ifunc_resolver field. | |
985 | (build_global_entry_stubs_and_plt): Set local_ifunc_resolver in | |
986 | cases where maybe_local_ifunc_resolver was set. | |
987 | (ppc64_elf_relocate_section): Likewise. | |
988 | (ppc64_elf_finish_dynamic_sections): Downgrade ifunc with textrel | |
989 | error to a warning. | |
990 | ||
9bcc30e4 L |
991 | 2020-06-08 H.J. Lu <hongjiu.lu@intel.com> |
992 | ||
993 | * elf-bfd.h (elf_link_hash_entry): Add tlsdesc_plt and | |
994 | tlsdesc_got. | |
995 | * elf32-arm.c (elf32_arm_link_hash_table): Remove tlsdesc_plt | |
996 | and dt_tlsdesc_got. | |
997 | (elf32_arm_size_dynamic_sections): Updated. Clear | |
998 | root.tlsdesc_plt for DF_BIND_NOW. | |
999 | (elf32_arm_finish_dynamic_sections): Updated. | |
1000 | (elf32_arm_output_arch_local_syms): Likewise. | |
1001 | * elf32-nds32.c (nds32_elf_size_dynamic_sections): Updated. | |
1002 | Clear root.tlsdesc_plt for DF_BIND_NOW. | |
1003 | (nds32_elf_finish_dynamic_sections): Updated. | |
1004 | * elf32-nds32.h (elf_nds32_link_hash_table): Remove | |
1005 | dt_tlsdesc_plt and dt_tlsdesc_got. | |
1006 | * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Updated. | |
1007 | * elfnn-aarch64.c (elf_aarch64_link_hash_table): Remove | |
1008 | tlsdesc_plt and dt_tlsdesc_got. | |
1009 | (elfNN_aarch64_allocate_dynrelocs): Updated. | |
1010 | (elfNN_aarch64_finish_dynamic_sections): Likewise. | |
1011 | (elfNN_aarch64_size_dynamic_sections): Updated. Clear | |
1012 | root.tlsdesc_plt for DF_BIND_NOW. Don't check DF_BIND_NOW | |
1013 | twice. | |
1014 | * elfxx-x86.c (elf_x86_allocate_dynrelocs): Updated. | |
1015 | (_bfd_x86_elf_size_dynamic_sections): Likewise. | |
1016 | (_bfd_x86_elf_finish_dynamic_sections): Likewise. | |
1017 | * elfxx-x86.h (elf_x86_link_hash_table): Remove tlsdesc_plt and | |
1018 | tlsdesc_got. | |
1019 | ||
845b83d7 L |
1020 | 2020-06-07 H.J. Lu <hongjiu.lu@intel.com> |
1021 | ||
1022 | * elf32-tic6x.c (elf32_bed): Defined the default to | |
1023 | elf32_tic6x_bed. | |
1024 | ||
9b8a8575 L |
1025 | 2020-06-07 H.J. Lu <hongjiu.lu@intel.com> |
1026 | ||
1027 | * elf64-hppa.c (elf64_hppa_link_hash_table): Remove plt_sec and | |
1028 | plt_rel_sec. | |
1029 | (elf64_hppa_check_relocs): Replace plt_sec/plt_rel_sec with | |
1030 | root.splt/root.srelplt. | |
1031 | (elf64_hppa_create_dynamic_sections): Likewise. | |
1032 | (elf64_hppa_size_dynamic_sections): Likewise. | |
1033 | (elf64_hppa_finish_dynamic_symbol): Likewise. | |
1034 | (elf_hppa_final_link): Likewise. | |
1035 | (elf_hppa_final_link_relocate): Likewise. | |
1036 | ||
bcab203d L |
1037 | 2020-06-06 H.J. Lu <hongjiu.lu@intel.com> |
1038 | ||
1039 | * elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): Updated. | |
1040 | * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Remove | |
1041 | is_vxworks. | |
1042 | ||
90c14f0c L |
1043 | 2020-06-06 H.J. Lu <hongjiu.lu@intel.com> |
1044 | ||
1045 | * elf-bfd.h (elf_target_os): New. | |
1046 | (elf_link_hash_table): Add target_os. | |
1047 | (elf_backend_data): Add target_os. | |
1048 | * elf32-arm.c (elf32_arm_link_hash_table): Remove vxworks_p, | |
1049 | symbian_p and nacl_p. | |
1050 | (create_got_section): Updated. | |
1051 | (elf32_arm_create_dynamic_sections): Likewise. | |
1052 | (arm_type_of_stub): Likewise. | |
1053 | (elf32_arm_create_or_find_stub_sec): Likewise. | |
1054 | (elf32_arm_allocate_plt_entry): Likewise. | |
1055 | (elf32_arm_populate_plt_entry): Likewise. | |
1056 | (elf32_arm_final_link_relocate): Likewise. | |
1057 | (elf32_arm_check_relocs): Likewise. | |
1058 | (allocate_dynrelocs_for_symbol): Likewise. | |
1059 | (elf32_arm_finish_dynamic_symbol): Likewise. | |
1060 | (elf32_arm_finish_dynamic_sections): Likewise. | |
1061 | (elf32_arm_output_plt_map_1): Likewise. | |
1062 | (elf32_arm_output_arch_local_syms): Likewise. | |
1063 | (elf32_arm_add_symbol_hook): Likewise. | |
1064 | (elf32_arm_nacl_link_hash_table_create): Likewise. | |
1065 | (elf32_arm_vxworks_link_hash_table_create): Likewise. | |
1066 | (elf32_arm_symbian_link_hash_table_create): Likewise. | |
1067 | (ELF_TARGET_OS): New. | |
1068 | * elf32-i386.c (elf_i386_arch_bed): Removed. | |
1069 | (elf_backend_arch_data): Likewise. | |
1070 | (elf_i386_solaris_arch_bed): Likewise. | |
1071 | (elf_i386_nacl_arch_bed): Likewise. | |
1072 | (elf_i386_vxworks_arch_bed): Likewise. | |
1073 | (elf_i386_relocate_section): Updated. | |
1074 | (elf_i386_finish_dynamic_sections): Likewise. | |
1075 | (elf_i386_get_synthetic_symtab): Likewise. | |
1076 | (elf_i386_link_setup_gnu_properties): Likewise. | |
1077 | (ELF_TARGET_OS): New. | |
1078 | * elf32-mips.c (ELF_TARGET_OS): New. | |
1079 | * elf32-ppc.c (ppc_elf_link_hash_table): Remove is_vxworks. | |
1080 | (ppc_elf_create_got): Updated. | |
1081 | (ppc_elf_create_dynamic_sections): Likewise. | |
1082 | (ppc_elf_check_relocs): Likewise. | |
1083 | (ppc_elf_adjust_dynamic_symbol): Likewise. | |
1084 | (ppc_elf_size_dynamic_sections): Likewise. | |
1085 | (ppc_elf_relocate_section): Likewise. | |
1086 | (ppc_elf_finish_dynamic_sections): Likewise. | |
1087 | (ppc_elf_vxworks_link_hash_table_create): Likewise. | |
1088 | (ELF_TARGET_OS): New. | |
1089 | * elf32-sh.c (elf_sh_link_hash_table): Remove vxworks_p. | |
1090 | (sh_elf_link_hash_table_create): Updated. | |
1091 | (sh_elf_create_dynamic_sections): Likewise. | |
1092 | (allocate_dynrelocs): Likewise. | |
1093 | (sh_elf_size_dynamic_sections): Likewise. | |
1094 | (sh_elf_relocate_section): Likewise. | |
1095 | (sh_elf_finish_dynamic_symbol): Likewise. | |
1096 | (sh_elf_finish_dynamic_sections): Likewise. | |
1097 | (ELF_TARGET_OS): New. | |
1098 | * elf32-sparc.c (elf32_sparc_vxworks_link_hash_table_create): | |
1099 | Removed. | |
1100 | (bfd_elf32_bfd_link_hash_table_create): Likewise. | |
1101 | (ELF_TARGET_OS): New. | |
1102 | * elf64-x86-64.c (elf_x86_64_arch_bed): Removed. | |
1103 | (elf_x86_64_solaris_arch_bed): Likewise. | |
1104 | (elf_x86_64_nacl_arch_bed): Likewise. | |
1105 | (elf_x86_64_finish_dynamic_sections): Updated. | |
1106 | (elf_x86_64_get_synthetic_symtab): Likewise. | |
1107 | (elf_x86_64_link_setup_gnu_properties): Likewise. | |
1108 | (ELF_TARGET_OS): New. | |
1109 | * elflink.c (_bfd_elf_link_hash_table_init): Initialize | |
1110 | target_o. | |
1111 | * elfxx-mips.c (mips_elf_link_hash_table): Remove is_vxworks. | |
1112 | (MIPS_ELF_REL_DYN_NAME): Updated. | |
1113 | (ELF_MIPS_GP_OFFSET): Likewise. | |
1114 | (mips_elf_create_local_got_entry): Likewise. | |
1115 | (mips_elf_allocate_dynamic_relocations): Likewise. | |
1116 | (mips_elf_count_got_symbols): Likewise. | |
1117 | (is_gott_symbol): Likewise. | |
1118 | (mips_elf_calculate_relocation): Likewise. | |
1119 | (mips_elf_create_dynamic_relocation): Likewise. | |
1120 | (_bfd_mips_elf_check_relocs): Likewise. | |
1121 | (allocate_dynrelocs): Likewise. | |
1122 | (_bfd_mips_elf_adjust_dynamic_symbol): Likewise. | |
1123 | (mips_elf_lay_out_got): Likewise. | |
1124 | (mips_elf_set_plt_sym_value): Likewise. | |
1125 | (_bfd_mips_elf_size_dynamic_sections): Likewise. | |
1126 | (_bfd_mips_elf_finish_dynamic_symbol): Likewise. | |
1127 | (_bfd_mips_elf_finish_dynamic_sections): Likewise. | |
1128 | (_bfd_mips_elf_final_link): Likewise. | |
1129 | (_bfd_mips_init_file_header): Likewise. | |
1130 | * elfxx-sparc.c (_bfd_sparc_elf_create_dynamic_sections): | |
1131 | Likewise. | |
1132 | (allocate_dynrelocs): Likewise. | |
1133 | (_bfd_sparc_elf_size_dynamic_sections): Likewise. | |
1134 | (_bfd_sparc_elf_relocate_section): Likewise. | |
1135 | (_bfd_sparc_elf_finish_dynamic_symbol): Likewise. | |
1136 | (sparc_finish_dyn): Likewise. | |
1137 | (_bfd_sparc_elf_finish_dynamic_sections): Likewise. | |
1138 | * elfxx-target.h (ELF_TARGET_OS): New. | |
1139 | (elfNN_bed): Add ELF_TARGET_OS. | |
1140 | * elfxx-x86.c (elf_x86_allocate_dynrelocs): Updated. | |
1141 | (_bfd_x86_elf_link_hash_table_create): Likewise. | |
1142 | (_bfd_x86_elf_size_dynamic_sections): Likewise. | |
1143 | (_bfd_x86_elf_finish_dynamic_sections): Likewise. | |
1144 | (_bfd_x86_elf_adjust_dynamic_symbol): Likewise. | |
1145 | (_bfd_x86_elf_link_setup_gnu_properties): Likewise. | |
1146 | * elfxx-x86.h (elf_x86_target_os): Removed. | |
1147 | (elf_x86_backend_data): Likewise. | |
1148 | (get_elf_x86_backend_data): Likewise. | |
1149 | (elf_x86_link_hash_table): Remove target_os. | |
1150 | ||
87c69f97 AM |
1151 | 2020-06-06 Alan Modra <amodra@gmail.com> |
1152 | ||
1153 | * reloc.c: Rename | |
1154 | BFD_RELOC_PPC64_GOT_TLSGD34 to BFD_RELOC_PPC64_GOT_TLSGD_PCREL34, | |
1155 | BFD_RELOC_PPC64_GOT_TLSLD34 to BFD_RELOC_PPC64_GOT_TLSLD_PCREL34, | |
1156 | BFD_RELOC_PPC64_GOT_TPREL34 to BFD_RELOC_PPC64_GOT_TPREL_PCREL34, | |
1157 | BFD_RELOC_PPC64_GOT_DTPREL34 to BFD_RELOC_PPC64_GOT_DTPREL_PCREL34. | |
1158 | * elf64-ppc.c: Update throughout for reloc renaming. | |
1159 | (ppc64_elf_reloc_name_lookup): Handle old reloc names. | |
1160 | * libbfd.h: Regenerate. | |
1161 | * bfd-in2.h: Regenerate. | |
1162 | ||
981f1518 L |
1163 | 2020-06-05 H.J. Lu <hongjiu.lu@intel.com> |
1164 | ||
8a4ba3a1 | 1165 | PR ld/26080 |
981f1518 L |
1166 | * elf32-bfin.c (bfinfdpic_relocate_section): Skip non SEC_ALLOC |
1167 | section. | |
1168 | ||
9c65eeac NC |
1169 | 2020-06-05 Nick Clifton <nickc@redhat.com> |
1170 | ||
1171 | * pdp11.c (aout_link_add_symbols): Fix use before initialisation | |
1172 | bug. | |
1173 | ||
41285764 NC |
1174 | 2020-06-05 Nelson Chu <nelson.chu@sifive.com> |
1175 | ||
1176 | * elfnn-riscv.c (riscv_merge_attributes): Add new boolean | |
1177 | priv_may_conflict, in_priv_zero and out_priv_zero to decide | |
1178 | whether the object can be linked according to it's priv | |
1179 | attributes. The object without any priv spec attributes can | |
1180 | be linked with others. If the first input object doesn't contain | |
1181 | any priv attributes, then we need to copy the setting from the | |
1182 | next input one. Also report more detailed error messages to user. | |
1183 | ||
a975c88e SC |
1184 | 2020-06-04 Stephen Casner <casner@acm.org> |
1185 | ||
1186 | Extend pdp11-aout symbol table format to accommodate .stab | |
1187 | symbols and implement correct handling of them. | |
1188 | ||
1189 | * pdp11.c (pdp11_external_nlist): Repurposed e_unused to e_desc. | |
1190 | (N_STAB, is_stab): Needed new function is_stab to disambiguate | |
1191 | normal vs. .stab symbol table type values, replacing N_STAB mask. | |
1192 | (translate_from_native_sym_flags): Determine correct section for | |
1193 | different .stab types. | |
1194 | (translate_to_native_sym_flags): Leave .stab types intact. | |
1195 | (translate_symbol_table): Error if symbol indicates overlay; | |
1196 | store desc field from .stab symbols. | |
1197 | (write_syms): Output desc field with symbol. | |
1198 | (aout_link_check_ar_symbols): Skip .stab symbols. | |
1199 | (aout_link_add_symbols): Correctly distinguish .stab symbols. | |
1200 | (aout_link_write_other_symbol): Write 0 for desk and ovly fields. | |
1201 | (aout_link_write_symbols): Write 0 for desk and ovly fields; | |
1202 | correctly distinguish .stab symbols and select calculate their | |
1203 | section and value; and copy desc and ovly fields from input symbol | |
1204 | to output symbol. | |
1205 | ||
3b9313c4 SC |
1206 | 2020-06-04 Stephen Casner <casner@acm.org> |
1207 | ||
1208 | * aoutx.h (translate_symbol_table): Comment had external and | |
1209 | internal swapped. | |
1210 | * pdp11.c (translate_symbol_table): Likewise. | |
1211 | ||
add5f777 L |
1212 | 2020-06-04 H.J. Lu <hongjiu.lu@intel.com> |
1213 | ||
1214 | * elfxx-x86.h (elf_x86_link_hash_table): Remove target_id. | |
1215 | (is_x86_elf): Check elf.hash_table_id instead of target_id. | |
1216 | * elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Updated. | |
1217 | ||
c4b126b8 L |
1218 | 2020-06-04 H.J. Lu <hongjiu.lu@intel.com> |
1219 | ||
1220 | PR ld/26080 | |
1221 | * elf-m10300.c (mn10300_elf_relocate_section): Resolve relocation | |
1222 | in debug section against symbol defined in shared library to 0. | |
1223 | * elf32-i386.c (elf_i386_check_relocs): Remove SEC_ALLOC check. | |
1224 | * elf32-lm32.c (lm32_elf_check_relocs): Likewise. | |
1225 | * elf32-m32r.c (m32r_elf_check_relocs): Likewise. | |
1226 | * elf32-nds32.c (nds32_elf_check_relocs): Likewise. | |
1227 | * elf32-nios2.c (nios2_elf32_check_relocs): Likewise. | |
1228 | * elf32-or1k.c (or1k_elf_check_relocs): Likewise. | |
1229 | * elf32-ppc.c (ppc_elf_check_relocs): Likewise. | |
1230 | * elf32-sh.c (sh_elf_check_relocs): Likewise. | |
1231 | * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise. | |
1232 | * elf64-alpha.c (elf64_alpha_check_relocs): Likewise. | |
1233 | * elf64-ppc.c (ppc64_elf_check_relocs): Likewise. | |
1234 | * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise. | |
1235 | * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise. | |
1236 | * elf32-vax.c (elf_vax_check_relocs): Set non_got_ref for non-GOT | |
1237 | reference. | |
1238 | (elf_vax_adjust_dynamic_symbol): Generate a copy reloc only if | |
1239 | there is non-GOT reference. | |
1240 | * elflink.c (_bfd_elf_link_check_relocs): Skip non-loaded, | |
1241 | non-alloced sections. | |
1242 | ||
31af1e68 SC |
1243 | 2020-06-03 Stephen Casner <casner@acm.org> |
1244 | ||
1245 | Copy several years of fixes from bfd/aoutx.h to bfd/pdp11.c. | |
1246 | ||
1247 | * pdp11.c (some_aout_object_p): 4c1534c7a2a - Don't set EXEC_P for | |
1248 | files with relocs. | |
1249 | (aout_get_external_symbols): 6b8f0fd579d - Return if count is zero. | |
1250 | 0301ce1486b PR 22306 - Handle stringsize of zero, and error for any | |
1251 | other size that doesn't qcover the header word. | |
1252 | bf82069dce1 PR 23056 - Allocate an extra byte at the end of the | |
1253 | string table, and zero it. | |
1254 | (translate_symbol_table): 0d329c0a83a PR 22887 - Print an error | |
1255 | message and set bfd_error on finding an invalid name string offset. | |
1256 | (add_to_stringtab): INLINE -> inline | |
1257 | (pdp11_aout_swap_reloc_in): 116acb2c268 PR 22887 - Correct r_index | |
1258 | bound check. | |
1259 | (squirt_out_relocs): e2996cc315d PR 20921 - Check for and report | |
1260 | any relocs that could not be recognised. | |
1261 | 92744f05809 PR 20929 - Check for relocs without an associated symbol. | |
1262 | (find_nearest_line): 808346fcfcf PR 23055 - Check that the symbol | |
1263 | name exists and is long enough, before attempting to see if it is | |
1264 | for a .o file. | |
1265 | c3864421222 - Correct case for N_SO being the last symbol. | |
1266 | 50455f1ab29 PR 20891 - Handle the case where the main file name | |
1267 | and the directory name are both empty. | |
1268 | e82ab856bb4 PR 20892 - Handle the case where function name is empty. | |
1269 | (aout_link_add_symbols): e517df3dbf7 PR 19629 - Check for out of | |
1270 | range string table offsets. | |
1271 | 531336e3a0b PR 20909 - Fix off-by-one error in check for an | |
cae64165 | 1272 | illegal string offset. |
31af1e68 SC |
1273 | (aout_link_includes_newfunc): Add comment. |
1274 | (pdp11_aout_link_input_section): ad756e3f9e6 - Return with an error | |
1275 | on unexpected relocation type rather than ASSERT. | |
1276 | ||
d4d8aee3 L |
1277 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1278 | ||
1279 | PR ld/26066 | |
1280 | * elf32-nios2.c (nios2_elf32_size_dynamic_sections): Call | |
1281 | _bfd_elf_maybe_set_textrel to set DF_TEXTREL. | |
1282 | ||
58ee44ef L |
1283 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1284 | ||
1285 | PR ld/26066 | |
1286 | * elf32-nios2.c (nios2_elf32_check_relocs): Skip non-loaded, | |
1287 | non-alloced sections. | |
1288 | ||
9a689602 L |
1289 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1290 | ||
1291 | * elf32-frv.c (elf32_frv_relocate_section): Don't generate | |
1292 | dynamic relocations for non SEC_ALLOC sections. | |
1293 | ||
0bff7528 GN |
1294 | 2020-06-03 Gunther Nikl <gnikl@justmail.de> |
1295 | ||
1296 | * aout64.c (BMAGIC, QMAGIC): Do not define. | |
1297 | * aoutx.h (N_IS_BMAGIC, N_SET_QMAGIC): New defines. | |
1298 | (NAME (aout, some_aout_object_p)): Use N_IS_QMAGIC and N_IS_BMAGIC | |
1299 | to check the file format. | |
1300 | (adjust_z_magic): Use N_SET_QMAGIC to set file format. | |
1301 | * i386aout.c (NO_WRITE_HEADER_KLUDGE): Delete define. | |
1302 | * libaout.h (NO_WRITE_HEADER_KLUDGE): Do not define. | |
1303 | ||
50d03636 L |
1304 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1305 | ||
1306 | * elf32-arc.c (elf_arc_relocate_section): Don't generate dynamic | |
1307 | relocations for non SEC_ALLOC sections. | |
1308 | ||
d49e5065 L |
1309 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1310 | ||
1311 | * elf-bfd.h (_bfd_elf_maybe_set_textrel): New | |
1312 | * elf32-arm.c (maybe_set_textrel): Removed. | |
1313 | (elf32_arm_size_dynamic_sections): Replace maybe_set_textrel | |
1314 | with _bfd_elf_maybe_set_textrel. | |
1315 | * elf32-csky.c (maybe_set_textrel): Removed. | |
1316 | (csky_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1317 | with _bfd_elf_maybe_set_textrel. | |
1318 | * elf32-hppa.c (maybe_set_textrel): Removed. | |
1319 | (elf32_hppa_size_dynamic_sections): Replace maybe_set_textrel | |
1320 | with _bfd_elf_maybe_set_textrel. | |
1321 | * elf32-lm32.c (maybe_set_textrel): Removed. | |
1322 | (lm32_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1323 | with _bfd_elf_maybe_set_textrel. | |
1324 | * elf32-m32r.c (maybe_set_textrel): Removed. | |
1325 | (m32r_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1326 | with _bfd_elf_maybe_set_textrel. | |
1327 | * elf32-metag.c (maybe_set_textrel): Removed. | |
1328 | (elf_metag_size_dynamic_sections): Replace maybe_set_textrel | |
1329 | with _bfd_elf_maybe_set_textrel. | |
1330 | * elf32-nds32.c (maybe_set_textrel): Removed. | |
1331 | (nds32_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1332 | with _bfd_elf_maybe_set_textrel. | |
1333 | * elf32-or1k.c (maybe_set_textrel): Removed. | |
1334 | (or1k_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1335 | with _bfd_elf_maybe_set_textrel. | |
1336 | * elf32-ppc.c (maybe_set_textrel): Removed. | |
1337 | (ppc_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1338 | with _bfd_elf_maybe_set_textrel. | |
1339 | * elf32-s390.c (maybe_set_textrel): Removed. | |
1340 | (elf_s390_size_dynamic_sections): Replace maybe_set_textrel | |
1341 | with _bfd_elf_maybe_set_textrel. | |
1342 | * elf32-sh.c (maybe_set_textrel): Removed. | |
1343 | (sh_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1344 | with _bfd_elf_maybe_set_textrel. | |
1345 | * elf32-tic6x.c (maybe_set_textrel): Removed. | |
1346 | (elf32_tic6x_size_dynamic_sections): Replace maybe_set_textrel | |
1347 | with _bfd_elf_maybe_set_textrel. | |
1348 | * elf32-tilepro.c (maybe_set_textrel): Removed. | |
1349 | (tilepro_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1350 | with _bfd_elf_maybe_set_textrel. | |
1351 | * elf64-ppc.c (maybe_set_textrel): Removed. | |
1352 | (ppc64_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1353 | with _bfd_elf_maybe_set_textrel. | |
1354 | * elf64-s390.c (maybe_set_textrel): Removed. | |
1355 | (elf_s390_size_dynamic_sections): Replace maybe_set_textrel | |
1356 | with _bfd_elf_maybe_set_textrel. | |
1357 | * elfnn-aarch64.c (maybe_set_textrel): Removed. | |
1358 | (elfNN_aarch64_size_dynamic_sections): Replace maybe_set_textrel | |
1359 | with _bfd_elf_maybe_set_textrel. | |
1360 | * elfnn-riscv.c (maybe_set_textrel): Removed. | |
1361 | (riscv_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1362 | with _bfd_elf_maybe_set_textrel. | |
1363 | * elfxx-sparc.c (maybe_set_textrel): Removed. | |
1364 | (_bfd_sparc_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1365 | with _bfd_elf_maybe_set_textrel. | |
1366 | * elfxx-tilegx.c (maybe_set_textrel): Removed. | |
1367 | (tilegx_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1368 | with _bfd_elf_maybe_set_textrel. | |
1369 | * elfxx-x86.c (maybe_set_textrel): Removed. | |
1370 | (_bfd_x86_elf_size_dynamic_sections): Replace maybe_set_textrel | |
1371 | with _bfd_elf_maybe_set_textrel. | |
1372 | * elflink.c (_bfd_elf_maybe_set_textrel): New. | |
1373 | ||
ad172eaa L |
1374 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1375 | ||
1376 | PR ld/26067 | |
1377 | * elf32-arm.c (elf32_arm_copy_indirect_symbol): Don't copy | |
1378 | dyn_relocs. | |
1379 | * elf32-csky.c (csky_elf_copy_indirect_symbol): Likewise. | |
1380 | * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise. | |
1381 | * elf32-metag.c (elf_metag_copy_indirect_symbol): Likewise. | |
1382 | * elf32-microblaze.c (microblaze_elf_copy_indirect_symbol): | |
1383 | Likewise. | |
1384 | * elf32-nds32.c (nds32_elf_copy_indirect_symbol): Likewise. | |
1385 | * elf32-nios2.c (nios2_elf32_copy_indirect_symbol): Likewise. | |
1386 | * elf32-or1k.c (or1k_elf_copy_indirect_symbol): Likewise. | |
1387 | * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise. | |
1388 | * elf32-sh.c (sh_elf_copy_indirect_symbol): Likewise. | |
1389 | * elf32-tilepro.c (tilepro_elf_copy_indirect_symbol): Likewise. | |
1390 | * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise. | |
1391 | * elfnn-aarch64.c (elfNN_aarch64_copy_indirect_symbol): Likewise. | |
1392 | * elfnn-riscv.c (riscv_elf_copy_indirect_symbol): Likewise. | |
1393 | * elfxx-sparc.c (_bfd_sparc_elf_copy_indirect_symbol): Likewise. | |
1394 | * elfxx-tilegx.c (tilegx_elf_copy_indirect_symbol): Likewise. | |
1395 | * elfxx-x86.c (_bfd_x86_elf_copy_indirect_symbol): Likewise. | |
1396 | * elf32-lm32.c (lm32_elf_copy_indirect_symbol): Removed. | |
1397 | (elf_backend_copy_indirect_symbol): Likewise. | |
1398 | * elf32-m32r.c (m32r_elf_copy_indirect_symbol): Removed. | |
1399 | (elf_backend_copy_indirect_symbol): Likewise. | |
1400 | * elflink.c (_bfd_elf_link_hash_copy_indirect): Copy dyn_relocs. | |
1401 | ||
5dbc8b37 L |
1402 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1403 | ||
1404 | PR ld/26067 | |
1405 | * elf-bfd.h (_bfd_elf_readonly_dynrelocs): New. | |
1406 | * elf32-arm.c (readonly_dynrelocs): Removed. | |
1407 | (maybe_set_textrel): Replace readonly_dynrelocs with | |
1408 | _bfd_elf_readonly_dynrelocs. | |
1409 | * elf32-csky.c (readonly_dynrelocs): Removed. | |
1410 | (maybe_set_textrel): Replace readonly_dynrelocs with | |
1411 | _bfd_elf_readonly_dynrelocs. | |
1412 | * elf32-hppa.c(readonly_dynrelocs): Removed. | |
1413 | (alias_readonly_dynrelocs): Replace readonly_dynrelocs with | |
1414 | _bfd_elf_readonly_dynrelocs. | |
1415 | (maybe_set_textrel): Likewise. | |
1416 | * elf32-lm32.c (readonly_dynrelocs): Removed. | |
1417 | (lm32_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1418 | with _bfd_elf_readonly_dynrelocs. | |
1419 | (maybe_set_textrel): Likewise. | |
1420 | * elf32-m32r.c (readonly_dynrelocs): Removed. | |
1421 | (m32r_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1422 | with _bfd_elf_readonly_dynrelocs. | |
1423 | (maybe_set_textrel): Likewise. | |
1424 | * elf32-metag.c (readonly_dynrelocs): Removed. | |
1425 | (elf_metag_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1426 | with _bfd_elf_readonly_dynrelocs. | |
1427 | (maybe_set_textrel): Likewise. | |
1428 | * elf32-microblaze.c (readonly_dynrelocs): Removed. | |
1429 | (microblaze_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1430 | with _bfd_elf_readonly_dynrelocs. | |
1431 | * elf32-nds32.c (readonly_dynrelocs): Removed. | |
1432 | (nds32_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1433 | with _bfd_elf_readonly_dynrelocs. | |
1434 | (maybe_set_textrel): Likewise. | |
1435 | * elf32-or1k.c (readonly_dynrelocs): Removed. | |
1436 | (or1k_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1437 | with _bfd_elf_readonly_dynrelocs. | |
1438 | * elf32-ppc.c (readonly_dynrelocs): Removed. | |
1439 | (alias_readonly_dynrelocs): Replace readonly_dynrelocs with | |
1440 | _bfd_elf_readonly_dynrelocs. | |
1441 | (ppc_elf_adjust_dynamic_symbol): Likewise. | |
1442 | (maybe_set_textrel): Likewise. | |
1443 | * elf32-s390.c (readonly_dynrelocs): Removed. | |
1444 | (elf_s390_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1445 | with _bfd_elf_readonly_dynrelocs. | |
1446 | (maybe_set_textrel): Likewise. | |
1447 | * elf32-sh.c (readonly_dynrelocs): Removed. | |
1448 | (sh_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs with | |
1449 | _bfd_elf_readonly_dynrelocs. | |
1450 | (maybe_set_textrel): Likewise. | |
1451 | * elf32-tic6x.c (readonly_dynrelocs): Removed. | |
1452 | (maybe_set_textrel): Replace readonly_dynrelocs with | |
1453 | _bfd_elf_readonly_dynrelocs. | |
1454 | * elf32-tilepro.c (readonly_dynrelocs): Removed. | |
1455 | (tilepro_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1456 | with _bfd_elf_readonly_dynrelocs. | |
1457 | (maybe_set_textrel): Likewise. | |
1458 | * elf64-ppc.c (readonly_dynrelocs): Removed. | |
1459 | (alias_readonly_dynrelocs): Replace readonly_dynrelocs with | |
1460 | _bfd_elf_readonly_dynrelocs. | |
1461 | (ppc64_elf_adjust_dynamic_symbol): Likewise. | |
1462 | (maybe_set_textrel): Likewise. | |
1463 | * elf64-s390.c (readonly_dynrelocs): Removed. | |
1464 | (elf_s390_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1465 | with _bfd_elf_readonly_dynrelocs. | |
1466 | (maybe_set_textrel): Likewise. | |
1467 | * elflink.c (_bfd_elf_readonly_dynrelocs): New. | |
1468 | * elfnn-aarch64.c (readonly_dynrelocs): Removed. | |
1469 | (maybe_set_textrel): Replace readonly_dynrelocs with | |
1470 | _bfd_elf_readonly_dynrelocs. | |
1471 | * elfnn-riscv.c (readonly_dynrelocs): Removed. | |
1472 | (riscv_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1473 | with _bfd_elf_readonly_dynrelocs. | |
1474 | (maybe_set_textrel): Likewise. | |
1475 | * elfxx-sparc.c (readonly_dynrelocs): Removed. | |
1476 | (_bfd_sparc_elf_adjust_dynamic_symbol): Replace | |
1477 | readonly_dynrelocs with _bfd_elf_readonly_dynrelocs. | |
1478 | (maybe_set_textrel): Likewise. | |
1479 | * elfxx-tilegx.c (readonly_dynrelocs): Removed. | |
1480 | (tilegx_elf_adjust_dynamic_symbol): Replace readonly_dynrelocs | |
1481 | with _bfd_elf_readonly_dynrelocs. | |
1482 | (maybe_set_textrel): Likewise. | |
1483 | * elfxx-x86.c (readonly_dynrelocs): Removed. | |
1484 | (maybe_set_textrel): Replace readonly_dynrelocs with | |
1485 | _bfd_elf_readonly_dynrelocs. | |
1486 | (_bfd_x86_elf_adjust_dynamic_symbol): Likewise. | |
1487 | ||
433953ff L |
1488 | 2020-06-03 H.J. Lu <hongjiu.lu@intel.com> |
1489 | ||
1490 | * elfxx-x86.h (GENERATE_DYNAMIC_RELOCATION_P): Silence | |
1491 | -fsanitize=undefined. | |
1492 | ||
67580036 AM |
1493 | 2020-06-03 Alan Modra <amodra@gmail.com> |
1494 | ||
1495 | PR 26069 | |
1496 | PR 18758 | |
1497 | * peicode.h (pe_ILF_make_a_section): Align data for compilers | |
1498 | other than gcc. | |
1499 | (pe_ILF_build_a_bfd): Likewise. | |
1500 | ||
0ed18fa1 AM |
1501 | 2020-06-03 Alan Modra <amodra@gmail.com> |
1502 | ||
7eea15c5 | 1503 | PR 26069 |
0ed18fa1 AM |
1504 | * elf.c (_bfd_elf_close_and_cleanup): Free elf_shstrtab for |
1505 | core files as well as objects. | |
1506 | ||
190eb1dd L |
1507 | 2020-06-01 H.J. Lu <hongjiu.lu@intel.com> |
1508 | ||
1509 | PR ld/26067 | |
1510 | * elf-bfd.h (elf_link_hash_entry): Add dyn_relocs after size. | |
1511 | * elf-s390-common.c (s390_elf_allocate_ifunc_dyn_relocs): | |
1512 | Updated. | |
1513 | * elf32-arc.c (elf_arc_link_hash_entry): Remove dyn_relocs. | |
1514 | (elf_arc_link_hash_newfunc): Updated. | |
1515 | * elf32-arm.c (elf32_arm_link_hash_entry): Remove dyn_relocs. | |
1516 | (elf32_arm_link_hash_newfunc): Updated. | |
1517 | (elf32_arm_copy_indirect_symbol): Likewise. | |
1518 | (elf32_arm_check_relocs): Likewise. | |
1519 | (readonly_dynrelocs): Likewise. | |
1520 | (allocate_dynrelocs_for_symbol): Likewise. | |
1521 | * elf32-csky.c (csky_elf_link_hash_entry): Remove dyn_relocs. | |
1522 | (csky_elf_link_hash_newfunc): Updated. | |
1523 | (csky_allocate_dynrelocs): Likewise. | |
1524 | (readonly_dynrelocs): Likewise. | |
1525 | (csky_elf_copy_indirect_symbol): Likewise. | |
1526 | * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove dyn_relocs. | |
1527 | (hppa_link_hash_newfunc): Updated. | |
1528 | (elf32_hppa_copy_indirect_symbol): Likewise. | |
1529 | (elf32_hppa_hide_symbol): Likewise. | |
1530 | (elf32_hppa_adjust_dynamic_symbol): Likewise. | |
1531 | (allocate_dynrelocs): Likewise. | |
1532 | (elf32_hppa_relocate_section): Likewise. | |
1533 | * elf32-i386.c (elf_i386_check_relocs): Likewise. | |
1534 | * elf32-lm32.c (elf_lm32_link_hash_entry): Removed. | |
1535 | (lm32_elf_link_hash_newfunc): Likewise. | |
1536 | (lm32_elf_link_hash_table_create): Updated. | |
1537 | (readonly_dynrelocs): Likewise. | |
1538 | (allocate_dynrelocs): Likewise. | |
1539 | (lm32_elf_copy_indirect_symbol): Likewise. | |
1540 | * elf32-m32r.c (elf_m32r_link_hash_entry): Removed. | |
1541 | (m32r_elf_link_hash_newfunc): Likewise. | |
1542 | (m32r_elf_link_hash_table_create): Updated. | |
1543 | (m32r_elf_copy_indirect_symbol): Likewise. | |
1544 | (allocate_dynrelocs): Likewise. | |
1545 | * elf32-metag.c (elf_metag_link_hash_entry): Remove dyn_relocs. | |
1546 | (metag_link_hash_newfunc): Updated. | |
1547 | (elf_metag_copy_indirect_symbol): Likewise. | |
1548 | (readonly_dynrelocs): Likewise. | |
1549 | (allocate_dynrelocs): Likewise. | |
1550 | * elf32-microblaze.c (elf32_mb_link_hash_entry): Remove | |
1551 | dyn_relocs. | |
1552 | (link_hash_newfunc): Updated. | |
1553 | (microblaze_elf_check_relocs): Likewise. | |
1554 | (microblaze_elf_copy_indirect_symbol): Likewise. | |
1555 | (readonly_dynrelocs): Likewise. | |
1556 | (allocate_dynrelocs): Likewise. | |
1557 | * elf32-nds32.c (elf_nds32_link_hash_entry): Remove dyn_relocs. | |
1558 | (nds32_elf_link_hash_newfunc): Updated. | |
1559 | (nds32_elf_copy_indirect_symbol): Likewise. | |
1560 | (readonly_dynrelocs): Likewise. | |
1561 | (allocate_dynrelocs): Likewise. | |
1562 | (nds32_elf_check_relocs): Likewise. | |
1563 | * elf32-nios2.c (elf32_nios2_link_hash_entry): Remove dyn_relocs. | |
1564 | (link_hash_newfunc): Updated. | |
1565 | (nios2_elf32_copy_indirect_symbol): Likewise. | |
1566 | (nios2_elf32_check_relocs): Likewise. | |
1567 | (allocate_dynrelocs): Likewise. | |
1568 | * elf32-or1k.c (elf_or1k_link_hash_entry): Remove dyn_relocs. | |
1569 | (or1k_elf_link_hash_newfunc): Updated. | |
1570 | (readonly_dynrelocs): Likewise. | |
1571 | (allocate_dynrelocs): Likewise. | |
1572 | (or1k_elf_copy_indirect_symbol): Likewise. | |
1573 | * elf32-ppc.c (ppc_elf_link_hash_entry): Remove dyn_relocs. | |
1574 | (ppc_elf_link_hash_newfunc): Updated. | |
1575 | (ppc_elf_copy_indirect_symbol): Likewise. | |
1576 | (ppc_elf_check_relocs): Likewise. | |
1577 | (readonly_dynrelocs): Likewise. | |
1578 | (ppc_elf_adjust_dynamic_symbol): Likewise. | |
1579 | (allocate_dynrelocs): Likewise. | |
1580 | (ppc_elf_relocate_section): Likewise. | |
1581 | * elf32-s390.c (elf_s390_link_hash_entry): Remove dyn_relocs. | |
1582 | (link_hash_newfunc): Updated. | |
1583 | (elf_s390_copy_indirect_symbol): Likewise. | |
1584 | (readonly_dynrelocs): Likewise. | |
1585 | (elf_s390_adjust_dynamic_symbol): Likewise. | |
1586 | (allocate_dynrelocs): Likewise. | |
1587 | * elf32-sh.c (elf_sh_link_hash_entry): Remove dyn_relocs. | |
1588 | (sh_elf_link_hash_newfunc): Updated. | |
1589 | (readonly_dynrelocs): Likewise. | |
1590 | (allocate_dynrelocs): Likewise. | |
1591 | (sh_elf_copy_indirect_symbol): Likewise. | |
1592 | (sh_elf_check_relocs): Likewise. | |
1593 | * elf32-tic6x.c (elf32_tic6x_link_hash_entry): Removed. | |
1594 | (elf32_tic6x_link_hash_newfunc): Likewise. | |
1595 | (elf32_tic6x_link_hash_table_create): Updated. | |
1596 | (readonly_dynrelocs): Likewise. | |
1597 | (elf32_tic6x_check_relocs): Likewise. | |
1598 | (elf32_tic6x_allocate_dynrelocs): Likewise. | |
1599 | * elf32-tilepro.c (tilepro_elf_link_hash_entry): Remove | |
1600 | dyn_relocs. | |
1601 | (link_hash_newfunc): Updated. | |
1602 | (tilepro_elf_copy_indirect_symbol): Likewise. | |
1603 | (tilepro_elf_check_relocs): Likewise. | |
1604 | (allocate_dynrelocs): Likewise. | |
1605 | * elf64-ppc.c (ppc_link_hash_entry): Remove dyn_relocs. | |
1606 | (ppc64_elf_copy_indirect_symbol): Updated. | |
1607 | (ppc64_elf_check_relocs): Likewise. | |
1608 | (readonly_dynrelocs): Likewise. | |
1609 | (ppc64_elf_adjust_dynamic_symbol): Likewise. | |
1610 | (dec_dynrel_count): Likewise. | |
1611 | (allocate_dynrelocs): Likewise. | |
1612 | (ppc64_elf_relocate_section): Likewise. | |
1613 | * elf64-s390.c (elf_s390_link_hash_entry): Remove dyn_relocs. | |
1614 | (link_hash_newfunc): Updated. | |
1615 | (elf_s390_copy_indirect_symbol): Likewise. | |
1616 | (readonly_dynrelocs): Likewise. | |
1617 | (allocate_dynrelocs): Likewise. | |
1618 | * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise. | |
1619 | * elfnn-aarch64.c (elf_aarch64_link_hash_entry): Remove | |
1620 | dyn_relocs. | |
1621 | (elfNN_aarch64_link_hash_newfunc): Updated. | |
1622 | (elfNN_aarch64_copy_indirect_symbol): Likewise. | |
1623 | (readonly_dynrelocs): Likewise. | |
1624 | (need_copy_relocation_p): Likewise. | |
1625 | (elfNN_aarch64_allocate_dynrelocs): Likewise. | |
1626 | (elfNN_aarch64_allocate_ifunc_dynrelocs): Likewise. | |
1627 | * elfnn-riscv.c (riscv_elf_link_hash_entry): Remove dyn_relocs. | |
1628 | (link_hash_newfunc): Updated. | |
1629 | (riscv_elf_copy_indirect_symbol): Likewise. | |
1630 | (riscv_elf_check_relocs): Likewise. | |
1631 | (readonly_dynrelocs): Likewise. | |
1632 | (allocate_dynrelocs): Likewise. | |
1633 | * elfxx-sparc.c (_bfd_sparc_elf_link_hash_entry): Remove | |
1634 | dyn_relocs. | |
1635 | (link_hash_newfunc): Updated. | |
1636 | (_bfd_sparc_elf_copy_indirect_symbol): Likewise. | |
1637 | (_bfd_sparc_elf_check_relocs): Likewise. | |
1638 | (readonly_dynrelocs): Likewise. | |
1639 | (allocate_dynrelocs): Likewise. | |
1640 | * elfxx-tilegx.c (tilegx_elf_link_hash_entry): Remove dyn_relocs. | |
1641 | (link_hash_newfunc): Updated. | |
1642 | (tilegx_elf_copy_indirect_symbol): Likewise. | |
1643 | (tilegx_elf_check_relocs): Likewise. | |
1644 | (readonly_dynrelocs): Likewise. | |
1645 | (allocate_dynrelocs): Likewise. | |
1646 | * elfxx-x86.c (elf_x86_allocate_dynrelocs): Likewise. | |
1647 | (readonly_dynrelocs): Likewise. | |
1648 | (_bfd_x86_elf_copy_indirect_symbol): Likewise. | |
1649 | * elfxx-x86.h (elf_x86_link_hash_entry): Remove dyn_relocs. | |
1650 | ||
2fdb65f2 AM |
1651 | 2020-06-01 Alan Modra <amodra@gmail.com> |
1652 | ||
1653 | * vms-alpha.c (_bfd_vms_slurp_etir): Check bound for the current | |
1654 | command against cmd_length, not the end of record. For | |
1655 | ETIR__C_STO_IMMR check size against cmd_length, mask repeat count | |
1656 | to 32-bits and break out on zero size. Add ETIR__C_STC_LP_PSB | |
1657 | cmd_length test. | |
1658 | ||
12adf805 DF |
1659 | 2020-05-28 David Faust <david.faust@oracle.com> |
1660 | ||
1661 | * elf64-bpf.c (bpf_elf_relocate_section): Fix handling of | |
1662 | R_BPF_INSN_{32,64} relocations. | |
1663 | ||
66e3eb08 SC |
1664 | 2020-05-28 Stephen Casner <casner@acm.org> |
1665 | ||
1666 | * pdp11.c: Implement BRD_RELOC_32 to relocate the low 16 bits of | |
1667 | addreses in .long (used in testsuites) and .stab values. | |
1668 | ||
a6dbf402 L |
1669 | 2020-05-27 H.J. Lu <hongjiu.lu@intel.com> |
1670 | ||
1671 | PR ld/22909 | |
1672 | * elflink.c (bfd_elf_final_link): Use bfd_link_textrel_check. | |
1673 | Check bfd_link_dll when issue a DT_TEXTREL warning. | |
1674 | * elfxx-x86.c (maybe_set_textrel): Likewise. | |
1675 | (_bfd_x86_elf_size_dynamic_sections): Likewise. | |
1676 | ||
9e7cb4c3 NC |
1677 | 2020-05-26 Nick Clifton <nickc@redhat.com> |
1678 | ||
1679 | * plugin.c (try_load_plugin): Extend error message when a plugin | |
1680 | fails to open. | |
1681 | ||
c892b447 AM |
1682 | 2020-05-23 Alan Modra <amodra@gmail.com> |
1683 | ||
1684 | * bfdio.c (bfd_get_file_size): Don't segfault on NULL arch_header. | |
1685 | ||
6f3fe02b AM |
1686 | 2020-05-22 Alan Modra <amodra@gmail.com> |
1687 | ||
1688 | PR 25882 | |
1689 | * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Don't init FP | |
1690 | attributes from shared libraries, and do not return an error if | |
1691 | they don't match. | |
1692 | ||
0490dd41 AM |
1693 | 2020-05-21 Alan Modra <amodra@gmail.com> |
1694 | ||
1695 | PR 25993 | |
1696 | * opncls.c (_bfd_free_cached_info): Keep a copy of the bfd | |
1697 | filename. | |
1698 | (_bfd_delete_bfd): Free the copy. | |
1699 | (_bfd_new_bfd): Free nbfd->memory on error. | |
1700 | ||
c9594989 AM |
1701 | 2020-05-21 Alan Modra <amodra@gmail.com> |
1702 | ||
1703 | * aoutx.h: Replace "if (x) free (x)" with "free (x)" throughout. | |
1704 | * archive.c, * bfd.c, * bfdio.c, * coff-alpha.c, * coff-ppc.c, | |
1705 | * coff-sh.c, * coff-stgo32.c, * coffcode.h, * coffgen.c, | |
1706 | * cofflink.c, * cpu-arm.c, * doc/chew.c, * dwarf2.c, * ecoff.c, | |
1707 | * ecofflink.c, * elf-eh-frame.c, * elf-m10200.c, * elf-m10300.c, | |
1708 | * elf-strtab.c, * elf.c, * elf32-arc.c, * elf32-arm.c, | |
1709 | * elf32-avr.c, * elf32-bfin.c, * elf32-cr16.c, * elf32-crx.c, | |
1710 | * elf32-epiphany.c, * elf32-ft32.c, * elf32-h8300.c, | |
1711 | * elf32-ip2k.c, * elf32-m32c.c, * elf32-m68hc11.c, | |
1712 | * elf32-m68k.c, * elf32-microblaze.c, * elf32-msp430.c, | |
1713 | * elf32-nds32.c, * elf32-nios2.c, * elf32-ppc.c, * elf32-pru.c, | |
1714 | * elf32-rl78.c, * elf32-rx.c, * elf32-sh.c, * elf32-spu.c, | |
1715 | * elf32-v850.c, * elf32-xtensa.c, * elf64-alpha.c, | |
1716 | * elf64-hppa.c, * elf64-ia64-vms.c, * elf64-mips.c | |
1717 | * elf64-mmix.c, * elf64-ppc.c, * elf64-sparc.c, * elfcode.h, | |
1718 | * elflink.c, * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, | |
1719 | * elfxx-x86.c, * format.c, * ihex.c, * libbfd.c, * linker.c, | |
1720 | * mmo.c, * opncls.c, * pdp11.c, * peXXigen.c, * pef.c, | |
1721 | * peicode.h, * simple.c, * som.c, * srec.c, * stabs.c, * syms.c, | |
1722 | * targets.c, * vms-lib.c, * xcofflink.c, * xtensa-isa.c: Likewise. | |
1723 | ||
8f595e9b NC |
1724 | 2020-05-20 Nelson Chu <nelson.chu@sifive.com> |
1725 | ||
1726 | * elfxx-riscv.h (riscv_parse_subset_t): Add new callback function | |
1727 | get_default_version. It is used to find the default version for | |
1728 | the specific extension. | |
1729 | * elfxx-riscv.c (riscv_parsing_subset_version): Remove the parameters | |
1730 | default_major_version and default_minor_version. Add new bfd_boolean | |
1731 | parameter *use_default_version. Set it to TRUE if we need to call | |
1732 | the callback rps->get_default_version to find the default version. | |
1733 | (riscv_parse_std_ext): Call rps->get_default_version if we fail to find | |
1734 | the default version in riscv_parsing_subset_version, and then call | |
1735 | riscv_add_subset to add the subset into subset list. | |
1736 | (riscv_parse_prefixed_ext): Likewise. | |
1737 | (riscv_std_z_ext_strtab): Support Zicsr extensions. | |
1738 | * elfnn-riscv.c (riscv_merge_std_ext): Use strcasecmp to compare the | |
1739 | strings rather than characters. | |
1740 | riscv_merge_arch_attr_info): The callback function get_default_version | |
1741 | is only needed for assembler, so set it to NULL int the linker. | |
1742 | * elfxx-riscv.c (riscv_estimate_digit): Remove the static. | |
1743 | * elfxx-riscv.h: Updated. | |
1744 | ||
7b958a48 AM |
1745 | 2020-05-20 Alan Modra <amodra@gmail.com> |
1746 | ||
1747 | PR 25993 | |
1748 | * archive.c (_bfd_get_elt_at_filepos): Don't strdup filename, | |
1749 | use bfd_set_filename. | |
1750 | * elfcode.h (_bfd_elf_bfd_from_remote_memory): Likewise. | |
1751 | * mach-o.c (bfd_mach_o_fat_member_init): Likewise. | |
1752 | * opncls.c (bfd_fopen, bfd_openstreamr, bfd_openr_iovec, bfd_openw), | |
1753 | (bfd_create): Likewise. | |
1754 | (_bfd_delete_bfd): Don't free filename. | |
1755 | (bfd_set_filename): Copy filename param to bfd_alloc'd memory, | |
1756 | return pointer to the copy or NULL on alloc fail. | |
1757 | * vms-lib.c (_bfd_vms_lib_get_module): Free newname and test | |
1758 | result of bfd_set_filename. | |
1759 | * bfd-in2.h: Regenerate. | |
1760 | ||
3c568b8a AM |
1761 | 2020-05-20 Alan Modra <amodra@gmail.com> |
1762 | ||
1763 | PR 26011 | |
1764 | * elf.c (_bfd_elf_get_reloc_upper_bound): Sanity check reloc | |
1765 | section size against file size. | |
1766 | (_bfd_elf_get_dynamic_reloc_upper_bound): Likewise. | |
1767 | ||
6fd1d259 GN |
1768 | 2020-05-19 Gunther Nikl <gnikl@justmail.de> |
1769 | ||
1770 | PR 26005 | |
11c0dd51 NC |
1771 | * elf.c (bfd_section_from_shdr): Replace bfd_zmalloc with bfd_malloc |
1772 | and memset when allocating memory for the sections_being_created | |
1773 | array. | |
6fd1d259 | 1774 | |
7e94cf6c SH |
1775 | 2020-05-19 Stafford Horne <shorne@gmail.com> |
1776 | ||
1777 | * elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Rename srela | |
1778 | to relgot. | |
1779 | (or1k_elf_relocate_section): Access srelgot via | |
1780 | htab->root.srelgot. Add assertions for srelgot->contents. | |
1781 | Introduce local variable for srelgot to not reuse global | |
1782 | sreloc. | |
1783 | (or1k_elf_relocate_section): Fixup dynamic symbol detection. | |
1784 | (or1k_set_got_and_rela_sizes): New function. | |
1785 | (or1k_initial_exec_offset): New function. | |
1786 | (TLS_GD, TLS_IE, TLS_LD, TLS_LE): Redefine macros as masks. | |
1787 | (or1k_elf_relocate_section): Allow for TLS to handle multiple | |
1788 | model access. | |
1789 | (or1k_elf_check_relocs): Use OR to set TLS access. | |
1790 | (allocate_dynrelocs): Use or1k_set_got_and_rela_sizes to set | |
1791 | sizes. | |
1792 | (or1k_elf_size_dynamic_sections): Use | |
1793 | or1k_set_got_and_rela_sizes to set sizes. | |
1794 | (or1k_elf_relocate_section): Fixup PCREL relocation calculation. | |
1795 | (TCB_SIZE): New macro. | |
1796 | (tpoff): Use TCB_SIZE and alignment to calculate offset. | |
1797 | (allocate_dynrelocs, readonly_dynrelocs, or1k_elf_check_relocs) | |
1798 | (or1k_elf_size_dynamic_sections): Rename p to sec_relocs. | |
1799 | (allocate_dynrelocs): Rename s to splt or sgot based on usage. | |
1800 | (tpoff): Add dynamic boolean argument. | |
1801 | (or1k_elf_relocate_section): Pass dynamic flag to tpoff. | |
1802 | ||
7e057737 SP |
1803 | 2020-05-19 Siddhesh Poyarekar <siddesh.poyarekar@arm.com> |
1804 | ||
1805 | * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Club | |
1806 | BFD_RELOC_AARCH64_BRANCH19 and BFD_RELOC_AARCH64_TSTBR14 | |
1807 | cases with BFD_RELOC_AARCH64_JUMP26. | |
1808 | (elfNN_aarch64_check_relocs): Likewise. | |
1809 | ||
765cf5f6 AM |
1810 | 2020-05-19 Alan Modra <amodra@gmail.com> |
1811 | ||
1812 | * aix5ppc-core.c (xcoff64_core_file_matches_executable_p): Use | |
1813 | bfd_get_filename rather than accessing bfd->filename directly. | |
1814 | * aout-target.h (MY (object_p)): Likewise. | |
1815 | * aoutx.h (aout_find_nearest_line, aout_link_write_symbols): Likewise. | |
1816 | * archive.c (find_nested_archive, _bfd_generic_read_ar_hdr_mag), | |
1817 | (_bfd_construct_extended_name_table, _bfd_bsd44_write_ar_hdr), | |
1818 | (_bfd_archive_bsd44_construct_extended_name_table), | |
1819 | (_bfd_write_archive_contents, _bfd_compute_and_write_armap), | |
1820 | (_bfd_bsd_write_armap): Likewise. | |
1821 | * bfd.c (bfd_errmsg, _bfd_doprnt): Likewise. | |
1822 | * cache.c (bfd_open_file): Likewise. | |
1823 | * ecoff.c (_bfd_ecoff_write_armap): Likewise. | |
1824 | * ecofflink.c (bfd_ecoff_debug_accumulate_other): Likewise. | |
1825 | * elf32-bfin.c (bfinfdpic_relocate_section): Likewise. | |
1826 | * elf32-frv.c (elf32_frv_relocate_section): Likewise. | |
1827 | * elf32-hppa.c (elf32_hppa_final_link): Likewise. | |
1828 | * elf32-nds32.c (nds32_elf_output_symbol_hook), | |
1829 | (patch_tls_desc_to_ie): Likewise. | |
1830 | * elf32-spu.c (sort_bfds, print_one_overlay_section), | |
1831 | (spu_elf_auto_overlay): Likewise. | |
1832 | * elf64-hppa.c (elf_hppa_final_link): Likewise. | |
1833 | * elf64-ia64-vms.c (elf64_ia64_size_dynamic_sections): Likewise. | |
1834 | * elfcore.h (elf_core_file_matches_executable_p): Likewise. | |
1835 | * elflink.c (bfd_elf_size_dynamic_sections), | |
1836 | (elf_link_input_bfd): Likewise. | |
1837 | * linker.c (_bfd_generic_link_output_symbols): Likewise. | |
1838 | * mach-o.c (bfd_mach_o_follow_dsym), | |
1839 | (bfd_mach_o_close_and_cleanup): Likewise. | |
1840 | * opncls.c (_bfd_delete_bfd, _maybe_make_executable), | |
1841 | (find_separate_debug_file, get_build_id_name): Likewise. | |
1842 | * pdp11.c (aout_find_nearest_line, aout_link_write_symbols): Likewise. | |
1843 | * plugin.c (bfd_plugin_open_input): Likewise. | |
1844 | * rs6000-core.c (rs6000coff_core_file_matches_executable_p): Likewise. | |
1845 | * som.c (som_write_armap): Likewise. | |
1846 | * srec.c (srec_write_record, srec_write_symbols): Likewise. | |
1847 | * vms-lib.c (_bfd_vms_lib_get_imagelib_file), | |
1848 | (_bfd_vms_lib_write_archive_contents): Likewise. | |
1849 | * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise. | |
1850 | ||
39a1432c AM |
1851 | 2020-05-19 Alan Modra <amodra@gmail.com> |
1852 | ||
1853 | PR 25713 | |
1854 | * bfdio.c (_bfd_real_fopen): Typo fix. | |
1855 | ||
ed02cdb5 NC |
1856 | 2020-05-18 Nick Clifton <nickc@redhat.com> |
1857 | ||
1858 | PR 26005 | |
1859 | * elf.c (bfd_section_from_shdr): Use bfd_malloc to allocate memory | |
1860 | for the sections_being_created array. | |
1861 | ||
7a87e9c8 AM |
1862 | 2020-05-18 Alan Modra <amodra@gmail.com> |
1863 | ||
1864 | * ecoff.c (ecoff_slurp_reloc_table): Malloc external_relocs so | |
1865 | they can be freed without also freeing internal_relocs. | |
1866 | ||
ca859a89 JC |
1867 | 2020-05-18 Jaydeep Chauhan <jaydeepchauhan1494@gmail.com> |
1868 | ||
1869 | PR 25713 | |
1870 | * bfdio.c (_bfd_real_fopen): Convert UNIX style sirectory | |
1871 | separators into DOS style when creating a WIN32 fullpath. | |
1872 | ||
fc46e8bd NC |
1873 | 2020-05-14 Nelson Chu <nelson.chu@sifive.com> |
1874 | ||
1875 | * elfnn-riscv.c (elfNN_riscv_mkobject): New function. We need this | |
1876 | to initialize RISC-V tdata. | |
1877 | ||
533f049e GN |
1878 | 2020-05-12 Gunther Nikl <gnikl@justmail.de> |
1879 | ||
1880 | * aoutx.h (NAME (aout, swap_std_reloc_out)): Reject an unsupported | |
1881 | relocation size. | |
1882 | ||
94ba9882 AM |
1883 | 2020-05-11 Alan Modra <amodra@gmail.com> |
1884 | ||
1885 | * elf64-ppc.c (xlate_pcrel_opt): Handle lxvp and stxvp. | |
1886 | ||
7c1f4227 AM |
1887 | 2020-05-11 Alan Modra <amodra@gmail.com> |
1888 | ||
1889 | * elf64-ppc.c: Rename powerxx to power10 throughout. | |
1890 | ||
4d5acb1e AM |
1891 | 2020-05-11 Alan Modra <amodra@gmail.com> |
1892 | ||
1893 | PR 25961 | |
1894 | * coffgen.c (coff_get_normalized_symtab): Check that buffer | |
1895 | contains required number of auxents before processing any auxent. | |
1896 | * coffswap.h (coff_swap_aux_in <C_FILE>): Only swap in extended | |
1897 | file name from auxents for PE. | |
1898 | ||
7242fa8a GN |
1899 | 2020-05-04 Gunther Nikl <gnikl@justmail.de> |
1900 | ||
1901 | * aout-cris.c (DEFAULT_ARCH): Delete define. | |
1902 | (MY_set_arch_mach): Likewise. | |
1903 | (SET_ARCH_MACH): Use bfd_set_arch_mach with an explicit architecture | |
1904 | of bfd_arch_cris. | |
1905 | (swap_ext_reloc_in): Add casts to r_index extraction. Mask valid bits | |
1906 | of r_type before the shift. | |
1907 | ||
1908 | 2020-05-04 Wilco Dijkstra <wdijkstr@arm.com> | |
cff69cf4 WD |
1909 | |
1910 | PR ld/25665 | |
1911 | * elfnn-aarch64.c (group_sections): Copy implementation from | |
1912 | elf32-arm.c. | |
1913 | ||
a2714d6c AM |
1914 | 2020-05-01 Alan Modra <amodra@gmail.com> |
1915 | ||
1916 | PR 25900 | |
1917 | * elfnn-riscv.c (_bfd_riscv_relax_section): Check root.type before | |
1918 | accessing root.u.def of symbols. Also check root.u.def.section | |
1919 | is non-NULL. Reverse tests so as to make the logic positive. | |
1920 | ||
a8acd6ee AM |
1921 | 2020-05-01 Alan Modra <amodra@gmail.com> |
1922 | ||
1923 | PR 25882 | |
1924 | * elf32-tic6x.c (elf32_tic6x_merge_attributes): Don't transfer | |
1925 | Tag_ABI_PIC or Tag_ABI_PID from dynamic objects to the output. | |
1926 | ||
6b728d32 AM |
1927 | 2020-05-01 Alan Modra <amodra@gmail.com> |
1928 | ||
1929 | PR 25882 | |
1930 | * elf32-bfin.c (elf32_bfin_merge_private_bfd_data): Add FIXME. | |
1931 | * elf32-frv.c (frv_elf_merge_private_bfd_data): Likewise. | |
1932 | * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise. | |
1933 | * elf32-nds32.c (nds32_elf_merge_private_bfd_data): Likewise. | |
1934 | * elf32-score.c (s3_elf32_score_merge_private_bfd_data): Likewise. | |
1935 | * elf32-score7.c (s7_elf32_score_merge_private_bfd_data): Likewise. | |
1936 | * elf32-sh.c (sh_elf_merge_private_data): Likewise. | |
1937 | * elf32-tic6x.c (elf32_tic6x_merge_attributes): Likewise. | |
1938 | * elf64-ia64-vms.c (elf64_ia64_merge_private_bfd_data): Likewise. | |
1939 | * elfnn-ia64.c (elfNN_ia64_merge_private_bfd_data): Likewise. | |
1940 | ||
91ed9b71 AM |
1941 | 2020-05-01 Alan Modra <amodra@gmail.com> |
1942 | ||
1943 | PR 25882 | |
1944 | * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Ignore e_flags | |
1945 | from shared libraries. | |
1946 | ||
d548f47d MF |
1947 | 2020-04-29 Max Filippov <jcmvbkbc@gmail.com> |
1948 | ||
1949 | * elf32-xtensa.c (relax_section): Don't negate diff_value for | |
1950 | XTENSA_NDIFF relocations. Don't add sign bits whe diff_value | |
1951 | equals 0. Report overflow when the result has negative sign but | |
1952 | all significant bits are zero. | |
1953 | ||
dfa85db1 GN |
1954 | 2020-04-29 Gunther Nikl <gnikl@justmail.de> |
1955 | ||
1956 | * aoutx.h (swap_std_reloc_out): Special case 64 bit relocations. | |
1957 | (aout_link_reloc_link_order): Likewise. Make r_length an unsigned. | |
1958 | ||
48e5bada AM |
1959 | 2020-04-28 Alan Modra <amodra@gmail.com> |
1960 | ||
1961 | * vms-alpha.c (_bfd_vms_slurp_etir): Correct divide by zero check. | |
1962 | Emit warning message. | |
1963 | ||
251dae91 TC |
1964 | 2020-04-27 Tamar Christina <tamar.christina@arm.com> |
1965 | ||
1966 | * coff-i386.c (COFF_WITH_PE_BIGOBJ): New. | |
1967 | * coff-x86_64.c (COFF_WITH_PE_BIGOBJ): New. | |
1968 | * config.bfd (targ_selvecs): Rename x86_64_pe_be_vec | |
1969 | to x86_64_pe_big_vec as it not a big-endian format. | |
1970 | (vec i386_pe_big_vec): New. | |
1971 | * configure.ac: Likewise. | |
1972 | * targets.c: Likewise. | |
1973 | * configure: Regenerate. | |
1974 | * pe-i386.c (TARGET_SYM_BIG, TARGET_NAME_BIG, | |
1975 | COFF_WITH_PE_BIGOBJ): New. | |
1976 | * pe-x86_64.c (TARGET_SYM_BIG, TARGET_NAME_BIG): | |
1977 | New. | |
1978 | (x86_64_pe_be_vec): Moved. | |
1979 | ||
27456742 AK |
1980 | 2020-04-23 Anton Kolesov <anton.kolesov@synopsys.com> |
1981 | ||
1982 | * elf-bfd.h (elfcore_write_arc_v2): Add prototype. | |
1983 | * elf.c (elfcore_grok_arc_v2): New function. | |
1984 | (elfcore_grok_note): Call the new function to handle the corresponding | |
1985 | note. | |
1986 | (elfcore_write_arc_v2): New function. | |
1987 | (elfcore_write_register_note): Call the new function to handle the | |
1988 | corresponding pseudo-sections. | |
1989 | ||
30ce8e47 MF |
1990 | 2020-04-22 Max Filippov <jcmvbkbc@gmail.com> |
1991 | ||
1992 | PR ld/25861 | |
1993 | * bfd-in2.h: Regenerated. | |
1994 | * elf32-xtensa.c (elf_howto_table): New entries for | |
1995 | R_XTENSA_PDIFF{8,16,32} and R_XTENSA_NDIFF{8,16,32}. | |
1996 | (elf_xtensa_reloc_type_lookup, elf_xtensa_do_reloc) | |
1997 | (relax_section): Add cases for R_XTENSA_PDIFF{8,16,32} and | |
1998 | R_XTENSA_NDIFF{8,16,32}. | |
1999 | * libbfd.h (bfd_reloc_code_real_names): Add names for | |
2000 | BFD_RELOC_XTENSA_PDIFF{8,16,32} and | |
2001 | BFD_RELOC_XTENSA_NDIFF{8,16,32}. | |
2002 | * reloc.c: Add documentation for BFD_RELOC_XTENSA_PDIFF{8,16,32} | |
2003 | and BFD_RELOC_XTENSA_NDIFF{8,16,32}. | |
2004 | ||
c36876fe TC |
2005 | 2020-04-21 Tamar Christina <tamar.christina@arm.com> |
2006 | ||
2007 | PR binutils/24753 | |
2008 | * compress.c (bfd_get_full_section_contents): Exclude sections with no | |
2009 | content. | |
2010 | ||
6f6fd151 L |
2011 | 2020-04-21 H.J. Lu <hongjiu.lu@intel.com> |
2012 | ||
2013 | PR ld/25849 | |
2014 | * elf-bfd.h (elf_backend_data): Add | |
2015 | elf_backend_strip_zero_sized_dynamic_sections. | |
2016 | (_bfd_elf_strip_zero_sized_dynamic_sections): New prototype. | |
2017 | * elf64-alpha.c (elf_backend_strip_zero_sized_dynamic_sections): | |
2018 | New macro. | |
2019 | * elflink.c (_bfd_elf_strip_zero_sized_dynamic_sections): New | |
2020 | function. | |
2021 | * elfxx-target.h (elf_backend_strip_zero_sized_dynamic_sections): | |
2022 | New macro. | |
2023 | (elfNN_bed): Add elf_backend_strip_zero_sized_dynamic_sections. | |
2024 | ||
1f7f2abb L |
2025 | 2020-04-21 H.J. Lu <hongjiu.lu@intel.com> |
2026 | ||
2027 | * elf64-alpha.c (alpha_elf_reloc_entry): Replace reltext with | |
2028 | sec. | |
2029 | (elf64_alpha_check_relocs): Set sec instead of reltext. Warn | |
2030 | DT_TEXTREL with -M. | |
2031 | (elf64_alpha_calc_dynrel_sizes): Warn DT_TEXTREL with -M. | |
2032 | ||
e04f33c0 NC |
2033 | 2020-04-21 Nick Clifton <nickc@redhat.com> |
2034 | ||
2035 | * po/sr.po: Updated Serbian translation. | |
2036 | ||
fad3d2c1 AM |
2037 | 2020-04-21 Alan Modra <amodra@gmail.com> |
2038 | ||
2039 | * elf32-sh.c (sh_elf_relocate_section): Remove STO_SH5_ISA32 | |
2040 | processing. | |
2041 | ||
23c8270e SC |
2042 | 2020-04-20 Stephen Casner <casner@acm.org> |
2043 | ||
2044 | * pdp11.c (N_STAB): Modify value to avoid conflict with N_EXT | |
2045 | causing globals from linker script to be treated as debug symbols. | |
2046 | (translate_symbol_table): Don't sign-extend symbol values from 16 | |
2047 | to 64 bits in nm output. | |
2048 | ||
2efec98b AM |
2049 | 2020-04-20 Alan Modra <amodra@gmail.com> |
2050 | ||
2051 | * elf64-ppc.c (ppc64_elf_size_stubs): Strip relbrlt too. | |
2052 | ||
18f97353 AM |
2053 | 2020-04-18 Alan Modra <amodra@gmail.com> |
2054 | ||
2055 | * section.c (bfd_is_const_section): Correct test for special | |
2056 | sections. | |
2057 | * bfd-in2.h: Regenerate. | |
2058 | ||
8d55d10a AM |
2059 | 2020-04-17 Alan Modra <amodra@gmail.com> |
2060 | ||
2061 | PR 25842 | |
2062 | * elf.c (_bfd_elf_get_symbol_version_string): Don't segfault on | |
2063 | NULL nodename. | |
2064 | ||
8e4979ac NC |
2065 | 2020-04-16 Nick Clifton <nickc@redhat.com> |
2066 | ||
2067 | PR 25803 | |
2068 | * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Replace an | |
2069 | abort with a more helpful error message. | |
2070 | ||
aec72fda AM |
2071 | 2020-04-16 Alan Modra <amodra@gmail.com> |
2072 | ||
2073 | PR 25827 | |
2074 | * dwarf2.c (scan_unit_for_symbols): Wrap overlong lines. Don't | |
2075 | strdup(0). | |
2076 | ||
95a51568 FS |
2077 | 2020-04-15 Fangrui Song <maskray@google.com> |
2078 | ||
2079 | PR binutils/24613 | |
2080 | * coff-rs6000.c (xcoff_ppc_relocate_section): Change RM_GENERATE_ERROR | |
2081 | to RM_DIAGNOSE plus a check of warn_unresolved_syms. | |
2082 | * coff64-rs6000.c (xcoff_ppc_relocate_section): Likewise. | |
2083 | * elf-bfd.h (_bfd_elf_large_com_section): Likewise. | |
2084 | * elf32-m32r.c (m32r_elf_relocate_section): Likewise. | |
2085 | * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise. | |
2086 | * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise. | |
2087 | * elf32-sh.c (sh_elf_relocate_section): Likewise. | |
2088 | * elf32-spu.c (spu_elf_relocate_section): Likewise. | |
2089 | * elf64-hppa.c (elf64_hppa_relocate_section): Likewise. | |
2090 | * elflink.c (elf_link_output_extsym): Likewise. | |
2091 | * elfxx-mips.c (mips_elf_calculate_relocation): Likewise. | |
2092 | ||
7ecb5154 AM |
2093 | 2020-04-15 Alan Modra <amodra@gmail.com> |
2094 | ||
2095 | PR 25823 | |
2096 | * peXXigen.c (_bfd_XXi_swap_sym_in <C_SECTION>): Don't use a | |
2097 | pointer into strings that may be freed for section name, always | |
2098 | allocate a new string. | |
2099 | ||
f717994f JMG |
2100 | 2020-04-14 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
2101 | Jan W. Jagersma <jwjagersma@gmail.com> | |
2102 | ||
2103 | * coff-go32.c (COFF_GO32, IMAGE_SCN_LNK_NRELOC_OVFL) | |
2104 | (coff_SWAP_scnhdr_in, coff_SWAP_scnhdr_out): Define. | |
2105 | (_bfd_go32_swap_scnhdr_in, _bfd_go32_swap_scnhdr_out) | |
2106 | (_bfd_go32_mkobject): New functions. | |
2107 | * coff-stgo32.c (IMAGE_SCN_LNK_NRELOC_OVFL) | |
2108 | (coff_SWAP_scnhdr_in, coff_SWAP_scnhdr_out): Define. | |
2109 | (go32exe_mkobject): Call _bfd_go32_mkobject. | |
2110 | * coffcode.h (COFF_WITH_EXTENDED_RELOC_COUNTER): Define. | |
2111 | (coff_set_alignment_hook): Define function for COFF_GO32_EXE | |
2112 | and COFF_GO32. | |
2113 | (coff_write_relocs): Enable extended reloc counter code if | |
2114 | COFF_WITH_EXTENDED_RELOC_COUNTER is defined. Test for obj_go32. | |
2115 | (coff_write_object_contents): Likewise. Pad section headers | |
2116 | for COFF_GO32 and COFF_GO32EXE. Use bfd_coff_swap_scnhdr_out | |
2117 | instead of coff_swap_scnhdr_out. | |
2118 | * cofflink.c (_bfd_coff_final_link): Test also for obj_go32 to | |
2119 | enable extended reloc counter. | |
2120 | * coffswap.h: (coff_swap_scnhdr_in, coff_swap_scnhdr_out): | |
2121 | Declare with ATTRIBUTE_UNUSED. | |
2122 | * libcoff-in.h: (struct coff_tdata): New field go32. | |
2123 | (obj_go32): Define. | |
2124 | * libcoff.h: Regenerate. | |
2125 | ||
34ca5531 FS |
2126 | 2020-04-14 Fangrui Song <maskray@google.com> |
2127 | ||
2128 | PR gas/25768 | |
2129 | * elf.c (assign_section_numbers): Always set .stab sh_entsize to | |
2130 | 12. | |
2131 | ||
fa1477dc SC |
2132 | 2020-04-14 Stephen Casner <casner@acm.org> |
2133 | ||
2134 | PR ld/25677 | |
2135 | * pdp11.c: Add implementation of --imagic option. | |
2136 | (adjust_o_magic): Fix objcopy --extract-symbol test. | |
2137 | * libaout.h (enum aout_magic): Add i_magic. | |
2138 | ||
a0543b0b RO |
2139 | 2020-04-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> |
2140 | Nick Clifton <nickc@redhat.com> | |
2141 | ||
2142 | * elf32-sparc.c (sparc_final_write_processing): Fix whitespace. | |
2143 | <0>: Ignore. | |
2144 | <default>: Error rather than abort. | |
2145 | ||
3349112e L |
2146 | 2020-04-03 H.J. Lu <hongjiu.lu@intel.com> |
2147 | ||
2148 | PR ld/25767 | |
2149 | * elf.c (_bfd_elf_fixup_group_sections): Remove zero-sized | |
2150 | relocation section from section group. | |
2151 | ||
4d095f5b JJ |
2152 | 2020-04-02 Jan W. Jagersma <jwjagersma@gmail.com> |
2153 | ||
2154 | * bfdio.c (bfd_bread, bfd_tell, bfd_seek, bfd_mmap): Always add | |
2155 | bfd->origin to file offset. | |
2156 | * bfdwin.c (bfd_get_file_window): Likewise. | |
2157 | * bfd.c: Clarify the use of the bfd->origin field. | |
2158 | * bfd-in2.h: Regenerate. | |
2159 | * coff-i386.c: Don't include go32exe.h. Allow overriding | |
2160 | coff_write_object_contents via COFF_WRITE_CONTENTS. | |
2161 | * coff-stgo32.c (go32exe_cleanup, go32exe_mkobject) | |
2162 | (go32exe_write_object_contents): New functions. | |
2163 | (go32exe_temp_stub, go32exe_temp_stub_size): New static globals. | |
2164 | (COFF_WRITE_CONTENTS, GO32EXE_DEFAULT_STUB_SIZE): Define. | |
2165 | (create_go32_stub): Remove check for 2k size limit. Read stub | |
2166 | from go32exe_temp_stub if present. | |
2167 | (go32_stubbed_coff_bfd_copy_private_bfd_data): Allocate and | |
2168 | copy variable-length stub. | |
2169 | (go32_check_format): Read stub to go32exe_temp_stub, set | |
2170 | origin, return go32exe_cleanup. | |
2171 | (adjust_filehdr_in_post, adjust_filehdr_out_pre) | |
2172 | (adjust_filehdr_out_post, adjust_scnhdr_in_post) | |
2173 | (adjust_scnhdr_out_pre, adjust_scnhdr_out_post) | |
2174 | (adjust_aux_in_post, adjust_aux_out_pre, adjust_aux_out_post): | |
2175 | Remove functions and their associated #defines. | |
2176 | * coffcode.h (coff_mkobject_hook): Remove stub copying code. | |
2177 | * libcoff-in.h: (struct coff_tdata): New field stub_size. | |
2178 | Rename field go32stub to stub. | |
2179 | * libcoff.h: Regenerate. | |
2180 | * coff-stgo32.c (go32_check_format): Rename to... | |
2181 | (go32exe_check_format): ...this. | |
2182 | (go32_stubbed_coff_bfd_copy_private_bfd_data): Rename to... | |
2183 | (go32exe_copy_private_bfd_data): ...this. | |
2184 | (stub_bytes): Rename to... | |
2185 | (go32exe_default_stub): ...this. | |
2186 | (create_go32_stub): Rename to... | |
2187 | (go32exe_create_stub): ...this. | |
2188 | * coff-stgo32.c (go32exe_copy_private_bfd_data): Avoid realloc | |
2189 | when possible. | |
2190 | ||
382aae06 L |
2191 | 2020-04-01 H.J. Lu <hongjiu.lu@intel.com> |
2192 | ||
2193 | PR ld/25749 | |
2194 | PR ld/25754 | |
2195 | * elf32-i386.c (elf_i386_convert_load_reloc): Convert load | |
2196 | relocation to R_386_32 for relocation against non-preemptible | |
2197 | absolute symbol. | |
2198 | (elf_i386_check_relocs): Call _bfd_elf_x86_valid_reloc_p. Don't | |
2199 | allocate dynamic relocation for non-preemptible absolute symbol. | |
2200 | (elf_i386_relocate_section): Pass sec to | |
2201 | GENERATE_DYNAMIC_RELOCATION_P. | |
2202 | * elf64-x86-64.c (R_X86_64_converted_reloc_bit): Moved. | |
2203 | (elf_x86_64_convert_load_reloc): Covert load relocation to | |
2204 | R_X86_64_32S or R_X86_64_32 for relocation against non-preemptible | |
2205 | absolute symbol. Don't convert to R_X86_64_32S nor R_X86_64_32 | |
2206 | for non-preemptible absolute symbol if they overflow. | |
2207 | (elf_x86_64_check_relocs): Call _bfd_elf_x86_valid_reloc_p. Set | |
2208 | tls_type for GOT slot to GOT_ABS for non-preemptible absolute | |
2209 | symbol. Don't allocate dynamic relocation for non-preemptible | |
2210 | absolute symbol. | |
2211 | (elf_x86_64_relocate_section): Don't generate relative relocation | |
2212 | for GOTPCREL relocations aganst local absolute symbol. Pass sec | |
2213 | to GENERATE_DYNAMIC_RELOCATION_P. | |
2214 | * elfxx-x86.c (elf_x86_allocate_dynrelocs): No dynamic relocation | |
2215 | against non-preemptible absolute symbol. | |
2216 | (_bfd_elf_x86_valid_reloc_p): New function. | |
2217 | (_bfd_x86_elf_size_dynamic_sections): No dynamic relocation for | |
2218 | GOT_ABS GOT slot. | |
2219 | * elfxx-x86.h (GENERATE_DYNAMIC_RELOCATION_P): Add an SEC | |
2220 | argument. Don't generate dynamic relocation against | |
2221 | non-preemptible absolute symbol. | |
2222 | (ABS_SYMBOL_P): New. | |
2223 | (GENERATE_RELATIVE_RELOC_P): Don't generate relative relocation | |
2224 | against non-preemptible absolute symbol. | |
2225 | (GOT_ABS): New. | |
2226 | (R_X86_64_converted_reloc_bit): New. Moved from elf64-x86-64.c. | |
2227 | (_bfd_elf_x86_valid_reloc_p): New. | |
2228 | ||
a7618269 TC |
2229 | 2020-04-01 Tamar Christina <tamar.christina@arm.com> |
2230 | ||
2231 | PR ld/16017 | |
2232 | * elf32-arm.c (elf32_arm_populate_plt_entry): Set LSB of the PLT0 | |
2233 | address in the GOT if in thumb only mode. | |
2234 | ||
15ccbdd7 TC |
2235 | 2020-04-01 Tamar Christina <tamar.christina@arm.com> |
2236 | ||
2237 | * elf32-arm.c (elf32_thumb2_plt_entry): Fix PC-rel offset. | |
2238 | ||
7b948a25 HPN |
2239 | 2020-04-01 Hans-Peter Nilsson <hp@bitrange.com> |
2240 | ||
2241 | * mmo.c (mmo_scan): Create .text section only when needed, not | |
2242 | from the start. | |
2243 | ||
89b599df AM |
2244 | 2020-03-31 Alan Modra <amodra@gmail.com> |
2245 | ||
2246 | * coff-alpha.c (alpha_ecoff_get_elt_at_filepos): Correct bfd_bread | |
2247 | return value check. | |
2248 | ||
81699544 AM |
2249 | 2020-03-31 Alan Modra <amodra@gmail.com> |
2250 | ||
2251 | * vms-alpha.c (image_write): Check bounds for sections without | |
2252 | contents too. Error on non-zero write to section without | |
2253 | contents. | |
2254 | (_bfd_vms_slurp_etir): Check return of image_write* functions. | |
2255 | ||
b3b360de AM |
2256 | 2020-03-31 Alan Modra <amodra@gmail.com> |
2257 | ||
2258 | * tekhex.c (pass_over): Check is_eof before reading buffer. | |
2259 | ||
00386881 NC |
2260 | 2020-03-30 Nick Clifton <nickc@redhat.com> |
2261 | ||
2262 | PR binutils/pr25662 | |
2263 | * libcoff-in.h (struct pe_tdata): Rename the insert_timestamp | |
2264 | field to timestamp and make it an integer. | |
2265 | * libcoff.h: Regenerate. | |
2266 | * peXXigen.c (_bfd_XXi_only_swap_filehdr_out): Test the timestamp | |
2267 | field in the pe_data structure rather than the insert_timestamp | |
2268 | field. | |
2269 | ||
988b7300 AM |
2270 | 2020-03-30 Alan Modra <amodra@gmail.com> |
2271 | ||
2272 | PR 25745 | |
2273 | * elf64-ppc.c (ppc64_elf_build_stubs): Use asprintf to form | |
2274 | statistics message. | |
2275 | ||
aa49fc22 NC |
2276 | 2020-03-26 Nick Clifton <nickc@redhat.com> |
2277 | ||
2278 | * cofflink.c (bfd_coff_get_internal_extra_pe_aouthdr): Delete. | |
2279 | * libbfd-in.h (bfd_coff_get_internal_extra_pe_aouthdr): Remove | |
2280 | prototype. | |
2281 | * libbfd.h: Regenerate. | |
2282 | ||
ff768510 AM |
2283 | 2020-03-26 Alan Modra <amodra@gmail.com> |
2284 | ||
2285 | * i386msdos.c (msdos_object_p): Catch -1 return from bfd_bread. | |
2286 | ||
f75fbe8a AM |
2287 | 2020-03-26 Alan Modra <amodra@gmail.com> |
2288 | ||
2289 | * vms-alpha.c (dst_define_location): Limit size of dst_ptr_offsets | |
2290 | array. | |
2291 | (_bfd_vms_slurp_object_records): Rename "err" to "ok". | |
2292 | ||
aac88046 NC |
2293 | 2020-03-25 Nick Clifton <nickc@redhat.com> |
2294 | ||
2295 | * cofflink.c (bfd_coff_get_internal_extra_pe_aouthdr): New | |
2296 | function. | |
2297 | * libbfd-in.h (bfd_coff_get_internal_extra_pe_aouthdr): Prototype. | |
2298 | * libbfd.h: Regenerate. | |
2299 | ||
cf2611fe SV |
2300 | 2020-03-25 Shahab Vahedi <shahab@synopsys.com> |
2301 | ||
2302 | * elf32-arc.c (PRINT_DEBUG_RELOC_INFO_BEFORE): Use the | |
2303 | correct field name in the output string. | |
2304 | ||
d16e3d2e AM |
2305 | 2020-03-25 Alan Modra <amodra@gmail.com> |
2306 | ||
2307 | PR 25662 | |
2308 | * elf.c (assign_file_positions_for_load_sections): Adjust offset | |
2309 | for SHT_NOBITS section if first in segment. | |
2310 | ||
1081065c L |
2311 | 2020-03-24 H.J. Lu <hongjiu.lu@intel.com> |
2312 | ||
2313 | PR binutils/25708 | |
2314 | * elf-bfd.h (_bfd_elf_get_symbol_version_name): Renamed to ... | |
2315 | (_bfd_elf_get_symbol_version_string): This. | |
2316 | * elf.c (_bfd_elf_get_symbol_version_name): Renamed to ... | |
2317 | (_bfd_elf_get_symbol_version_string): This. | |
2318 | (bfd_elf_print_symbol): Pass TRUE to | |
2319 | _bfd_elf_get_symbol_version_string. | |
2320 | * libbfd-in.h (_bfd_nosymbols_get_symbol_version_string): Add a | |
2321 | bfd_boolean argument. | |
2322 | * syms.c (_bfd_nosymbols_get_symbol_version_string): Likewise. | |
2323 | * targets.c (_bfd_get_symbol_version_string): Likewise. | |
2324 | (bfd_get_symbol_version_string): Likewise. | |
2325 | * bfd-in2.h: Regenerated. | |
2326 | ||
0b8448af | 2327 | 2020-03-24 Nick Clifton <nickc@redhat.com> |
e11cd7c4 | 2328 | Jaydeep Chauhan <jaydeepchauhan1494@gmail.com> |
0b8448af NC |
2329 | |
2330 | PR 25713 | |
2331 | * bfdio.c (_bfd_real_fopen): Add code to handle long filenames on | |
2332 | Win32 systems. | |
2333 | ||
ec2e748a NC |
2334 | 2020-03-24 Nick Clifton <nickc@redhat.com> |
2335 | ||
2336 | PR 25681 | |
2337 | * elf.c (_bfd_elf_map_sections_to_segments): When looking for a | |
2338 | segment to use for PT_GNU_RELRO, ignore empty sections in a | |
2339 | segment's current list. | |
2340 | ||
cda7e560 L |
2341 | 2020-03-24 H.J. Lu <hongjiu.lu@intel.com> |
2342 | ||
2343 | PR binutils/25717 | |
2344 | * elf-bfd.h (elf_obj_tdata): Change num_group to unsigned int. | |
2345 | ||
7e6e972f L |
2346 | 2020-03-24 H.J. Lu <hongjiu.lu@intel.com> |
2347 | ||
2348 | PR binutils/25708 | |
2349 | * elf-bfd.h (_bfd_elf_get_symbol_version_name): New. | |
2350 | * elf.c (_bfd_elf_get_symbol_version_name): New function. Based | |
2351 | on the previous _bfd_elf_get_symbol_version_string. | |
2352 | (_bfd_elf_get_symbol_version_string): Use it. | |
2353 | ||
65109548 AM |
2354 | 2020-03-24 Alan Modra <amodra@gmail.com> |
2355 | ||
2356 | * archive.c (_bfd_generic_read_ar_hdr_mag): Sanity check extended | |
2357 | name size. Use bfd_malloc rather than bfd_zmalloc, clearing just | |
2358 | struct areltdata. | |
2359 | ||
fdde2fb6 SH |
2360 | 2020-03-23 Sebastian Huber <sebastian.huber@embedded-brains.de> |
2361 | ||
2362 | * elflink.c (_bfd_elf_tls_setup): Mention .tdata in comment. | |
2363 | ||
cf28cfef AM |
2364 | 2020-03-23 Alan Modra <amodra@gmail.com> |
2365 | ||
2366 | * ecoff.c (_bfd_ecoff_slurp_armap): Sanity check parsed_size and | |
2367 | symbol count. Allocate an extra byte to ensure name strings | |
2368 | are terminated. Sanity check name offsets. Release memory on | |
2369 | error return. | |
2370 | ||
5e737279 AM |
2371 | 2020-03-23 Alan Modra <amodra@gmail.com> |
2372 | ||
2373 | * i386msdos.c (msdos_object_p): Don't access e_lfanew when that | |
2374 | field hasn't been read. Remove unnecessary casts. | |
2375 | ||
c15a8f17 AM |
2376 | 2020-03-22 Alan Modra <amodra@gmail.com> |
2377 | ||
2378 | * coff64-rs6000.c (xcoff64_slurp_armap): Ensure size is large | |
2379 | enough to read number of symbols. | |
2380 | ||
3d98c460 L |
2381 | 2020-03-20 H.J. Lu <hongjiu.lu@intel.com> |
2382 | ||
2383 | * configure.ac (HAVE_EXECUTABLE_SUFFIX): Removed. | |
2384 | (EXECUTABLE_SUFFIX): Likewise. | |
2385 | * config.in: Regenerated. | |
2386 | * configure: Likewise. | |
2387 | * plugin.c (bfd_plugin_close_and_cleanup): Defined as | |
2388 | _bfd_generic_close_and_cleanup. | |
2389 | (plugin_list_entry): Remove resolution_file, resolution_option, | |
2390 | real_bfd, real_nsyms, real_syms, lto_nsyms, lto_syms, gcc, | |
2391 | lto_wrapper, gcc_env and initialized, | |
2392 | (need_lto_wrapper_p): Removed. | |
2393 | (get_lto_wrapper): Likewise. | |
2394 | (setup_lto_wrapper_env): Likewise. | |
2395 | (register_all_symbols_read): Likewise. | |
2396 | (egister_cleanup): Likewise. | |
2397 | (get_symbols): Likewise. | |
2398 | (add_input_file): Likewise. | |
2399 | (bfd_plugin_set_program_name): Remove need_lto_wrapper. | |
2400 | (add_symbols): Updated. | |
2401 | (try_claim): Likewise. | |
2402 | (try_load_plugin): Likewise. | |
2403 | (bfd_plugin_canonicalize_symtab): Likewise. | |
2404 | * plugin.h (bfd_plugin_set_program_name): Remove int argument. | |
2405 | (plugin_data_struct): Remove real_bfd, real_nsyms and real_syms. | |
2406 | ||
c3a1714c L |
2407 | 2020-03-19 H.J. Lu <hongjiu.lu@intel.com> |
2408 | ||
2409 | PR binutils/25640 | |
2410 | * plugin.c (plugin_list_entry): Add has_symbol_type. | |
2411 | (add_symbols_v2): New function. | |
2412 | (bfd_plugin_open_input): Don't invoke LTO wrapper if LTO plugin | |
2413 | provides symbol type. | |
2414 | (try_load_plugin): Add LDPT_ADD_SYMBOLS_V2. | |
2415 | (bfd_plugin_canonicalize_symtab): Use LTO plugin symbol type if | |
2416 | available. | |
2417 | ||
67338173 AM |
2418 | 2020-03-20 Alan Modra <amodra@gmail.com> |
2419 | ||
2420 | * coff-rs6000.c (_bfd_xcoff_slurp_armap): Ensure size is large | |
2421 | enough to read number of symbols. | |
2422 | ||
a859124d AM |
2423 | 2020-03-20 Alan Modra <amodra@gmail.com> |
2424 | ||
2425 | * elf.c (_bfd_elf_setup_sections): Don't test known non-NULL | |
2426 | backend functions for NULL before calling. | |
2427 | (copy_special_section_fields, _bfd_elf_copy_private_bfd_data), | |
2428 | (bfd_section_from_shdr, assign_section_numbers): Likewise. | |
2429 | * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): Likewise. | |
2430 | * elfnn-ia64.c (ignore_errors): New function. | |
2431 | (elf_backend_link_order_error_handler): Redefine as ignore_errors. | |
2432 | ||
f3a08f77 NC |
2433 | 2020-03-19 Nick Clifton <nickc@redhat.com> |
2434 | ||
2435 | PR 25676 | |
2436 | * dwarf2.c (struct varinfo): Add unit_offset field to record the | |
2437 | location of the varinfo in the unit's debug info data. Change the | |
2438 | type of the stack field to a boolean. | |
2439 | (lookup_var_by_offset): New function. Returns the varinfo | |
2440 | structure for the variable described at the given offset in the | |
2441 | unit's debug info. | |
2442 | (scan_unit_for_symbols): Add support for variables which have the | |
2443 | DW_AT_specification attribute. | |
2444 | ||
6a541707 NC |
2445 | 2020-03-19 Nick Clifton <nickc@redhat.com> |
2446 | ||
2447 | PR 25699 | |
2448 | * elf.c (bfd_elf_set_group_contents): Replace assertion with an | |
2449 | error return. | |
2450 | ||
effc14f5 SH |
2451 | 2020-03-19 Sebastian Huber <sebastian.huber@embedded-brains.de> |
2452 | ||
2453 | * elfxx-riscv.c (riscv_parse_subset): Don't use C99. | |
2454 | ||
ac4bf06c NC |
2455 | 2020-03-18 Nick Clifton <nickc@redhat.com> |
2456 | ||
2457 | PR 25673 | |
2458 | * elf.c (_bfd_elf_write_secondary_reloc_section): Fix illegal | |
2459 | memory access when processing a corrupt secondary reloc section. | |
2460 | ||
53215f21 CL |
2461 | 2020-03-18 Christophe Lyon <christophe.lyon@linaro.org> |
2462 | ||
2463 | * elf32-arm.c (arm_build_one_stub): Emit a fatal error message | |
2464 | instead of calling abort. | |
2465 | * elf32-csky.c (csky_build_one_stub): Likewise. | |
2466 | * elf32-hppa.c (hppa_build_one_stub): Likewise. | |
2467 | * elf32-m68hc11.c (m68hc11_elf_build_one_stub): Likewise. | |
2468 | * elf32-m68hc12.c (m68hc12_elf_build_one_stub): Likewise. | |
2469 | * elf32-metag.c (metag_build_one_stub): Likewise. | |
2470 | * elf32-nios2.c (nios2_build_one_stub): Likewise. | |
2471 | * elf64-ppc.c (ppc_build_one_stub): Likewise. | |
2472 | (ppc_size_one_stub): Likewise. | |
2473 | * elfnn-aarch64.c (aarch64_build_one_stub): Likewise. | |
2474 | ||
327ef784 NC |
2475 | 2020-03-17 Nick Clifton <nickc@redhat.com> |
2476 | ||
d3c3c542 | 2477 | PR 25688 |
327ef784 NC |
2478 | * elf.c (_bfd_elf_copy_special_section_fields): Replace assertions |
2479 | with error messages. | |
2480 | ||
ecbbbdba NC |
2481 | 2020-03-17 Nick Clifton <nickc@redhat.com> |
2482 | ||
2483 | PR 25687 | |
2484 | * elf.c (_bfd_elf_slurp_secondary_reloc_section): Remove redundant | |
2485 | free. Add free on another failure path. | |
2486 | ||
4b3ecb3b AM |
2487 | 2020-03-16 Alan Modra <amodra@gmail.com> |
2488 | ||
2489 | PR 25675 | |
2490 | * elf.c (elf_sort_segments): Don't call bfd_octets_per_byte unless | |
2491 | we have a non-zero section count. Do lma comparison in octets. | |
2492 | ||
7bac4137 AM |
2493 | 2020-03-16 Alan Modra <amodra@gmail.com> |
2494 | ||
2495 | * vms-alpha.c (dst_restore_location): Validate index into | |
2496 | dst_ptr_offsets array before accessing. Return status. | |
2497 | (dst_retrieve_location): Similarly, making "loc" parameter a | |
2498 | pointer to return value. | |
2499 | (_bfd_vms_slurp_etir): Update calls to above functions. | |
2500 | ||
8b5d0a4f KR |
2501 | 2020-03-14 Kamil Rytarowski <n54@gmx.com> |
2502 | ||
2503 | * configure.ac: Include netbsd-core.lo for all NetBSD arm and mips | |
2504 | targets. | |
2505 | * configure: Regenerated. | |
2506 | ||
48e81d7f AM |
2507 | 2020-03-14 Alan Modra <amodra@gmail.com> |
2508 | ||
2509 | * section.c (BFD_FAKE_SECTIONS): Formatting. | |
2510 | * bfd-in2.h: Regenerate. | |
2511 | ||
06d949ec KR |
2512 | 2020-03-13 Kamil Rytarowski <n54@gmx.com> |
2513 | ||
2514 | * elf.c (elfcore_grok_netbsd_note): Add support for | |
2515 | NT_NETBSDCORE_LWPSTATUS notes. | |
2516 | ||
abf874aa CL |
2517 | 2020-03-13 Christophe Lyon <christophe.lyon@linaro.org> |
2518 | ||
2519 | * bfd-in2.h: Regenerate. | |
2520 | * section.c (asection): Add already_assigned field. | |
2521 | (BFD_FAKE_SECTION): Add default initializer for it. | |
2522 | * ecoff.c (bfd_debug_section): Initialize already_assigned field. | |
2523 | * elf32-arm.c (arm_build_one_stub): Add support for | |
2524 | non_contiguous_regions. | |
2525 | * elf32-csky.c (csky_build_one_stub): Likewise. | |
2526 | * elf32-hppa.c (hppa_build_one_stub): Likewise. | |
2527 | * elf32-m68hc11.c (m68hc11_elf_build_one_stub): Likewise. | |
2528 | * elf32-m68hc12.c (m68hc12_elf_build_one_stub): Likewise. | |
2529 | * elf32-metag.c (metag_build_one_stub): Likewise. | |
2530 | * elf32-nios2.c (nios2_build_one_stub): Likewise. | |
2531 | * elf64-ppc.c (ppc_build_one_stub): Likewise. | |
2532 | (ppc_size_one_stub): Likewise. | |
2533 | * elfnn-aarch64.c (aarch64_build_one_stub): Likewise. | |
2534 | * elflink.c (elf_link_input_bfd): Likewise. | |
2535 | ||
74e10d17 L |
2536 | 2020-03-13 H.J. Lu <hongjiu.lu@intel.com> |
2537 | ||
2538 | PR ld/24920 | |
2539 | * elf-linker-x86.h (elf_linker_x86_params): Add | |
2540 | static_before_all_inputs and has_dynamic_linker. | |
2541 | * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Report | |
2542 | dynamic input objects if -static is passed at command-line | |
2543 | before all input files without --dynamic-linker unless | |
2544 | --no-dynamic-linker is used. | |
2545 | ||
015ec493 KR |
2546 | 2020-03-13 Kamil Rytarowski <n54@gmx.com> |
2547 | ||
2548 | * elf.c (elfcore_grok_netbsd_note): Add support for aarch64. | |
2549 | ||
66631823 CE |
2550 | 2020-03-13 Christian Eggers <ceggers@gmx.de> |
2551 | ||
2552 | * bfd.c (bfd_record_phdr): New local "opb". Fix assignment of | |
2553 | "p_paddr" from "at". | |
2554 | * elfcode.h (bfd_from_remote_memory): Add units to several | |
2555 | parameters. New local "opb". Fix usage of p_align. Fix | |
2556 | calculation of "localbase" from "ehdr_vma" and "p_vaddr". Fix | |
2557 | call of target_read_memory. | |
2558 | * elflink.c (elf_fixup_link_order): Fix scope of "s" local. Fix | |
2559 | calculation of "offset" and "output_offset". | |
2560 | (bfd_elf_final_link): New local "opb". Fix calculation of "size" | |
2561 | from "offset" and fix calculation of "end" from "vma+size". Fix | |
2562 | comparison between "sh_addr" and "vma"/"output_offset". | |
2563 | (bfd_elf_discard_info): Fix calculation of "eh_alignment". | |
2564 | * elf-bfd.h (struct elf_link_hash_table): Add unit to tls_size | |
2565 | member. | |
2566 | * elf.c (_bfd_elf_map_sections_to_segments): Add unit (bytes/ | |
2567 | octets) to "wrap_to2 and "phdr_size" locals. Fix calculation of | |
2568 | "wrap_to" value. Add unit (bytes) to phdr_lma variable. Fix | |
2569 | assignment of p_paddr from phdr_lma. Fix comparison between | |
2570 | "lma+size" and "next->lma". | |
2571 | (elf_sort_segments): Fix assignment from p_paddr to lma. | |
2572 | (assign_file_positions_for_load_sections): Add unit (bytes) to | |
2573 | local "align". Fix calculation of local "off_adjust". Fix | |
2574 | calculation of local "filehdr_vaddr". | |
2575 | (assign_file_positions_for_non_load_sections): New local "opb". | |
2576 | Fix calculation of "end" from "p_size". Fix comparison between | |
2577 | "vma+SECTION_SIZE" and "start". Fix calculation of "p_memsz" | |
2578 | from "end" and "p_vaddr". | |
2579 | (rewrite_elf_program_header): Fix comparison between p_vaddr and | |
2580 | vma. Fix assignment to p_paddr from lma. Fix comparison between | |
2581 | p_paddr and lma. Fix assignment to p_paddr from lma. | |
2582 | * merge.c (sec_merge_emit): New local "opb". Convert | |
2583 | "alignment_power" to octets. | |
2584 | (_bfd_add_merge_section): New locals "alignment_power" and | |
2585 | "opb". Fix comparison between "alignment_power" and | |
2586 | "sizeof(align)". | |
2587 | (_bfd_merge_sections): New local "opb". Divide size by opb | |
2588 | before checking align mask. | |
2589 | ||
502794d4 CE |
2590 | 2020-03-13 Christian Eggers <ceggers@gmx.de> |
2591 | ||
2592 | * elf.c (_bfd_elf_make_section_from_shdr): Introduce new temp | |
2593 | opb. Divide Elf_Internal_Shdr::sh_addr by opb when setting | |
2594 | section LMA/VMA. | |
2595 | (_bfd_elf_make_section_from_phdr): Similarly. | |
2596 | (elf_fake_sections): Fix calculation of | |
2597 | Elf_Internal_shdr::sh_addr from section VMA. | |
2598 | (_bfd_elf_map_sections_to_segments): Fix mixup between octets | |
2599 | and bytes. | |
2600 | (assign_file_positions_for_load_sections): Fix calculations of | |
2601 | Elf_Internal_shdr::p_vaddr and p_paddr from section LMA/VMA. Fix | |
2602 | comparison between program header address and section LMA. | |
2603 | (assign_file_positions_for_non_load_sections): Likewise. | |
2604 | (rewrite_elf_program_header): Likewise. Introduce new temp opb. | |
2605 | (IS_CONTAINED_BY_VMA): Add parameter opb. | |
2606 | (IS_CONTAINED_BY_LMA,IS_SECTION_IN_INPUT_SEGMENT, | |
2607 | INCLUDE_SECTION_IN_SEGMENT): Likewise. | |
2608 | (copy_elf_program_header): Update call to ELF_SECTION_IN_SEGMENT. | |
2609 | Fix calculations of p_addr_valid and p_vaddr_offset. | |
2610 | * elflink.c (elf_link_add_object_symbols): Multiply section VMA | |
2611 | with octets per byte when comparing against p_vaddr. | |
2612 | ||
8248d21a AM |
2613 | 2020-03-11 Alan Modra <amodra@gmail.com> |
2614 | ||
2615 | * som.c (setup_sections): Sanity check subspace.name. | |
2616 | ||
435edf0b AM |
2617 | 2020-03-11 Alan Modra <amodra@gmail.com> |
2618 | ||
2619 | * elf64-ppc.c (ppc64_elf_inline_plt): Do increment rel in for loop. | |
2620 | ||
6b5e16ff AM |
2621 | 2020-03-10 Alan Modra <amodra@gmail.com> |
2622 | ||
2623 | PR 25648 | |
2624 | * ihex.c (ihex_write_object_contents): Don't assume ordering of | |
2625 | addresses here. | |
2626 | ||
2f57795b AM |
2627 | 2020-03-09 Alan Modra <amodra@gmail.com> |
2628 | ||
2629 | * wasm-module.c (wasm_scan): Sanity check file name length | |
2630 | before allocating memory. Move common section setup code. Do | |
2631 | without bfd_tell to calculate section size. | |
2632 | ||
a0dcf297 NC |
2633 | 2020-03-06 Nick Clifton <nickc@redhat.com> |
2634 | ||
2635 | * elf.c (_bfd_elf_set_section_contents): Replace call to abort | |
2636 | with error messages and failure return values. | |
2637 | ||
e15a8da9 MF |
2638 | 2020-03-05 Max Filippov <jcmvbkbc@gmail.com> |
2639 | ||
2640 | * elf32-xtensa.c (shrink_dynamic_reloc_sections): Shrink dynamic | |
2641 | relocation sections for any removed reference to a dynamic symbol. | |
2642 | ||
a8e14f4c NC |
2643 | 2020-03-05 Nick Clifton <nickc@redhat.com> |
2644 | ||
2645 | * elf-bfd.h (struct elf_backend_data): Add new fields: | |
2646 | init_secondary_reloc_section, slurp_secondary_reloc_section, | |
2647 | write_secondary_reloc_section. | |
2648 | (_bfd_elf_init_secondary_reloc_section): Prototype. | |
2649 | (_bfd_elf_slurp_secondary_reloc_section): Prototype. | |
2650 | (_bfd_elf_write_secondary_reloc_section): Prototype. | |
2651 | * elf.c ( bfd_section_from_shdr): Invoke the new | |
2652 | init_secondary_reloc_section backend function, if defined, when a | |
2653 | second reloc section is encountered. | |
2654 | (swap_out_syms): Invoke the new symbol_section_index function, if | |
2655 | defined, when computing the section index of an OS/PROC specific | |
2656 | symbol. | |
2657 | (_bfd_elf_init_secondary_reloc_section): New function. | |
2658 | (_bfd_elf_slurp_secondary_reloc_section): New function. | |
2659 | (_bfd_elf_write_secondary_reloc_section): New function. | |
2660 | (_bfd_elf_copy_special_section_fields): New function. | |
2661 | * elfcode.h (elf_write_relocs): Invoke the new | |
2662 | write_secondary_relocs function, if defined, in order to emit | |
2663 | secondary relocs. | |
2664 | (elf_slurp_reloc_table): Invoke the new slurp_secondary_relocs | |
2665 | function, if defined, in order to read in secondary relocs. | |
2666 | * elfxx-target.h (elf_backend_copy_special_section_fields): | |
2667 | Provide a non-NULL default definition. | |
2668 | (elf_backend_init_secondary_reloc_section): Likewise. | |
2669 | (elf_backend_slurp_secondary_reloc_section): Likewise. | |
2670 | (elf_backend_write_secondary_reloc_section): Likewise. | |
2671 | (struct elf_backend_data elfNN_bed): Add initialisers for the new | |
2672 | fields. | |
2673 | * configure.ac (score_elf32_[bl]e_vec): Add elf64.lo | |
2674 | * configure: Regenerate. | |
2675 | ||
6f8f95b4 AM |
2676 | 2020-03-05 Alan Modra <amodra@gmail.com> |
2677 | ||
2678 | * archive64.c (_bfd_archive_64_bit_slurp_armap): Check parsed_size | |
2679 | against file size before allocating memory. Use bfd_alloc rather | |
2680 | than bfd_zalloc for carsym/strings memory. | |
2681 | ||
233bf4f8 AM |
2682 | 2020-03-04 Alan Modra <amodra@gmail.com> |
2683 | ||
2684 | * elf.c (elf_fake_sections): Ensure sh_addralign is such that | |
2685 | sh_addr mod sh_addalign is zero. | |
2686 | ||
1039fd9a AM |
2687 | 2020-03-04 Alan Modra <amodra@gmail.com> |
2688 | ||
2689 | * format.c (bfd_check_format_matches): Call cleanup on error exit. | |
2690 | ||
f5714099 AM |
2691 | 2020-03-03 Alan Modra <amodra@gmail.com> |
2692 | ||
2693 | * format.c (struct bfd_preserve): Add cleanup field. | |
2694 | (bfd_preserve_save): Add cleanup param and save. | |
2695 | (bfd_preserve_restore): Return cleanup. | |
2696 | (bfd_preserve_finish): Call the cleanup for the discarded match. | |
2697 | (bfd_check_format_matches): Pass cleanup to bfd_preserve_save, | |
2698 | and clear when preserving a match. Restore cleanup too when | |
2699 | restoring that match. | |
2700 | ||
40b35c78 AM |
2701 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2702 | ||
2703 | * cisco-core.c (cisco_core_file_p): Return bfd_cleanup. | |
2704 | * hpux-core.c (hpux_core_core_file_p): Update prototype. | |
2705 | * sco5-core.c (sco5_core_file_p): Return bfd_cleanup. | |
2706 | (core_sco5_vec): Correct initialisers. | |
2707 | ||
601b73d5 AM |
2708 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2709 | ||
2710 | * aix386-core.c (aix386_core_file_p): Return bfd_cleanup. | |
2711 | * aix5ppc-core.c (xcoff64_core_p): Likewise. | |
2712 | * cisco-core.c (cisco_core_file_validate): Likewise. | |
2713 | * hppabsd-core.c (hppabsd_core_core_file_p): Likewise. | |
2714 | * hpux-core.c (hpux_core_core_file_p): Likewise. | |
2715 | * irix-core.c (irix_core_core_file_p): Likewise. | |
2716 | * lynx-core.c (lynx_core_file_p): Likewise. | |
2717 | * netbsd-core.c (netbsd_core_file_p): Likewise. | |
2718 | * osf-core.c (osf_core_core_file_p): Likewise. | |
2719 | * ptrace-core.c (ptrace_unix_core_file_p): Likewise. | |
2720 | * sco5-core.c (sco5_core_file_p): Likewise. | |
2721 | ||
728d32c4 L |
2722 | 2020-03-02 H.J. Lu <hongjiu.lu@intel.com> |
2723 | ||
2724 | * trad-core.c (trad_unix_core_file_p): Return bfd_cleanup. | |
2725 | ||
cb001c0d AM |
2726 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2727 | ||
2728 | * targets.c (bfd_cleanup): New typedef. | |
2729 | (struct bfd <_bfd_check_format>): Return a bfd_cleanup. | |
2730 | * libbfd-in.h (_bfd_no_cleanup): Define. | |
2731 | * format.c (bfd_reinit): Add cleanup parameter, call it. | |
2732 | (bfd_check_format_matches): Set cleanup from _bfd_check_format | |
2733 | call and pass to bfd_reinit. Delete temp, use abfd->xvec instead. | |
2734 | * aout-target.h (callback, object_p): Return bfd_cleanup. | |
2735 | * aout-tic30.c (tic30_aout_callback, tic30_aout_object_p): Likewise. | |
2736 | * archive.c (bfd_generic_archive_p): Likewise. | |
2737 | * binary.c (binary_object_p): Likewise. | |
2738 | * coff-alpha.c (alpha_ecoff_object_p): Likewise. | |
2739 | * coff-ia64.c (ia64coff_object_p): Likewise. | |
2740 | * coff-rs6000.c (_bfd_xcoff_archive_p, rs6000coff_core_p): Likewise. | |
2741 | * coff-sh.c (coff_small_object_p): Likewise. | |
2742 | * coff-stgo32.c (go32_check_format): Likewise. | |
2743 | * coff64-rs6000.c (xcoff64_archive_p, rs6000coff_core_p), | |
2744 | (xcoff64_core_p): Likewise. | |
2745 | * coffgen.c (coff_real_object_p, coff_object_p): Likewise. | |
2746 | * elf-bfd.h (bfd_elf32_object_p, bfd_elf32_core_file_p), | |
2747 | (bfd_elf64_object_p, bfd_elf64_core_file_p): Likewise. | |
2748 | * elfcode.h (elf_object_p): Likewise. | |
2749 | * elfcore.h (elf_core_file_p): Likewise. | |
2750 | * i386msdos.c (msdos_object_p): Likewise. | |
2751 | * ihex.c (ihex_object_p): Likewise. | |
2752 | * libaout.h (some_aout_object_p): Likewise. | |
2753 | * libbfd-in.h (bfd_generic_archive_p, _bfd_dummy_target), | |
2754 | (_bfd_vms_lib_alpha_archive_p, _bfd_vms_lib_ia64_archive_p): Likewise. | |
2755 | * libbfd.c (_bfd_dummy_target): Likewise. | |
2756 | * libcoff-in.h (coff_object_p): Likewise. | |
2757 | * mach-o-aarch64.c (bfd_mach_o_arm64_object_p), | |
2758 | (bfd_mach_o_arm64_core_p): Likewise. | |
2759 | * mach-o-arm.c (bfd_mach_o_arm_object_p), | |
2760 | (bfd_mach_o_arm_core_p): Likewise. | |
2761 | * mach-o-i386.c (bfd_mach_o_i386_object_p), | |
2762 | (bfd_mach_o_i386_core_p): Likewise. | |
2763 | * mach-o-x86-64.c (bfd_mach_o_x86_64_object_p), | |
2764 | (bfd_mach_o_x86_64_core_p): Likewise. | |
2765 | * mach-o.c (bfd_mach_o_header_p, bfd_mach_o_gen_object_p), | |
2766 | (bfd_mach_o_gen_core_p, bfd_mach_o_fat_archive_p): Likewise. | |
2767 | * mach-o.h (bfd_mach_o_object_p, bfd_mach_o_core_p), | |
2768 | (bfd_mach_o_fat_archive_p, bfd_mach_o_header_p): Likewise. | |
2769 | * mmo.c (mmo_object_p): Likewise. | |
2770 | * pef.c (bfd_pef_object_p, bfd_pef_xlib_object_p): Likewise. | |
2771 | * peicode.h (coff_real_object_p, pe_ILF_object_p), | |
2772 | (pe_bfd_object_p): Likewise. | |
2773 | * plugin.c (ld_plugin_object_p, bfd_plugin_object_p): Likewise. | |
2774 | * ppcboot.c (ppcboot_object_p): Likewise. | |
2775 | * rs6000-core.c (rs6000coff_core_p): Likewise. | |
2776 | * som.c (som_object_setup, som_object_p): Likewise. | |
2777 | * srec.c (srec_object_p, symbolsrec_object_p): Likewise. | |
2778 | * tekhex.c (tekhex_object_p): Likewise. | |
2779 | * vms-alpha.c (alpha_vms_object_p): Likewise. | |
2780 | * vms-lib.c (_bfd_vms_lib_archive_p, _bfd_vms_lib_alpha_archive_p), | |
2781 | (_bfd_vms_lib_ia64_archive_p, _bfd_vms_lib_txt_archive_p): Likewise. | |
2782 | * wasm-module.c (wasm_object_p): Likewise. | |
2783 | * xsym.c (bfd_sym_object_p): Likewise. | |
2784 | * xsym.h (bfd_sym_object_p): Likewise. | |
2785 | * aoutx.h (some_aout_object_p): Likewise, and callback parameter | |
2786 | return type. | |
2787 | * pdp11.c (some_aout_object_p): Likewise. | |
2788 | * plugin.c (register_ld_plugin_object_p): Update object_p | |
2789 | parameter type. | |
2790 | * plugin.h (register_ld_plugin_object_p): Likewise. | |
2791 | * bfd-in2.h: Regenerate. | |
2792 | * libbfd.h: Regenerate. | |
2793 | * libcoff.h: Regenerate. | |
2794 | ||
a4dd6c97 AM |
2795 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2796 | ||
2797 | * coff-alpha.c (alpha_ecoff_le_vec): Add SEC_SMALL_DATA to | |
2798 | applicable section flags. | |
2799 | * coff-mips.c (mips_ecoff_le_vec, mips_ecoff_be_vec): Likewise. | |
2800 | (mips_ecoff_bele_vec): Likewise. | |
2801 | * coffcode.h (sec_to_styp_flags): Set SEC_SMALL_DATA for .sdata | |
2802 | and .sbss sections. | |
2803 | * ecoff.c (_bfd_ecoff_new_section_hook): Likewise. | |
2804 | (_bfd_ecoff_styp_to_sec_flags): Likewise. | |
2805 | ||
bf577467 AM |
2806 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2807 | ||
2808 | * elf32-m32r.c (m32r_elf_section_flags): New function. | |
2809 | (elf_backend_section_flags): Define. | |
2810 | * elf32-nds32.c (nds32_elf_section_flags): New function. | |
2811 | (elf_backend_section_flags): Define. | |
2812 | * elf32-ppc.c (ppc_elf_section_from_shdr): Set SEC_SMALL_DATA for | |
2813 | .sbss and .sdata sections. | |
2814 | * elf32-v850.c (v850_elf_section_from_shdr): Set SEC_SMALL_DATA | |
2815 | for SHF_V850_GPREL sections. | |
2816 | * elf64-alpha.c (elf64_alpha_section_from_shdr): Delete outdated | |
2817 | FIXME. | |
2818 | * elf64-hppa.c (elf64_hppa_section_from_shdr): Set SEC_SMALL_DATA | |
2819 | for SHF_PARISC_SHORT sections. | |
2820 | * elf64-ppc.c (ppc64_elf_section_flags): New function. | |
2821 | (elf_backend_section_flags): Define. | |
2822 | * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Set SEC_SMALL_DATA | |
2823 | for SHF_MIPS_GPREL sections. Delete FIXME. | |
2824 | ||
8c803a2d AM |
2825 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2826 | ||
2827 | * elf-bfd.h (elf_backend_section_flags): Remove flagword* param. | |
2828 | * elf.c (_bfd_elf_make_section_from_shdr): Set section flags before | |
2829 | calling elf_backend_section_flags with adjusted params. Use | |
2830 | newsect->flags past that point. | |
2831 | (_bfd_elf_new_section_hook): Always set sh_type and sh_flags for | |
2832 | special sections. | |
2833 | (_bfd_elf_init_private_section_data): Allow normal sh_type sections | |
2834 | to have their type overridden, and all sh_flags but processor and | |
2835 | os specific. | |
2836 | * elf32-arm.c (elf32_arm_section_flags): Adjust for changed params. | |
2837 | * elf32-mep.c (mep_elf_section_flags): Likewise. | |
2838 | * elf32-nios2.c (nios2_elf32_section_flags): Likewise. | |
2839 | * elf64-alpha.c (elf64_alpha_section_flags): Likewise. | |
2840 | * elf64-ia64-vms.c (elf64_ia64_section_flags): Likewise. | |
2841 | * elfnn-ia64.c (elfNN_ia64_section_flags): Likewise. | |
2842 | * elfnn-aarch64.c (elfNN_aarch64_size_stubs): Exclude the linker | |
2843 | stub BFD and non-aarch64 input files when scanning for stubs. | |
2844 | ||
7d4b2d2d AM |
2845 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2846 | ||
2847 | * coff-alpha.c (alpha_ecoff_get_elt_at_filepos): Provide an upper | |
2848 | limit to decompressed element size. | |
2849 | ||
26f60d59 AM |
2850 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2851 | ||
2852 | * vms-lib.c (vms_traverse_index): Add recur_count param and | |
2853 | update calls. Fail on excessive recursion. | |
2854 | ||
9cb56943 AM |
2855 | 2020-03-02 Alan Modra <amodra@gmail.com> |
2856 | ||
2857 | * vms-alpha.c (vms_get_remaining_object_record): Use | |
2858 | bfd_realloc_or_free rather than bfd_realloc. | |
2859 | (add_symbol_entry, vector_grow1, alpha_vms_slurp_relocs): Likewise. | |
2860 | (dst_define_location, parse_module): Likewise, and check realloc | |
2861 | return status before using memory. Return status from function | |
2862 | adjusting all callers. | |
2863 | ||
182ec670 AM |
2864 | 2020-02-28 Alan Modra <amodra@gmail.com> |
2865 | ||
2866 | * vms-lib.c (_bfd_vms_lib_archive_p): Free memory on error paths. | |
2867 | ||
1b088c82 AM |
2868 | 2020-02-28 Alan Modra <amodra@gmail.com> |
2869 | ||
2870 | * vms-alpha.c (alpha_vms_object_p): Use _bfd_malloc_and_read. | |
2871 | Remove duplicate undersize check. | |
2872 | ||
5f602802 AM |
2873 | 2020-02-27 Alan Modra <amodra@gmail.com> |
2874 | ||
2875 | PR 24511 | |
2876 | * mmo.c (mmo_scan): Set SEC_DATA for .data. | |
2877 | ||
49d9fd42 AM |
2878 | 2020-02-27 Alan Modra <amodra@gmail.com> |
2879 | ||
2880 | PR 24511 | |
2881 | * syms.c (stt): Trim off all but 'e', 'i' and 'p' entries. | |
2882 | (coff_section_type): Adjust comment. | |
2883 | (decode_section_type): Likewise. Call coff_section_type before | |
2884 | decode_section_type. | |
2885 | (bfd_decode_symclass): Use 'c' for common sections other than | |
2886 | the standard one. | |
2887 | ||
05f52dc2 AM |
2888 | 2020-02-27 Alan Modra <amodra@gmail.com> |
2889 | ||
2890 | * coff-rs6000.c (_bfd_xcoff_read_ar_hdr): Put all data in one | |
2891 | malloc'd block. | |
2892 | ||
ff69a894 AM |
2893 | 2020-02-27 Alan Modra <amodra@gmail.com> |
2894 | ||
2895 | * bfd.c (bfd_stat_arch_elt): Use vector of containing archive, | |
2896 | if file is an archive element. | |
2897 | * bfd-in2.h: Regenerate. | |
2898 | ||
02f7e7ee AM |
2899 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2900 | ||
2901 | * archive.c (do_slurp_bsd_armap): Increase minimum parsed_size, and | |
2902 | bfd_set_error on failing test. Don't bother changing bfd_error on | |
2903 | file read error. Check symdef_count is multiple of BSD_SYMDEF_SIZE. | |
2904 | Check sym name is within string buffer. Use size_t for some vars. | |
2905 | (do_slurp_coff_armap): Use size_t for some variables, fix size of | |
2906 | int_buf. Don't change bfd_error on file read error. Use | |
2907 | _bfd_mul_overflow when calculating carsym buffer size. Reorder | |
2908 | calculations to catch overflows before they occur. malloc and | |
2909 | free raw armap rather than using bfd_alloc. Read raw armap before | |
2910 | allocating carsym+strings buffer. | |
2911 | (_bfd_slurp_extended_name_table): Localize variables. Check | |
2912 | name size against file size. | |
2913 | ||
cc4c4f40 AM |
2914 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2915 | ||
2916 | * vms-lib.c (vms_lib_read_index): Release correct buffer. | |
2917 | ||
e0b317de AM |
2918 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2919 | ||
2920 | * elf32-rx.c (rx_elf_relocate_section): Use bfd_malloc rather than | |
2921 | malloc. Check for NULL return from bfd_malloc. | |
2922 | (rx_table_find, rx_table_map): Likewise. | |
2923 | (rx_set_section_contents): Check bfd_alloc return. | |
2924 | (rx_dump_symtab): Don't alloc internal_syms or external_syms. | |
2925 | ||
dc1e8a47 AM |
2926 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2927 | ||
2928 | * aoutx.h: Indent labels correctly. Format error strings. | |
2929 | * archive.c: Likewise. | |
2930 | * archive64.c: Likewise. | |
2931 | * coff-arm.c: Likewise. | |
2932 | * coff-rs6000.c: Likewise. | |
2933 | * coff-stgo32.c: Likewise. | |
2934 | * cpu-arm.c: Likewise. | |
2935 | * dwarf2.c: Likewise. | |
2936 | * elf-ifunc.c: Likewise. | |
2937 | * elf-properties.c: Likewise. | |
2938 | * elf-s390-common.c: Likewise. | |
2939 | * elf-strtab.c: Likewise. | |
2940 | * elf.c: Likewise. | |
2941 | * elf32-arm.c: Likewise. | |
2942 | * elf32-bfin.c: Likewise. | |
2943 | * elf32-cr16.c: Likewise. | |
2944 | * elf32-csky.c: Likewise. | |
2945 | * elf32-i386.c: Likewise. | |
2946 | * elf32-m68k.c: Likewise. | |
2947 | * elf32-msp430.c: Likewise. | |
2948 | * elf32-nds32.c: Likewise. | |
2949 | * elf32-nios2.c: Likewise. | |
2950 | * elf32-pru.c: Likewise. | |
2951 | * elf32-xtensa.c: Likewise. | |
2952 | * elf64-ia64-vms.c: Likewise. | |
2953 | * elf64-x86-64.c: Likewise. | |
2954 | * elfcode.h: Likewise. | |
2955 | * elfcore.h: Likewise. | |
2956 | * elflink.c: Likewise. | |
2957 | * elfnn-aarch64.c: Likewise. | |
2958 | * elfnn-ia64.c: Likewise. | |
2959 | * elfnn-riscv.c: Likewise. | |
2960 | * elfxx-mips.c: Likewise. | |
2961 | * elfxx-sparc.c: Likewise. | |
2962 | * elfxx-x86.c: Likewise. | |
2963 | * i386lynx.c: Likewise. | |
2964 | * merge.c: Likewise. | |
2965 | * pdp11.c: Likewise. | |
2966 | * plugin.c: Likewise. | |
2967 | * reloc.c: Likewise. | |
2968 | ||
e310298c AM |
2969 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2970 | ||
2971 | PR 25593 | |
2972 | * elf-bfd.h (struct elf_link_hash_table): Rename "loaded" to | |
2973 | "dyn_loaded". | |
2974 | (bfd_elf_add_dt_needed_tag): Declare. | |
2975 | * elf-strtab.c (_bfd_elf_strtab_restore): Handle NULL buf. | |
2976 | * elflink.c (bfd_elf_add_dt_needed_tag): Make global and rename | |
2977 | from elf_add_dt_needed_tag. Remove soname and doit param. | |
2978 | (elf_link_add_object_symbols): Don't use elf_add_dt_needed_tag | |
2979 | to see whether as-needed lib is already loaded, use dyn_loaded | |
2980 | list instead. When saving and restoring around as-needed lib | |
2981 | handle possibility that dynstr has not been initialised. Don't | |
2982 | add DT_NEEDED tags here. Limit dyn_loaded list to dynamic libs. | |
2983 | Mark libs loaded via DT_NEEDED entries of other libs with | |
2984 | DYN_NO_NEEDED if they should not be mentioned in DT_NEEDED of | |
2985 | the output. | |
2986 | (elf_link_check_versioned_symbol): Remove now unneccesary | |
2987 | DYNAMIC check when traversing dyn_loaded list. | |
2988 | ||
b570b954 AM |
2989 | 2020-02-26 Alan Modra <amodra@gmail.com> |
2990 | ||
2991 | * bfdio.c (bfd_get_file_size): Ignore bogus archive element sizes. | |
2992 | ||
ecda9016 L |
2993 | 2020-02-25 H.J. Lu <hongjiu.lu@intel.com> |
2994 | ||
2995 | PR binutils/25584 | |
2996 | * plugin.c (need_lto_wrapper_p): New. | |
2997 | (bfd_plugin_set_program_name): Add an int argument to set | |
2998 | need_lto_wrapper_p. | |
2999 | (get_lto_wrapper): Return FALSE if need_lto_wrapper_p isn't | |
3000 | set. | |
3001 | * plugin.h (bfd_plugin_set_program_name): Add an int argument. | |
3002 | ||
a98c743f AM |
3003 | 2020-02-24 Alan Modra <amodra@gmail.com> |
3004 | ||
3005 | * vms-lib.c (_bfd_vms_lib_archive_p): Correct overflow checks. | |
3006 | ||
c893ce36 AM |
3007 | 2020-02-24 Alan Modra <amodra@gmail.com> |
3008 | ||
3009 | * vms-lib.c (struct carsym_mem): Add limit. | |
3010 | (vms_add_index): Heed limit. | |
3011 | (vms_traverse_index): Catch buffer overflows. Remove outdated fixme. | |
3012 | (vms_lib_read_index): Set up limit. Catch 32-bit overflow. | |
3013 | Always return actual number read. | |
3014 | (_bfd_vms_lib_archive_p): Catch buffer overflows. Replace | |
3015 | assertion with error exit. | |
3016 | ||
7b3c2715 AM |
3017 | 2020-02-22 Alan Modra <amodra@gmail.com> |
3018 | ||
3019 | PR 25585 | |
3020 | * elf.c (assign_file_positions_for_load_sections): Continue linking | |
3021 | on "PHDR segment not covered by LOAD segment" errors. | |
3022 | ||
a4425a57 AM |
3023 | 2020-02-21 Alan Modra <amodra@gmail.com> |
3024 | ||
3025 | * mach-o.c (bfd_mach_o_canonicalize_relocs): Fix ineffective | |
3026 | overflow check. | |
3027 | (bfd_mach_o_canonicalize_reloc): Likewise. | |
3028 | (bfd_mach_o_canonicalize_dynamic_reloc): Likewise. Sanity check | |
3029 | counts and offsets against file size. | |
3030 | (bfd_mach_o_build_dysymtab): Fix ineffective overflow check. | |
3031 | (bfd_mach_o_mangle_sections): Remove unnecessary overflow check. | |
3032 | (bfd_mach_o_read_symtab_symbols): Sanity check count and offset | |
3033 | against file size. Delete symbol table error message. | |
3034 | (bfd_mach_o_read_dysymtab): Sanity check counts and offsets | |
3035 | against file size. | |
3036 | (bfd_mach_o_read_symtab): Likewise. | |
3037 | (bfd_mach_o_read_command): Pass file size. | |
3038 | (bfd_mach_o_scan): Sanity check command count against file size. | |
3039 | ||
dda2980f AM |
3040 | 2020-02-21 Alan Modra <amodra@gmail.com> |
3041 | ||
3042 | PR 25569 | |
3043 | * aoutx.h (adjust_o_magic, adjust_z_magic, adjust_n_magic): Use | |
3044 | "text", "data" and "bss" section pointer vars. Don't update | |
3045 | section size, just exec header sizes. | |
3046 | (adjust_sizes_and_vmas): Don't update text section size. Set | |
3047 | initial exec header a_text. Print exec headers sizes. | |
3048 | * pdp11.c (adjust_o_magic, adjust_z_magic, adjust_n_magic), | |
3049 | (adjust_sizes_and_vmas): Similarly. Formatting. | |
3050 | (final_link): Correct final file extension. | |
3051 | ||
00e49dff NC |
3052 | 2020-02-20 Nick Clifton <nickc@redhat.com> |
3053 | ||
3054 | * elf-bfd.h (struct elf_backend_data): Add symbol_section_index | |
3055 | callback. | |
3056 | * elfxx-target.h (elf_backend_symbol_section_index): Provide | |
3057 | default definition. | |
3058 | (elfNN_bed): Initialise the symbol_section_index field. | |
3059 | * elf.c (swap_out_syms): Call symbol_section_index, if defined, on | |
3060 | OS and PROC specific section indicies. Warn if converting other | |
3061 | reserved incidies to SHN_ABS. | |
3062 | ||
fcaaac0a SB |
3063 | 2020-02-19 Sergey Belyashov <sergey.belyashov@gmail.com> |
3064 | ||
3065 | PR 25537 | |
3066 | * cpu-z80.c: Add machine type compatibility checking. | |
3067 | ||
dcf06b89 L |
3068 | 2020-02-19 H.J. Lu <hongjiu.lu@intel.com> |
3069 | ||
3070 | PR binutils/25355 | |
3071 | * plugin.c (plugin_list_entry): Remove handle. | |
3072 | (try_load_plugin): Call dlclose before return. | |
3073 | ||
2c7c5554 AM |
3074 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3075 | ||
3076 | * libbfd-in.h (_bfd_constant_p): Define. | |
3077 | (_bfd_alloc_and_read, _bfd_malloc_and_read): Check read size against | |
3078 | file size before allocating memory. | |
3079 | * coffgen.c (_bfd_coff_get_external_symbols): Remove file size check. | |
3080 | * elf.c (bfd_elf_get_str_section): Likewise. | |
3081 | (_bfd_elf_slurp_version_tables): Likewise. | |
3082 | * libbfd.h: Regenerate. | |
3083 | ||
2bb3687b AM |
3084 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3085 | ||
3086 | * libbfd-in.h (_bfd_alloc_and_read, _bfd_malloc_and_read): New. | |
3087 | * aoutx.h (aout_get_external_symbols): Replace calls to | |
3088 | bfd_[m]alloc and bfd_bread with call to _bfd_[m]alloc_and_read. | |
3089 | (slurp_reloc_table): Likewise. | |
3090 | * archive.c (do_slurp_bsd_armap): Likewise. | |
3091 | (do_slurp_coff_armap): Likewise. | |
3092 | * archive64.c (_bfd_archive_64_bit_slurp_armap): Likewise. | |
3093 | * coff-rs6000.c (_bfd_xcoff_slurp_armap): Likewise. | |
3094 | * coff64-rs6000.c (xcoff64_slurp_armap): Likewise. | |
3095 | * coffcode.h (coff_set_arch_mach_hook, buy_and_read): Likewise. | |
3096 | * coffgen.c (coff_real_object_p, coff_object_p, build_debug_section), | |
3097 | (_bfd_coff_get_external_symbols): Likewise. | |
3098 | * ecoff.c (ecoff_slurp_symbolic_header), | |
3099 | (_bfd_ecoff_slurp_symbolic_info, ecoff_slurp_reloc_table), | |
3100 | (_bfd_ecoff_slurp_armap, ecoff_link_add_object_symbols, READ), | |
3101 | (ecoff_indirect_link_order): Likewise. | |
3102 | * elf.c (bfd_elf_get_str_section, setup_group, elf_read_notes), | |
3103 | (_bfd_elf_slurp_version_tables): Likewise. | |
3104 | * elf32-m32c.c (m32c_elf_relax_section): Likewise. | |
3105 | * elf32-rl78.c (rl78_elf_relax_section): Likewise. | |
3106 | * elf32-rx.c (elf32_rx_relax_section): Likewise. | |
3107 | * elf64-alpha.c (READ): Likewise. | |
3108 | * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Likewise. | |
3109 | * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise. | |
3110 | * elfcode.h (elf_slurp_symbol_table), | |
3111 | (elf_slurp_reloc_table_from_section): Likewise. | |
3112 | * elflink.c (elf_link_add_object_symbols), | |
3113 | (elf_link_check_versioned_symbol): Likewise. | |
3114 | * elfxx-mips.c (READ): Likewise. | |
3115 | * i386lynx.c (slurp_reloc_table): Likewise. | |
3116 | * lynx-core.c (lynx_core_file_p): Likewise. | |
3117 | * mach-o.c (bfd_mach_o_canonicalize_relocs), | |
3118 | (bfd_mach_o_read_symtab_strtab, bfd_mach_o_alloc_and_read), | |
3119 | (bfd_mach_o_read_prebound_dylib, bfd_mach_o_read_dyld_content | |
3120 | * pdp11.c (aout_get_external_symbols, slurp_reloc_table | |
3121 | * pef.c (bfd_pef_print_loader_section, bfd_pef_scan_start_address), | |
3122 | (bfd_pef_parse_symbols): Likewise. | |
3123 | * peicode.h (pe_ILF_object_p, pe_bfd_object_p | |
3124 | * som.c (setup_sections, som_slurp_string_table), | |
3125 | (som_slurp_reloc_table, som_bfd_count_ar_symbols), | |
3126 | (som_bfd_fill_in_ar_symbols): Likewise. | |
3127 | * vms-alpha.c (module_find_nearest_line, evax_bfd_print_dst), | |
3128 | (evax_bfd_print_image): Likewise. | |
3129 | * vms-lib.c (_bfd_vms_lib_archive_p): Likewise. | |
3130 | * wasm-module.c (wasm_scan): Likewise. | |
3131 | * xcofflink.c (xcoff_link_add_symbols): Likewise. | |
3132 | * xsym.c (bfd_sym_read_name_table), | |
3133 | (bfd_sym_print_type_information_table_entry): Likewise. | |
3134 | * libbfd.h: Regenerate. | |
3135 | ||
806470a2 AM |
3136 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3137 | ||
3138 | * aoutx.h (slurp_reloc_table): Allocate reloc_cache after | |
3139 | reading external relocs. | |
3140 | * ecoff.c (ecoff_slurp_reloc_table): Likewise. | |
3141 | * archive.c (_bfd_write_archive_contents): Don't twiddle bfd_error | |
3142 | after bfd_bread. | |
3143 | * archive64.c (_bfd_archive_64_bit_slurp_armap): Remove unnecessary | |
3144 | bfd_release. | |
3145 | * elf32-m32c.c (m32c_offset_for_reloc): Make shndx_buf a bfd_byte*. | |
3146 | (m32c_elf_relax_section): Likewise. | |
3147 | * elf32-rl78.c (rl78_offset_for_reloc): Likewise. | |
3148 | (rl78_elf_relax_section): Likewise. | |
3149 | * elf32-rx.c (rx_offset_for_reloc): Likewise. | |
3150 | (elf32_rx_relax_section): Likewise. | |
3151 | * mach-o.c (bfd_mach_o_alloc_and_read): Move earlier with better | |
3152 | parameter types and use.. | |
3153 | (bfd_mach_o_read_dylinker, bfd_mach_o_read_dylib), | |
3154 | (bfd_mach_o_read_fvmlib, bfd_mach_o_read_str): ..in these functions. | |
3155 | * peicode.h (pe_bfd_object_p): Don't zero the part of opthdr | |
3156 | being read from file, just the extra. | |
3157 | * som.c (som_slurp_symbol_table): Allocate internal symbol buffer | |
3158 | after reading external syms. Free on failure. | |
3159 | ||
1f4361a7 AM |
3160 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3161 | ||
3162 | * coffcode.h (buy_and_read, coff_slurp_line_table), | |
3163 | (coff_slurp_symbol_table, coff_slurp_reloc_table): Replace | |
3164 | bfd_[z][m]alloc2 calls with _bfd_mul_overflow followed by the | |
3165 | corresponding bfd_alloc call. Adjust variables to suit. | |
3166 | * coffgen.c (_bfd_coff_get_external_symbols): Likewise. | |
3167 | * ecoff.c (_bfd_ecoff_slurp_symbolic_info), | |
3168 | (_bfd_ecoff_slurp_symbol_table, READ): Likewise. | |
3169 | * elf.c (bfd_elf_get_elf_syms, setup_group, bfd_section_from_shdr), | |
3170 | (swap_out_syms, _bfd_elf_slurp_version_tables): Likewise. | |
3171 | * elf32-m32c.c (m32c_elf_relax_section): Likewise. | |
3172 | * elf32-rl78.c (rl78_elf_relax_section): Likewise. | |
3173 | * elf32-rx.c (elf32_rx_relax_section): Likewise. | |
3174 | * elf64-alpha.c (READ): Likewise. | |
3175 | * elfcode.h (elf_object_p, elf_write_relocs, elf_write_shdrs_and_ehdr), | |
3176 | (elf_slurp_symbol_table, elf_slurp_reloc_table), | |
3177 | (bfd_from_remote_memory): Likewise. | |
3178 | * elfcore.h (core_find_build_id): Likewise. | |
3179 | * elfxx-mips.c (READ): Likewise. | |
3180 | * mach-o.c (bfd_mach_o_mangle_sections), | |
3181 | (bfd_mach_o_read_symtab_symbols, bfd_mach_o_read_thread), | |
3182 | (bfd_mach_o_read_dysymtab, bfd_mach_o_flatten_sections), | |
3183 | (bfd_mach_o_scan, bfd_mach_o_fat_archive_p): Likewise. | |
3184 | * som.c (setup_sections, som_prep_for_fixups) | |
3185 | (som_build_and_write_symbol_table, som_slurp_symbol_table), | |
3186 | (som_slurp_reloc_table, som_bfd_count_ar_symbols), | |
3187 | (som_bfd_fill_in_ar_symbols, som_slurp_armap), | |
3188 | (som_bfd_ar_write_symbol_stuff): Likewise. | |
3189 | * vms-alpha.c (vector_grow1): Likewise. | |
3190 | * vms-lib.c (vms_add_index): Likewise. | |
3191 | * wasm-module.c (wasm_scan_name_function_section): Likewise. | |
3192 | * libbfd.c (bfd_malloc2, bfd_realloc2, bfd_zmalloc2): Delete. | |
3193 | * opncls.c (bfd_alloc2, bfd_zalloc2): Delete. | |
3194 | * libbfd-in.h (bfd_malloc2, bfd_realloc2, bfd_zmalloc2), | |
3195 | (bfd_alloc2, bfd_zalloc2): Delete. | |
3196 | (_bfd_mul_overflow): Define. | |
3197 | * libbfd.h: Regenerate. | |
3198 | ||
446f7ed5 AM |
3199 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3200 | ||
3201 | * elf.c (bfd_section_from_shdr): Use bfd_zalloc rather than | |
3202 | bfd_zalloc2. | |
3203 | (assign_section_numbers): Likewise. | |
3204 | (elf_map_symbols): Likewise, and bfd_alloc rather than bfd_alloc2. | |
3205 | (_bfd_elf_map_sections_to_segments): Use bfd_malloc rather than | |
3206 | bfd_malloc2, size_t amt, and unsigned tls_count. | |
3207 | (rewrite_elf_program_header): Use bfd_malloc and size_t amt. | |
3208 | * elflink.c (elf_create_symbuf): Use bfd_malloc. | |
3209 | (elf_output_implib): Use bfd_alloc. | |
3210 | ||
b03202e3 AM |
3211 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3212 | ||
3213 | * bfd.c (struct bfd): Move format and direction to other | |
3214 | bitfields. Add "size". | |
3215 | * bfdio.c (bfd_get_size): Cache size when not writing file. | |
3216 | * opncls.c (bfd_get_debug_link_info_1): Allow for bfd_get_size | |
3217 | returning zero, ie. unknown. | |
3218 | (bfd_get_alt_debug_link_info): Likewise. | |
3219 | * bfd-in2.h: Regenerate. | |
3220 | ||
7c5fa58e AM |
3221 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3222 | ||
3223 | * coffgen.c (_bfd_coff_get_external_symbols): Don't call | |
3224 | bfd_get_file_size twice. | |
3225 | (_bfd_coff_read_string_table): Allow for bfd_get_file_size | |
3226 | zero, ie. unknown, return. | |
3227 | * elf-attrs.c (_bfd_elf_parse_attributes): Likewise. | |
3228 | * elfcode.h (elf_swap_shdr_in): Likewise. | |
3229 | (elf_object_p): Don't call bfd_get_file_size twice and correct | |
3230 | file size check. | |
3231 | ||
96d3b80f AM |
3232 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3233 | ||
3234 | * mach-o.c (bfd_mach_o_flatten_sections): Return a bfd_boolean, | |
3235 | FALSE if memory alloc fails. Adjust calls. | |
3236 | * som.c (som_prep_for_fixups): Likewise. | |
3237 | * vms-alpha.c (alpha_vms_add_fixup_lp, alpha_vms_add_fixup_ca), | |
3238 | (alpha_vms_add_fixup_qr, alpha_vms_add_fixup_lr), | |
3239 | (alpha_vms_add_lw_reloc, alpha_vms_add_qw_reloc): Likewise. | |
3240 | * som.c (som_build_and_write_symbol_table): Return via error_return | |
3241 | on seek failure. | |
3242 | * vms-alpha.c (VEC_APPEND): Adjust for vector_grow1 changes. | |
3243 | (VEC_APPEND_EL): Delete. | |
3244 | (vector_grow1): Return pointer to element. Catch overflow. | |
3245 | Return NULL on memory allocation failure. | |
3246 | (alpha_vms_add_fixup_lp): Replace VEC_APPEND_EL with VEC_APPEND. | |
3247 | (alpha_vms_add_fixup_ca): Likewise. | |
3248 | (alpha_vms_link_add_object_symbols): Check VEC_APPEND result | |
3249 | before using. | |
3250 | * elf.c (bfd_section_from_shdr): Check bfd_zalloc2 result. | |
3251 | ||
986f0783 AM |
3252 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3253 | ||
3254 | * aix386-core.c (aix386_core_file_p): Use size_t for "amt". | |
3255 | * aout-target.h (object_p): Likewise. | |
3256 | * aout-tic30.c (tic30_aout_object_p): Likewise. | |
3257 | * aoutx.h (some_aout_object_p, mkobject, make_empty_symbol), | |
3258 | (emit_stringtab, write_syms, link_hash_table_create), | |
3259 | (aout_link_write_other_symbol): Likewise. | |
3260 | * archive.c (_bfd_generic_mkarchive, bfd_generic_archive_p), | |
3261 | (bfd_ar_hdr_from_filesystem, _bfd_write_archive_contents), | |
3262 | (_bfd_compute_and_write_armap): Likewise. | |
3263 | * archures.c (bfd_arch_list): Likewise. | |
3264 | * bfd.c (bfd_record_phdr): Likewise. | |
3265 | * binary.c (binary_canonicalize_symtab): Likewise. | |
3266 | * cisco-core.c (cisco_core_file_validate): Likewise. | |
3267 | * coff-arm.c (coff_arm_link_hash_table_create, find_thumb_glue), | |
3268 | (find_arm_glue, record_arm_to_thumb_glue), | |
3269 | (record_thumb_to_arm_glue): Likewise. | |
3270 | * coff-ppc.c (ppc_coff_link_hash_table_create, record_toc), | |
3271 | (ppc_allocate_toc_section): Likewise. | |
3272 | * coff-rs6000.c (_bfd_xcoff_mkobject, _bfd_xcoff_archive_p): Likewise. | |
3273 | * coff-sh.c (sh_relax_section): Likewise. | |
3274 | * coff64-rs6000.c (xcoff64_archive_p): Likewise. | |
3275 | * coffcode.h (handle_COMDAT, coff_new_section_hook), | |
3276 | (coff_set_alignment_hook, coff_mkobject), | |
3277 | (coff_compute_section_file_positions): Likewise. | |
3278 | * coffgen.c (coff_make_empty_symbol, coff_bfd_make_debug_symbol), | |
3279 | (coff_find_nearest_line_with_names), | |
3280 | ( bfd_coff_set_symbol_class): Likewise. | |
3281 | * cofflink.c (_bfd_coff_link_hash_table_create), | |
3282 | (_bfd_coff_link_input_bfd): Likewise. | |
3283 | * dwarf1.c (alloc_dwarf1_unit, alloc_dwarf1_func): Likewise. | |
3284 | * dwarf2.c (read_abbrevs, read_attribute_value, add_line_info), | |
3285 | (build_line_info_table, sort_line_sequences), | |
3286 | (line_info_add_include_dir, line_info_add_file_name), | |
3287 | (decode_line_info, scan_unit_for_symbols, parse_comp_unit), | |
3288 | (place_sections, _bfd_dwarf2_slurp_debug_info): Likewise. | |
3289 | * ecoff.c (_bfd_ecoff_mkobject, _bfd_ecoff_make_empty_symbol), | |
3290 | (_bfd_ecoff_find_nearest_line), | |
3291 | (_bfd_ecoff_bfd_link_hash_table_create): Likewise. | |
3292 | * ecofflink.c (bfd_ecoff_debug_init): Likewise. | |
3293 | * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Likewise. | |
3294 | * elf-m10300.c (mn10300_elf_relax_section), | |
3295 | (elf32_mn10300_link_hash_table_create): Likewise. | |
3296 | * elf-strtab.c (_bfd_elf_strtab_init): Likewise. | |
3297 | * elf.c (make_mapping, copy_elf_program_header): Likewise. | |
3298 | * elf32-arm.c (elf32_arm_link_hash_table_create), | |
3299 | (elf32_arm_setup_section_lists, elf32_arm_check_relocs), | |
3300 | (elf32_arm_new_section_hook): Likewise. | |
3301 | * elf32-avr.c (elf_avr_new_section_hook), | |
3302 | (elf32_avr_link_hash_table_create, get_local_syms), | |
3303 | (elf32_avr_setup_section_lists): Likewise. | |
3304 | * elf32-bfin.c (bfinfdpic_elf_link_hash_table_create), | |
3305 | (bfin_link_hash_table_create): Likewise. | |
3306 | * elf32-cr16.c (elf32_cr16_link_hash_table_create): Likewise. | |
3307 | * elf32-cris.c (elf_cris_link_hash_table_create): Likewise. | |
3308 | * elf32-csky.c (csky_elf_link_hash_table_create), | |
3309 | (csky_elf_check_relocs, elf32_csky_setup_section_lists): Likewise. | |
3310 | * elf32-frv.c (frvfdpic_elf_link_hash_table_create): Likewise. | |
3311 | * elf32-hppa.c (elf32_hppa_link_hash_table_create), | |
3312 | (elf32_hppa_setup_section_lists, get_local_syms): Likewise. | |
3313 | * elf32-i386.c (elf_i386_check_relocs): Likewise. | |
3314 | * elf32-lm32.c (lm32_elf_link_hash_table_create): Likewise. | |
3315 | * elf32-m32r.c (m32r_elf_link_hash_table_create), | |
3316 | (m32r_elf_check_relocs): Likewise. | |
3317 | * elf32-m68hc1x.c (m68hc11_elf_hash_table_create), | |
3318 | (elf32_m68hc11_setup_section_lists), | |
3319 | (elf32_m68hc11_size_stubs): Likewise. | |
3320 | * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise. | |
3321 | * elf32-metag.c (elf_metag_link_hash_table_create), | |
3322 | (elf_metag_setup_section_lists): Likewise. | |
3323 | * elf32-microblaze.c (microblaze_elf_link_hash_table_create), | |
3324 | (microblaze_elf_check_relocs): Likewise. | |
3325 | * elf32-nds32.c (nds32_elf_link_hash_table_create), | |
3326 | (nds32_elf_check_relocs): Likewise. | |
3327 | * elf32-nios2.c (nios2_elf32_setup_section_lists), | |
3328 | (get_local_syms, nios2_elf32_check_relocs), | |
3329 | (nios2_elf32_link_hash_table_create): Likewise. | |
3330 | * elf32-or1k.c (or1k_elf_link_hash_table_create), | |
3331 | (or1k_elf_check_relocs): Likewise. | |
3332 | * elf32-ppc.c (ppc_elf_modify_segment_map, update_plt_info): Likewise. | |
3333 | * elf32-pru.c (pru_elf32_link_hash_table_create): Likewise. | |
3334 | * elf32-s390.c (elf_s390_link_hash_table_create), | |
3335 | (elf_s390_check_relocs): Likewise. | |
3336 | * elf32-score.c (score_elf_create_got_section), | |
3337 | (s3_elf32_score_new_section_hook), | |
3338 | (elf32_score_link_hash_table_create): Likewise. | |
3339 | * elf32-score7.c (score_elf_create_got_section), | |
3340 | (s7_elf32_score_new_section_hook): Likewise. | |
3341 | * elf32-sh.c (sh_elf_link_hash_table_create), | |
3342 | (sh_elf_check_relocs): Likewise. | |
3343 | * elf32-tic6x.c (elf32_tic6x_link_hash_table_create), | |
3344 | (elf32_tic6x_new_section_hook, elf32_tic6x_check_relocs): Likewise. | |
3345 | * elf32-tilepro.c (tilepro_elf_link_hash_table_create), | |
3346 | (tilepro_elf_check_relocs): Likewise. | |
3347 | * elf32-v850.c (remember_hi16s_reloc): Likewise. | |
3348 | * elf32-vax.c (elf_vax_link_hash_table_create): Likewise. | |
3349 | * elf32-xtensa.c (elf_xtensa_link_hash_table_create), | |
3350 | (elf_xtensa_new_section_hook): Likewise. | |
3351 | * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create), | |
3352 | (get_got_entry, elf64_alpha_check_relocs): Likewise. | |
3353 | * elf64-hppa.c (elf64_hppa_hash_table_create): Likewise. | |
3354 | * elf64-ia64-vms.c (elf64_ia64_object_p): Likewise. | |
3355 | * elf64-mmix.c (mmix_elf_new_section_hook): Likewise. | |
3356 | * elf64-ppc.c (ppc64_elf_new_section_hook), | |
3357 | (ppc64_elf_link_hash_table_create, update_local_sym_info), | |
3358 | (update_plt_info, ppc64_elf_check_relocs): Likewise. | |
3359 | * elf64-s390.c (elf_s390_link_hash_table_create), | |
3360 | (elf_s390_check_relocs): Likewise. | |
3361 | * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise. | |
3362 | * elflink.c (bfd_elf_link_record_local_dynamic_symbol), | |
3363 | (_bfd_elf_link_find_version_dependencies, elf_link_add_object_symbols), | |
3364 | (elf_link_add_archive_symbols, compute_bucket_count), | |
3365 | (bfd_elf_size_dynsym_hash_dynstr, _bfd_elf_link_hash_table_create), | |
3366 | (bfd_elf_get_bfd_needed_list, elf_link_swap_symbols_out), | |
3367 | (bfd_elf_final_link): Likewise. | |
3368 | * elfnn-aarch64.c (elfNN_aarch64_link_hash_table_create), | |
3369 | (elfNN_aarch64_setup_section_lists, elfNN_aarch64_check_relocs), | |
3370 | (elfNN_aarch64_new_section_hook): Likewise. | |
3371 | * elfnn-ia64.c (elfNN_ia64_object_p): Likewise. | |
3372 | * elfnn-riscv.c (riscv_elf_link_hash_table_create), | |
3373 | (riscv_elf_check_relocs): Likewise. | |
3374 | * elfxx-mips.c (_bfd_mips_elf_new_section_hook), | |
3375 | (_bfd_mips_elf_add_symbol_hook, _bfd_mips_elf_check_relocs), | |
3376 | (_bfd_mips_elf_modify_segment_map, _bfd_mips_elf_set_section_contents), | |
3377 | (_bfd_mips_elf_link_hash_table_create): Likewise. | |
3378 | * elfxx-sparc.c (_bfd_sparc_elf_link_hash_table_create), | |
3379 | (_bfd_sparc_elf_check_relocs), | |
3380 | (_bfd_sparc_elf_new_section_hook): Likewise. | |
3381 | * elfxx-tilegx.c (tilegx_elf_link_hash_table_create), | |
3382 | (tilegx_elf_check_relocs): Likewise. | |
3383 | * elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Likewise. | |
3384 | * format.c (bfd_check_format_matches): Likewise. | |
3385 | * hash.c (_bfd_stringtab_init): Likewise. | |
3386 | * ihex.c (ihex_scan): Likewise. | |
3387 | * irix-core.c (irix_core_core_file_p): Likewise. | |
3388 | * linker.c (bfd_wrapped_link_hash_lookup), | |
3389 | (_bfd_generic_link_hash_table_create), | |
3390 | (_bfd_generic_reloc_link_order): Likewise. | |
3391 | * lynx-core.c (lynx_core_file_p): Likewise. | |
3392 | * netbsd-core.c (netbsd_core_file_p): Likewise. | |
3393 | * osf-core.c (osf_core_core_file_p): Likewise. | |
3394 | * pdp11.c (some_aout_object_p, mkobject, make_empty_symbol), | |
3395 | (link_hash_table_create, aout_link_write_other_symbol): Likewise. | |
3396 | * peXXigen.c (_bfd_XX_bfd_copy_private_section_data): Likewise. | |
3397 | * peicode.h (pe_mkobject): Likewise. | |
3398 | * ppcboot.c (ppcboot_mkobject, ppcboot_canonicalize_symtab): Likewise. | |
3399 | * ptrace-core.c (ptrace_unix_core_file_p): Likewise. | |
3400 | * sco5-core.c (read_uarea): Likewise. | |
3401 | * som.c (hppa_som_gen_reloc_type, som_object_p, som_prep_headers), | |
3402 | (som_write_fixups, som_write_space_strings, som_write_symbol_strings), | |
3403 | (som_finish_writing, som_canonicalize_symtab, som_new_section_hook), | |
3404 | (som_bfd_copy_private_section_data, bfd_som_set_section_attributes), | |
3405 | (bfd_som_attach_aux_hdr, som_write_armap): Likewise. | |
3406 | * srec.c (srec_scan): Likewise. | |
3407 | * syms.c (_bfd_generic_make_empty_symbol): Likewise. | |
3408 | * targets.c (bfd_target_list): Likewise. | |
3409 | * tekhex.c (first_phase, tekhex_sizeof_headers): Likewise. | |
3410 | * trad-core.c (trad_unix_core_file_p): Likewise. | |
3411 | * vms-alpha.c (vms_initialize, alpha_vms_bfd_link_hash_table_create), | |
3412 | (vms_new_section_hook): Likewise. | |
3413 | * wasm-module.c (wasm_make_empty_symbol): Likewise. | |
3414 | * xcofflink.c (xcoff_get_section_contents), | |
3415 | (_bfd_xcoff_bfd_link_hash_table_create, xcoff_set_import_path), | |
3416 | (xcoff_find_function, bfd_xcoff_link_record_set, xcoff_build_ldsym), | |
3417 | (bfd_xcoff_size_dynamic_sections, xcoff_link_input_bfd): Likewise. | |
3418 | ||
2d0e1217 AM |
3419 | 2020-02-19 Alan Modra <amodra@gmail.com> |
3420 | ||
3421 | * elfxx-riscv.c (riscv_multi_letter_ext_valid_p): Don't use C99. | |
3422 | ||
99845b3b L |
3423 | 2020-02-13 H.J. Lu <hongjiu.lu@intel.com> |
3424 | ||
3425 | * plugin.c (try_load_plugin): Make plugin_list_iter an argument | |
3426 | and use it if it isn't NULL. Remove has_plugin_p argument. Add | |
3427 | a build_list_p argument. Don't search plugin_list. Short circuit | |
3428 | when building the plugin list. | |
3429 | (has_plugin): Renamed to has_plugin_list. | |
3430 | (bfd_plugin_set_plugin): Don't set has_plugin. | |
3431 | (bfd_plugin_specified_p): Check plugin_list instead. | |
3432 | (build_plugin_list): New function. | |
3433 | (load_plugin): Call build_plugin_list and use plugin_list. | |
3434 | ||
22fe7df8 L |
3435 | 2020-02-11 H.J. Lu <hongjiu.lu@intel.com> |
3436 | ||
3437 | PR binutils/25355 | |
3438 | * plugin.c (try_claim): Always clean up for LTO wrapper. | |
3439 | (try_load_plugin): Treat each object as independent. Create a | |
3440 | copy for plugin name. | |
3441 | ||
c675ec1e NC |
3442 | 2020-02-11 Nick Clifton <nickc@redhat.com> |
3443 | ||
3444 | * elf32-msp430.c (msp430_final_link_relocate): Always use longs | |
3445 | for addresses in print statements. | |
3446 | (msp430_elf_relax_delete_bytes): Likewise. | |
3447 | (msp430_elf_relax_add_words): Likewise. | |
3448 | (msp430_elf_relax_section): Likewise. | |
3449 | ||
1d07a805 L |
3450 | 2020-02-11 H.J. Lu <hongjiu.lu@intel.com> |
3451 | ||
3452 | * plugin.c (add_symbols): Clear plugin_data memory. | |
3453 | ||
0aa99dcd L |
3454 | 2020-02-10 H.J. Lu <hongjiu.lu@intel.com> |
3455 | ||
3456 | PR binutils/25355 | |
3457 | * configure.ac (HAVE_EXECUTABLE_SUFFIX): New AC_DEFINE. | |
3458 | (EXECUTABLE_SUFFIX): Likewise. | |
3459 | * config.in: Regenerated. | |
3460 | * configure: Likewise. | |
3461 | * plugin.c (bfd_plugin_close_and_cleanup): Removed. | |
3462 | (plugin_list_entry): Add all_symbols_read, cleanup_handler, | |
3463 | gcc, lto_wrapper, resolution_file, resolution_option, gcc_env, | |
3464 | real_bfd, real_nsyms, real_syms, lto_nsyms and lto_syms. | |
3465 | (get_lto_wrapper): New. | |
3466 | (setup_lto_wrapper_env): Likewise. | |
3467 | (current_plugin): Likewise. | |
3468 | (register_all_symbols_read): Likewise. | |
3469 | (register_cleanup): Likewise. | |
3470 | (get_symbols): Likewise. | |
3471 | (add_input_file): Likewise. | |
3472 | (bfd_plugin_close_and_cleanup): Likewise. | |
3473 | (claim_file): Removed. | |
3474 | (register_claim_file): Set current_plugin->claim_file. | |
3475 | (add_symbols): Make a copy of LTO symbols. Set lto_nsyms and | |
3476 | lto_syms in current_plugin. | |
3477 | (try_claim): Use current_plugin->claim_file. Call LTO plugin | |
3478 | all_symbols_read handler. Copy real symbols to plugin_data. | |
3479 | Call LTO plugin cleanup handler. Clean up for LTO wrapper. | |
3480 | (try_load_plugin): Don't reuse the previous plugin for LTO | |
3481 | wrapper. Set up GCC LTO wrapper if possible. Don't set | |
3482 | plugin_list_iter->claim_file. | |
3483 | (bfd_plugin_canonicalize_symtab): Use real LTO symbols if | |
3484 | possible. | |
3485 | * plugin.h (plugin_data_struct): Add real_bfd, real_nsyms and | |
3486 | real_syms. | |
3487 | ||
ac4280da JL |
3488 | 2020-02-10 Jozef Lawrynowicz <jozef.l@mittosystems.com> |
3489 | ||
3490 | * elf32-msp430.c (msp430_elf_relax_section): Before relaxing a branch, | |
3491 | check if previous instruction matches a conditional jump inserted | |
3492 | earlier. Invert conditional jump and delete branch in this case. | |
3493 | ||
8d6cb116 JL |
3494 | 2020-02-10 Jozef Lawrynowicz <jozef.l@mittosystems.com> |
3495 | ||
3496 | * elf32-msp430.c (msp430_elf_relax_add_two_words): Rename to | |
3497 | msp430_elf_relax_add_words. Support insertion of either one or two | |
3498 | words. | |
3499 | (msp430_elf_relax_section): Catch opcode of 0x3c00 when relocation | |
3500 | needs to be grown. Handle insertion of branch instruction to replace | |
3501 | jump. | |
3502 | ||
d60f5448 JL |
3503 | 2020-02-10 Jozef Lawrynowicz <jozef.l@mittosystems.com> |
3504 | ||
3505 | * elf32-msp430.c (msp430_final_link_relocate): Add printf statements for | |
3506 | debugging relocations. | |
3507 | (msp430_elf_relax_delete_bytes): Likewise. | |
3508 | (msp430_elf_relax_add_two_words): Likewise. | |
3509 | (msp430_elf_relax_section): Likewise. | |
3510 | ||
e1f85e11 AM |
3511 | 2020-02-10 Alan Modra <amodra@gmail.com> |
3512 | ||
3513 | * archures.c: Wrap overlong z80 comments. | |
3514 | * bfd-in2.h: Regenerate. | |
3515 | ||
9fc0b501 SB |
3516 | 2020-02-07 Sergey Belyashov <sergey.belyashov@gmail.com> |
3517 | ||
3518 | PR 25469 | |
3519 | * archures.c: Add GBZ80 and Z80N machine values. | |
3520 | * reloc.c: Add BFD_RELOC_Z80_16_BE. | |
3521 | * coff-z80.c: Add support for new reloc. | |
3522 | * coffcode.h: Add support for new machine values. | |
3523 | * cpu-z80.c: Add support for new machine names. | |
3524 | * elf32-z80.c: Add support for new reloc. | |
3525 | * bfd-in2.h: Regenerate. | |
3526 | * libbfd.h: Regenerate. | |
3527 | ||
9984857c NC |
3528 | 2020-02-07 Nick Clifton <nickc@redhat.com> |
3529 | ||
3530 | PR 23932 | |
3531 | * elf.c (rewrite_elf_program_header): Do not complain if no | |
3532 | sections are mapped to a segment. | |
3533 | ||
5242a0a0 L |
3534 | 2020-02-06 H.J. Lu <hongjiu.lu@intel.com> |
3535 | ||
3536 | PR ld/25490 | |
3537 | * elflink.c (_bfd_elf_gc_mark_extra_sections): Issue an error | |
3538 | for garbage collection on __patchable_function_entries section | |
3539 | without linked-to section. | |
3540 | ||
b7d07216 L |
3541 | 2020-02-06 H.J. Lu <hongjiu.lu@intel.com> |
3542 | ||
3543 | PR gas/25381 | |
3544 | * bfd-in2.h: Regenerated. | |
3545 | * elflink.c (_bfd_elf_gc_mark_extra_sections): Call mark_hook | |
3546 | on section if gc_mark of any of its linked-to sections is set | |
3547 | and don't set gc_mark again. | |
3548 | * section.c (asection): Add linked_to_symbol_name to map_head | |
3549 | union. | |
3550 | ||
b93a662b MR |
3551 | 2020-02-06 Maciej W. Rozycki <macro@wdc.com> |
3552 | ||
3553 | * elf32-v850.c (v850_elf_relax_section): Fix the index used for | |
3554 | reporting an unrecognized instruction with R_V850_LONGJUMP. | |
3555 | ||
6df4c9c2 AM |
3556 | 2020-02-05 Alan Modra <amodra@gmail.com> |
3557 | ||
3558 | * elf64-ppc.c (ppc_stub_plt_branch): Match comment with reality. | |
3559 | ||
24872cb3 AM |
3560 | 2020-02-04 Alan Modra <amodra@gmail.com> |
3561 | ||
3562 | * elf32-ppc.c (ppc_elf_relocate_section): After applying | |
3563 | R_PPC_VLE_ADDR20, goto copy_reloc. | |
3564 | ||
ef4627fa L |
3565 | 2020-02-02 H.J. Lu <hongjiu.lu@intel.com> |
3566 | ||
3567 | * bfd-in2.h: Regenerated. | |
3568 | * section.c (SEC_ASSEMBLER_SECTION_ID): Fix a typo in comments. | |
3569 | ||
a8c4d40b L |
3570 | 2020-02-02 H.J. Lu <hongjiu.lu@intel.com> |
3571 | ||
3572 | PR gas/25380 | |
3573 | * bfd-in2.h: Regenerated. | |
3574 | * ecoff.c (bfd_debug_section): Add section_id. | |
3575 | * section.c (bfd_section): Add section_id. | |
3576 | (SEC_ASSEMBLER_SECTION_ID): New. | |
3577 | (BFD_FAKE_SECTION): Add section_id. | |
3578 | ||
5a9212a1 NC |
3579 | 2020-02-01 Nick Clifton <nickc@redhat.com> |
3580 | ||
3581 | * config.bfd: Move the c30-aout and tic30-aout targets onto the | |
3582 | obsolete list. | |
3583 | ||
e7cbe0c4 SL |
3584 | 2020-01-31 Sandra Loosemore <sandra@codesourcery.com> |
3585 | ||
3586 | * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): DW_EH_PE_datarel | |
3587 | encodings are relative to the GOT on nios2, too. | |
3588 | ||
72ebe8c5 AM |
3589 | 2020-01-31 Alan Modra <amodra@gmail.com> |
3590 | ||
3591 | * Makefile.am (elf32-target.h, elf64-target.h): Don't use a temp | |
3592 | file. Use $< and $@ in rules. | |
3593 | (elf32-aarch64.c, elf64-aarch64.c): Likewise. | |
3594 | (elf32-ia64.c, elf64-ia64.c): Likewise. | |
3595 | (elf32-riscv.c, elf64-riscv.c): Likewise. | |
3596 | (peigen.c, pepigen.c, pex64igen.c): Likewise. | |
3597 | (elf32-aarch64.c, elf64-aarch64.c): Don't emit $srcdir on #line. | |
3598 | (elf32-riscv.c, elf64-riscv.c): Likewise, and use $(SED). | |
3599 | (elf32-ia64.c, elf64-ia64.c): Do emit #line. | |
3600 | (peigen.c, pepigen.c, pex64igen.c): Likewise. | |
3601 | * Makefile.in: Regenerate. | |
3602 | ||
327301a4 AM |
3603 | 2020-01-31 Alan Modra <amodra@gmail.com> |
3604 | ||
3605 | PR 4110 | |
3606 | * elf.c (setup_group): Don't clear entire section contents, | |
3607 | just the padding after group flags. Release alloc'd memory | |
3608 | after a seek or read failure. | |
3609 | ||
b5d36aaa JT |
3610 | 2020-01-16 Jon Turney <jon.turney@dronecode.org.uk> |
3611 | ||
3612 | * peXXigen.c (pe_is_repro): New function. | |
3613 | (_bfd_XX_print_private_bfd_data_common): Note timestamp is | |
3614 | actually a build hash if PE_IMAGE_DEBUG_TYPE_REPRO is present. | |
3615 | ||
1957ab10 JT |
3616 | 2020-01-16 Jon Turney <jon.turney@dronecode.org.uk> |
3617 | ||
3618 | * peXXigen.c (debug_type_names): Add names for new debug data type | |
3619 | values. | |
3620 | ||
87b2920f JT |
3621 | 2020-01-16 Jon Turney <jon.turney@dronecode.org.uk> |
3622 | ||
3623 | * peXXigen.c (pe_print_debugdata): Fix the iteration variable for | |
3624 | inner loop. Fix a memory leak. | |
3625 | ||
72913831 AM |
3626 | 2020-01-30 Alan Modra <amodra@gmail.com> |
3627 | ||
3628 | * coffgen.c (coff_real_object_p): Don't clear obj_coff_keep_syms | |
3629 | or obj_coff_keep_strings here. | |
3630 | (coff_get_normalized_symtab): Free external syms directly. | |
3631 | * xcofflink.c (xcoff_link_input_bfd): Restore obj_coff_keep_syms | |
3632 | on error exit path. | |
3633 | ||
c35d018b JW |
3634 | 2020-01-27 Jim Wilson <jimw@sifive.com> |
3635 | ||
3636 | * cpu-riscv.c (riscv_scan): New. | |
3637 | (N): Change bfd_default_scan to riscv_scan. | |
3638 | ||
086b06f3 AS |
3639 | 2020-01-27 Andreas Schwab <schwab@suse.de> |
3640 | ||
3641 | * Makefile.am (ALL_MACHINES): Remove cpu-plugin.lo. | |
3642 | (ALL_MACHINES_CFILES): Remove cpu-plugin.c. | |
3643 | * Makefile.in: Regenerate. | |
3644 | * cpu-plugin.c: Remove. | |
3645 | * archures.c (enum bfd_architecture): Remove bfd_arch_plugin. | |
3646 | (bfd_plugin_arch): Remove declaration. | |
3647 | * bfd-in2.h: Regenerate. | |
3648 | * po/SRC-POTFILES.in: Regenerate. | |
3649 | ||
3024a17a AM |
3650 | 2020-01-27 H.J. Lu <hongjiu.lu@intel.com> |
3651 | Alan Modra <amodra@gmail.com> | |
3652 | ||
3653 | PR ld/25458 | |
3654 | * elflink.c (_bfd_elf_gc_mark_rsec): Mark all weak aliases. | |
3655 | ||
b5f998b2 JW |
3656 | 2020-01-24 Jim Wilson <jimw@sifive.com> |
3657 | ||
3658 | * elfxx-riscv.c (riscv_get_prefix_class): Format s case like others. | |
3659 | (riscv_parse_prefixed_ext): Fix s extension comment and reword to | |
3660 | avoid over long line. | |
3661 | ||
caa31cfa NC |
3662 | 2020-01-24 Nick Clifton <nickc@redhat.com> |
3663 | ||
3664 | PR 25447 | |
3665 | * coffgen.c (_bfd_coff_close_and_cleanup): Do not clear the keep | |
3666 | syms and keep strings flags as these may have been set in order to | |
3667 | prevent a bogus call to free. | |
3668 | ||
24e648d4 NC |
3669 | 2020-01-23 Nick Clifton <nickc@redhat.com> |
3670 | ||
3671 | * po/fr.po: Updated French translation. | |
3672 | ||
67641dd3 AM |
3673 | 2020-01-23 Alan Modra <amodra@gmail.com> |
3674 | ||
3675 | PR 25444 | |
3676 | * elf.c (assign_file_positions_for_load_sections): Avoid divide | |
3677 | by zero when p_align is zero. | |
3678 | ||
403d1bd9 JW |
3679 | 2020-01-22 Maxim Blinov <maxim.blinov@embecosm.com> |
3680 | ||
3681 | * bfd/elfnn-riscv.c (riscv_skip_prefix): New. | |
3682 | (riscv_prefix_cmp): Likewise. | |
3683 | (riscv_non_std_ext_p): Deleted. | |
3684 | (riscv_std_sv_ext_p): Likewise. | |
3685 | (riscv_non_std_sv_ext_p): Likewise. | |
3686 | (riscv_merge_non_std_and_sv_ext): Rename to... | |
3687 | (riscv_merge_multi_letter_ext): and modified to use riscv_prefix_cmp. | |
3688 | (riscv_merge_arch_attr_info): Replace 3 calls to | |
3689 | riscv_merge_non_std_and_sv_ext with single call to | |
3690 | riscv_merge_multi_letter_ext. | |
3691 | * bfd/elfxx-riscv.c (riscv_parse_std_ext): Break if we | |
3692 | encounter a 'z' prefix. | |
3693 | (riscv_get_prefix_class): New function, return prefix class based | |
3694 | on first few characters of input string. | |
3695 | (riscv_parse_config): New structure to factor out minor differences | |
3696 | in extension class parsing behaviour. | |
3697 | (riscv_parse_sv_or_non_std_ext): Rename to... | |
3698 | (riscv_parse_prefixed_ext): and parameterise with | |
3699 | riscv_parse_config. | |
3700 | (riscv_std_z_ext_strtab, riscv_std_s_ext_strtab): New. | |
3701 | (riscv_multi_letter_ext_valid_p): New. | |
3702 | (riscv_ext_x_valid_p, riscv_ext_z_valid_p, riscv_ext_s_valid_p): New. | |
3703 | (riscv_parse_subset): Delegate all non-single-letter parsing work | |
3704 | to riscv_parse_prefixed_ext. | |
3705 | * bfd/elfxx-riscv.h (riscv_isa_ext_class): New type. | |
3706 | (riscv_get_prefix_class): Declare. | |
3707 | ||
a804e476 AM |
3708 | 2020-01-22 Alan Modra <amodra@gmail.com> |
3709 | ||
3710 | * elf64-ppc.c (struct ppc_link_hash_table): Add tga_group. | |
3711 | (ppc64_elf_archive_symbol_lookup): Extract __tls_get_addr_opt for | |
3712 | __tls_get_addr_desc. | |
3713 | (ppc64_elf_size_stubs): Add section for linker generated | |
3714 | __tls_get_addr_desc wrapper function. Loop at least once if | |
3715 | generating this function. | |
3716 | (emit_tga_desc, emit_tga_desc_eh_frame): New functions. | |
3717 | (ppc64_elf_build_stubs): Generate __tls_get_addr_desc. | |
3718 | ||
9e7028aa AM |
3719 | 2020-01-22 Alan Modra <amodra@gmail.com> |
3720 | ||
3721 | * elf64-ppc.h (struct ppc64_elf_params): Add no_tls_get_addr_regsave. | |
3722 | * elf64-ppc.c (struct ppc_link_hash_table): Add tga_desc and | |
3723 | tga_desc_fd. | |
3724 | (is_tls_get_addr): Match tga_desc and tga_desc_df too. | |
3725 | (STDU_R1_0R1, ADDI_R1_R1): Define. | |
3726 | (tls_get_addr_prologue, tls_get_addr_epilogue): New functions. | |
3727 | (ppc64_elf_tls_setup): Set up tga_desc and tga_desc_fd. Indirect | |
3728 | tga_desc_fd to opt_fd, and tga_desc to opt. Set | |
3729 | no_tls_get_addr_regsave. | |
3730 | (branch_reloc_hash_match): Add hash3 and hash4. | |
3731 | (ppc64_elf_tls_optimize): Handle tga_desc_fd and tga_desc too. | |
3732 | (ppc64_elf_size_dynamic_sections): Likewise. | |
3733 | (ppc64_elf_relocate_section): Likewise. | |
3734 | (plt_stub_size, build_plt_stub): Likewise. Size regsave | |
3735 | __tls_get_addr stub. | |
3736 | (build_tls_get_addr_stub): Build regsave __tls_get_addr stub and | |
3737 | eh_frame. | |
3738 | (ppc_size_one_stub): Handle tga_desc_fd and tga_desc too. Size | |
3739 | eh_frame for regsave __tls_get_addr. | |
3740 | ||
abc489c6 AM |
3741 | 2020-01-22 Alan Modra <amodra@gmail.com> |
3742 | ||
3743 | * elf64-ppc.c (ppc64_elf_size_stubs): Correct condition under | |
3744 | which __tls_get_addr calls will be eliminated. | |
3745 | ||
26916852 NC |
3746 | 2020-01-20 Nick Clifton <nickc@redhat.com> |
3747 | ||
3748 | * po/pt.po: Updates Portuguese translation. | |
3749 | * po/ru.po: Updated Russian translation. | |
3750 | * po/uk.po: Updated Ukranian translation. | |
3751 | ||
14470f07 L |
3752 | 2020-01-20 H.J. Lu <hongjiu.lu@intel.com> |
3753 | ||
3754 | PR ld/25416 | |
3755 | * elf64-x86-64.c (elf_x86_64_check_tls_transition): Support | |
3756 | "rex leal x@tlsdesc(%rip), %reg" and "call *x@tlsdesc(%eax)" in | |
3757 | X32 mode. | |
3758 | (elf_x86_64_relocate_section): In x32 mode, for GDesc -> LE | |
3759 | transition, relax "rex leal x@tlsdesc(%rip), %reg" to | |
3760 | "rex movl $x@tpoff, %reg", for GDesc -> IE transition, relax | |
3761 | "rex leal x@tlsdesc(%rip), %reg" to | |
3762 | "rex movl x@gottpoff(%rip), %eax". For both transitions, relax | |
3763 | "call *(%eax)" to "nopl (%rax)". | |
3764 | ||
b9ca1af6 AM |
3765 | 2020-01-20 Alan Modra <amodra@gmail.com> |
3766 | ||
3767 | * elf64-ppc.c (LD_R11_0R3, CMPDI_R11_0, STD_R11_0R1, LD_R11_0R1), | |
3768 | (MTLR_R11): Don't define. | |
3769 | (LD_R0_0R3, CMPDI_R0_0): Define. | |
3770 | (build_tls_get_addr_stub): Don't use r11 in stub. | |
3771 | ||
ed7007c1 AM |
3772 | 2020-01-20 Alan Modra <amodra@gmail.com> |
3773 | ||
3774 | * elf64-ppc.c (ppc_elf_hash_entry): New function, use throughout file. | |
3775 | (defined_sym_val, is_tls_get_addr): Likewise. | |
3776 | ||
1b1bb2c6 NC |
3777 | 2020-01-18 Nick Clifton <nickc@redhat.com> |
3778 | ||
3779 | * version.m4 (BFD_VERSION): Set to 2.34.50. | |
3780 | * configure: Regenerate. | |
3781 | * po/bfd.pot: Regenerate. | |
3782 | ||
ae774686 NC |
3783 | 2020-01-18 Nick Clifton <nickc@redhat.com> |
3784 | ||
3785 | Binutils 2.34 branch created. | |
3786 | ||
07f1f3aa CB |
3787 | 2020-01-17 Christian Biesinger <cbiesinger@google.com> |
3788 | ||
3789 | * coff-arm.c: Fix spelling error (seperate). | |
3790 | * elfxx-riscv.c (riscv_parse_sv_or_non_std_ext): Fix spelling | |
3791 | error (seperate). | |
3792 | * sysdep.h (strnlen): Fix spelling error (seperate). | |
3793 | ||
0d1cc75d LB |
3794 | 2020-01-15 Lars Brinkhoff <lars@nocrew.org> |
3795 | ||
3796 | PR 20694 | |
3797 | * pdp11.c (TARGET_PAGE_SIZE): Set to 8192. | |
3798 | ||
e1c6cf61 AM |
3799 | 2020-01-15 Alan Modra <amodra@gmail.com> |
3800 | ||
3801 | PR 25384 | |
3802 | * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Update comment. | |
3803 | (ppc64_elf_adjust_dynamic_symbol): Don't allow .dynbss copies | |
3804 | of function symbols unless dot symbols are present. Do warn | |
3805 | whenever one is created, regardles of whether a PLT entry is | |
3806 | also emitted for the function symbol. | |
3807 | ||
ef4e5ba5 AM |
3808 | 2020-01-14 Alan Modra <amodra@gmail.com> |
3809 | ||
3810 | * som.c (som_bfd_count_ar_symbols): Error when file position | |
3811 | of symbols on chains is not strictly increasing. | |
3812 | ||
8ab484c2 AM |
3813 | 2020-01-14 Alan Modra <amodra@gmail.com> |
3814 | ||
3815 | * vms.h (VMS_DEBUG): Define as 0. | |
3816 | * vms-alpha.c (image_write): Move debug output after bounds check. | |
3817 | Tidy bounds check. | |
3818 | (_bfd_vms_slurp_eihd): Warning fix. | |
3819 | (_bfd_vms_slurp_etir): Init variables to avoid bogus warnings. | |
3820 | ||
b50ef514 AM |
3821 | 2020-01-13 Alan Modra <amodra@gmail.com> |
3822 | ||
3823 | * vms-alpha.c (_bfd_vms_slurp_egsd): Ensure minimum size even | |
3824 | for "ignored" records. | |
3825 | ||
0c0adcc5 AM |
3826 | 2020-01-13 Alan Modra <amodra@gmail.com> |
3827 | ||
3828 | * wasm-module.c (wasm_scan_name_function_section): Formatting. | |
3829 | Delete asect name check. Move asect NULL check to wasm_object_p. | |
3830 | Correct bounds check of sizes against end. Replace uses of | |
3831 | bfd_zalloc with bfd_alloc, zeroing only necessary bytes. Use | |
3832 | just one bfd_release. | |
3833 | (wasm_scan): Don't use malloc/strdup for section names, | |
3834 | bfd_alloc instead. Simplify code prefixing section name. | |
3835 | Formatting. Don't attempt to free memory here.. | |
3836 | (wasm_object_p): ..do so here. | |
3837 | ||
7f026732 SN |
3838 | 2020-01-10 Szabolcs Nagy <szabolcs.nagy@arm.com> |
3839 | ||
3840 | PR ld/22269 | |
3841 | * elf32-arm.c (elf32_arm_final_link_relocate): Use | |
3842 | UNDEFWEAK_NO_DYNAMIC_RELOC. | |
3843 | (allocate_dynrelocs_for_symbol): Likewise. | |
3844 | ||
8cd0e5e9 TC |
3845 | 2020-01-10 Tamar Christina <tamar.christina@arm.com> |
3846 | ||
3847 | PR 25210 | |
3848 | * elfnn-aarch64.c (_bfd_aarch64_create_stub_section): Remove elfclass. | |
3849 | ||
71780f45 AM |
3850 | 2020-01-10 Alan Modra <amodra@gmail.com> |
3851 | ||
3852 | * coff-alpha.c (alpha_ecoff_object_p): Calculate size in bfd_size_type. | |
3853 | ||
b899eb3b NC |
3854 | 2020-01-09 Nick Clifton <nickc@redhat.com> |
3855 | ||
3856 | PR 25221 | |
3857 | * bfd.c (bfd_convert_section_contents): Check for a compress | |
3858 | header size that is larger than the actual section size. | |
3859 | ||
4c6ee646 AM |
3860 | 2020-01-08 Alan Modra <amodra@gmail.com> |
3861 | ||
3862 | PR 25351 | |
3863 | * elflink.c (bfd_elf_final_link): Call _bfd_fix_excluded_sec_syms | |
3864 | after removing sections. | |
3865 | ||
85f78364 JW |
3866 | 2020-01-06 Jim Wilson <jimw@sifive.com> |
3867 | ||
3868 | PR 25205 | |
3869 | * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Add | |
3870 | check for !bfd_link_pic (info). | |
3871 | <R_RISCV_CALL_PLT>: Move next to R_RISCV_CALL. | |
3872 | <R_RISCV_JAL>: Add comment. | |
3873 | (_bfd_riscv_relax_section): For plt.offset check, add check for | |
3874 | bfd_link_pic (info). Add comment. | |
3875 | ||
49078ece AM |
3876 | 2020-01-06 Alan Modra <amodra@gmail.com> |
3877 | ||
3878 | * format.c (bfd_check_format_matches): Ignore bfd_error on target | |
3879 | match failures. Don't init to bfd_error_wrong_format before | |
3880 | calling _bfd_check_format. | |
3881 | ||
ab356be7 AM |
3882 | 2020-01-06 Alan Modra <amodra@gmail.com> |
3883 | ||
3884 | * vms-alpha.c (_bfd_vms_push, _bfd_vms_pop): Return pass/fail | |
3885 | status rather than exiting on stack overflow or underflow. | |
3886 | (_bfd_vms_slurp_etir): Adjust to suit. | |
3887 | ||
85d86817 AM |
3888 | 2020-01-06 Alan Modra <amodra@gmail.com> |
3889 | ||
3890 | * som.c (som_bfd_fill_in_ar_symbols): Bounds check som_dict index. | |
3891 | ||
3e6aa775 AM |
3892 | 2020-01-06 Alan Modra <amodra@gmail.com> |
3893 | ||
3894 | * mach-o.c (bfd_mach_o_read_dylinker): Don't read past end of | |
3895 | command. Check name offset is within command. | |
3896 | (bfd_mach_o_read_dylib, bfd_mach_o_read_prebound_dylib), | |
3897 | (bfd_mach_o_read_prebind_cksum, bfd_mach_o_read_twolevel_hints), | |
3898 | (bfd_mach_o_read_fvmlib, bfd_mach_o_read_dysymtab), | |
3899 | (bfd_mach_o_read_symtab, bfd_mach_o_read_uuid), | |
3900 | (bfd_mach_o_read_linkedit, bfd_mach_o_read_str), | |
3901 | (bfd_mach_o_read_dyld_info, bfd_mach_o_read_version_min), | |
3902 | (bfd_mach_o_read_encryption_info, bfd_mach_o_read_source_version), | |
3903 | (bfd_mach_o_read_encryption_info_64, bfd_mach_o_read_main), | |
3904 | (bfd_mach_o_read_note, bfd_mach_o_read_build_version), | |
3905 | (bfd_mach_o_read_segment): Similarly. | |
3906 | (bfd_mach_o_read_thread): Properly bound check thread struct. | |
3907 | Don't repeat checks on second loop. | |
3908 | (bfd_mach_o_read_command): Fail on invalid command length. | |
3909 | ||
ea933f17 AM |
3910 | 2020-01-04 Alan Modra <amodra@gmail.com> |
3911 | ||
3912 | * format.c (bfd_check_format_matches): Add preserve_match. | |
3913 | Save initial bfd state in "preserve", matched bfd state in | |
3914 | "preserve_match". Save just the first match. Release | |
3915 | bfd_alloc memory. Restore and finish preserved state as | |
3916 | appropriate on all function exit paths. | |
3917 | ||
f24bdec4 AM |
3918 | 2020-01-04 Alan Modra <amodra@gmail.com> |
3919 | ||
3920 | * mmo.c (mmo_mkobject): Allocate tdata with bfd_zalloc. | |
3921 | ||
991fb595 AM |
3922 | 2020-01-04 Alan Modra <amodra@gmail.com> |
3923 | ||
3924 | * coffgen.c (coff_real_object_p): Free malloc'd memory on target | |
3925 | match too. | |
3926 | ||
f2a3559d NC |
3927 | 2020-01-03 Nick Clifton <nickc@redhat.com> |
3928 | ||
3929 | PR 25307 | |
3930 | (bfd_pef_parse_function_stubs): Correct the test that ensures that | |
3931 | there is enough data remaining in the code buffer before | |
3932 | attempting to read a function stub. | |
3933 | ||
7a0fb7be NC |
3934 | 2020-01-03 Nick Clifton <nickc@redhat.com> |
3935 | ||
3936 | PR 25308 | |
3937 | * elf-properties.c (_bfd_elf_convert_gnu_properties): Check the | |
3938 | return value from bfd_malloc. | |
3939 | * elf32-arm.c (bfd_elf32_arm_vfp11_fix_veneer_locations): Likewise. | |
3940 | (bfd_elf32_arm_stm32l4xx_fix_veneer_locations): Likewise. | |
3941 | (elf32_arm_filter_cmse_symbols): Likewise. | |
3942 | (elf32_arm_write_section): Likewise. | |
3943 | * mach-o.c (bfd_mach_o_core_fetch_environment): Likewise. | |
3944 | (bfd_mach_o_follow_dsym): Likewise. | |
3945 | * pef.c (bfd_pef_print_loader_section): Likewise. | |
3946 | (bfd_pef_scan_start_address): Likewise. | |
3947 | (bfd_pef_parse_function_stubs): Likewise. | |
3948 | (bfd_pef_parse_symbols): Likewise. | |
3949 | ||
b26a3d58 ST |
3950 | 2020-01-03 Sergei Trofimovich <siarheit@google.com> |
3951 | ||
3952 | * elfnn-ia64.c (elfNN_ia64_merge_private_bfd_data): don't fail | |
3953 | on binary inputs ld/PR25316. | |
3954 | (is_ia64_elf): new helper to filter on ia64 objects. | |
3955 | ||
4bb7a87e JB |
3956 | 2020-01-03 Jan Beulich <jbeulich@suse.com> |
3957 | ||
3958 | * mach-o.c (cpusubtype, bfd_mach_o_header_p): Insert underscore | |
3959 | in parameter names. | |
3960 | (bfd_mach_o_scan): Insert underscore in two variable names. | |
3961 | ||
6655dba2 SB |
3962 | 2020-01-02 Sergey Belyashov <sergey.belyashov@gmail.com> |
3963 | ||
3964 | * Makefile.am: Add z80-elf target support. | |
3965 | * configure.ac: Likewise. | |
3966 | * targets.c: Likewise. | |
3967 | * Makefile.in: Regenerate. | |
3968 | * configure: Regenerate. | |
3969 | * config.bfd: Add z80-elf target support and new arches: ez80 and | |
3970 | z180. | |
3971 | * elf32-z80.c: New file. | |
3972 | * archures.c: Add new z80 architectures: eZ80 and Z180. | |
3973 | * coffcode.h: Likewise. | |
3974 | * cpu-z80.c: Likewise. | |
3975 | * coff-z80.c: Add new relocations for Z80 target and local label | |
3976 | check. | |
3977 | * reloc.c: Add new relocs. | |
3978 | * bfd-in2.h: Regenerate. | |
3979 | * libbfd.h: Regenerate. | |
3980 | ||
0db131fb TC |
3981 | 2020-01-02 Tamar Christina <tamar.christina@arm.com> |
3982 | ||
3983 | PR 25210 | |
3984 | PR 24753 | |
3985 | * elfnn-aarch64.c (_bfd_aarch64_create_stub_section): Set ELF class. | |
3986 | ||
b14ce8bf AM |
3987 | 2020-01-01 Alan Modra <amodra@gmail.com> |
3988 | ||
3989 | Update year range in copyright notice of all files. | |
3990 | ||
0b114740 | 3991 | For older changes see ChangeLog-2019 |
3499769a | 3992 | \f |
0b114740 | 3993 | Copyright (C) 2020 Free Software Foundation, Inc. |
3499769a AM |
3994 | |
3995 | Copying and distribution of this file, with or without modification, | |
3996 | are permitted in any medium without royalty provided the copyright | |
3997 | notice and this notice are preserved. | |
3998 | ||
3999 | Local Variables: | |
4000 | mode: change-log | |
4001 | left-margin: 8 | |
4002 | fill-column: 74 | |
4003 | version-control: never | |
4004 | End: |