Skip to content

Commit 3d4b363

Browse files
committed
Driver: honour -sdk even on Darwin
If `-resource-dir` is passed, it takes precedence. If the user specifies `-sdk` that should find content in that SDK. Generalise this to Darwin as well.
1 parent f82572a commit 3d4b363

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Driver/ToolChains.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1172,7 +1172,7 @@ void ToolChain::getResourceDirPath(SmallVectorImpl<char> &resourceDirPath,
11721172
if (const Arg *A = args.getLastArg(options::OPT_resource_dir)) {
11731173
StringRef value = A->getValue();
11741174
resourceDirPath.append(value.begin(), value.end());
1175-
} else if (!getTriple().isOSDarwin() && args.hasArg(options::OPT_sdk)) {
1175+
} else if (args.hasArg(options::OPT_sdk)) {
11761176
StringRef value = args.getLastArg(options::OPT_sdk)->getValue();
11771177
resourceDirPath.append(value.begin(), value.end());
11781178
llvm::sys::path::append(resourceDirPath, "usr", "lib",

0 commit comments

Comments
 (0)