Commit a3986ebf authored by Phillip Stephens's avatar Phillip Stephens

shaderc metal "error" fix

parent c26869eb
...@@ -124,7 +124,7 @@ struct ShaderCompiler<PlatformType::Metal> { ...@@ -124,7 +124,7 @@ struct ShaderCompiler<PlatformType::Metal> {
pid_t pid = fork(); pid_t pid = fork();
if (!pid) { if (!pid) {
execlp("xcrun", "xcrun", "-sdk", "macosx", "metal", NULL); execlp("xcrun", "xcrun", "-sdk", "macosx", "metal", "--version", NULL);
/* xcrun returns 72 if metal command not found; /* xcrun returns 72 if metal command not found;
* emulate that if xcrun not found */ * emulate that if xcrun not found */
exit(72); exit(72);
...@@ -134,7 +134,7 @@ struct ShaderCompiler<PlatformType::Metal> { ...@@ -134,7 +134,7 @@ struct ShaderCompiler<PlatformType::Metal> {
while ((ret = waitpid(pid, &status, 0)) < 0 && errno == EINTR) {} while ((ret = waitpid(pid, &status, 0)) < 0 && errno == EINTR) {}
if (ret < 0) if (ret < 0)
return false; return false;
return WEXITSTATUS(status) == 1; return WEXITSTATUS(status) == 0;
} }
template <typename S> template <typename S>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment