We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b01c71b commit e95aef0Copy full SHA for e95aef0
lld/COFF/Driver.cpp
@@ -786,6 +786,13 @@ void LinkerDriver::addWinSysRootLibSearchPaths() {
786
path))
787
searchPaths.push_back(saver().save(path));
788
}
789
+
790
+ // Libraries specified by `/nodefaultlib:` may not be found in incomplete
791
+ // search paths before lld infers a machine type from input files.
792
+ std::set<std::string> noDefaultLibs;
793
+ for (const std::string &path : ctx.config.noDefaultLibs)
794
+ noDefaultLibs.insert(findLib(path).lower());
795
+ ctx.config.noDefaultLibs = noDefaultLibs;
796
797
798
// Parses LIB environment which contains a list of search paths.
0 commit comments