diff options
author | Igor Kudrin <ikudrin.dev@gmail.com> | 2015-10-05 10:29:46 +0000 |
---|---|---|
committer | Igor Kudrin <ikudrin.dev@gmail.com> | 2015-10-05 10:29:46 +0000 |
commit | b1f2b51a896e561397aa4ef2620b37ed02c03a58 (patch) | |
tree | 67a956eeee946c230793ce83f92e6fbae68a87cc /lld/ELF/Config.h | |
parent | 9ed154f9213acaa34fd79aa4a274e9162bf3bf77 (diff) | |
download | bcm5719-llvm-b1f2b51a896e561397aa4ef2620b37ed02c03a58.tar.gz bcm5719-llvm-b1f2b51a896e561397aa4ef2620b37ed02c03a58.zip |
[ELF2] Add DT_INIT and DT_FINI dynamic table entries
The entries are added if there are "_init" or "_fini" entries in
the symbol table respectively. According to the behavior of ld,
entries are inserted even for undefined symbols.
Symbol names can be overridden by using -init and -fini command
line switches. If used, these switches neither add new symbol table
entries nor require those symbols to be resolved.
Differential Revision: http://reviews.llvm.org/D13385
llvm-svn: 249297
Diffstat (limited to 'lld/ELF/Config.h')
-rw-r--r-- | lld/ELF/Config.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lld/ELF/Config.h b/lld/ELF/Config.h index e774583de44..d9c3a4b43f8 100644 --- a/lld/ELF/Config.h +++ b/lld/ELF/Config.h @@ -20,6 +20,8 @@ namespace elf2 { struct Configuration { llvm::StringRef DynamicLinker; llvm::StringRef Entry; + llvm::StringRef Fini = "_fini"; + llvm::StringRef Init = "_init"; llvm::StringRef OutputFile = "a.out"; llvm::StringRef SoName; llvm::StringRef Sysroot; |