Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[COFF] Don't let /def override /out filename
Summary: This also delays setting the output filename based on the first input argument until after processing /def. Fixes PR32354 Reviewers: ruiu, pcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D31152 llvm-svn: 298327
- Loading branch information
Showing
3 changed files
with
49 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# REQUIRES: winres | ||
|
||
# RUN: rm -rf %t | ||
# RUN: mkdir -p %t | ||
# RUN: cd %t | ||
# RUN: yaml2obj < %p/Inputs/ret42.yaml > in.obj | ||
|
||
# RUN: lld-link /entry:main in.obj | ||
# RUN: lld-link /entry:main /dll in.obj | ||
|
||
# RUN: echo -e "NAME foo\n" > fooexe.def | ||
# RUN: echo -e "LIBRARY foo\n" > foodll.def | ||
# RUN: lld-link /entry:main /def:fooexe.def in.obj | ||
# RUN: lld-link /entry:main /def:foodll.def /dll in.obj | ||
|
||
# RUN: lld-link /entry:main /out:bar.exe /def:fooexe.def in.obj | ||
# RUN: lld-link /entry:main /out:bar.dll /def:foodll.def /dll in.obj | ||
|
||
# RUN: llvm-readobj in.exe | FileCheck %s | ||
# RUN: llvm-readobj in.dll | FileCheck %s | ||
|
||
# RUN: llvm-readobj foo.exe | FileCheck %s | ||
# RUN: llvm-readobj foo.dll | FileCheck %s | ||
|
||
# RUN: llvm-readobj bar.exe | FileCheck %s | ||
# RUN: llvm-readobj bar.dll | FileCheck %s | ||
|
||
CHECK: File: |