aboutsummaryrefslogtreecommitdiff
path: root/ld/Makefile.in
AgeCommit message (Collapse)AuthorFilesLines
2024-01-04Update year range in copyright notice of binutils filesAlan Modra1-1/+1
Adds two new external authors to etc/update-copyright.py to cover bfd/ax_tls.m4, and adds gprofng to dirs handled automatically, then updates copyright messages as follows: 1) Update cgen/utils.scm emitted copyrights. 2) Run "etc/update-copyright.py --this-year" with an extra external author I haven't committed, 'Kalray SA.', to cover gas testsuite files (which should have their copyright message removed). 3) Build with --enable-maintainer-mode --enable-cgen-maint=yes. 4) Check out */po/*.pot which we don't update frequently.
2023-12-12Support rodata in flash for more AVR devicesGeorg-Johann Lay1-0/+4
PR 31124 * Makefile.am (ALL_EMULATION_SOURCES): Add eavrxmega2_flmap.c and eavrxmega4_flmap.c. * Makefile.in: Regenerate. * configure.tgt: Add eavrxmega2_flmap and eavrxmega4_flmap to avr's targ_extra_emuls list. * emulparams/avrxmega2.sh (MAYBE_FLMAP): Define. * emulparams/avrxmega2_flmap.sh: New file. * emulparams/avrxmega4.sh (MAYBE_FLMAP): Define. * emulparams/avrxmega4_flmap.sh: New file. * scripttempl/avr.sc: Add support for HAVE_FLMAP.
2023-11-15Finalized intl-update patchesArsen Arsenovi?1-0/+11
* intl: Remove directory. Replaced with out-of-tree GNU gettext. * .gitignore: Add '/gettext*'. * configure.ac (host_libs): Replace intl with gettext. (hbaseargs, bbaseargs, baseargs): Split baseargs into {h,b}baseargs. (skip_barg): New flag. Skips appending current flag to bbaseargs. <library exemptions>: Exempt --with-libintl-{type,prefix} from target and build machine argument passing. * configure: Regenerate. * Makefile.def (host_modules): Replace intl module with gettext module. (configure-ld): Depend on configure-gettext. * Makefile.in: Regenerate. * src-release.sh: Remove references to the intl/ directory.
2023-09-25Revert "arc: Add new linker emulation and scripts for ARCv3 ISA."Claudiu Zissulescu1-8/+0
This reverts commit 4deb1ee57fdb711cac6f36fed75b3c8cb5112d99.
2023-09-25arc: Add new linker emulation and scripts for ARCv3 ISA.Claudiu Zissulescu1-0/+8
Add ARCv3's linker bits. Remove obsolete tests. ld/ xxxx-xx-xx Claudiu Zissulescu <claziss@synopsys.com> * ld/Makefile.am: Add ARC64 targets. * ld/configure.tgt: Likewise. * ld/Makefile.in: Regenerate. * ld/emulparams/arc64elf32.sh: New file. * ld/emulparams/arc64elf64.sh: Likewise. * ld/emulparams/arc64linux32.sh: Likewise. * ld/emulparams/arc64linux64.sh: Likewise. * ld/scripttempl/elfarc.sc: Update stack and heap definitions. * ld/testsuite/ld-arc/got-weak.d: Deleted file. * ld/testsuite/ld-arc/got-weak.s: Likewise. Signed-off-by: Claudiu Zissulescu <claziss@synopsys.com>
2023-09-01Fix ld Makefile variable naming: ELF_CLFAGS -> ELF_CFLAGSJerry Zhang Jian1-2/+2
Signed-off-by: Jerry Zhang Jian <jerry.zhangjian@sifive.com>
2023-08-26ld STRINGIFYAlan Modra1-6/+2
Delete support for old compilers that don't support string concatentation. * Makefile.am (stringify.sed): Delete rule. (GEN_DEPENDS, DISTCLEANFILES): Adjust. * configure.ac (STRINGIFY): Delete. * emultempl/beos.em: Use stringify.sed from srcdir. * emultempl/elf.em: Likewise. * emultempl/generic.em: Likewise. * emultempl/msp430.em: Likewise. * emultempl/pdp11.em: Likewise. * emultempl/pe.em: Likewise. * emultempl/pep.em: Likewise. * emultempl/stringify.sed: Renamed from.. * emultempl/astring.sed: ..this. * emultempl/ostring.sed: Delete. * Makefile.in: Regenerate. * configure: Regenerate.
2023-08-26ld .deps/*.Pc filesAlan Modra1-320/+16
This patch gets rid of the individual rules including the .Pc dependency files made while generating e*.c files, replacing them with a fancy GNU make pattern include. I've also moved creation of ldscripts to the makefile since it is possible to run more than one genscripts at once, resulting in "ldscripts: File exists" messages. * Makefile.am: Replace individual include of *.Pc dependency files with one pattern rule. (.Pc): New dummy rule. (ldscripts/stamp): New rule. (GEN_DEPENDS): Add ldscripts/stamp. (install-data-local): Exclude ldscripts/stamp from install. * genscripts.sh: Don't make ldscripts dir. * Makefile.in: Regenerate.
2023-08-25Use GNU make pattern rule in ld MakefileAlan Modra1-11/+2
Use the pattern rule in a comment from commit 77ac17b8453f. * Makefile.am (run-genscripts): Delete. Use pattern rule e%.c instead. * Makefile.in: Regenerate.
2023-08-23kvx: fix 32-bit buildPaul Iannetta1-1/+1
bfd/ * Makefile.am: Move elf32-kvx.lo from BFD32_BACKENDS to BFD64_BACKENDS. Remove elfxx-kvx.lo from BFD32_BACKENDS. Remove elfxx-kvx.c from BFD32_BACKENDS_CFILES. * Makefile.in: Regenerate. * config.bfd: Adjust targ_defvec and targ_selvecs and gate them behind BFD64. * configure.ac: Add target_size=64 to kvx_elf64_*vec. * configure: Regenerate. * elfnn-kvx.c (elfNN_kvx_stub_name): Cast rel->r_addend to uint64_t to match format string. (elfNN_kvx_relocate_section): Similarly for r_offset, and use PRIx64 in format string. * targets.c (_bfd_target_vector <kvx_elf32_vec>): Move inside #ifdef BFD64. ld/ * Makefile.am: Move eelf32kvx.c from ALL_EMULATION_SOURCES to ALL_64_EMULATION_SOURCES. * Makefile.in: Regenerate.
2023-08-17generated bfd files, and kvx regenAlan Modra1-5/+5
The elf32-kvx.c and elf64-kvx.c rules in the bfd makefile are different to the other similar generated files, and that reminded me that we need to have $srcdir in the generated #line reference back to the source for debugging, but don't want it for comments in bfd.pot (because then bfd.pot will likely reference Nick's source tree). This patch fixes that by making all the #line use $srcdir by virtue of using $<, and edits bfd.pot. I also uniq list of files to remove duplicated elfxx-x86.c, sort lists of files and regen with our standard automake/autoconf. * configure: Regenerate. bfd/ * Makefile.am: Sort various lists of files. Use $< in #line directive of generated C files. (po/SRC-POTFILES.in): uniq SRC_POTFILES. (po/BLD-POTFILES.in): uniq BFD_POTFILES. * Makefile.in: Regenerate. * po/Make-in (bfd.pot): Edit out source dir from comments. * po/SRC-POTFILES.in: Regenerate. gas/ * Makefile.in: Regenerate. * configure: Regenerate. * po/POTFILES.in: Regenerate. ld/ * Makefile.am (ALL_64_EMULATION_SOURCES): Sort. * Makefile.in: Regenerate.
2023-08-16kvx: New port.Paul Iannetta1-0/+9
2023-08-09Add ld makefile dependenciesAlan Modra1-2/+4
* Makefile.am (EXTRA_ld_new_SOURCES): Add pep-dll-aarch64.c and pep-dll-x86_64.c. * Makefile.in: Regenerate.
2023-06-29Ignore --prefix-file-map compiler option whist running testsuite.Matthias Klose1-2/+2
2023-05-09regen ld/Makefile.inAlan Modra1-33/+45
2023-04-04bfd+ld: when / whether to generate .c filesJan Beulich1-2/+3
Having been irritated by seeing bfd/elf{32,64}-aarch64.c to be re- generated in x86-only builds, I came across 769a27ade588 ("Re: bfd BLD-POTFILES.in dependencies"). I think this went slightly too far, as outside of maintainer mode dependencies will cause the subset of files to be (re-)generated which are actually needed for the build. Generating them all is only needed when wanting to update certain files under bfd/po/, i.e. in maintainer mode. In the course of looking around in an attempt to try to understand how things are meant to work, I further noticed that ld has got things slightly wrong too: BLD-POTFILES.in depending on $(BLD_POTFILES) isn't quite right (the output doesn't change when any of the enumerated files changes; it's the mere presence which matters); like in bfd it looks like we would better extend BUILT_SOURCES accordingly. Furthermore it became apparent that ld fails to enumerate the .c files generated from the .l and .y ones. While in their absence it was benign whether translatable strings in the source files were actually marked as such, this now becomes relevant. Mark respective strings at the same time, but skipping ones which look to be of interest for debugging purposes only (e.g. such used by printf() enclosed in #ifdef TRACE).
2023-03-16configure: add new target aarch64-*-nto*Clément Chigot1-0/+3
This target has its own ld emulation based on aarch64elf.em.
2023-03-10Revert ld DIGEST supportAlan Modra1-13/+0
This is a hopefully temporary reversion of new ld features for embedded processors by Ulf Samuelsson, plus some followup patches. Squashed together from the following: Revert "lddigest 32-bit support and gcc-4 compile errors" This reverts commit d7ee19be87110a8f5342cec6e323d83d01c641d1. Revert "ld: Use correct types for crc64 calculations" This reverts commit 9a534b9f8e3d0f3cdb5a20f19ff165693fbb84d2. Revert "Re: DIGEST: testsuite" This reverts commit c8e85484d8a0fe9f7b88e00a6b9ae63bcb53ba32. Revert "Regen potfiles" This reverts commit 4d98c966f8bf305ab25badd34cb295631873cf7c. Revert "DIGEST: Makefile.*" This reverts commit 78ef6ab03f56ce83a606d974bb8a9f34b5d6e0b7. Revert "DIGEST: calculation" This reverts commit 5243990191e683d5066d3dd622c76deaba0bf15c. Revert "DIGEST: ldlang.*: add timestamp" This reverts commit bd9466d4aa277a469a9d8b12f0a6e6fa51678e36. Revert "DIGEST: ldmain.c" This reverts commit c8f8653fa7eeb3dc0769ac23039eadb5c5f09dff. Revert "DIGEST: ldgram.y" This reverts commit d73c01be2669e9c5267fab669a269f95a32048c9. Revert "DIGEST: ldlex.l" This reverts commit 48b5163a9dd5759cc87171331bbd6e902c547b5a. Revert "DIGEST: testsuite" This reverts commit a4135d1a4886400ea29af2da782dd8dd40ccad23. Revert "DIGEST: Documentation" This reverts commit 3ec28966c3e4c63704212778f96c517cbf2e0090. Revert "DIGEST: NEWS" This reverts commit 099bf2927d446424e8585a60cf4ce63209999aa2. Revert "DIGEST: LICENSING" This reverts commit 5c8a0c6654fb55926985edf3b360b62d4f20691d.
2023-03-07Build ldintUlf Samuelsson1-6/+47
Signed-off-by: Ulf Samuelsson <ulf@emagii.com>
2023-03-07DIGEST: Makefile.*Ulf Samuelsson1-0/+13
The Makefile.in was generated using automake after adding a few files. When adding the ldreflect.* files, the autotools versions were wrong. After upgrading the host OS, autotools were upgraded to 2.71 reinstalling the desired 2.69 still generates a lot of changes. Makefile.ini has therefore been manually edited. Signed-off-by: Ulf Samuelsson <ulf@emagii.com>
2023-02-06[PR 30082] Pass $JANSSON_LIBS and $ZSTD_LIBS to ld-bootstrap/bootrap.expRomain Geissler1-0/+1
2023-01-05Add an extra emulation called arm64pe to the aarch64pe emulation.Nick Clifton1-0/+3
2023-01-01Update year range in copyright notice of binutils filesAlan Modra1-1/+1
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.
2022-12-23pdb build fixesAlan Modra1-5/+6
Enable compilation of ld/pdb.c just for x86, as is done for bfd/pdb.c. This reduces the size of ld and is necessary with the following patches that call a COFF-only bfd function from ld/pdb.c. Without it we'd break every non-COFF target build.
2022-11-15bfd: linker: merge .sframe sectionsIndu Bhagat1-0/+2
The linker merges all the input .sframe sections. When merging, the linker verifies that all the input .sframe sections have the same abi/arch. The linker uses libsframe library to perform key actions on the .sframe sections - decode, read, and create output data. This implies buildsystem changes to make and install libsframe before libbfd. The linker places the output .sframe section in a new segment of its own: PT_GNU_SFRAME. A new segment is not added, however, if the generated .sframe section is empty. When a section is discarded from the final link, the corresponding entries in the .sframe section for those functions are also deleted. The linker sorts the SFrame FDEs on start address by default and sets the SFRAME_F_FDE_SORTED flag in the .sframe section. This patch also adds support for generation of SFrame unwind information for the .plt* sections on x86_64. SFrame unwind info is generated for IBT enabled PLT, lazy/non-lazy PLT. The existing linker option --no-ld-generated-unwind-info has been adapted to include the control of whether .sframe unwind information will be generated for the linker generated sections like PLT. Changes to the linker script have been made as necessary. ChangeLog: * Makefile.def: Add install dependency on libsframe for libbfd. * Makefile.in: Regenerated. * bfd/Makefile.am: Add elf-sframe.c * bfd/Makefile.in: Regenerated. * bfd/bfd-in2.h (SEC_INFO_TYPE_SFRAME): Regenerated. * bfd/configure: Regenerate. * bfd/configure.ac: Add elf-sframe.lo. * bfd/elf-bfd.h (struct sframe_func_bfdinfo): New struct. (struct sframe_dec_info): Likewise. (struct sframe_enc_info): Likewise. (struct elf_link_hash_table): New member for encoded .sframe object. (struct output_elf_obj_tdata): New member. (elf_sframe): New access macro. (_bfd_elf_set_section_sframe): New declaration. * bfd/elf.c (get_segment_type): Handle new segment PT_GNU_SFRAME. (bfd_section_from_phdr): Likewise. (get_program_header_size): Likewise. (_bfd_elf_map_sections_to_segments): Likewise. * bfd/elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Add contents to the .sframe sections or .plt* entries. * bfd/elflink.c (elf_section_ignore_discarded_relocs): Handle SEC_INFO_TYPE_SFRAME. (_bfd_elf_default_action_discarded): Handle .sframe section. (elf_link_input_bfd): Merge .sframe section. (bfd_elf_final_link): Write the output .sframe section. (bfd_elf_discard_info): Handle discarding .sframe section. * bfd/elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Create .sframe section for .plt and .plt.sec. (_bfd_x86_elf_finish_dynamic_sections): Handle .sframe from .plt* sections. * bfd/elfxx-x86.h (PLT_SFRAME_FDE_START_OFFSET): New definition. (SFRAME_PLT0_MAX_NUM_FRES): Likewise. (SFRAME_PLTN_MAX_NUM_FRES): Likewise. (struct elf_x86_sframe_plt): New structure. (struct elf_x86_link_hash_table): New member. (struct elf_x86_init_table): New members for .sframe creation. * bfd/section.c: Add new definition SEC_INFO_TYPE_SFRAME. * binutils/readelf.c (get_segment_type): Handle new segment PT_GNU_SFRAME. * ld/ld.texi: Update documentation for --no-ld-generated-unwind-info. * ld/scripttempl/elf.sc: Support .sframe sections. * ld/Makefile.am (TESTSFRAMELIB): Use it. (check-DEJAGNU): Likewise. * ld/Makefile.in: Regenerated. * ld/configure.ac (TESTSFRAMELIB): Set to the .so or .a like TESTBFDLIB. * ld/configure: Regenerated. * bfd/elf-sframe.c: New file. include/ChangeLog: * elf/common.h (PT_GNU_SFRAME): New definition. * elf/internal.h (struct elf_segment_map): Handle new segment type PT_GNU_SFRAME. ld/testsuite/ChangeLog: * ld/testsuite/ld-bootstrap/bootstrap.exp: Add SFRAMELIB. * ld/testsuite/ld-aarch64/aarch64-elf.exp: Add new test sframe-simple-1. * ld/testsuite/ld-aarch64/sframe-bar.s: New file. * ld/testsuite/ld-aarch64/sframe-foo.s: Likewise. * ld/testsuite/ld-aarch64/sframe-simple-1.d: Likewise. * ld/testsuite/ld-sframe/sframe-empty.d: New test. * ld/testsuite/ld-sframe/sframe-empty.s: New file. * ld/testsuite/ld-sframe/sframe.exp: New testsuite. * ld/testsuite/ld-x86-64/sframe-bar.s: New file. * ld/testsuite/ld-x86-64/sframe-foo.s: Likewise. * ld/testsuite/ld-x86-64/sframe-simple-1.d: Likewise. * ld/testsuite/ld-x86-64/sframe-plt-1.d: Likewise. * ld/testsuite/ld-x86-64/sframe-simple-1.d: Likewise. * ld/testsuite/ld-x86-64/x86-64.exp: Add new tests - sframe-simple-1, sframe-plt-1. * ld/testsuite/lib/ld-lib.exp: Add new proc to check if assembler supports SFrame section. * ld/testsuite/ld-sframe/discard.d: New file. * ld/testsuite/ld-sframe/discard.ld: Likewise. * ld/testsuite/ld-sframe/discard.s: Likewise.
2022-10-20Re: aarch64-pe support for LD, GAS and BFDAlan Modra1-0/+2
Fix dependencies for eaarch64pe.c. Generated files aren't handled fully automatically.
2022-10-20ld: Add minimal pdb generationMark Harmstone1-5/+8
2022-10-19aarch64-pe support for LD, GAS and BFDJedidiah Thompson1-0/+1
Allows aarch64-pe to be targeted natively, not having to use objcopy to convert it from ELF to PE. Based on initial work by Jedidiah Thompson Co-authored-by: Jedidiah Thompson <wej22007@outlook.com> Co-authored-by: Zac Walker <zac.walker@linaro.org>
2022-09-26binutils, gdb: support zstd compressed debug sectionsFangrui Song1-3/+8
PR29397 PR29563: Add new configure option --with-zstd which defaults to auto. If pkgconfig/libzstd.pc is found, define HAVE_ZSTD and support zstd compressed debug sections for most tools. * bfd: for addr2line, objdump --dwarf, gdb, etc * gas: support --compress-debug-sections=zstd * ld: support ELFCOMPRESS_ZSTD input and --compress-debug-sections=zstd * objcopy: support ELFCOMPRESS_ZSTD input for --decompress-debug-sections and --compress-debug-sections=zstd * gdb: support ELFCOMPRESS_ZSTD input. The bfd change references zstd symbols, so gdb has to link against -lzstd in this patch. If zstd is not supported, ELFCOMPRESS_ZSTD input triggers an error. We can avoid HAVE_ZSTD if binutils-gdb imports zstd/ like zlib/, but this is too heavyweight, so don't do it for now. ``` % ld/ld-new a.o ld/ld-new: a.o: section .debug_abbrev is compressed with zstd, but BFD is not built with zstd support ... % ld/ld-new a.o --compress-debug-sections=zstd ld/ld-new: --compress-debug-sections=zstd: ld is not built with zstd support % binutils/objcopy --compress-debug-sections=zstd a.o b.o binutils/objcopy: --compress-debug-sections=zstd: binutils is not built with zstd support % binutils/objcopy b.o --decompress-debug-sections binutils/objcopy: zstd.o: section .debug_abbrev is compressed with zstd, but BFD is not built with zstd support ... ```
2022-07-08Fix regeneration of ld configure and makefilesNick Clifton1-1260/+412
2022-07-08Update version to 2.39.50 and regenerate filesNick Clifton1-412/+1260
2022-06-27drop XC16x bitsJan Beulich1-9/+0
Commit 04f096fb9e25 ("Move the xc16x target to the obsolete list") moved the architecture from the "obsolete but still available" to the "obsolete / support removed" list in config.bfd, making the architecture impossible to enable (except maybe via "enable everything" options"). Note that I didn't touch */po/*.po{,t} on the assumption that these would be updated by some (half)automatic means.
2022-05-26ld: add --package-metadataLuca Boccassi1-3/+9
Generate a .note.package FDO package metadata ELF note, following the spec: https://systemd.io/ELF_PACKAGE_METADATA/ If the jansson library is available at build time (and it is explicitly enabled), link ld to it, and use it to validate that the input is correct JSON, to avoid writing garbage to the file. The configure option --enable-jansson has to be used to explicitly enable it (error out when not found). This allows bootstrappers (or others who are not interested) to seamlessly skip it without issues.
2022-03-24x86: drop L1OM/K1OM support from ldJan Beulich1-12/+0
This was only rudimentary support anyway; none of the sub-architecture specific insns were ever supported.
2022-01-23Regenerate Makefile.in files with automake 1.15.1H.J. Lu1-1/+0
Regenerate Makefile.in files with the unmodified automake 1.15.1 to remove runstatedir = @runstatedir@ bfd/ * Makefile.in: Regenerate. binutils/ * Makefile.in: Regenerate. gas/ * Makefile.in: Regenerate. gold/ * Makefile.in: Regenerate. * testsuite/Makefile.in: Likewise. gprof/ * Makefile.in: Regenerate. ld/ * Makefile.in: Regenerate. opcodes/ * Makefile.in: Regenerate.
2022-01-17Update the config.guess and config.sub files from the master repository and ↵Nick Clifton1-0/+1
regenerate files.
2022-01-02Update year range in copyright notice of binutils filesAlan Modra1-1/+1
The result of running etc/update-copyright.py --this-year, fixing all the files whose mode is changed by the script, plus a build with --enable-maintainer-mode --enable-cgen-maint=yes, then checking out */po/*.pot which we don't update frequently. The copy of cgen was with commit d1dd5fcc38ead reverted as that commit breaks building of bfp opcodes files.
2022-01-01unify 64-bit bfd checksMike Frysinger1-0/+1
Move the 64-bit bfd logic out of bfd/configure.ac and into bfd64.m4 under config so it can be shared between all the other subdirs. This replaces want64 with enable_64_bit_bfd which was already being declared, but not used directly.
2021-11-29ld: enable silent build rulesMike Frysinger1-31/+31
Also add $(AM_V_xxx) to various manual rules in here.
2021-11-15Regenerate a couple of filesAlan Modra1-2/+3
A couple of files changed on my latest --enable-maintainer-mode build. ld/Makefile.in had a missing dependency but better sorting of the loongson entries. intl/ * configure: Regenerate. ld/ * Makefile.am: Sort loongson entries. * Makefile.in: Regenerate.
2021-10-24LoongArch ld supportliuzhensong1-0/+5
2021-10-22 Chenghua Xu <xuchenghua@loongson.cn> Zhensong Liu <liuzhensong@loongson.cn> Weinan Liu <liuweinan@loongson.cn> Xiaolin Tang <tangxiaolin@loongson.cn> ld/ * Makefile.am: Add LoongArch. * NEWS: Mention LoongArch support. * configure.tgt: Add LoongArch. * emulparams/elf32loongarch-defs.sh: New. * emulparams/elf32loongarch.sh: Likewise. * emulparams/elf64loongarch-defs.sh: Likewise. * emulparams/elf64loongarch.sh: Likewise. * emultempl/loongarchelf.em: Likewise. * Makefile.in: Regenerate. * po/BLD-POTFILES.in: Regenerate. ld/testsuite/ * ld-loongarch-elf/disas-jirl.d: New. * ld-loongarch-elf/disas-jirl.s: Likewise. * ld-loongarch-elf/jmp_op.d: Likewise. * ld-loongarch-elf/jmp_op.s: Likewise. * ld-loongarch-elf/ld-loongarch-elf.exp: Likewise. * ld-loongarch-elf/macro_op.d: Likewise. * ld-loongarch-elf/macro_op.s: Likewise. * ld-loongarch-elf/syscall-0.s: Likewise. * ld-loongarch-elf/syscall-1.s: Likewise. * ld-loongarch-elf/syscall.d: Likewise. * ld-srec/srec.exp: Add LoongArch. * ld-unique/pr21529.d: Likewise.
2021-09-20Move eelf_mipsel_haiki.c to ALL_64_EMULATION_SOURCESAlan Modra1-59/+66
--enable-targets=all on a 32-bit host results in a link failure with undefined references due to elfxx-mips.c not being compiled. This patch fixes that by putting eelf_mipsel_haiki.c in the correct EMULATION_SOURCES Makefile variable. I've also added a bunch of missing file dependencies and sorted a few things so that it's easier to verify dependencies are present. * Makfile.am: Add missing haiku dependencies, sort. (ALL_EMULATION_SOURCES): Sort. Move eelf_mipsel_haiku.c to.. (ALL_64_EMULATION_SOURCES): ..here. Sort. * Makfile.in: Regenerate.
2021-09-03ld testsuite tidyAlan Modra1-2/+2
Fixes a few issues: 1) If you use "-fsanitize=address,undefined" in CFLAGS, the Makefile attempt to trim off -fsanitize options left us with ",undefined". 2) ld_compile adds CFLAGS_FOR_TARGET itself, no need to pass it. 3) CFLAGS might be needed linking bootstrap test. * Makefile.am (CFLAGS_FOR_TARGET, CXXFLAGS_FOR_TARGET): Trim off all -fsanitize=*. * Makefile.in: Regenerate. * testsuite/ld-bootstrap/bootstrap.exp: Use CFLAGS when linking. * testsuite/ld-cdtest/cdtest.exp: Use CFLAGS_FOR_TARGET when linking. * testsuite/ld-auto-import/auto-import.exp: Don't pass CFLAGS_FOR_TARGET to ld_compile. * testsuite/ld-cygwin/exe-export.exp: Likewise. * testsuite/ld-elfvers/vers.exp: Likewise. * testsuite/ld-elfvsb/elfvsb.exp: Likewise. * testsuite/ld-elfweak/elfweak.exp: Likewise. * testsuite/ld-gc/gc.exp: Likewise. * testsuite/ld-pe/pe-compile.exp: Likewise. * testsuite/ld-pe/pe-run.exp: Likewise. * testsuite/ld-pe/pe-run2.exp: Likewise. * testsuite/ld-plugin/plugin.exp: Likewise. * testsuite/ld-shared/shared.exp: Likewise. * testsuite/ld-elfcomm/elfcomm.exp: Likewise, and don't allow nios2 testing to trash CFLAGS_FOR_TARGET. * testsuite/ld-scripts/crossref.exp: Don't pass options in CC_FOR_TARGET, do so in CFLAGS_FOR_TARGET instead. * testsuite/ld-srec/srec.exp: Likewise, and for CXX.
2021-09-03CC_FOR_TARGET et alAlan Modra1-3/+6
The top level Makefile, the ld Makefile and others, define CC_FOR_TARGET to be a compiler for the binutils target machine. This is the compiler that should be used for almost all tests with C source. There are _FOR_TARGET versions of CFLAGS, CXX, and CXXFLAGS too. This was all supposed to work with the testsuite .exp files using CC for the target compiler, and CC_FOR_HOST for the host compiler, with the makefiles passing CC=$CC_FOR_TARGET and CC_FOR_HOST=$CC to the runtest invocation. One exception to the rule of using CC_FOR_TARGET is the native-only ld bootstrap test, which uses the newly built ld to link a copy of itself. Since the files being linked were created with the host compiler, the boostrap test should use CC and CFLAGS, in case some host compiler option provides needed libraries automatically. However, bootstrap.exp used CC where it should have used CC_FOR_HOST. I set about fixing that problem, then decided that playing games in the makefiles with CC was a bad idea. Not only is it confusing, but other dejagnu code knows about CC_FOR_TARGET. See dejagnu/target.exp. So this patch gets rid of the makefile variable renaming and changes all the .exp files to use the correct _FOR_TARGET variables. CC_FOR_HOST and CFLAGS_FOR_HOST disappear. A followup patch will correct bootstrap.exp to use CFLAGS, and a number of other things I noticed. binutils/ * testsuite/lib/binutils-common.exp (run_dump_test): Use CC_FOR_TARGET and CFLAGS_FOR_TARGET rather than CC and CFLAGS. ld/ * Makefile.am (check-DEJAGNU): Don't set CC to CC_FOR_TARGET and similar. Pass variables with unchanged names. Don't set CC_FOR_HOST or CFLAGS_FOR_HOST. * Makefile.in: Regenerate. * testsuite/config/default.exp: Update default CC and similar. (compiler_supports, plug_opt): Use CC_FOR_TARGET. * testsuite/ld-cdtest/cdtest.exp: Replace all uses of CC with CC_FOR_TARGET, and similarly for CFLAGS, CXX and CXXFLAGS. * testsuite/ld-auto-import/auto-import.exp: Likewise. * testsuite/ld-cygwin/exe-export.exp: Likewise. * testsuite/ld-elf/dwarf.exp: Likewise. * testsuite/ld-elf/indirect.exp: Likewise. * testsuite/ld-elf/shared.exp: Likewise. * testsuite/ld-elfcomm/elfcomm.exp: Likewise. * testsuite/ld-elfvers/vers.exp: Likewise. * testsuite/ld-elfvsb/elfvsb.exp: Likewise. * testsuite/ld-elfweak/elfweak.exp: Likewise. * testsuite/ld-gc/gc.exp: Likewise. * testsuite/ld-ifunc/ifunc.exp: Likewise. * testsuite/ld-mn10300/mn10300.exp: Likewise. * testsuite/ld-pe/pe-compile.exp: Likewise. * testsuite/ld-pe/pe-run.exp: Likewise. * testsuite/ld-pe/pe-run2.exp: Likewise. * testsuite/ld-pie/pie.exp: Likewise. * testsuite/ld-plugin/lto.exp: Likewise. * testsuite/ld-plugin/plugin.exp: Likewise. * testsuite/ld-scripts/crossref.exp: Likewise. * testsuite/ld-selective/selective.exp: Likewise. * testsuite/ld-sh/sh.exp: Likewise. * testsuite/ld-shared/shared.exp: Likewise. * testsuite/ld-srec/srec.exp: Likewise. * testsuite/ld-undefined/undefined.exp: Likewise. * testsuite/ld-unique/unique.exp: Likewise. * testsuite/ld-x86-64/tls.exp: Likewise. * testsuite/lib/ld-lib.exp: Likewise. libctf/ * Makefile.am (check-DEJAGNU): Don't set CC to CC_FOR_TARGET. Pass CC and CC_FOR_TARGET. Don't set CC_FOR_HOST. * Makefile.in: Regenerate. * testsuite/config/default.exp: Update default CC and similar. * testsuite/lib/ctf-lib.exp (run_native_host_cmd): Use CC rather than CC_FOR_HOST. (run_lookup_test): Use CC_FOR_TARGET and CFLAGS_FOR_TARGET.
2021-09-03haiku tidyAlan Modra1-3/+3
--enable-maintainer-mode showed a number of files needing to be regenerated, and in the case of ld/Makefile.in that the file was regenerated by hand. Nothing to see here really. ld/ * Makefile.am (ALL_64_EMULATION_SOURCES): Sort haiku entry. * Makefile.in: Regenerate. * po/BLD-POTFILES.in: Regenerate. libctf/ * configure: Regenerate. zlib/ * configure: Regenerate.
2021-09-02Add support for the haiku operating system. These are the os support ↵Alexander von Gluck IV1-0/+12
patches we have been grooming and maintaining for quite a few years over on git.haiku-os.org. All of these architectures are working and most have been stable for quite some time.
2021-05-11Prevent libdel.dll.a from being installed on Windows based systems.Nick Clifton1-0/+1
PR 27113 * Makefile.am (install-data-local): Also delete libdep.dll.a if it is present. * Makefile.in: Regenerate.
2021-05-08support generating multi-html pages in parallelMike Frysinger1-7/+13
Use the pattern from other projects where we generate the html pages in a dir named the same as the project. So now we have: gas/doc/gas.html - single html page gas/doc/gas/ - multiple html pages This works for projects that have a doc/ subdir already, but gprof & ld require a little tweaking since they generate their docs in their respective toplevels.
2021-05-08generate single html manual page by defaultMike Frysinger1-1/+1
This better matches other GNU projects like autoconf/automake where the html manual is the single page form. We'll support the multi-page form in a follow up change.
2021-03-12riscv --enable-targets=all on 32-bit hostAlan Modra1-6/+6
Attempting to build --enable-targets=all on a 32-bit host results in a number of errors like the following. eelf32lriscv.o: in function `gldelf32lriscv_after_allocation': eelf32lriscv.c:98: undefined reference to `bfd_elf32_riscv_restart_relax_sections' That's due to needing --enable-64-bit-bfd to get the riscv BFD support built. * Makefile.am (ALL_EMULATION_SOURCES): Move riscv files to.. (ALL_64_EMULATION_SOURCES): ..here. * Makefile.in: Regenerate.