Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion clang/lib/Driver/ToolChains/UEFI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ using namespace clang;
using namespace llvm::opt;

UEFI::UEFI(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
: ToolChain(D, Triple, Args) {}
: ToolChain(D, Triple, Args) {
getProgramPaths().push_back(getDriver().Dir);
}

Tool *UEFI::buildLinker() const { return new tools::uefi::Linker(*this); }

Expand Down
5 changes: 5 additions & 0 deletions clang/test/Driver/fuse-ld.c
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,8 @@
// RUN: | FileCheck %s --check-prefix CHECK-WINDOWS-MSVC-BFD
// CHECK-WINDOWS-MSVC-BFD: "{{.*}}ld.bfd"
// CHECK-WINDOWS-MSVC-BFD-SAME: "-o"

// RUN: %clang %s -### -fuse-ld=lld \
// RUN: --target=x86_64-unknown-uefi 2>&1 \
// RUN: | FileCheck %s --check-prefix CHECK-UEFI-LLD-LINK
// CHECK-UEFI-LLD-LINK: "{{.*}}lld-link
5 changes: 5 additions & 0 deletions clang/test/Driver/uefi-constructed-args.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,8 @@
// CHECK-SAME: "/entry:EfiMain"
// CHECK-SAME: "/tsaware:no"
// CHECK-SAME: "/debug"

// RUN: %clang -### --target=x86_64-unknown-uefi -print-search-dirs 2>&1 \
// RUN: | FileCheck -check-prefixes=PROGPATH %s
// PROGPATH-DAG: InstalledDir: [[DRIVER_INSTALLED_DIR:.*]]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should remove -DAG: (it's a no-op in this case)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. Done.

// PROGPATH: programs: =[[DRIVER_INSTALLED_DIR]]