mirror of
https://codeberg.org/ziglings/exercises.git
synced 2025-09-20 22:55:38 +00:00
pass -freference-trace to executed compile command
Currently users executing `zig build` to run the exercises, may encounter compiler output that tells them to use `-freference-trace=[num]` to see more of the hidden reference traces, so we should pass this parameter to the zigling exercise being compiled, so that the learner can provide this parameter like they would normally, when using `zig build` directly in normal Zig programs.
This commit is contained in:
parent
1407c7fb91
commit
02db832677
|
@ -508,6 +508,10 @@ const ZiglingStep = struct {
|
||||||
zig_args.append("-lc") catch @panic("OOM");
|
zig_args.append("-lc") catch @panic("OOM");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (b.reference_trace) |rt| {
|
||||||
|
zig_args.append(b.fmt("-freference-trace={}", .{rt})) catch @panic("OOM");
|
||||||
|
}
|
||||||
|
|
||||||
zig_args.append(b.pathFromRoot(path)) catch @panic("OOM");
|
zig_args.append(b.pathFromRoot(path)) catch @panic("OOM");
|
||||||
|
|
||||||
zig_args.append("--cache-dir") catch @panic("OOM");
|
zig_args.append("--cache-dir") catch @panic("OOM");
|
||||||
|
|
Loading…
Reference in New Issue
Block a user