[lld] r271367 - Handle the -T option.

Rafael Espindola via llvm-commits llvm-commits at lists.llvm.org
Tue May 31 23:17:27 PDT 2016


Author: rafael
Date: Wed Jun  1 01:17:27 2016
New Revision: 271367

URL: http://llvm.org/viewvc/llvm-project?rev=271367&view=rev
Log:
Handle the -T option.

We were not reading it or including in the --reproduce archive.

Modified:
    lld/trunk/ELF/Driver.cpp
    lld/trunk/ELF/DriverUtils.cpp
    lld/trunk/test/ELF/reproduce.s

Modified: lld/trunk/ELF/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Driver.cpp?rev=271367&r1=271366&r2=271367&view=diff
==============================================================================
--- lld/trunk/ELF/Driver.cpp (original)
+++ lld/trunk/ELF/Driver.cpp Wed Jun  1 01:17:27 2016
@@ -422,6 +422,7 @@ void LinkerDriver::createFiles(opt::Inpu
     case OPT_l:
       addLibrary(Arg->getValue());
       break;
+    case OPT_alias_script_T:
     case OPT_INPUT:
     case OPT_script:
       addFile(Arg->getValue());

Modified: lld/trunk/ELF/DriverUtils.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/DriverUtils.cpp?rev=271367&r1=271366&r2=271367&view=diff
==============================================================================
--- lld/trunk/ELF/DriverUtils.cpp (original)
+++ lld/trunk/ELF/DriverUtils.cpp Wed Jun  1 01:17:27 2016
@@ -217,6 +217,7 @@ std::string elf::createResponseFile(cons
     case OPT_L:
     case OPT_dynamic_list:
     case OPT_rpath:
+    case OPT_alias_script_T:
     case OPT_script:
     case OPT_version_script:
       OS << Arg->getSpelling() << " "

Modified: lld/trunk/test/ELF/reproduce.s
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/ELF/reproduce.s?rev=271367&r1=271366&r2=271367&view=diff
==============================================================================
--- lld/trunk/test/ELF/reproduce.s (original)
+++ lld/trunk/test/ELF/reproduce.s Wed Jun  1 01:17:27 2016
@@ -29,8 +29,9 @@
 # RUN: echo "{ local: *; };" >  ver
 # RUN: echo > dyn
 # RUN: echo > file
+# RUN: echo > file2
 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o 'foo bar'
-# RUN: ld.lld --reproduce repro2 'foo bar' -L"foo bar" -Lfile \
+# RUN: ld.lld --reproduce repro2 'foo bar' -L"foo bar" -Lfile -Tfile2 \
 # RUN:   --dynamic-list dyn -rpath file --script file --version-script ver \
 # RUN:   --dynamic-linker "some unusual/path" -soname 'foo bar' -soname='foo bar'
 # RUN: cpio -id < repro2.cpio
@@ -38,6 +39,7 @@
 # RSP2:      "{{.*}}foo bar"
 # RSP2-NEXT: -L "{{.*}}foo bar"
 # RSP2-NEXT: -L {{.+}}file
+# RSP2-NEXT: --script {{.+}}file2
 # RSP2-NEXT: --dynamic-list {{.+}}dyn
 # RSP2-NEXT: -rpath {{.+}}file
 # RSP2-NEXT: --script {{.+}}file




More information about the llvm-commits mailing list