]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - bfd/ChangeLog
sim: rl78/rx: drop unnecessary getopt.h probing
[thirdparty/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
6f8f6017
AM
12021-04-16 Alan Modra <amodra@gmail.com>
2
3 PR 27567
4 * coffcode.h (styp_to_sec_flags): Use an unsigned long styp_flags.
5 (coff_write_object_contents): Pass bfd to COFF_ENCODE_ALIGNMENT,
6 ignore alignment checks when return is false. Formatting.
7
ddfe525f
NC
82021-04-15 Nelson Chu <nelson.chu@sifive.com>
9
10 PR27584
11 * elfnn-riscv.c (riscv_elf_is_target_special_symbol): Added to
12 omit local and empty symbols since they usually generated to
13 mark the auipc instructions.
14
f6a1f957
LX
152021-04-15 Lifang Xia<lifang_xia@c-sky.com>
16
17 * elf32-csky.c (csky_elf_howto_table)
18 <R_CKCORE_PCREL_IMM16BY2>: Set special_function to
19 bfd_elf_generic_reloc.
20 <R_CKCORE_PCREL_IMM16BY4>: Likewise.
21 <R_CKCORE_PCREL_IMM10BY4>: Likewise.
22 <R_CKCORE_PCREL_IMM18BY2>: Likewise.
23 <R_CKCORE_PCREL_FLRW_IMM8BY4>: Likewise.
24
9917b559
L
252021-04-14 H.J. Lu <hongjiu.lu@intel.com>
26
27 PR binutils/27708
28 * elf.c (assign_file_positions_for_non_load_sections): Set
29 p_memsz to p_filesz for the loadable PT_NOTE segment.
30
5f47741b
FC
312021-04-14 Frederic Cambus <fred@statdns.com>
32
33 * elf.c (elfcore_grok_netbsd_note): Remove unneeded #ifdef
34 checks for NT_NETBSDCORE_AUXV and NT_NETBSDCORE_LWPSTATUS.
35
8985b74b
AM
362021-04-14 Alan Modra <amodra@gmail.com>
37
38 PR 27631
39 * elf32-metag.c (elf_metag_relocate_section): Don't use &hh->elf
40 when hh might be NULL, test for NULL first.
41
c9f9a78d
AM
422021-04-14 Alan Modra <amodra@gmail.com>
43
44 PR 27630
45 * elf32-arm.c (elf32_arm_size_stubs): Don't use &hash->root when
46 hash might be NULL, cast instead.
47
d2f1139e
CC
482021-04-13 Clément Chigot <clement.chigot@atos.net>
49
50 * xcofflink.c (xcoff_link_check_ar_symbols): Update esym earlier.
51
e3839c10
NC
522021-04-13 Nelson Chu <nelson.chu@sifive.com>
53
54 * elfnn-riscv.c (riscv_version_mismatch): Do not report the warning
55 when the version of input or output is RISCV_UNKNOWN_VERSION, since
56 the extension is added implicitly.
57 * elfxx-riscv.c: Updated the obsolete comments.
58 (RISCV_UNKNOWN_VERSION): Moved to elfxx-riscv.h.
59 * elfxx-riscv.h (RISCV_UNKNOWN_VERSION): Added.
60
43e05cd4
AM
612021-04-12 Alan Modra <amodra@gmail.com>
62
63 * elf-bfd.h (ENABLE_CHECKING): Define.
64 (elf_link_hash_lookup): Abort if wrong type of hash table.
65 * configure.ac (--enable-checking): Add support.
66 * config.in: Regenerate.
67 * configure: Regenerate.
68
2cc15b10
AM
692021-04-12 Alan Modra <amodra@gmail.com>
70
71 * elf-bfd.h (is_elf_hash_table): Convert macro to inline function.
72 (elf_link_hash_lookup, elf_link_hash_traverse): Likewise.
73 (elf_hash_table, elf_hash_table_id): Likewise.
74 * elf32-arm.c (elf32_arm_setup_section_lists): Delete redundant
75 is_elf_hash_table check.
76 * elf32-csky.c (elf32_csky_setup_section_lists): Likewise.
77 * elf32-hppa.c (clobber_millicode_symbols): Correct param types.
78 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
79 * elfnn-ia64.c (elfNN_ia64_global_dyn_info_free: Likewise.
80 (elfNN_ia64_global_dyn_sym_thunk: Likewise.
81 * elf64-ia64-vms.c (elf64_ia64_global_dyn_info_free): Likewise.
82 (elf64_ia64_global_dyn_sym_thunk): Likewise.
83 (elf64_vms_link_add_object_symbols): Pass base type of hash table
84 to is_elf_hash_table.
85 * elflink.c (_bfd_elf_dynamic_symbol_p): Likewise.
86 (_bfd_elf_symbol_refs_local_p, _bfd_elf_add_dynamic_entry): Likewise.
87 (_bfd_elf_strip_zero_sized_dynamic_sections): Likewise.
88 (_bfd_elf_link_check_relocs, elf_link_add_object_symbols): Likewise.
89 (bfd_elf_final_link): Likewise.
90 * elfnn-aarch64.c (elfNN_aarch64_setup_section_lists): Likewise.
91 * elf64-ppc.c (ppc64_elf_set_toc): Likewise. Use bfd_link_hash_lookup.
92
b585e899
AM
932021-04-12 Alan Modra <amodra@gmail.com>
94
95 * elf-bfd.h (struct elf_backend_data): Return bfd_link_hash_entry*
96 from elf_backend_archive_symbol_lookup.
97 (_bfd_elf_archive_symbol_lookup): Return bfd_link_hash_entry*.
98 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Likewise. Check
99 we have a ppc_hash_table before accessing ppc_link_hash_entry
100 fields.
101 * elflink.c (_bfd_elf_archive_symbol_lookup): Return
102 bfd_link_hash_entry*.
103 (elf_link_add_archive_symbols): Adjust to suit.
104
f5b10973
NC
1052021-04-12 Nelson Chu <nelson.chu@sifive.com>
106
107 * elfxx-riscv.c (riscv_parse_std_ext): Fixed the wrong versions of
108 i-ext when expanding g-ext.
109
f0bae255
NC
1102021-04-12 Nelson Chu <nelson.chu@sifive.com>
111
112 * elfxx-riscv.c (riscv_ext_dont_care_version): Removed.
113 (riscv_parse_add_subset): Always add the implicit extensions, even if
114 their versions are RISCV_UNKNOWN_VERSION.
115 (riscv_parse_std_ext): Delay to add i-ext as the implicit extension
116 in the riscv_parse_add_implicit_subsets. Besides, add g-ext as the
117 implicit extension after it has been expanded.
118 (riscv_parse_add_implicit_subsets): Updated.
119
e601909a
NC
1202021-04-12 Nelson Chu <nelson.chu@sifive.com>
121
122 * elfxx-riscv.c (riscv_std_z_ext_strtab): Moved forward.
123 (riscv_std_s_ext_strtab): Likewise.
124 (riscv_std_h_ext_strtab): Likewise.
125 (riscv_std_zxm_ext_strtab): Added for the zxm prefix.
126 (enum riscv_prefix_ext_class): Moved forward and renamed from
127 riscv_isa_ext_class. Reorder them according to the parsing order,
128 since the enum values are used to check the orders in the
129 riscv_compare_subsets.
130 (struct riscv_parse_prefix_config): Moved forward and renamed from
131 riscv_parse_config_t. Also removed the ext_valid_p field, the
132 related functions are replaced by riscv_valid_prefixed_ext.
133 (parse_config): Moved forward and updated. The more letters of the
134 prefix string, the more forward it must be defined. Otherwise, we
135 will get the wrong mapping when using strncmp in riscv_get_prefix_class.
136 (riscv_get_prefix_class): Moved forward. Support to parse the
137 multi-letter prefix, like zxm.
138 (riscv_known_prefixed_ext): New function, check if the prefixed
139 extension is supported according to the right riscv_std_*_ext_strtab.
140 (riscv_valid_prefixed_ext): New function, used to replace the
141 riscv_ext_*_valid_p functions.
142 (riscv_init_ext_order): Do not set the values for prefix keywords
143 since they may have multiple letters for now.
144 (riscv_compare_subsets): Set the order values of prefix keywords
145 to negative numbers according to the riscv_prefix_ext_class.
146 (riscv_parse_std_ext): Call riscv_get_prefix_class to see if we
147 have parsed the prefixed extensions.
148 (riscv_parse_prefixed_ext): Updated and removed the parameter config.
149 Report error when the prefix is unknown.
150 (riscv_parse_subset): Do not parse the prefixed extensions according
151 to the orders in the parse_config. Remove the confused message and
152 let riscv_parse_prefixed_ext to report the details.
153 * elfxx-riscv.h (enum riscv_isa_ext_class): Moved to elfxx-riscv.c.
154 (riscv_get_prefix_class): Removed to static.
155
eec8bf7e
MF
1562021-04-08 Mike Frysinger <vapier@gentoo.org>
157
158 * configure.ac (ACX_BUGURL): Use https://.
159 * configure.com (COPY_TEXT): Likewise.
160 * configure: Regenerate.
161
83c79df8
AM
1622021-04-05 Alan Modra <amodra@gmail.com>
163
164 * configure.ac: Don't check for long long or long double type.
165 Don't check for alloca.h, limits.h, stddef.h, stdlib.h, string.h,
166 strings.h, time.h, wchar.h, wctype.h or sys/time.h. Don't check
167 for strtoull, free, malloc, realloc, getenv, strstr, snprintf,
168 vsnprintf, strlen or setitimer. Sort AC_CHECK_DECLS.
169 (AC_ISC_POSIX): Don't invoke.
170 (AC_HEADER_TIME, AC_HEADER_DIRENT, ACX_HEADER_STRING): Likewise.
171 * sysdep.h: Remove many HAVE_*_H checks and fallback declarations.
172 Do test HAVE_SYS_TYPES_H. Don't include sys/time.h. Reorder
173 header order as per automake AC_INCLUDES_DEFAULT.
174 * bfd-in.h: Include inttypes.h unconditionally.
175 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Assume long long and
176 long double are available.
177 (bfd_scan_vma): Assume long long and strtoull are available.
178 * elflink.c: Include limits.h unconditionally.
179 * elfnn-riscv.c: Likewise.
180 * wasm-module.c: Likewise.
181 * hpux-core.c: Include dirent.h unconditionally.
182 * trad-core.c: Likewise.
183 * hosts/x86-64linux.h: Include stdlib.h unconditionally.
184 * peXXigen.c: Remove HAVE_WCHAR_H and HAVE_WCTYPE_H checks.
185 * elf32-m68hc1x.c: Don't include alloca-conf.h.
186 * elf64-hppa.c: Likewise.
187 * som.c: Likewise.
188 * wasm-module.c: Likewise.
189 * xsym.c: Likewise.
190 * bfd-in2.h: Regenerate.
191 * config.in: Regenerate.
192 * configure: Regenerate.
193
74edb473
TC
1942021-04-01 Tamar Christina <tamar.christina@arm.com>
195
196 PR ld/26659
197 * cofflink.c (_bfd_coff_generic_relocate_section): Ignore overflow.
198
e9b095a5
ML
1992021-04-01 Martin Liska <mliska@suse.cz>
200
201 * ecoff.c (strneq): Remove strneq and use startswith.
202 (_bfd_ecoff_slurp_armap): Likewise.
203
3f3328b8
ML
2042021-04-01 Martin Liska <mliska@suse.cz>
205
206 * elf-bfd.h (bfd_section_is_ctf): Use startswith function.
207 * elf.c (_bfd_elf_make_section_from_shdr): Likewise.
208 (elf_get_reloc_section): Likewise.
209 * elf32-arc.c (elf_arc_size_dynamic_sections): Likewise.
210 * elf32-m32r.c (m32r_elf_section_flags): Likewise.
211 * elf32-microblaze.c (microblaze_elf_size_dynamic_sections): Likewise.
212 * elf32-nds32.c (nds32_elf_size_dynamic_sections): Likewise.
213 (nds32_elf_relocate_section): Likewise.
214 (nds32_elf_action_discarded): Likewise.
215 (nds32_elf_check_relocs): Likewise.
216 (nds32_elf_section_flags): Likewise.
217 * elf32-or1k.c (or1k_elf_check_relocs): Likewise.
218 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
219 * elf32-rx.c (rx_table_find): Likewise.
220 (rx_table_map): Likewise.
221 * elf32-spu.c (spu_elf_backend_symbol_processing): Likewise.
222 (spu_elf_find_overlays): Likewise.
223 (needs_ovl_stub): Likewise.
224 (allocate_spuear_stubs): Likewise.
225 (build_spuear_stubs): Likewise.
226 (mark_overlay_section): Likewise.
227 (spu_elf_auto_overlay): Likewise.
228 (spu_elf_output_symbol_hook): Likewise.
229 * elf32-tilepro.c (tilepro_elf_size_dynamic_sections): Likewise.
230 * elf32-xtensa.c (xtensa_property_section_name): Likewise.
231 * elf64-ppc.c (ppc64_elf_section_flags): Likewise.
232 (ppc64_elf_relocate_section): Likewise.
233 * elflink.c (resolve_section): Likewise.
234 (UNARY_OP): Likewise.
235 (BINARY_OP_HEAD): Likewise.
236 (elf_link_input_bfd): Likewise.
237 * elfnn-riscv.c (riscv_elf_size_dynamic_sections): Likewise.
238 * elfxx-riscv.c (riscv_parse_subset): Likewise.
239 * elfxx-tilegx.c (tilegx_elf_size_dynamic_sections): Likewise.
240 * opncls.c (get_build_id): Likewise.
241
65c5fbd4
AM
2422021-03-31 Alan Modra <amodra@gmail.com>
243
244 PR 27671
245 * bfd-in.h: Don't poison FALSE or TRUE.
246 * bfd-in2.h: Regenerate.
247
0a1b45a2
AM
2482021-03-31 Alan Modra <amodra@gmail.com>
249
250 * sysdep.h: POISON_BFD_BOOLEAN: Define.
251 * aix5ppc-core.c, * aout-cris.c, * aout-ns32k.c, * aout-target.h,
252 * aoutx.h, * arc-got.h, * archive.c, * archive64.c, * archures.c,
253 * bfd-in.h, * bfd.c, * bfdwin.c, * binary.c, * cache.c,
254 * coff-alpha.c, * coff-arm.c, * coff-arm.h, * coff-bfd.c,
255 * coff-bfd.h, * coff-go32.c, * coff-i386.c, * coff-ia64.c,
256 * coff-mcore.c, * coff-mips.c, * coff-rs6000.c, * coff-sh.c,
257 * coff-stgo32.c, * coff-tic30.c, * coff-tic4x.c, * coff-tic54x.c,
258 * coff-x86_64.c, * coff-z80.c, * coff-z8k.c, * coff64-rs6000.c,
259 * coffcode.h, * coffgen.c, * cofflink.c, * compress.c,
260 * corefile.c, * cpu-aarch64.c, * cpu-aarch64.h, * cpu-alpha.c,
261 * cpu-arc.c, * cpu-arm.c, * cpu-arm.h, * cpu-avr.c, * cpu-bfin.c,
262 * cpu-bpf.c, * cpu-cr16.c, * cpu-cris.c, * cpu-crx.c,
263 * cpu-csky.c, * cpu-d10v.c, * cpu-d30v.c, * cpu-dlx.c,
264 * cpu-epiphany.c, * cpu-fr30.c, * cpu-frv.c, * cpu-ft32.c,
265 * cpu-h8300.c, * cpu-hppa.c, * cpu-i386.c, * cpu-ia64.c,
266 * cpu-iamcu.c, * cpu-ip2k.c, * cpu-iq2000.c, * cpu-k1om.c,
267 * cpu-l1om.c, * cpu-lm32.c, * cpu-m10200.c, * cpu-m10300.c,
268 * cpu-m32c.c, * cpu-m32r.c, * cpu-m68hc11.c, * cpu-m68hc12.c,
269 * cpu-m68k.c, * cpu-m9s12x.c, * cpu-m9s12xg.c, * cpu-mcore.c,
270 * cpu-mep.c, * cpu-metag.c, * cpu-microblaze.c, * cpu-mips.c,
271 * cpu-mmix.c, * cpu-moxie.c, * cpu-msp430.c, * cpu-mt.c,
272 * cpu-nds32.c, * cpu-nfp.c, * cpu-nios2.c, * cpu-ns32k.c,
273 * cpu-or1k.c, * cpu-pdp11.c, * cpu-pj.c, * cpu-powerpc.c,
274 * cpu-pru.c, * cpu-riscv.c, * cpu-rl78.c, * cpu-rs6000.c,
275 * cpu-rx.c, * cpu-s12z.c, * cpu-s390.c, * cpu-score.c,
276 * cpu-sh.c, * cpu-sparc.c, * cpu-spu.c, * cpu-tic30.c,
277 * cpu-tic4x.c, * cpu-tic54x.c, * cpu-tic6x.c, * cpu-tilegx.c,
278 * cpu-tilepro.c, * cpu-v850.c, * cpu-v850_rh850.c, * cpu-vax.c,
279 * cpu-visium.c, * cpu-wasm32.c, * cpu-xc16x.c, * cpu-xgate.c,
280 * cpu-xstormy16.c, * cpu-xtensa.c, * cpu-z80.c, * cpu-z8k.c,
281 * dwarf1.c, * dwarf2.c, * ecoff-bfd.h, * ecoff.c, * ecofflink.c,
282 * elf-attrs.c, * elf-bfd.h, * elf-eh-frame.c, * elf-hppa.h,
283 * elf-ifunc.c, * elf-m10200.c, * elf-m10300.c, * elf-nacl.c,
284 * elf-nacl.h, * elf-properties.c, * elf-s390-common.c,
285 * elf-s390.h, * elf-strtab.c, * elf-vxworks.c, * elf-vxworks.h,
286 * elf.c, * elf32-am33lin.c, * elf32-arc.c, * elf32-arm.c,
287 * elf32-arm.h, * elf32-avr.c, * elf32-avr.h, * elf32-bfin.c,
288 * elf32-bfin.h, * elf32-cr16.c, * elf32-cr16.h, * elf32-cris.c,
289 * elf32-crx.c, * elf32-csky.c, * elf32-csky.h, * elf32-d10v.c,
290 * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
291 * elf32-fr30.c, * elf32-frv.c, * elf32-ft32.c, * elf32-gen.c,
292 * elf32-h8300.c, * elf32-hppa.c, * elf32-hppa.h, * elf32-i386.c,
293 * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c, * elf32-m32c.c,
294 * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
295 * elf32-m68hc1x.c, * elf32-m68hc1x.h, * elf32-m68k.c,
296 * elf32-m68k.h, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
297 * elf32-metag.h, * elf32-microblaze.c, * elf32-mips.c,
298 * elf32-moxie.c, * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c,
299 * elf32-nios2.c, * elf32-nios2.h, * elf32-or1k.c, * elf32-pj.c,
300 * elf32-ppc.c, * elf32-ppc.h, * elf32-pru.c, * elf32-rl78.c,
301 * elf32-rx.c, * elf32-s12z.c, * elf32-s390.c, * elf32-score.c,
302 * elf32-score.h, * elf32-score7.c, * elf32-sh-relocs.h,
303 * elf32-sh.c, * elf32-sparc.c, * elf32-spu.c, * elf32-spu.h,
304 * elf32-tic6x.c, * elf32-tic6x.h, * elf32-tilegx.c,
305 * elf32-tilepro.c, * elf32-v850.c, * elf32-v850.h,
306 * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
307 * elf32-xc16x.c, * elf32-xgate.c, * elf32-xstormy16.c,
308 * elf32-xtensa.c, * elf32-z80.c, * elf64-alpha.c, * elf64-bpf.c,
309 * elf64-gen.c, * elf64-hppa.c, * elf64-ia64-vms.c,
310 * elf64-mips.c, * elf64-mmix.c, * elf64-nfp.c, * elf64-ppc.c,
311 * elf64-ppc.h, * elf64-s390.c, * elf64-sparc.c,
312 * elf64-tilegx.c, * elf64-x86-64.c, * elfcode.h,
313 * elfcore.h, * elflink.c, * elfn32-mips.c, * elfnn-aarch64.c,
314 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-aarch64.c,
315 * elfxx-aarch64.h, * elfxx-ia64.c, * elfxx-ia64.h,
316 * elfxx-mips.c, * elfxx-mips.h, * elfxx-riscv.c, * elfxx-riscv.h,
317 * elfxx-sparc.c, * elfxx-sparc.h, * elfxx-target.h,
318 * elfxx-tilegx.c, * elfxx-tilegx.h, * elfxx-x86.c, * elfxx-x86.h,
319 * format.c, * genlink.h, * hash.c, * i386aout.c, * i386lynx.c,
320 * i386msdos.c, * ihex.c, * libaout.h, * libbfd-in.h,
321 * libbfd.c, * libcoff-in.h, * libecoff.h, * libpei.h,
322 * libxcoff.h, * linker.c, * mach-o-aarch64.c, * mach-o-arm.c,
323 * mach-o-i386.c, * mach-o-x86-64.c, * mach-o.c, * mach-o.h,
324 * merge.c, * mmo.c, * netbsd.h, * opncls.c, * pc532-mach.c,
325 * pdp11.c, * pe-arm.c, * pe-i386.c, * pe-mcore.c, * pe-sh.c,
326 * pe-x86_64.c, * peXXigen.c, * pef.c, * pei-arm.c, * pei-i386.c,
327 * pei-ia64.c, * pei-mcore.c, * pei-sh.c, * pei-x86_64.c,
328 * peicode.h, * plugin.c, * plugin.h, * ppcboot.c, * reloc.c,
329 * reloc16.c, * rs6000-core.c, * section.c, * simple.c, * som.c,
330 * som.h, * srec.c, * stabs.c, * syms.c, * targets.c, * tekhex.c,
331 * verilog.c, * vms-alpha.c, * vms-lib.c, * vms-misc.c, * vms.h,
332 * wasm-module.c, * xcofflink.c, * xcofflink.h, * xsym.c,
333 * xsym.h: Replace bfd_boolean with bool, FALSE with false, and
334 TRUE with true throughout.
335 * bfd-in2.h: Regenerate.
336 * libbfd.h: Regenerate.
337 * libcoff.h: Regenerate.
338
ad9e24ad
AM
3392021-03-31 Alan Modra <amodra@gmail.com>
340
341 * bfd-in.h: Include stdbool.h.
342 (bfd_boolean): Define as bool
343 * bfd-in2.h: Regenerate.
344
3dfb1b6d
AM
3452021-03-31 Alan Modra <amodra@gmail.com>
346
347 * .gitignore: Delete bfd_stdint.h entry.
348 * Makefile.am (bfdinclude_HEADERS): Delete bfd_stdint.h.
349 (BUILD_HFILES, LOCAL_H_DEPS): Likewise.
350 * bfd-in.h: Include stdint.h in place of bfd_stdint.h.
351 * configure.ac: Don't invoke GCC_HEADER_STDINT.
352 * configure.com: Don't create bfd_stdint.h.
353 * Makefile.in: Regenerate.
354 * aclocal.m4: Regenerate.
355 * bfd-in2.h: Regenerate.
356 * config.in: Regenerate.
357 * configure: Regenerate.
358 * doc/Makefile.in: Regenerate.
359 * po/BLD-POTFILES.in: Regenerate.
360
57ae980e
AM
3612021-03-31 Alan Modra <amodra@gmail.com>
362
363 * bfd-in.h: Include string.h.
364 (LITMEMCPY, LITSTRCPY): Delete.
365 * bfd-in2.h: Regenerate.
366
d1cbe007
AM
3672021-03-30 Alan Modra <amodra@gmail.com>
368
369 * elflink.c (elf_link_add_object_symbols): Don't set h->indx
370 unless is_elf_hash_table.
371
63b4cc53
AM
3722021-03-29 Alan Modra <amodra@gmail.com>
373
374 * aoutx.h (aout_link_write_symbols): Don't cast boolean expression
375 to bfd_boolean.
376 * elf32-or1k.c (or1k_set_got_and_rela_sizes): Dont compare booleans
377 against FALSE.
378 * elf32-arc.c (name_for_global_symbol): Don't compare boolean to TRUE.
379 (is_reloc_PC_relative): Don't use "boolean_condition ? TRUE : FALSE".
380 (is_reloc_SDA_relative, is_reloc_for_GOT): Likewise.
381 (is_reloc_for_PLT, is_reloc_for_TLS): Likewise.
382 * elf32-arm.c (stm32l4xx_need_create_replacing_stub): Likewise.
383 * elf32-nds32.c (insert_nds32_elf_blank): Likewise.
384 * elf32-rx.c (rx_set_section_contents): Likewise.
385 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
386 * elfxx-mips.c (_bfd_mips_elf_ignore_undef_symbol): Likewise.
387 * mach-o.c (bfd_mach_o_read_command): Likewise.
388 * targets.c (bfd_get_target_info): Likewise.
389
f4f9ede0
AM
3902021-03-29 Alan Modra <amodra@gmail.com>
391
392 * coff-z80.c (z80_is_local_label_name): Return bfd_boolean.
393 * elf32-z80.c (z80_is_local_label_name): Likewise.
394 * elf32-spu.c (spu_elf_modify_headers): Likewise.
395 * elf32-nds32.h (struct elf_nds32_link_hash_table <hyper_relax>):
396 Change type to int.
397 * vms-lib.c (_bfd_vms_lib_write_archive_contents): Correct test
398 for error return from vms_write_data_block.
399
1201fda6
AM
4002021-03-29 Alan Modra <amodra@gmail.com>
401
402 * elf32-i386.c (elf_i386_finish_local_dynamic_symbol): Return int.
403 * elf64-ia64-vms.c (elf64_ia64_local_dyn_info_free): Likewise.
404 (elf64_ia64_local_dyn_sym_thunk): Likewise.
405 * elf64-x86-64.c (elf_x86_64_finish_local_dynamic_symbol): Likewise.
406 * elfnn-aarch64.c (elfNN_aarch64_allocate_local_ifunc_dynrelocs),
407 (elfNN_aarch64_finish_local_dynamic_symbol): Likewise.
408 * elfnn-ia64.c (elfNN_ia64_local_dyn_info_free): Likewise.
409 (elfNN_ia64_local_dyn_sym_thunk): Likewise.
410 * elfnn-riscv.c (allocate_local_ifunc_dynrelocs): Likewise.
411 (riscv_pcrel_reloc_eq): Likewise.
412 (riscv_elf_finish_local_dynamic_symbol): Likewise.
413 * elfxx-sparc.c (allocate_local_dynrelocs): Likewise.
414 (finish_local_dynamic_symbol): Likewise.
415 * elfxx-x86.c (elf_x86_allocate_local_dynreloc): Likewise.
416 * elfxx-mips.c (mips_elf_resolve_got_page_ref): Likewise.
417 (mips_elf_count_got_symbols): Change return type to bfd_boolean.
418
37bb890f
AM
4192021-03-29 Alan Modra <amodra@gmail.com>
420
421 * elflink.c (elf_link_output_symstrtab): Make flinfo parameter
422 a void pointer.
423 (bfd_elf_final_link): Delete out_sym_func typedef and don't cast
424 elf_link_output_symstrtab when calling output_arch_syms and
425 output_arch_local_syms.
426 * elf-bfd.h (struct elf_backend_data <elf_backend_output_arch_syms,
427 elf_backend_output_arch_local_syms>): Change return type of func
428 arg to match elf_link_output_symstrtab.
429 * elf-vxworks.h (elf_vxworks_link_output_symbol_hook): Correct
430 return type.
431 * elf32-nds32.c (nds32_elf_output_symbol_hook): Correct return type.
432 (nds32_elf_output_arch_syms): Correct func return type.
433
0f684201
AM
4342021-03-29 Alan Modra <amodra@gmail.com>
435
436 * elf-m10200.c (mn10200_elf_relocate_section): Return int.
437 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
438 * elf32-arc.c (elf_arc_relocate_section): Likewise.
439 * elf32-arm.c (elf32_arm_relocate_section): Likewise.
440 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
441 * elf32-bfin.c (bfin_relocate_section): Likewise.
442 (bfinfdpic_relocate_section): Likewise.
443 * elf32-cr16.c (elf32_cr16_relocate_section): Likewise.
444 * elf32-cris.c (cris_elf_relocate_section): Likewise.
445 * elf32-crx.c (elf32_crx_relocate_section): Likewise.
446 * elf32-csky.c (csky_elf_relocate_section): Likewise.
447 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
448 * elf32-epiphany.c (epiphany_elf_relocate_section): Likewise.
449 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
450 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
451 * elf32-ft32.c (ft32_elf_relocate_section): Likewise.
452 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
453 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
454 * elf32-i386.c (elf_i386_relocate_section): Likewise.
455 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
456 * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
457 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
458 * elf32-m32c.c (m32c_elf_relocate_section): Likewise.
459 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
460 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
461 * elf32-m68hc1x.h (elf32_m68hc11_relocate_section): Likewise.
462 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
463 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
464 * elf32-mep.c (mep_elf_relocate_section): Likewise.
465 * elf32-metag.c (elf_metag_relocate_section): Likewise.
466 * elf32-microblaze.c (microblaze_elf_relocate_section): Likewise.
467 * elf32-moxie.c (moxie_elf_relocate_section): Likewise.
468 * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
469 * elf32-mt.c (mt_elf_relocate_section): Likewise.
470 * elf32-nds32.c (nds32_elf_relocate_section): Likewise.
471 * elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
472 * elf32-or1k.c (or1k_elf_relocate_section): Likewise.
473 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
474 * elf32-pru.c (pru_elf32_relocate_section): Likewise.
475 * elf32-rl78.c (rl78_elf_relocate_section): Likewise.
476 * elf32-rx.c (rx_elf_relocate_section): Likewise.
477 * elf32-s390.c (elf_s390_relocate_section): Likewise.
478 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
479 (_bfd_score_elf_relocate_section): Likewise.
480 * elf32-score.h (s7_bfd_score_elf_relocate_section): Likewise.
481 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
482 * elf32-sh.c (sh_elf_relocate_section): Likewise.
483 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
484 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
485 * elf32-v850.c (v850_elf_relocate_section): Likewise.
486 * elf32-vax.c (elf_vax_relocate_section): Likewise.
487 * elf32-visium.c (visium_elf_relocate_section): Likewise.
488 * elf32-xc16x.c (elf32_xc16x_relocate_section): Likewise.
489 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
490 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
491 * elf32-z80.c (z80_elf_relocate_section): Likewise.
492 * elf64-alpha.c (elf64_alpha_relocate_section_r): Likewise.
493 (elf64_alpha_relocate_section): Likewise.
494 * elf64-bpf.c (bpf_elf_relocate_section): Likewise.
495 * elf64-hppa.c (elf64_hppa_relocate_section): Likewise.
496 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
497 * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
498 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
499 * elf64-s390.c (elf_s390_relocate_section): Likewise.
500 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
501 * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.
502 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
503 * elfnn-riscv.c (riscv_elf_relocate_section): Likewise.
504 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Likewise.
505 * elfxx-mips.h (_bfd_mips_elf_relocate_section): Likewise.
506 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
507 * elfxx-sparc.h (_bfd_sparc_elf_relocate_section): Likewise.
508 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
509 * elfxx-tilegx.h (tilegx_elf_relocate_section): Likewise.
510
ff5b3e14
KS
5112021-03-26 Keith Seitz <keiths@redhat.com>
512
513 * elfcore.h (_bfd_elf_core_find_build_id): Seek file
514 offset of program headers after calling elf_read_notes.
515
f596b03f
JB
5162021-03-23 Jan Beulich <jbeulich@suse.com>
517
518 * dwarf2.c (read_indexed_string): Rename index to idx.
519
08dedd66
ML
5202021-03-22 Martin Liska <mliska@suse.cz>
521
522 * bfd-in.h (startswith): Add startswith function.
523 (CONST_STRNEQ): Remove.
524 * bfd-in2.h (startswith): Regenerate with make headers.
525 * archive.c (bfd_slurp_armap): Replace usage of CONST_STRNEQ with startswith.
526 (_bfd_slurp_extended_name_table): Likewise.
527 * archive64.c (_bfd_archive_64_bit_slurp_armap): Likewise.
528 * bfd.c (bfd_get_sign_extend_vma): Likewise.
529 (bfd_convert_section_size): Likewise.
530 (bfd_convert_section_contents): Likewise.
531 * coff-stgo32.c (go32exe_create_stub): Likewise.
532 (go32exe_check_format): Likewise.
533 * coffcode.h (styp_to_sec_flags): Likewise.
534 (GNU_DEBUGALTLINK): Likewise.
535 * coffgen.c (_bfd_coff_section_already_linked): Likewise.
536 (coff_gc_sweep): Likewise.
537 (bfd_coff_gc_sections): Likewise.
538 * cofflink.c (coff_link_add_symbols): Likewise.
539 (process_embedded_commands): Likewise.
540 * compress.c (bfd_is_section_compressed_with_header): Likewise.
541 (bfd_init_section_decompress_status): Likewise.
542 * dwarf2.c (find_debug_info): Likewise.
543 (place_sections): Likewise.
544 * ecoff.c (_bfd_ecoff_slurp_armap): Likewise.
545 * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
546 * elf.c (_bfd_elf_make_section_from_shdr): Likewise.
547 (assign_section_numbers): Likewise.
548 (elfcore_grok_win32pstatus): Likewise.
549 * elf32-arm.c (cmse_scan): Likewise.
550 (elf32_arm_gc_mark_extra_sections): Likewise.
551 (elf32_arm_size_dynamic_sections): Likewise.
552 (is_arm_elf_unwind_section_name): Likewise.
553 * elf32-bfin.c (bfin_size_dynamic_sections): Likewise.
554 * elf32-cr16.c (_bfd_cr16_elf_size_dynamic_sections): Likewise.
555 * elf32-cris.c (elf_cris_size_dynamic_sections): Likewise.
556 * elf32-csky.c (csky_elf_size_dynamic_sections): Likewise.
557 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
558 * elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
559 * elf32-lm32.c (lm32_elf_size_dynamic_sections): Likewise.
560 * elf32-m32r.c (m32r_elf_size_dynamic_sections): Likewise.
561 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
562 * elf32-metag.c (elf_metag_size_dynamic_sections): Likewise.
563 * elf32-msp430.c (msp430_elf_relax_delete_bytes): Likewise.
564 * elf32-nios2.c (nios2_elf32_size_dynamic_sections): Likewise.
565 * elf32-or1k.c (or1k_elf_size_dynamic_sections): Likewise.
566 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
567 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
568 * elf32-score.c (s3_bfd_score_elf_size_dynamic_sections): Likewise.
569 * elf32-score7.c (s7_bfd_score_elf_size_dynamic_sections): Likewise.
570 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
571 * elf32-tic6x.c (is_tic6x_elf_unwind_section_name): Likewise.
572 (elf32_tic6x_size_dynamic_sections): Likewise.
573 * elf32-vax.c (elf_vax_size_dynamic_sections): Likewise.
574 * elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Likewise.
575 (xtensa_is_insntable_section): Likewise.
576 (xtensa_is_littable_section): Likewise.
577 (xtensa_is_proptable_section): Likewise.
578 (xtensa_property_section_name): Likewise.
579 (xtensa_callback_required_dependence): Likewise.
580 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
581 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
582 * elf64-ia64-vms.c (is_unwind_section_name): Likewise.
583 (get_reloc_section): Likewise.
584 (elf64_ia64_size_dynamic_sections): Likewise.
585 (elf64_ia64_object_p): Likewise.
586 * elf64-mmix.c (mmix_elf_add_symbol_hook): Likewise.
587 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Likewise.
588 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
589 * elflink.c (elf_link_add_object_symbols): Likewise.
590 (_bfd_elf_gc_mark_extra_sections): Likewise.
591 (bfd_elf_parse_eh_frame_entries): Likewise.
592 (_bfd_elf_section_already_linked): Likewise.
593 * elfnn-aarch64.c (elfNN_aarch64_size_dynamic_sections): Likewise.
594 * elfnn-ia64.c (is_unwind_section_name): Likewise.
595 (elfNN_ia64_size_dynamic_sections): Likewise.
596 (elfNN_ia64_object_p): Likewise.
597 * elfxx-mips.c (FN_STUB_P): Likewise.
598 (CALL_STUB_P): Likewise.
599 (CALL_FP_STUB_P): Likewise.
600 (_bfd_mips_elf_section_from_shdr): Likewise.
601 (_bfd_mips_elf_fake_sections): Likewise.
602 (_bfd_mips_elf_size_dynamic_sections): Likewise.
603 (_bfd_mips_final_write_processing): Likewise.
604 (_bfd_mips_elf_final_link): Likewise.
605 * elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): Likewise.
606 * elfxx-x86.c (elf_i386_is_reloc_section): Likewise.
607 (elf_x86_64_is_reloc_section): Likewise.
608 * hpux-core.c (thread_section_p): Likewise.
609 * libcoff.h (bfd_pei_p): Likewise.
610 * linker.c (REAL): Likewise.
611 (unwrap_hash_lookup): Likewise.
612 (_bfd_generic_link_add_one_symbol): Likewise.
613 * mmo.c (mmo_internal_write_section): Likewise.
614 * osf-core.c (osf_core_core_file_p): Likewise.
615 * pef.c (bfd_pef_print_symbol): Likewise.
616 * pei-x86_64.c (pex64_print_all_pdata_sections): Likewise.
617 * som.c (som_slurp_symbol_table): Likewise.
618 (som_slurp_armap): Likewise.
619 * wasm-module.c (wasm_compute_custom_section_file_position): Likewise.
620
2aaf2ce8
JB
6212021-03-22 Jan Beulich <jbeulich@suse.com>
622
623 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Add missing
624 language translation wrapping to _bfd_error_handler()
625 invocations.
626
e9338841
AM
6272021-03-21 Alan Modra <amodra@gmail.com>
628
629 * bfd-in.h (startswith): New inline.
630 (CONST_STRNEQ): Use startswith.
631 * bfd-in2.h: Regenerate.
632
15407e7e
AM
6332021-03-20 Alan Modra <amodra@gmail.com>
634
635 PR 27590
636 * elf.c (_bfd_elf_make_section_from_shdr): Remove SHF_EXCLUDE
637 test for .gnu.debuglto*.
638
3818d4ab
L
6392021-03-18 H.J. Lu <hongjiu.lu@intel.com>
640
641 PR ld/27590
15407e7e 642 * elf.c (_bfd_elf_make_section_from_shdr): Treat
3818d4ab
L
643 .gnu.debuglto_.debug_ section as debugging section unless it is
644 marked with SHF_EXCLUDE.
645 * elflink.c (elf_create_symbuf): Revert commit 994b2513281.
646 (bfd_elf_match_symbols_in_sections): Ignore section symbols when
647 matching non-debugging sections or linkonce section with comdat
648 section.
649
51f6e7a9
L
6502021-03-18 H.J. Lu <hongjiu.lu@intel.com>
651
652 PR ld/27587
653 * dwarf2.c (read_attribute_value): Check version >= 3 for
654 DW_FORM_ref_addr.
655
012d4426
NC
6562021-03-16 Nick Clifton <nickc@redhat.com>
657
658 * peXXigen.c (_bfd_XXi_swap_aux_out): Avoid potential buffer
659 overrun by using sizeof of the destination x_fname field as the
660 limit for a memcpy.
661
80d49d6a
KLC
6622021-03-16 Kuan-Lin Chen <kuanlinchentw@gmail.com>
663
664 * elfxx-riscv.c (riscv_std_z_ext_strtab): Add zba, zbb and zbc.
665
1b2cb8e2
CC
6662021-03-12 Clément Chigot <clement.chigot@atos.net>
667
668 * reloc.c (BFD_RELOC_PPC_TLS_LE, BFD_RELOC_PPC_TLS_IE,
669 BFD_RELOC_PPC_TLS_M, BFD_RELOC_PPC_TLS_ML, BFD_RELOC_PPC64_TLS_GD,
670 BFD_RELOC_PPC64_TLS_LD, BFD_RELOC_PPC64_TLS_LE,
671 BFD_RELOC_PPC64_TLS_IE, BFD_RELOC_PPC64_TLS_M,
672 BFD_RELOC_PPC64_TLS_ML): New relocations.
673 * bfd-in2.h: Regenerate.
674 * libbfd.h: Regenerate.
675 * coff-rs6000.c (xcoff_calculate_relocation): Call
676 xcoff_reloc_type_tls for TLS relocations.
677 (xcoff_howto_table): Implement TLS relocations.
678 (_bfd_xcoff_reloc_type_lookup): Add cases TLS relocations.
679 (xcoff_reloc_type_tls): New function.
680 * coff64-rs6000.c (xcoff_calculate_relocation): Likewise.
681 (xcoff_howto_table): Likewise.
682 (_bfd_xcoff_reloc_type_lookup): Likewise.
683 * coffcode.h (sec_to_styp_flags): Handle TLS sections.
684 (styp_to_sec_flags): Likewise.
685 (coff_compute_section_file_positions): Avoid file offset
686 optimisation for .data when the previous section is .tdata.
687 (coff_write_object_contents): Handle TLS sections.
688 * coffswap.h (coff_swap_aouthdr_out): Add support for
689 new fields in aouthdr.
690 * libxcoff.h (xcoff_reloc_type_tls): Add prototype.
691 * xcofflink.c (xcoff_link_add_symbols): Handle XMC_UL.
692 (xcoff_need_ldrel_p): Add cases for TLS relocations.
693 (xcoff_create_ldrel): Add l_symndx for TLS sections.
694
4a403be0
CC
6952021-03-12 Clément Chigot <clement.chigot@atos.net>
696
697 * reloc.c (BFD_RELOC_PPC_TOC16_HI, BFD_RELOC_PPC_TOC16_LO):
698 New relocations.
699 * bfd-in2.h: Regenerate.
700 * libbfd.h: Regenerate.
701 * coff-rs6000.c (xcoff_calculate_relocation): Call
702 xcoff_reloc_type_toc for R_TOCU and R_TOCL.
703 (xcoff_howto_table): Remove src_mask for TOC relocations.
704 Add R_TOCU and R_TOCL howtos.
705 (_bfd_xcoff_reloc_type_lookup): Add cases for
706 BFD_RELOC_PPC_TOC16_HI and BFD_RELOC_PPC_TOC16_LO.
707 (xcoff_reloc_type_toc): Compute the whole offset.
708 Implement R_TOCU and R_TOCL.
709 * coff64-rs6000.c (xcoff64_calculate_relocation):
710 Likewise.
711 (xcoff64_howto_table): Likewise.
712 (xcoff64_reloc_type_lookup): Likewise.
713
2c1bef53
CC
7142021-03-12 Clément Chigot <clement.chigot@atos.net>
715
716 * coff-rs6000.c (xcoff_calculate_relocation): Correct and
717 add new relocations.
718 (xcoff_howto_table): Likewise.
719 (xcoff_rtype2howto): Increase r_type maximum value.
720 (xcoff_ppc_relocate_section): Reuse predefined HOWTOs instead
721 of create a new one from scratch. Enable only some relocations
722 to have a changing r_size.
723 * coff64-rs6000.c (xcoff64_calculate_relocation): Likewise.
724 (xcoff64_howto_table): Likewise.
725 (xcoff64_rtype2howto): Likewise.
726 (xcoff64_ppc_relocate_section): Likewise.
727 * libxcoff.h (XCOFF_MAX_CALCULATE_RELOCATION): Fix value.
728
0c929e83
CC
7292021-03-12 Clément Chigot <clement.chigot@atos.net>
730
731 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Move.
732
6d4d9328
CC
7332021-03-12 Clément Chigot <clement.chigot@atos.net>
734
735 * coff64-rs6000.c (xcoff64_write_object_contents): Remove.
736 * coffcode.h (coff_write_object_contents): Add bfd_mach_ppc_620
737 support for o_cputype field. Avoid creating an empty a.out header
738 for XCOFF64.
739
8aa2d023
CC
7402021-03-12 Clément Chigot <clement.chigot@atos.net>
741
742 * coff64-rs6000.c (xcoff64_create_csect_from_smclas): Add
743 missing smclass.
744
ebdcad3f
NC
7452021-03-11 Nelson Chu <nelson.chu@sifive.com>
746
747 * elfnn-riscv.c (riscv_elf_link_hash_table): New boolean
748 restart_relax, used to check if we need to run the whole
749 relaxations from relax pass 0 to 2 again.
750 (riscv_elf_link_hash_table_create): Init restart_relax to FALSE.
751 (_bfd_riscv_relax_align): Remove obsolete sec_flg0 set.
752 (_bfd_riscv_relax_delete): Set again to TRUE if we do delete the code.
753 (bfd_elfNN_riscv_restart_relax_sections): New function. Called by
754 after_allocation to check if we need to run the whole relaxations again.
755 (_bfd_riscv_relax_section): We will only enter into the relax pass 3
756 when the restart_relax is FALSE; At last set restart_relax to TRUE if
757 again is TRUE, too.
758 * elfxx-riscv.h (bfd_elf32_riscv_restart_relax_sections): Declaration.
759 (bfd_elf64_riscv_restart_relax_sections): Likewise.
760
67b0f684
JB
7612021-03-10 Jan Beulich <jbeulich@suse.com>
762
763 * cofflink.c (_bfd_coff_write_global_sym): Range-check symbol
764 offset.
765
2dfa8341
AM
7662021-03-10 Alan Modra <amodra@gmail.com>
767 Jan Beulich <jbeulich@suse.com>
768
769 * elf.c (bfd_elf_generic_reloc): Make references between debug
770 sections use section relative values.
771
87fa7d56
JB
7722021-03-09 Jan Beulich <jbeulich@suse.com>
773
774 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Diagnose out of range RVA.
775
8c0546e9
L
7762021-03-05 H.J. Lu <hongjiu.lu@intel.com>
777
778 PR ld/27425
779 PR ld/27432
780 * bfd.c (_bfd_get_link_info): New function.
781 * elf-bfd.h (output_elf_obj_tdata): Add link_info.
782 (elf_link_info): New.
783 * libbfd-in.h (_bfd_get_link_info): New prototype.
784 * coff-x86_64.c (coff_amd64_reloc): Also subtract __ImageBase for
785 R_AMD64_IMAGEBASE when generating x86-64 ELF executable.
786 * pe-x86_64.c: Include "coff/internal.h" and "libcoff.h".
787 (pex64_link_add_symbols): New function.
788 (coff_bfd_link_add_symbols): New macro.
789 * libbfd.h: Regenerated.
790
db6092f3
AB
7912021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
792 Andrew Burgess <andrew.burgess@embecosm.com>
793
794 * elf-bfd.h (elfcore_write_riscv_csr): Declare.
795 * elf.c (elfcore_grok_riscv_csr): New function.
796 (elfcore_grok_note): Handle NT_RISCV_CSR.
797 (elfcore_write_riscv_csr): New function.
798 (elfcore_write_register_note): Handle '.reg-riscv-csr'.
799
0897bb7d
AB
8002021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
801 Andrew Burgess <andrew.burgess@embecosm.com>
802
803 * elfnn-riscv.c (PRPSINFO_PR_FNAME_LENGTH): Define.
804 (PRPSINFO_PR_PSARGS_LENGTH): Define.
805 (riscv_write_core_note): New function.
806 (riscv_elf_grok_psinfo): Make use of two new length defines.
807 (elf_backend_write_core_note): Define.
808
b63a5e38
AB
8092021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
810 Andrew Burgess <andrew.burgess@embecosm.com>
811
812 * elf-bfd.h (elfcore_write_gdb_tdesc): Declare new function.
813 * elf.c (elfcore_grok_gdb_tdesc): New function.
814 (elfcore_grok_note): Handle NT_GDB_TDESC.
815 (elfcore_write_gdb_tdesc): New function.
816 (elfcore_write_register_note): Handle NT_GDB_TDESC.
817
2017f387
NC
8182021-03-05 Nick Clifton <nickc@redhat.com>
819
820 PR 27521
821 * dwarf2.c (is_str_attr): Add DW_FORM_strx* forms.
822 (read_indexed_string): Placeholder function.
823 (read_attribute_value): Handle DW_FORM_strx* and DW_FORM_addrx*
824 forms.
825
b01b5d9a
AM
8262021-03-05 Alan Modra <amodra@gmail.com>
827
828 * reloc.c (bfd_perform_relocation): Revert 2021-01-12 and
829 2020-09-16 changes.
830 * coff-x86_64.c (coff_amd64_reloc): Do more or less the same
831 adjustments here instead. Separate pc-relative adjustments
832 from symbol related adjustments. Tidy comments and formatting.
833
6b5465b9
JB
8342021-03-04 Jan Beulich <jbeulich@suse.com>
835
836 * coffcode.h (sec_to_styp_flags): Don't set IMAGE_SCN_LNK_* in
837 final PE images.
838
0b7733b6
AM
8392021-03-04 Alan Modra <amodra@gmail.com>
840
841 * rs6000-core.c (rs6000coff_core_p): Correct prototype.
842
5789f845
AM
8432021-03-03 Alan Modra <amodra@gmail.com>
844
845 PR 27500
846 * elflink.c (_bfd_elf_gc_mark_rsec): Do special start/stop
847 processing not when start/stop symbol section is unmarked but
848 on first time a start/stop symbol is processed.
849
dc83f2d2
AM
8502021-03-03 Alan Modra <amodra@gmail.com>
851
852 * reloc.c: Include x86_64.h rather than internal.h.
853
ca8f6bc6
NC
8542021-03-02 Nick Clifton <nickc@redhat.com>
855
856 PR 27484
857 * dwarf2.c (scan_unit_for_symbols): Scan twice, once to accumulate
858 function and variable tags and a second time to resolve their
859 attributes.
860
211bcd01
NA
8612021-03-02 Nick Alcock <nick.alcock@oracle.com>
862
863 * elf-strtab.c (_bfd_elf_strtab_str): Skip strings with zero refcount.
864
b80e421f
AM
8652021-03-02 Alan Modra <amodra@gmail.com>
866
867 PR 27451
868 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore synthesized
869 linker defined start/stop symbols when start_stop_gc.
870
f5b9c288
AM
8712021-03-02 Alan Modra <amodra@gmail.com>
872
873 * elf64-ppc.c (ppc64_elf_relocate_section): Don't optimise got
874 indirect to pc-relative or toc-relative for undefined symbols.
875
8ee10e86
AM
8762021-03-01 Alan Modra <amodra@gmail.com>
877 Fangrui Song <maskray@google.com>
878
879 * elflink.c (_bfd_elf_gc_mark_rsec): Ignore synthesized linker
880 defined start/stop symbols when start_stop_gc.
881 (bfd_elf_gc_mark_dynamic_ref_symbol): Likewise.
882 (bfd_elf_define_start_stop): Don't modify ldscript_def syms.
883 * linker.c (bfd_generic_define_start_stop): Likewise.
884
bbaddd4b
AM
8852021-02-25 Alan Modra <amodra@gmail.com>
886
887 PR 27441
888 * elf-bfd.h (struct elf_link_hash_entry): Add ref_ir_nonweak.
889 * elflink.c (elf_link_add_object_symbols): Set ref_ir_nonweak and
890 use when deciding an as-needed library should be loaded instead
891 of using the binding of the library definition.
892
93af1b04
AM
8932021-02-24 Alan Modra <amodra@gmail.com>
894
895 PR 27459
896 * coff-stgo32.c (go32exe_check_format): Sanity check size of
897 header to avoid a buffer overflow.
898
e9d18e06
AM
8992021-02-22 Alan Modra <amodra@gmail.com>
900
901 * coff-rs6000.c (_bfd_xcoff_reloc_type_lookup): Remove BFD_RELOC_16.
902 * coff64-rs6000.c (xcoff64_reloc_type_lookup): Likewise.
903
5a9f5403
NC
9042021-02-19 Nelson Chu <nelson.chu@sifive.com>
905
906 PR 27158
907 * elfnn-riscv.c (perform_relocation): Updated encoding macros.
908 (_bfd_riscv_relax_call): Likewise.
909 (_bfd_riscv_relax_lui): Likewise.
910 * elfxx-riscv.c (howto_table): Likewise.
911
3d73d29e
NC
9122021-02-18 Nelson Chu <nelson.chu@sifive.com>
913
914 * Makefile.am: Added cpu-riscv.h.
915 * Makefile.in: Regenerated.
916 * po/SRC-POTFILES.in: Regenerated.
917 * cpu-riscv.h: Added to support spec versions controlling.
918 Also added extern arrays and functions for cpu-riscv.c.
919 (enum riscv_spec_class): Define all spec classes here uniformly.
920 (struct riscv_spec): Added for all specs.
921 (RISCV_GET_SPEC_CLASS): Added to reduce repeated code.
922 (RISCV_GET_SPEC_NAME): Likewise.
923 (RISCV_GET_ISA_SPEC_CLASS): Added to get ISA spec class.
924 (RISCV_GET_PRIV_SPEC_CLASS): Added to get privileged spec class.
925 (RISCV_GET_PRIV_SPEC_NAME): Added to get privileged spec name.
926 * cpu-riscv.c (struct priv_spec_t): Replaced with struct riscv_spec.
927 (riscv_get_priv_spec_class): Replaced with RISCV_GET_PRIV_SPEC_CLASS.
928 (riscv_get_priv_spec_name): Replaced with RISCV_GET_PRIV_SPEC_NAME.
929 (riscv_priv_specs): Moved below.
930 (riscv_get_priv_spec_class_from_numbers): Likewise, updated.
931 (riscv_isa_specs): Moved from include/opcode/riscv.h.
932 * elfnn-riscv.c: Included cpu-riscv.h.
933 (riscv_merge_attributes): Initialize in_priv_spec and out_priv_spec.
934 * elfxx-riscv.c: Included cpu-riscv.h and opcode/riscv.h.
935 (RISCV_UNKNOWN_VERSION): Moved from include/opcode/riscv.h.
936 * elfxx-riscv.h: Removed extern functions to cpu-riscv.h.
937
b9b204b3
AM
9382021-02-17 Alan Modra <amodra@gmail.com>
939
940 * wasm-module.c: Guard include of limits.h.
941 (CHAR_BIT): Provide backup define.
942 (wasm_read_leb128): Use CHAR_BIT to size "result" in bits.
943 Correct signed overflow checking.
944
0d6aab77
NC
9452021-02-17 Nelson Chu <nelson.chu@sifive.com>
946
947 PR 27200
948 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Delay
949 copying the elf flags from input BFD to output BFD, until we have
950 checked if the input BFD has no code section or not. Also fix the
951 problem that we only check the first section rather than the entire
952 sections for input BFD.
953
7b54cadd
AM
9542021-02-16 Alan Modra <amodra@gmail.com>
955
956 * libbfd.c (_bfd_read_unsigned_leb128): Avoid excessive shift.
957 (_bfd_safe_read_leb128, _bfd_read_signed_leb128): Likewise.
958
8c674061
JB
9592021-02-15 Jan Beulich <jbeulich@suse.com>
960
961 * doc/Makefile.am: Replace "cp -p" by "$(LN_S)".
962 * doc/Makefile.in: Re-generate.
963
1781a9d0
AM
9642021-02-15 Alan Modra <amodra@gmail.com>
965
966 * elf32-nds32.c (nds32_get_section_contents): Replace
967 bfd_malloc_and_get_section with bfd_get_full_section_contents.
968 (nds32_elf_relax_delete_blanks): Init contents.
969 (nds32_elf_relax_section, nds32_relax_fp_as_gp): Likewise.
970
8b78cbec
AM
9712021-02-15 Alan Modra <amodra@gmail.com>
972
973 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
974 bfd_get_full_section_contents.
975
d7a7af8f
AM
9762021-02-14 Alan Modra <amodra@gmail.com>
977
978 * elfxx-mips.c (_bfd_elf_mips_get_relocated_section_contents): Apply
979 all fixes to bfd_generic_get_relocated_section_contents since this
980 function was split out.
981
234b98ce
AM
9822021-02-11 Alan Modra <amodra@gmail.com>
983
984 * config.bfd: Remove ia64 from obsolete list.
985
769c253f
AM
9862021-02-11 Alan Modra <amodra@gmail.com>
987
988 PR ld/22269
989 * elfnn-ia64.c: Revert 2017-10-14 git commit db41f6eb5234.
990
31c711a2
AM
9912021-02-11 Alan Modra <amodra@gmail.com>
992
993 PR 27294
994 * elf32-avr.c (avr_elf32_load_records_from_section): Use
995 bfd_malloc_and_get_section. Use bfd_byte* vars and remove then
996 unnecessary casts.
997
6db658c5
AM
9982021-02-11 Alan Modra <amodra@gmail.com>
999
1000 PR 27291
1001 * section.c (bfd_get_section_contents): Avoid possible overflow
1002 when range checking offset and count.
1003 (bfd_set_section_contents): Likewise.
1004
95148614
NA
10052021-02-03 Nick Alcock <nick.alcock@oracle.com>
1006
1007 * configure.ac (SHARED_LIBADD): Remove explicit -lintl population in
1008 favour of LIBINTL.
1009 * configure: Regenerated.
1010
a57d1773
AM
10112021-02-09 Alan Modra <amodra@gmail.com>
1012
1013 * config.bfd (arm*-*-symbianelf*): Move from obsolete to removed.
1014 * configure.ac: Delete symbian entries.
1015 * elf-bfd.h (enum elf_target_os): Delete is_symbian.
1016 * elf32-arm.c: Remove symbian support. Formatting.
1017 * targets.c: Delete symbian entries.
1018 * configure: Regenerate.
1019
1a2f1b54
L
10202021-02-04 H.J. Lu <hongjiu.lu@intel.com>
1021
1022 PR ld/19609
1023 * elf64-x86-64.c (elf_x86_64_relocate_section): Provide more
1024 info when failed to convert GOTPCREL relocation.
1025
24075dcc
NC
10262021-02-04 Nelson Chu <nelson.chu@sifive.com>
1027
1028 * elfxx-riscv.c (riscv_parse_prefixed_ext): Removed zb*.
1029
7d409ac0
AM
10302021-02-04 Alan Modra <amodra@gmail.com>
1031
1032 PR 27311
1033 * elflink.c (elf_link_add_object_symbols): Don't pull in as-needed
1034 libraries for IR references on pass over libraries after LTO
1035 recompilation.
1036
f01fb44c
AM
10372021-02-03 Alan Modra <amodra@gmail.com>
1038
1039 PR 27311
1040 * elflink.c (_bfd_elf_add_default_symbol): Revert last two changes.
1041 (elf_link_add_object_symbols): Here too. Don't pull in as-needed
1042 libraries when H is an indirect symbol after calling
1043 _bfd_elf_add_default_symbol.
1044
69551367
AM
10452021-02-03 Alan Modra <amodra@gmail.com>
1046
1047 PR 27311
1048 * elflink.c (_bfd_elf_add_default_symbol): Clear override when
1049 undecorated symbol will have a different version.
1050
9918bff7
AM
10512021-02-02 Alan Modra <amodra@gmail.com>
1052
1053 PR 27311
1054 * elflink.c (_bfd_elf_add_default_symbol): Add override parameter.
1055 Use when handling default versioned symbol. Rename existing
1056 override variable to nondef_override and use for non-default
1057 versioned symbol.
1058 (elf_link_add_object_symbols): Adjust call to suit. Don't
1059 pull in as-needed libraries when override is set.
1060
1f568f9a
EH
10612021-02-01 Emery Hemingway <ehmry@posteo.net>
1062
1063 * config.bfd: Add *-*-genode* as a target for AArch64 and x86.
1064
34c10233
EV
10652021-02-01 Egor Vishnyakov <lenvampir@yandex.ru>
1066
1067 PR 27254
1068 * elf32-rl78.c (rl78_elf_relocate_section): Fix calculation of
1069 offset for the R_RL78_RH_SADDR relocation.
1070
c4566785
AM
10712021-01-29 Alan Modra <amodra@gmail.com>
1072
1073 PR 27271
1074 * elflink.c (bfd_elf_link_record_dynamic_symbol): Don't segfault
1075 on symbols defined in absolute or other special sections.
1076
def97fb9
AM
10772021-01-28 Alan Modra <amodra@gmail.com>
1078
1079 PR 27259
1080 * elflink.c (_bfd_elf_gc_mark_extra_sections): Use linker_mark to
1081 prevent endless looping of linked-to sections.
1082
4cb1265b
MS
10832020-12-17 Mihails Strasuns <mihails.strasuns@intel.com>
1084
1085 * bfd-elf.h (elfcore_write_file_note): New function.
1086 * elf.c (elfcore_write_file_note): New function.
1087
4287950e
AM
10882021-01-26 Alan Modra <amodra@gmail.com>
1089
1090 * elf32-ft32.c (ft32_reloc_type_lookup): Don't miss ft32_reloc_map[0].
1091
940d0202
L
10922021-01-24 H.J. Lu <hongjiu.lu@intel.com>
1093
1094 PR binutils/27231
1095 * dwarf2.c (read_rnglists): Ignore empty range when parsing line
1096 number tables.
1097
18454c15
L
10982021-01-23 H.J. Lu <hongjiu.lu@intel.com>
1099
1100 PR binutils/27231
1101 * dwarf2.c (read_rnglists): Advance rngs_ptr after
1102 _bfd_safe_read_leb128 when parsing DW_RLE_offset_pair.
1103
4bd7c902
AM
11042021-01-20 Alan Modra <amodra@gmail.com>
1105
1106 * elf32-ppc.c: Delete outdated comment.
1107 (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): Define.
1108 * elf64-ppc.c (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): Define.
1109
8bd10d6b
AM
11102021-01-20 Alan Modra <amodra@gmail.com>
1111
1112 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't assume
1113 section symbols are present.
1114
30845f11
AM
11152021-01-19 Alan Modra <amodra@gmail.com>
1116
1117 * elf64-ppc.c (elf_hash_entry): New inline function. Use
1118 throughout to replace casts.
1119 (branch_reloc_hash_match): Remove const from params.
1120 (use_local_plt): New function.
1121 (allocate_dynrelocs, ppc_build_one_stub, ppc_size_one_stub),
1122 (build_global_entry_stubs_and_plt, ppc64_elf_relocate_section):
1123 Use use_local_plt.
1124 * elf32-ppc.c (use_local_plt): New function.
1125 (allocate_dynrelocs, ppc_elf_relocate_section),
1126 (write_global_sym_plt): Use use_local_plt.
1127
994b2513
L
11282021-01-17 H.J. Lu <hongjiu.lu@intel.com>
1129
1130 PR ld/27193
1131 * elflink.c (elf_create_symbuf): Also ignore section symbols.
1132
75a933f3
L
11332021-01-16 H.J. Lu <hongjiu.lu@intel.com>
1134
1135 PR ld/23169
1136 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): Don't
1137 check pointer_equality_needed.
1138
68b00778
L
11392021-01-15 H.J. Lu <hongjiu.lu@intel.com>
1140
1141 * elf-linker-x86.h (elf_linker_x86_params): Add
1142 report_relative_reloc.
1143 * elf32-i386.c (elf_i386_relocate_section): Call
1144 _bfd_x86_elf_link_report_relative_reloc to report relative
1145 relocations for -z report-relative-reloc.
1146 (elf_i386_finish_dynamic_symbol): Likewse.
1147 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewse.
1148 (elf_x86_64_finish_dynamic_symbol): Likewse.
1149 * elfxx-x86.c (_bfd_x86_elf_link_report_relative_reloc): New
1150 function.
1151 * elfxx-x86.h (_bfd_x86_elf_link_report_relative_reloc): New
1152 prototype.
1153
ad92f33d
AM
11542021-01-16 Alan Modra <amodra@gmail.com>
1155
1156 * compress.c (decompress_contents): Tidy inflateEnd result test.
1157
eb6e6af8
AM
11582021-01-16 Alan Modra <amodra@gmail.com>
1159
1160 PR 26002
1161 * elflink.c (elf_link_output_extsym): Use version 1 in
1162 .gnu.version for undefined unversioned symbols.
1163
4bb5732e
NC
11642021-01-15 Nelson Chu <nelson.chu@sifive.com>
1165
1166 * elfnn-riscv.c (riscv_relax_delete_bytes): Fixed the indent that
1167 caused the by previous commit accidentally.
1168
1942a048
NC
11692021-01-15 Nelson Chu <nelson.chu@sifive.com>
1170
1171 * elfnn-riscv.c: Indent, labels and GNU coding standards tidy,
1172 also aligned the code.
1173
b800637e
NC
11742021-01-15 Nelson Chu <nelson.chu@sifive.com>
1175
1176 * elfnn-riscv.c (riscv_merge_attributes): Fix typos of messages.
1177
dcd709e0
NC
11782021-01-15 Nelson Chu <nelson.chu@sifive.com>
1179
1180 * elfnn-riscv.c: Comments tidy and improvement.
1181 * elfxx-riscv.c: Likewise.
1182 * elfxx-riscv.h: Likewise.
1183
8ca9c7eb
L
11842021-01-14 H.J. Lu <hongjiu.lu@intel.com>
1185
1186 PR ld/26688
1187 * elf32-bfin.c (bfinfdpic_relocate_section): Skip non SEC_ALLOC
1188 section for R_BFIN_FUNCDESC.
1189
7e0d77ef
NC
11902021-01-14 Nick Clifton <nickc@redhat.com>
1191
1192 * elf.c (elfcore_grok_win32pstatus): Check for a note type of 0.
1193
5347ed60
AM
11942021-01-13 Alan Modra <amodra@gmail.com>
1195
1196 * Makefile.in: Regenerate.
1197 * doc/Makefile.in: Regenerate.
1198
b209b5a6
AM
11992021-01-13 Alan Modra <amodra@gmail.com>
1200
1201 PR 27160
1202 * section.c (struct bfd_section): Remove pattern field.
1203 (BFD_FAKE_SECTION): Adjust to suit.
1204 * bfd-in2.h: Regenerate.
1205 * elflink.c (compare_link_order, elf_fixup_link_order): Delete.
1206 (bfd_elf_final_link): Don't call elf_fixup_link_order.
1207
d546b610
L
12082021-01-12 H.J. Lu <hongjiu.lu@intel.com>
1209
1210 PR binutils/26792
1211 * configure.ac: Use GNU_MAKE_JOBSERVER.
1212 * aclocal.m4: Regenerated.
1213 * configure: Likewise.
1214
c2e9a4a3
L
12152021-01-12 H.J. Lu <hongjiu.lu@intel.com>
1216
1217 PR ld/27171
1218 * reloc.c (bfd_perform_relocation): Adjust R_AMD64_DIR64 and
1219 R_AMD64_DIR32 relocations for PE/x86-64 inputs.
1220
83b33c6c
L
12212021-01-11 H.J. Lu <hongjiu.lu@intel.com>
1222
1223 PR ld/27173
1224 * configure: Regenerated.
1225
a8aa72b9
NC
12262021-01-11 Nick Clifton <nickc@redhat.com>
1227
1228 * po/fr.po: Updated French translation.
1229 * po/pt.po: Updated Portuguese translation.
1230 * po/sr.po: Updated Serbian translation.
1231 * po/uk.po: Updated Ukranian translation.
1232
a4966cd9
L
12332021-01-09 H.J. Lu <hongjiu.lu@intel.com>
1234
1235 * configure: Regenerated.
1236
0a94990b
L
12372021-01-09 H.J. Lu <hongjiu.lu@intel.com>
1238
1239 PR ld/27166
1240 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Handle
1241 -z lam-u48 and -z lam-u57.
1242
573fe3fb
NC
12432021-01-09 Nick Clifton <nickc@redhat.com>
1244
1245 * version.m4: Change to 2.36.50.
1246 * configure: Regenerate.
1247 * po/bfd.pot: Regenerate.
1248
055bc77a
NC
12492021-01-09 Nick Clifton <nickc@redhat.com>
1250
1251 * 2.36 release branch crated.
1252
ba9e922f
L
12532021-01-08 H.J. Lu <hongjiu.lu@intel.com>
1254
1255 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Also set
1256 LAM_U57 when setting LAM_U48.
1257
b1b29aa5
L
12582021-01-08 H.J. Lu <hongjiu.lu@intel.com>
1259
1260 PR ld/26256
1261 PR ld/27160
1262 * elflink.c (elf_fixup_link_order): Verify that fixing up
1263 SHF_LINK_ORDER doesn't increase the output section size.
1264
64307045
AM
12652021-01-09 Alan Modra <amodra@gmail.com>
1266
1267 * configure: Regenerate.
1268
f4782128
ST
12692021-01-07 Samuel Thibault <samuel.thibault@gnu.org>
1270
1271 * configure: Regenerate.
1272
d1bcae83
L
12732021-01-07 H.J. Lu <hongjiu.lu@intel.com>
1274
1275 PR 27109
1276 * aix386-core.c (core_aix386_vec): Initialize
1277 keep_unused_section_symbol to TARGET_KEEP_UNUSED_SECTION_SYMBOLS.
1278 * aout-target.h (MY (vec)): Likewise.
1279 * binary.c (binary_vec): Likewise.
1280 * cisco-core.c (core_cisco_be_vec): Likewise.
1281 (core_cisco_le_vec): Likewise.
1282 * coff-alpha.c (alpha_ecoff_le_vec): Likewise.
1283 * coff-i386.c (TARGET_SYM): Likewise.
1284 (TARGET_SYM_BIG): Likewise.
1285 * coff-ia64.c (TARGET_SYM): Likewise.
1286 * coff-mips.c (mips_ecoff_le_vec): Likewise.
1287 (mips_ecoff_be_vec): Likewise.
1288 (mips_ecoff_bele_vec): Likewise.
1289 * coff-rs6000.c (rs6000_xcoff_vec): Likewise.
1290 (powerpc_xcoff_vec): Likewise.
1291 * coff-sh.c (sh_coff_small_vec): Likewise.
1292 (sh_coff_small_le_vec): Likewise.
1293 * coff-tic30.c (tic30_coff_vec): Likewise.
1294 * coff-tic54x.c (tic54x_coff0_vec): Likewise.
1295 (tic54x_coff0_beh_vec): Likewise.
1296 (tic54x_coff1_vec): Likewise.
1297 (tic54x_coff1_beh_vec): Likewise.
1298 (tic54x_coff2_vec): Likewise.
1299 (tic54x_coff2_beh_vec): Likewise.
1300 * coff-x86_64.c (TARGET_SYM): Likewise.
1301 (TARGET_SYM_BIG): Likewise.
1302 * coff64-rs6000.c (rs6000_xcoff64_vec): Likewise.
1303 (rs6000_xcoff64_aix_vec): Likewise.
1304 * coffcode.h (CREATE_BIG_COFF_TARGET_VEC): Likewise.
1305 (CREATE_BIGHDR_COFF_TARGET_VEC): Likewise.
1306 (CREATE_LITTLE_COFF_TARGET_VEC): Likewise.
1307 * elfxx-target.h (TARGET_BIG_SYM): Likewise.
1308 (TARGET_LITTLE_SYM): Likewise.
1309 * hppabsd-core.c (core_hppabsd_vec): Likewise.
1310 * hpux-core.c (core_hpux_vec): Likewise.
1311 * i386msdos.c (i386_msdos_vec): Likewise.
1312 * ihex.c (ihex_vec): Likewise.
1313 * irix-core.c (core_irix_vec): Likewise.
1314 * mach-o-target.c (TARGET_NAME): Likewise.
1315 * mmo.c (mmix_mmo_vec): Likewise.
1316 * netbsd-core.c (core_netbsd_vec): Likewise.
1317 * osf-core.c (core_osf_vec): Likewise.
1318 * pdp11.c (MY (vec)): Likewise.
1319 * pef.c (pef_vec): Likewise.
1320 (pef_xlib_vec): Likewise.
1321 * plugin.c (plugin_vec): Likewise.
1322 * ppcboot.c (powerpc_boot_vec): Likewise.
1323 * ptrace-core.c (core_ptrace_vec): Likewise.
1324 * sco5-core.c (core_sco5_vec): Likewise.
1325 * som.c (hppa_som_vec): Likewise.
1326 * srec.c (srec_vec): Likewise.
1327 (symbolsrec_vec): Likewise.
1328 * tekhex.c (tekhex_vec): Likewise.
1329 * trad-core.c (core_trad_vec): Likewise.
1330 * verilog.c (verilog_vec): Likewise.
1331 * vms-alpha.c (alpha_vms_vec): Likewise.
1332 * vms-lib.c (alpha_vms_lib_txt_vec): Likewise.
1333 * wasm-module.c (wasm_vec): Likewise.
1334 * xsym.c (sym_vec): Likewise.
1335 * elf.c (ignore_section_sym): Return TRUE if BSF_SECTION_SYM_USED
1336 isn't set.
1337 (elf_map_symbols): Don't include ignored section symbols.
1338 * elfcode.h (elf_slurp_symbol_table): Also set
1339 BSF_SECTION_SYM_USED on STT_SECTION symbols.
1340 * elflink.c (bfd_elf_final_link): Generated section symbols only
1341 when emitting relocations or reqired.
1342 * elfxx-x86.h (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): New.
1343 * syms.c (BSF_SECTION_SYM_USED): New.
1344 * targets.c (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): New.
1345 (bfd_target): Add keep_unused_section_symbols.
1346 (bfd_keep_unused_section_symbols): New.
1347 * bfd-in2.h: Regenerated.
1348
17d60030
NC
13492021-01-07 Nick Clifton <nickc@redhat.com>
1350
1351 PR 25713
1352 * bfdio.c (_bfd_real_fopen): For Win32 convert relative paths to
1353 absolute paths and check to see if they are longer than MAX_PATH.
1354
aa881ecd
PT
13552021-01-07 Philipp Tomsich <prt@gnu.org>
1356
1357 * elfxx-riscv.c (riscv_std_z_ext_strtab): Added zihintpause.
1358
2652cfad
CXW
13592021-01-07 Claire Xenia Wolf <claire@symbioticeda.com>
1360 Jim Wilson <jimw@sifive.com>
1361 Andrew Waterman <andrew@sifive.com>
1362 Maxim Blinov <maxim.blinov@embecosm.com>
1363 Kito Cheng <kito.cheng@sifive.com>
1364 Nelson Chu <nelson.chu@sifive.com>
1365
1366 * elfxx-riscv.c (riscv_std_z_ext_strtab): Added zba, zbb and zbc.
1367
d4e57b87
L
13682021-01-06 H.J. Lu <hongjiu.lu@intel.com>
1369
1370 * elf32-bfin.c (bfin_check_relocs): Check bfd_link_hash_indirect.
1371 (bfinfdpic_check_relocs): Likewise.
1372
599c86c4
AM
13732021-01-06 Alan Modra <amodra@gmail.com>
1374
1375 * elf32-score.c (s3_bfd_score_info_to_howto): Report an error
1376 on unknown r_type.
1377 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1378
3677b729
AM
13792021-01-06 Alan Modra <amodra@gmail.com>
1380
1381 * config.bfd (sparc-*-solaris2*): Add sparc_elf32_vec.
1382 (sparc64-*-solaris2*): Add sparc_elf64_vec and
1383 sparc_elf32_vec.
1384
fbc09e7a
MC
13852021-01-06 Marcus Comstedt <marcus@mc.pp.se>
1386
1387 * config.bfd: Added targets riscv64be*-*-*, riscv32be*-*-* and
1388 riscvbe*-*-*. Also added riscv_elf[32|64]_be_vec.
1389 * configure.ac: Handle riscv_elf[32|64]_be_vec.
1390 * configure: Regenerate.
1391 * elfnn-riscv.c: Include <limits.h> and define CHAR_BIT for
1392 riscv_is_insn_reloc.
1393 (riscv_get_insn): RISC-V instructions are always little endian, but
1394 bfd_get may be used for big-endian, so add new riscv_get_insn to handle
1395 the insturctions.
1396 (riscv_put_insn): Likewsie.
1397 (riscv_is_insn_reloc): Check if we are relocaing an instruction.
1398 (perform_relocation): Call riscv_is_insn_reloc to decide if we should
1399 use riscv_[get|put]_insn or bfd_[get|put].
1400 (riscv_zero_pcrel_hi_reloc): Use riscv_[get|put]_insn, bfd_[get|put]l32
1401 or bfd_[get|put]l16 for code.
1402 (riscv_elf_relocate_section): Likewise.
1403 (riscv_elf_finish_dynamic_symbol): Likewise.
1404 (riscv_elf_finish_dynamic_sections): Likewise.
1405 (_bfd_riscv_relax_call): Likewise.
1406 (_bfd_riscv_relax_lui): Likewise.
1407 (_bfd_riscv_relax_align): Likewise.
1408 (_bfd_riscv_relax_pc): Likewise.
1409 (riscv_elf_object_p): Handled for big endian.
1410 (TARGET_BIG_SYM, TARGET_BIG_NAME): Defined.
1411 * targets.c: Add riscv_elf[32|64]_be_vec.
1412 (_bfd_target_vector): Likewise.
1413
c8bad65e
AM
14142021-01-05 Alan Modra <amodra@gmail.com>
1415
1416 * elflink.c (bfd_elf_link_record_dynamic_symbol): Handle no_export
1417 for relocatable executable.
1418
de6a7ee4
AM
14192021-01-05 Alan Modra <amodra@gmail.com>
1420
1421 * vms-alpha.c (_bfd_vms_slurp_egsd): Read flags after size check.
1422
18b98722
NC
14232021-01-05 Nelson Chu <nelson.chu@sifive.com>
1424
1425 * elfnn-riscv.c (allocate_dynrelocs): When we are generating pde,
1426 make sure gp symbol is output as a dynamic symbol.
1427
cd6d537c
L
14282021-01-04 H.J. Lu <hongjiu.lu@intel.com>
1429
1430 PR ld/26256
1431 * elflink.c (compare_link_order): Place unordered sections before
1432 ordered sections.
1433 (elf_fixup_link_order): Add a link info argument. Allow mixed
1434 ordered and unordered input sections for non-relocatable link.
1435 Sort the consecutive bfd_indirect_link_order sections with the
1436 same pattern. Change the offsets of the bfd_indirect_link_order
1437 sections only.
1438 (bfd_elf_final_link): Pass info to elf_fixup_link_order.
1439 * section.c (bfd_section): Add pattern.
1440 (BFD_FAKE_SECTION): Initialize pattern to NULL.
1441 * bfd-in2.h: Regenerated.
1442
dbb078f6
AF
14432021-01-04 Alexander Fedotov <alfedotov@gmail.com>
1444
1445 * elf32-arm.c (elf32_arm_print_private_bfd_data): Prefix hex value
1446 of private flags with 0x.
1447 * elfnn-aarch64.c (elfNN_aarch64_print_private_bfd_data): Likewise.
1448
5b4293ba
AM
14492021-01-04 Alan Modra <amodra@gmail.com>
1450
1451 PR 26822
1452 * elflink.c (elf_link_input_bfd): Use the file base name in
1453 linker generated STT_FILE symbols.
1454
4c0e540e
NC
14552021-01-04 Nelson Chu <nelson.chu@sifive.com>
1456
1457 * elfxx-riscv.c (riscv_compare_subsets): Removed static.
1458 * elfxx-riscv.h: Add declaration.
1459 * elfnn-riscv.c (riscv_merge_multi_letter_ext): Use
1460 riscv_compare_subsets to check the orders.
1461 (riscv_skip_prefix): Removed.
1462 (riscv_prefix_cmp): Removed.
1463
e9cf3691
AM
14642021-01-04 Alan Modra <amodra@gmail.com>
1465
1466 PR 26741
1467 * elfxx-riscv.c (riscv_parse_prefixed_ext): Free subset after
1468 calculating subset version length.
1469
f9a6a8f0
AM
14702021-01-01 Nicolas Boulenguez <nicolas@debian.org>
1471
1472 * xcofflink.c: Correct spelling in comments.
1473
250d07de
AM
14742021-01-01 Alan Modra <amodra@gmail.com>
1475
1476 Update year range in copyright notice of all files.
1477
c2795844 1478For older changes see ChangeLog-2020
3499769a 1479\f
c2795844 1480Copyright (C) 2021 Free Software Foundation, Inc.
3499769a
AM
1481
1482Copying and distribution of this file, with or without modification,
1483are permitted in any medium without royalty provided the copyright
1484notice and this notice are preserved.
1485
1486Local Variables:
1487mode: change-log
1488left-margin: 8
1489fill-column: 74
1490version-control: never
1491End: