[lld] r249961 - ELF2: LinkerScript: Handle INPUT as a synonym for GROUP.
Rui Ueyama via llvm-commits
llvm-commits at lists.llvm.org
Sat Oct 10 18:31:57 PDT 2015
Author: ruiu
Date: Sat Oct 10 20:31:57 2015
New Revision: 249961
URL: http://llvm.org/viewvc/llvm-project?rev=249961&view=rev
Log:
ELF2: LinkerScript: Handle INPUT as a synonym for GROUP.
In our name resolution algorithm, --start-group and --end-group have
no special meaning.
Modified:
lld/trunk/ELF/LinkerScript.cpp
lld/trunk/test/elf2/linkerscript.s
Modified: lld/trunk/ELF/LinkerScript.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/LinkerScript.cpp?rev=249961&r1=249960&r2=249961&view=diff
==============================================================================
--- lld/trunk/ELF/LinkerScript.cpp (original)
+++ lld/trunk/ELF/LinkerScript.cpp Sat Oct 10 20:31:57 2015
@@ -55,7 +55,7 @@ void LinkerScript::run() {
StringRef Tok = next();
if (Tok == "ENTRY") {
readEntry();
- } else if (Tok == "GROUP") {
+ } else if (Tok == "GROUP" || Tok == "INPUT") {
readGroup();
} else if (Tok == "INCLUDE") {
readInclude();
Modified: lld/trunk/test/elf2/linkerscript.s
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/elf2/linkerscript.s?rev=249961&r1=249960&r2=249961&view=diff
==============================================================================
--- lld/trunk/test/elf2/linkerscript.s (original)
+++ lld/trunk/test/elf2/linkerscript.s Sat Oct 10 20:31:57 2015
@@ -5,6 +5,10 @@
# RUN: ld.lld2 -o %t2 %t.script
# RUN: llvm-readobj %t2 > /dev/null
+# RUN: echo "INPUT(" %t ")" > %t.script
+# RUN: ld.lld2 -o %t2 %t.script
+# RUN: llvm-readobj %t2 > /dev/null
+
# RUN: echo "GROUP(" %t.script2 ")" > %t.script1
# RUN: echo "GROUP(" %t ")" > %t.script2
# RUN: ld.lld2 -o %t2 %t.script1
More information about the llvm-commits
mailing list