Skip to content

Commit

Permalink
Make -depfile work for binary modules output too
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusikkala committed Jan 17, 2025
1 parent 9d99976 commit a1342a3
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions source/slang/slang-compiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2421,6 +2421,13 @@ static SlangResult _writeDependencyFile(EndToEndCompileRequest* compileRequest)
}
}

// When the output is a binary module, linkage->targets can be empty. So
// we need to do their dependencies separately.
if (compileRequest->m_containerFormat == ContainerFormat::SlangModule)
{
_writeDependencyStatement(stream, compileRequest, compileRequest->m_containerOutputPath);
}

return SLANG_OK;
}

Expand Down

0 comments on commit a1342a3

Please sign in to comment.