make more build steps integrate with the watch system

This commit is contained in:
Andrew Kelley
2024-07-09 21:08:20 -07:00
parent 956f1ebc70
commit 0cc492a272
10 changed files with 35 additions and 20 deletions

View File

@@ -39,9 +39,7 @@ fn make(step: *Step, prog_node: std.Progress.Node) !void {
_ = prog_node;
const b = step.owner;
const install_file: *InstallFile = @fieldParentPtr("step", step);
// Inputs never change when re-running `make`.
if (!step.inputs.populated()) step.addWatchInput(install_file.source);
try step.singleUnchangingWatchInput(install_file.source);
const full_src_path = install_file.source.getPath2(b, step);
const full_dest_path = b.getInstallPath(install_file.dir, install_file.dest_rel_path);