aboutsummaryrefslogtreecommitdiffstats
path: root/tools/lto
diff options
context:
space:
mode:
Diffstat (limited to 'tools/lto')
-rw-r--r--tools/lto/lto.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/lto/lto.cpp b/tools/lto/lto.cpp
index a64130d..c4face2 100644
--- a/tools/lto/lto.cpp
+++ b/tools/lto/lto.cpp
@@ -386,7 +386,7 @@ LTO::optimizeModules(const std::string &OutputFilename,
// We can't just assemble and link the file with the system assembler
// and linker because we don't know where to put the _start symbol.
// GCC mysteriously knows how to do it.
- const sys::Path gcc = FindExecutable("gcc", "/");
+ const sys::Path gcc = sys::Program::FindProgramByName("gcc");
if (gcc.isEmpty()) {
tmpAsmFilePath.eraseFromDisk();
TempDir.eraseFromDisk(true);