You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Jose E. Marchesi d218e7fedc DesCGENization of the BPF binutils port 3 years ago
..
emulparams Align linkerscript symbols according to ABI 3 years ago
emultempl PR10957, Missing option to really print section+offset 3 years ago
po Udated Freach and Romainian translations for various sub-directories 3 years ago
scripttempl Support NEXT_SECTION in ALIGNOF and SIZEOF 3 years ago
testsuite DesCGENization of the BPF binutils port 3 years ago
.gitignore bfd/binutils/gas/gprof/ld/libiberty/opcodes: add .gitignore 16 years ago
ChangeLog Change version number to 2.41.50 and regenerate files 3 years ago
ChangeLog-0001 Add copyright notices 14 years ago
ChangeLog-0203 Add copyright notices 14 years ago
ChangeLog-2004 Add copyright notices 14 years ago
ChangeLog-2005 Add copyright notices 14 years ago
ChangeLog-2006 Add copyright notices 14 years ago
ChangeLog-2007 Add copyright notices 14 years ago
ChangeLog-2008 strip off +x bits on non-executable/script files 13 years ago
ChangeLog-2009 Remove trailing spaces in ld 11 years ago
ChangeLog-2010 Add copyright notices 14 years ago
ChangeLog-2011 Add copyright notices 14 years ago
ChangeLog-2012 Rotate binutils ChangeLog for 2013 13 years ago
ChangeLog-2013 New Year - binutils ChangeLog rotation 12 years ago
ChangeLog-2014 ChangeLog rotatation and copyright year update 11 years ago
ChangeLog-2015 binutils ChangeLog rotation 10 years ago
ChangeLog-2016 ChangeLog rotation 9 years ago
ChangeLog-2017 ChangeLog rotation 8 years ago
ChangeLog-2018 ChangeLog rotation 7 years ago
ChangeLog-2019 ChangeLog rotation 6 years ago
ChangeLog-2020 ChangeLog rotation 5 years ago
ChangeLog-9197 Remove trailing spaces in ld 11 years ago
ChangeLog-9899 PR27116, Spelling errors found by Debian style checker 5 years ago
MAINTAINERS Update year range in copyright notice of binutils files 3 years ago
Makefile.am Ignore --prefix-file-map compiler option whist running testsuite. 3 years ago
Makefile.in Ignore --prefix-file-map compiler option whist running testsuite. 3 years ago
NEWS Add markers for the 2.41 branch 3 years ago
README Update year range in copyright notice of binutils files 3 years ago
TODO 19990502 sourceware import 27 years ago
aclocal.m4 binutils, gdb: support zstd compressed debug sections 4 years ago
config.in add --enable-default-compressed-debug-sections-algorithm configure option 4 years ago
configure Change version number to 2.41.50 and regenerate files 3 years ago
configure.ac Update year range in copyright notice of binutils files 3 years ago
configure.host Update year range in copyright notice of binutils files 3 years ago
configure.tgt MIPS: support mips*64 as CPU and gnuabi64 as ABI 3 years ago
deffile.h Update year range in copyright notice of binutils files 3 years ago
deffilep.y bfd+ld: when / whether to generate .c files 3 years ago
dep-in.sed * dep-in.sed: Don't use \n in replacement part of s command. 17 years ago
elf-hints-local.h Remove bfd_stdint.h 5 years ago
fdl.texi etc/ChangeLog 16 years ago
gen-doc.texi Update year range in copyright notice of binutils files 3 years ago
genscrba.sh Automatic makefile dependencies for generated ld/e*.c 7 years ago
genscripts.sh Update year range in copyright notice of binutils files 3 years ago
h8-doc.texi Update year range in copyright notice of binutils files 3 years ago
ld.h ELF: Strip section header in ELF objects 3 years ago
ld.texi Also support '^=' in linker script expressions 3 years ago
ldbuildid.c Update year range in copyright notice of binutils files 3 years ago
ldbuildid.h Update year range in copyright notice of binutils files 3 years ago
ldcref.c PR10957, Missing option to really print section+offset 3 years ago
ldctor.c Update year range in copyright notice of binutils files 3 years ago
ldctor.h Update year range in copyright notice of binutils files 3 years ago
ldelf.c PR30343 infrastructure 3 years ago
ldelf.h Update year range in copyright notice of binutils files 3 years ago
ldelfgen.c Update year range in copyright notice of binutils files 3 years ago
ldelfgen.h Update year range in copyright notice of binutils files 3 years ago
ldemul.c Update year range in copyright notice of binutils files 3 years ago
ldemul.h Update year range in copyright notice of binutils files 3 years ago
ldexp.c Also support '^=' in linker script expressions 3 years ago
ldexp.h Support NEXT_SECTION in ALIGNOF and SIZEOF 3 years ago
ldfile.c ld: fix build with old glibc / gcc 3 years ago
ldfile.h Add --remap-inputs option to the BFD linker. 3 years ago
ldgram.y Also support '^=' in linker script expressions 3 years ago
ldint.texi Update year range in copyright notice of binutils files 3 years ago
ldlang.c PR 30632 - ld segfaults if linker script includes a STARTUP line. 3 years ago
ldlang.h Add --enable-linker-version option to bfd linker to add an entry in the .comment section. 3 years ago
ldlex-wrapper.c Update year range in copyright notice of binutils files 3 years ago
ldlex.h Add --remap-inputs option to the BFD linker. 3 years ago
ldlex.l Also support '^=' in linker script expressions 3 years ago
ldmain.c PR10957, Missing option to really print section+offset 3 years ago
ldmain.h Update year range in copyright notice of binutils files 3 years ago
ldmisc.c Add support for %x and %lx formats to the linker's vinfo() function. 3 years ago
ldmisc.h Update year range in copyright notice of binutils files 3 years ago
ldver.c Update year range in copyright notice of binutils files 3 years ago
ldver.h Update year range in copyright notice of binutils files 3 years ago
ldwrite.c Update year range in copyright notice of binutils files 3 years ago
ldwrite.h Update year range in copyright notice of binutils files 3 years ago
lexsup.c ELF: Strip section header in ELF objects 3 years ago
libdep_plugin.c Update year range in copyright notice of binutils files 3 years ago
mri.c Update year range in copyright notice of binutils files 3 years ago
mri.h Update year range in copyright notice of binutils files 3 years ago
pdb.c ld/PDB: fix off-by-1 in add_globals_ref() 3 years ago
pdb.h ld: Add pdb support to aarch64-w64-mingw32 3 years ago
pe-dll.c PR10957, Missing option to really print section+offset 3 years ago
pe-dll.h Update year range in copyright notice of binutils files 3 years ago
pep-dll-aarch64.c Update year range in copyright notice of binutils files 3 years ago
pep-dll-x86_64.c Update year range in copyright notice of binutils files 3 years ago
pep-dll.c Update year range in copyright notice of binutils files 3 years ago
pep-dll.h Update year range in copyright notice of binutils files 3 years ago
plugin.c Add LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook [GCC PR109128] 3 years ago
plugin.h Update year range in copyright notice of binutils files 3 years ago
sysdep.h Update year range in copyright notice of binutils files 3 years ago
testplug.c Add LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook [GCC PR109128] 3 years ago
testplug2.c Add LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook [GCC PR109128] 3 years ago
testplug3.c Add LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook [GCC PR109128] 3 years ago
testplug4.c Add LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook [GCC PR109128] 3 years ago

README

		README for LD

This is the GNU linker. It is distributed with other "binary
utilities" which should be in ../binutils. See ../binutils/README for
more general notes, including where to send bug reports.

There are many features of the linker:

* The linker uses a Binary File Descriptor library (../bfd)
that it uses to read and write object files. This helps
insulate the linker itself from the format of object files.

* The linker supports a number of different object file
formats. It can even handle multiple formats at once:
Read two input formats and write a third.

* The linker can be configured for cross-linking.

* The linker supports a control language.

* There is a user manual (ld.texi), as well as the
beginnings of an internals manual (ldint.texi).

Installation
============

See ../binutils/README.

If you want to make a cross-linker, you may want to specify
a different search path of -lfoo libraries than the default.
You can do this by setting the LIB_PATH variable in ./Makefile
or using the --with-lib-path configure switch.

To build just the linker, make the target all-ld from the top level
directory (one directory above this one).

Porting to a new target
=======================

See the ldint.texi manual.

Reporting bugs etc
===========================

See ../binutils/README.

Known problems
==============

The Solaris linker normally exports all dynamic symbols from an
executable. The GNU linker does not do this by default. This is
because the GNU linker tries to present the same interface for all
similar targets (in this case, all native ELF targets). This does not
matter for normal programs, but it can make a difference for programs
which try to dlopen an executable, such as PERL or Tcl. You can make
the GNU linker export all dynamic symbols with the -E or
--export-dynamic command line option.

HP/UX 9.01 has a shell bug that causes the linker scripts to be
generated incorrectly. The symptom of this appears to be "fatal error
- scanner input buffer overflow" error messages. There are various
workarounds to this:
* Build and install bash, and build with "make SHELL=bash".
* Update to a version of HP/UX with a working shell (e.g., 9.05).
* Replace "(. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc)" in
genscripts.sh with "sh ${srcdir}..." (no parens) and make sure the
emulparams script used exports any shell variables it sets.

Copyright (C) 2012-2023 Free Software Foundation, Inc.

Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.