Commit Graph

4947 Commits

Author SHA1 Message Date
Claudiu Zissulescu
546c7898dc arc: Update ARC specific linker tests.
All the tests are designed for a little-endian ARC system. Thus,
update the arc predicate in arc.exp, improve the matching pattern for
linker relaxation test, and add linker scripts to nps-1x tests.

Signed-off-by: Claudiu Zissulescu <claziss@synopsys.com>
2023-04-13 11:21:01 +03:00
Nick Clifton
93cda40b4c Fix typos in the linker's documentation of the --enable-non-contiguous-regions option. 2023-04-12 09:54:48 +01:00
Nick Clifton
2d5783fad7 Add --enable-linker-version option to bfd linker to add an entry in the .comment section.
PR 30187
  * NEWS: Mention the new feature. * ld.texi: Document the new feature. * ldgram.y: Handle LINKER_VERSION token. * ldlang.c (lang_add_version): New function. (enable_linker_version): New global variable. * ldlang.h (land_add_version): Prototype. (enable_linker_version): Export. * ldlex.h (OPTION_ENABLE_LINKER_VERSION): Define. (OPTION_DISABLE_LINKER_VERSION): Define. * ldlex.l (LINKER_VERSION): Add token. * lexsup.c (ld_options): Add --enable-linker-version and --disable-linker-version. (parse_args): Handle the new options. * scripttempl/arclinux.sc: Remove stabs and comment sections and replace with inclusion of misc-sections.sc * scripttempl/avr.sc: Likewise. * scripttempl/dlx.sc: Likewise. * scripttempl/elf.sc: Likewise. * scripttempl/elf32cr16.sc: Likewise. * scripttempl/elf32crx.sc: Likewise. * scripttempl/elf32msp430.sc: Likewise. * scripttempl/elf64bpf.sc: Likewise. * scripttempl/elf64hppa.sc: Likewise. * scripttempl/elf_chaos.sc: Likewise. * scripttempl/elfarc.sc: Likewise. * scripttempl/elfarcv2.sc: Likewise. * scripttempl/elfd10v.sc: Likewise. * scripttempl/elfd30v.sc: Likewise. * scripttempl/elfm68hc11.sc: Likewise. * scripttempl/elfm68hc12.sc: Likewise. * scripttempl/elfm9s12z.sc: Likewise. * scripttempl/elfmicroblaze.sc: Likewise. * scripttempl/elfxgate.sc: Likewise. * scripttempl/elfxtensa.sc: Likewise. * scripttempl/epiphany_4x4.sc: Likewise. * scripttempl/ft32.sc: Likewise. * scripttempl/ip2k.sc: Likewise. * scripttempl/iq2000.sc: Likewise. * scripttempl/mep.sc: Likewise. * scripttempl/nds32elf.sc: Likewise. * scripttempl/pru.sc: Likewise. * scripttempl/v850.sc: Likewise. * scripttempl/v850_rh850.sc: Likewise. * scripttempl/visium.sc: Likewise. * scripttempl/xstormy16.sc: Likewise. * scripttempl/z80.sc: Likewise. * testsuite/ld-scripts/script.exp: Run new tests. * scripttempl/misc-sections.sc: New file. * testsuite/ld-scripts/ld-version-2.d: New file. * testsuite/ld-scripts/ld-version.d: New file. * testsuite/ld-scripts/ld-version.t: New file.
2023-03-15 14:27:21 +00:00
Alan Modra
a4d5aec71e Revert ld ASCII support
Revert "Prevent the ASCII linker script directive from generating huge amounts of padding if the size expression is not a constant."
This reverts commit adbe951fc9.

Revert "ld test asciz and ascii fails"
This reverts the ascii.d part of commit 5f497256be.

Revert "Add support for the ASCII directive inside linker scripts."
This mostly reverts commit 9fe129a410
leaving the asciz.d and asciz.t changes in place.
2023-03-10 21:22:16 +10:30
Nick Clifton
adbe951fc9 Prevent the ASCII linker script directive from generating huge amounts of padding if the size expression is not a constant.
PR 30193 * ldgram.y (ASCII): Fail if the size is not a constant.
2023-03-03 13:56:36 +00:00
Fangrui Song
50980ba351 RISC-V: Add --[no-]relax-gp to ld
--relax enables all relaxations.  --no-relax-gp disables GP relaxation to
allow measuring its effect.

The option can test effectiveness of GP relaxation and support some ABI
variants that use GP for other purposes.

Link: https://github.com/riscv-non-isa/riscv-elf-psabi-doc/issues/298

bfd/
    * elfnn-riscv.c (struct riscv_elf_link_hash_table): Add params.
    (riscv_elfNN_set_options): New.
    (riscv_info_to_howto_rela): Check relax_gp.
    (_bfd_riscv_relax_section): Likewise.
    * elfxx-riscv.h (struct riscv_elf_params): New.
    (riscv_elf32_set_options): New.
    (riscv_elf64_set_options): New.
ld/
    * emultempl/riscvelf.em: Add option parsing.
    * testsuite/ld-riscv-elf/code-model-relax-medlow-01-norelaxgp.d: New.
    * testsuite/ld-riscv-elf/pcgp-relax-01-norelaxgp.d: New.
    * testsuite/ld-riscv-elf/pcgp-relax-02.d: Test --relax --relax-gp can be
      used together.
2023-02-23 22:11:14 -08:00
Nick Clifton
c9802aca6d So the linker from producing an export data table when run with --exclude-all-symbols.
PR 30004 * pe-dll.c (pe_dll_build_sections): Do not build an edata section if all symbols are being excluded.
2023-02-20 11:32:52 +00:00
Nick Clifton
9fe129a410 Add support for the ASCII directive inside linker scripts.
* ldlex.l: Add ASCII token.
 * ldgram.y: Add parsing of the ASCII command.
 * ldlang.c (lang_add_string): Add maximum size parameter.  Move escape character handling code into separate function.
 * ldlang.h (lang_add_string): Update prototype.
 * NEWS: Mention the new feature.
 * ld.texi (Output Section Data): Document the new directives.
 * testsuite/ld-scripts/asciz.t: Adjust to work on more architectures and to test more aspects of the ASCIZ directive.
 * testsuite/ld-scripts/asciz.d: Adjust to match the changes to the test linker script.
 * testsuite/ld-scripts/ascii.d: New test driver.
 * testsuite/ld-scripts/ascii.s: New test assembler source.
 * testsuite/ld-scripts/ascii.t: New test script.
 * testsuite/ld-scripts/script.exp: Run the new test.
2023-02-16 16:27:08 +00:00
Nick Clifton
2b56cd9191 Fix the linker's merge4 test for the HPPA architecture.
PR 30078 * testsuite/ld-elf/merge4b.s: Use .asciz instead of .string in order to avoid the special behaviour of the .string directive on HPPA architectures.
2023-02-15 09:26:10 +00:00
Nick Clifton
9b38b85ec3 Mention that the -plugin command line option is used to load plugins. 2023-02-14 12:01:06 +00:00
Nick Clifton
1c66b8a039 Another fix for EFI generation with LTO enabled.
PR 29998 * pe-dll.c (build_filler_bfd): Initialise the next field of the filler input statement, so that it does not break the file chain.
2023-01-27 12:00:35 +00:00
Nick Clifton
f3d8ae90b2 Fix seg-fault when generating an empty DLL with LTO enabled.
ld   PR 29998
     * pe-dll.c (generate_reloc): Handle sections
     with no assigned output section.
     Terminate early of there are no relocs to put
     in the .reloc section.
     (pe_exe_fill_sections): Do not emit an empty
     .reloc section.

bfd  * cofflink.c (_bfd_coff_generic_relocate_section):
     Add an assertion that the output section is set
     for defined, global symbols.
2023-01-24 09:47:43 +00:00
Nick Clifton
59e1f50fef Updated Bulgarian and Russian translations for LD and BFD respectively 2023-01-06 11:00:47 +00:00
Nick Clifton
beb6b61d1e Add an extra emulation called arm64pe to the aarch64pe emulation. 2023-01-05 11:00:35 +00:00
Andreas K. Huettel
b26c8438c7 Un xfail the PR19719 test for the AArch64 architecture 2023-01-05 08:35:18 +00:00
Andreas K. Huettel
502c7218da Fix AArch64 linker testsuite failures trigeered by differences in build environments.
PR 29843
	* testsuite/ld-aarch64/bti-plt-5.d: Relax regxps slightly to allow
	for differences in build environments.
	* testsuite/ld-aarch64/tls-relax-gdesc-le-now.d: Likewise.
2023-01-04 09:30:14 +00:00
Nick Clifton
11982f9f8b Updated translations for various languages and sub-directories 2023-01-03 11:32:42 +00:00
Alan Modra
d87bef3a7b Update year range in copyright notice of binutils files
The newer update-copyright.py fixes file encoding too, removing cr/lf
on binutils/bfdtest2.c and ld/testsuite/ld-cygwin/exe-export.exp, and
embedded cr in binutils/testsuite/binutils-all/ar.exp string match.
2023-01-01 21:50:11 +10:30
Nick Clifton
a72b07181d Add markers for 2.40 branch 2022-12-31 12:05:28 +00:00
Nick Clifton
a7a32d588f Keep the .drectve section when performing a relocateable link.
PR 29900
	* scripttempl/pe.sc: Keep the .drectve section when performing a
	relocateable link.
	* scripttempl/pep.sc: Likewise.
2022-12-21 10:23:08 +00:00
Nick Clifton
dcb53d93eb Update the description of the linker script's TYPE directive.
PR 29861
	* ld.texi (Output Section Type): Note that setting the output
	section type only works if the section contains untyped data.
2022-12-08 13:06:31 +00:00
Nick Clifton
3bf5bf547a Prevent an illegal memory access when comparing the prefix of a section name regexp.
PR 29849
	* ldlang.c (spec_match): Check that there is sufficient length in
	the target name to match the spec's prefix.
2022-12-05 14:57:17 +00:00
Nick Clifton
e26943f9c7 V850 Linker: do not complain about RWX segments.
PR 29748
	* configure.tgt (ac_default_ld_warn_rwx_segments): Set to 0 for
	the V850.
2022-11-03 16:27:31 +00:00
Nick Clifton
78cd9188d0 AVR Linker: Allow the start of the data region to be specified on the linker command line. [Fix PR number in ChangeLog entry]
PR 29741
	* scripttempl/avr.sc (__DATA_REGION_ORIGIN__): Define.  If a value
	has not been provided on the command line then use DATA_ORIGIN.
	(MEMORY): Use __DATA_REGION_ORIGIN__ as the start of the data region.
2022-11-03 09:20:37 +00:00
Nick Clifton
fa6895ad35 AVR Linker: Allow the start of the data region to specified on the command line.
PR 29471
	* scripttempl/avr.sc (__DATA_REGION_ORIGIN__): Define.  If a value
	has not been provided on the command line then use DATA_ORIGIN.
	(MEMORY): Use __DATA_REGION_ORIGIN__ as the start of the data region.
2022-11-03 09:17:41 +00:00
Nick Clifton
4b2e7a577c Add a -w option to the linker to suppress warning and error messages.
PR 29654
	* ld.h (struct ld_config_type): Add no_warnings field.
	* ldlex.h (enum option_values): Add OPTION_NO_WARNINGS.
	* lexsup.c (ld_options): Add --no-warnings.
	(parse_args): Add support for -w and --no-warnings.
	* ldmisc.c (vfinfo): Return early if the message is a warning and
	-w has been enabled.
	* ld.texi (options): Document new command line option.
	* NEWS: Mention the new feature.
2022-10-21 12:20:09 +01:00
Nick Clifton
37833b9665 BFD library: Use entry 0 in directory and filename tables of DWARF-5 debug info.
PR 29529
	* dwarf2.c (struct line_info_table): Add new field:
	use_dir_and_file_0.
	(concat_filename): Use new field to help select the correct table
	slot.
	(read_formatted_entries): Do not skip entry 0.
	(decode_line_info): Set new field depending upon the version of
	DWARF being parsed.  Initialise filename based upon the setting of
	the new field.
2022-08-30 16:01:20 +01:00
Ralf Habacker
f082165361 Missing linking test case for pe dll using a def file.
PR 28362
	* testsuite/ld-pe/pe-run2-def.exp: New file.
2022-08-18 11:58:57 +01:00
Alan Modra
a6ad791442 Fix a conflict between the linker's need to rename some PE format input libraries and the BFD library's file caching mechanism.
PR 29389
bfd	* bfd.c (BFD_CLOSED_BY_CACHE): New bfd flag.
	* cache.c (bfd_cache_delete): Set BFD_CLOSED_BY_DELETE on the
	closed bfd.
	(bfd_cache_lookup_worker): Clear BFD_CLOSED_BY_DELETE on the newly
	reopened bfd.
	* opncls.c (bfd_set_filename): Refuse to change the name of a bfd
	that has been closed by bfd_cache_delete.  Mark changed bfds as
	uncacheable.
	* bfd-in2.h: Regenerate.

ld	* ldlang.h (lang_input_statement_struct): Add sort_key field.
	* emultempl/pe.em (after_open): If multiple import libraries refer
	to the same bfd, store their names in the sort_key field.
	* emultempl/pep.em (after_open): Likewise.
	* ldlang.c (sort_filename): New function.  Returns the filename to
	be used when sorting input files.
	(wild_sort): Use the sort_filename function.
2022-08-03 13:31:57 +01:00
Rainer Orth
b80b72c06c ld: Extend ac_default_ld_warn_rwx_segments to all SPARC targets [PR29411]
As discussed in PR ld/29411, the ld warning

	[...] has a LOAD segment with RWX permissions

needs to be disabled on all SPARC targets, not just Solaris/SPARC: the
.plt section is required to be RWX by the 32-bit SPARC ELF psABI and the
64-bit SPARC Compliance Definition 2.4.1.  Given that ld only supports
SPARC ELF targets, this patch implements this.

Tested on sparc64-unknown-linux-gnu and sparc-sun-solaris2.11.

2022-07-28  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	ld:
	PR ld/29411
	* configure.tgt (ac_default_ld_warn_rwx_segments): Extend to all
	sparc targets.  Expand comment.
2022-07-29 09:06:40 +02:00
Nick Clifton
91896b4d6a Stop the linker from complaining about RWX segments in sparc-solaris targets.
PR 29411
	* configure.tgt (ac_default_ld_warn_rwx_segments): Disable for
	sparc-solaris configurations.
2022-07-26 14:25:33 +01:00
Nick Clifton
0bd0932314 Add markers for 2.39 branch 2022-07-08 10:41:07 +01:00
Nick Clifton
ed1c7ad8e3 Disable execstack and rwx segments warnings for MIPS targets.
PR 29263
	* configure.ac: Move HPPA specific code from here...
	* configure.tgt: ... to here.  Add similar code for MIPS.
	Move code for CRIS, MIPS and HPPA to block at start of file.
	* configure: Regenerate.
2022-06-27 11:39:27 +01:00
Nick Clifton
acd65fa610 Default to disabling the linker warnings about execstack and RWX segments if the target is the HPPA architecture.
PR 29263
	* configure.ac (ac_default_ld_warn_execstack): Default to 'no' for
	HPPA targets.
	(ac_default_ld_warn_rwx_segments): Likewise.
	* configure: Regenerate.
	* testsuite/ld-elf/elf.exp: Add the --warn-execstack command line
	option to the command line when running execstack tests for the
	HPPA target.
2022-06-21 11:22:38 +01:00
Alan Modra
678dc756a5 Fix an illegal memory access when creating DLLs.
PR 29006
	* pe-dll.c (dll_name): Delete, replacing with..
	(dll_filename): ..this, moved earlier in file.
	(generate_edata): Delete parameters.  Don't set up dll_name here..
	(pe_process_import_defs): ..instead set up dll_filename and
	dll_symname here before returning.
	(dll_symname_len): Delete write-only variable.
	(pe_dll_generate_implib): Don't set up dll_symname here.
2022-05-12 12:55:20 +01:00
Nick Clifton
46465574a9 Fix potential arithmetic overflow in the linker's plugin handling code.
PR 29101
	* libdep_plugin.c (get_libdeps): Check for overflow when computing
	amount of memory to allocate.
2022-05-03 11:41:45 +01:00
Nick Clifton
639d467b08 Fix potential buffer overruns when creating DLLs.
PR 29006
	* pe-dll.c (make_head): Use asprintf to allocate and populate a
	buffer containing the temporary name.
	(make_tail, make_one, make_singleton_name_thunk): Likewise.
	(make_import_fixup_mark, make_import_fixup_entry): Likewise.
	(make_runtime_pseudo_reloc): Likewise.
	(pe_create_runtime_relocator_reference): Likewise.
2022-04-27 08:35:18 +01:00
Nick Clifton
0d38576a34 Emit a note warning the user that creating an executable stack because of a missing .note.GNU-stack section is deprecated.
PR 29072
bfd	* elflink.c (bfd_elf_size_dynamic_sections): Display a note to the
	user that the current ehaviour of creating an executable stack
	because of a missing .note.GNU-stack section is deprecated and
	will be changed in a future release.

binutils* testsuite/lib/binutils-common.exp (prune_warnings_extra): Filter
	out notes about the executable stacjk behaviour beign deprecated.

ld	* testsuite/ld-elf/pr29072.b.warn: Update to include the note
	about the linker's behaviour being depreccated.
2022-04-25 12:53:08 +01:00
Cl?ment Chigot
2d23f9656c xcoff: implement linker relaxation
bfd/ChangeLog:

	* coff-rs6000.c (xcoff_reloc_type_noop): Add info argument.
	(xcoff_reloc_type_fail): Likewise.
	(xcoff_reloc_type_pos): Likewise.
	(xcoff_reloc_type_neg): Likewise.
	(xcoff_reloc_type_rel): Likewise.
	(xcoff_reloc_type_toc): Likewise.
	(xcoff_reloc_type_ba): Likewise.
	(xcoff_reloc_type_crel): Likewise.
	(xcoff_reloc_type_tls): Likewise.
	(xcoff_reloc_type_br): Add stub handler.
	(xcoff_ppc_relocate_section): Add info to
	xcoff_calculate_relocation.
	(xcoff_stub_indirect_call_code): New constant.
	(xcoff_stub_shared_call_code): Likewise.
	(bfd_xcoff_backend_data): Add stub code fields.
	(bfd_pmac_xcoff_backend_data): Likewise.
	* coff64-rs6000.c (xcoff64_reloc_type_br): Add stub handler.
	(xcoff64_ppc_relocate_section): Add info to
	xcoff64_calculate_relocation.
	(xcoff64_stub_indirect_call_code): New constant.
	(xcoff64_stub_shared_call_code): Likewise.
	(bfd_xcoff_backend_data): Add stub code fields.
	(bfd_xcoff_aix5_backend_data): Likewise.
	* libxcoff.h (struct xcoff_backend_data_rec): Add stub fields.
	(bfd_xcoff_stub_indirect_call_code): New define.
	(bfd_xcoff_stub_indirect_call_size): New define.
	(bfd_xcoff_stub_shared_call_code): New define.
	(bfd_xcoff_stub_shared_call_size): New define.
	(xcoff_reloc_function): Add info argument.
	(enum xcoff_stub_type): New enum.
	(struct xcoff_stub_hash_entry): New structure.
	* xcofflink.c (struct xcoff_link_hash_table): Add stub hash
	table and params fields.
	(xcoff_stub_hash_entry): New define.
	(xcoff_stub_hash_lookup): New define.
	(stub_hash_newfunc): New function.
	(_bfd_xcoff_bfd_link_hash_table_free): Free the new stub hash
	table.
	(_bfd_xcoff_bfd_link_hash_table_create): Create the new stub
	hash table.
	(xcoff_link_add_symbols): Save rawsize for XTY_SD.
	(bfd_xcoff_link_init): New function.
	(xcoff_stub_csect_name): New function.
	(xcoff_stub_get_csect_in_range): New function.
	(xcoff_stub_name): New function.
	(bfd_xcoff_get_stub_entry): New function.
	(bfd_xcoff_type_of_stub): New function.
	(xcoff_add_stub): New function.
	(xcoff_build_one_stub): New function.
	(bfd_xcoff_size_stubs): New function.
	(bfd_xcoff_build_stubs): New function.
	(xcoff_stub_create_relocations): New function.
	(xcoff_link_input_bfd): Adapt relocations to stub.
	(xcoff_write_global_symbol): Adapt to new TOC entries generated
	for stubs.
	(_bfd_xcoff_bfd_final_link): Handle stub file.
	* xcofflink.h (struct bfd_xcoff_link_params): New structure.

ld/ChangeLog:

	* emultempl/aix.em (params): New variable.
	(stub_file): New variable.
	(xcoff_add_stub_section): New function.
	(xcoff_layout_sections_again): New function
	(hook_in_stub): New function.
	(_after_allocation): Add stub creation.
	(_create_output_section_statements): Allocate stub file and
	pass params to backend.
2022-04-20 15:11:47 +01:00
Cl?ment Chigot
1876a54217 Stubs (added in a later patch) will generate new .loader symbols, once the allocations have been done. Thus, the .loader section cannot be layout before that.
bfd/ChangeLog:

	* coff-rs6000.c (_bfd_xcoff_put_ldsymbol_name): Write len in
	  ldinfo->strings instead of directly in the output_bfd.
	* coff64-rs6000.c (_bfd_xcoff64_put_ldsymbol_name): Likewise.
	* xcofflink.c (struct xcoff_link_hash_table): Remove ldrel_count
	  field. Add ldinfo field.
	(xcoff_mark_symbol): Adjust to new ldinfo field.
	(xcoff_mark): Likewise.
	(bfd_xcoff_link_count_reloc): Likewise.
	(xcoff_build_loader_section): Split into two functions: one that
	build the loader section (this function) and one that only size
	it...
	(xcoff_size_loader_section): ... (this function).
	(bfd_xcoff_size_dynamic_sections): Adapt to new ldinfo field.
	Move the part where the dynamic sections are build to ...
	(bfd_xcoff_build_dynamic_sections): ... this function.
	* xcofflink.h: Add bfd_xcoff_build_dynamic_sections prototype.

include/ChangeLog:

	* coff/xcoff.h (struct xcoff_loader_info): Add ldrel_count and
	libpath fields.

ld/ChangeLog:

	* emultempl/aix.em (_after_allocation): New function.
2022-04-20 15:07:50 +01:00
Mark Harmstone
145667f8d9 Add support for COFF secidx relocations
bfd	* coff-i386.c (in_reloc_p): Add R_SECTION.
	(howto_table): Add R_SECTION.
	(coff_pe_i386_relocation_section): Add support for R_SECTION.
	(coff_i386_reloc_type_lookup): Add support for
	BFD_RELOC_16_SECCIDX.
	* coff-x86_64.c (in_reloc_p): Add R_SECTION.
	(howto_table): Add R_SECTION.
	(coff_pe_amd64_relocation_section): Add support for R_SECTION.
	(coff_amd64_reloc_type_lookup): Add support for
	BFD_RELOC_16_SECCIDX.
	* reloc.c: Add BFD_RELOC_16_SECIDX.
	* bfd-in2.h: Regenerate.
	* libbfd.h: Regenerate.

gas	* config/tc-i386.c (pe_directive_secidx): New function.
	(md_pseudo_table): Add support for secidx.
	(x86_cons_fix_new): Likewise.
	(tc_gen_reloc): Likewise.
	* expr.c (op_rank): Add O_secidx.
	* expr.h (operatorT): Likewise.
	* symbols.c (resolve_symbol_value): Add support for O_secidx.
	* testsuite/gas/i386/secidx.s: New test source file.
	* testsuite/gas/i386/secidx.d: New test driver file.
	* testsuite/gas/i386/i386.exp: Run new test.

include	* coff/i386.h: Define R_SECTION.
	* coff/x86_64.h: Likewise.

ld	* testsuite/ld-pe/secidx1.s: New test source file.
	* testsuite/ld-pe/secidx2.s: New test source file.
	* testsuite/ld-pe/secidx.d: New test driver file.
	* testsuite/ld-pe/secidx_64.d: New test driver file.
	* testsuite/ld-pe/pe.exp: Add new tests.
2022-04-07 14:47:17 +01:00
Nick Clifton
95e96e052a Fix linker tests to compile with gcc-12.
PR 21964
	* testsuite/ld-elf/pr21964-1a.c: Fix array comparisons.
	* testsuite/ld-elf/pr21964-1b.c: Likewise.
	* testsuite/ld-elf/pr21964-1c.c: Likewise.
	* testsuite/ld-elf/pr21964-2a.c: Likewise.
	* testsuite/ld-elf/pr21964-2b.c: Likewise.
	* testsuite/ld-elf/pr21964-3a.c: Likewise.
2022-03-01 10:10:20 +00:00
Roland McGrath
5c14cc552d Fix typo in ld.texi
ld/
	* ld.texi (Output Section Type): Fix typo in @code syntax.
2022-02-18 11:42:09 -08:00
Nick Clifton
36d285b9da Updated Serbian translations for the bfd, gold, ld and opcodes directories 2022-02-17 15:18:59 +00:00
Fangrui Song
c212f39d9a ld: Support customized output section type
bfd/
    PR ld/28841
    * bfd-in2.h (struct bfd_section): Add type.
    (discarded_section): Add field.
    * elf.c (elf_fake_sections): Handle bfd_section::type.
    * section.c (BFD_FAKE_SECTION): Add field.
    * mri.c (mri_draw_tree): Update function call.

ld/
    PR ld/28841
    * ld.texi: Document new output section type.
    * ldlex.l: Add new token TYPE.
    * ldgram.y: Handle TYPE=exp.
    * ldlang.h: Add type_section to list of section types.
    * ldlang.c (lang_add_section): Handle type_section.
    (map_input_to_output_sections): Handle type_section.
    * testsuite/ld-scripts/output-section-types.t: Add tests.
    * testsuite/ld-scripts/output-section-types.d: Update.
2022-02-16 17:41:23 +00:00
Nick Clifton
a698397481 Updated French translation for the ld/ and gold/ sub-directories 2022-02-02 15:05:05 +00:00
Nick Clifton
5fe73d4624 Update Bulgarian, French, Romaniam and Ukranian translation for some of the sub-directories 2022-01-24 14:22:49 +00:00
Alexander von Gluck IV
cc5e40736d Adjust default page sizes for haiku arm.
* configure.tgt (arm-haiku): Fix typo.
	* emulparams/armelf_haiku.su (MAXPAGESIZE): Use the default value.
	(COMMONPAGESIZE): Likewise.
2022-01-22 14:18:34 +00:00
Nick Clifton
f908e960c5 Change version number to 2.38.50 and regenerate files 2022-01-22 12:39:28 +00:00
Nick Clifton
a74e1cb344 Add markers for 2.38 branch 2022-01-22 12:08:55 +00:00