sylveos

Toy Operating System
Log | Files | Refs

commit 07bc985c2b1ed1018f73cde1903622a6a2dbeb98
parent 031266dabb2c016249295510cae533e85d8bc198
Author: Sylvia Ivory <git@sivory.net>
Date:   Tue, 13 Jan 2026 16:22:50 -0800

Fix lab runner building

Diffstat:
M.gitignore | 2+-
MJustfile | 1+
Mbuild.zig | 7+++++--
3 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/.gitignore b/.gitignore @@ -1,3 +1,3 @@ /.zig-cache /zig-out -/src/lab-runner.zig +/src/*.runner.zig diff --git a/Justfile b/Justfile @@ -3,6 +3,7 @@ build: lab name: zig build -Dlab={{ name }} + rm src/*.runner.zig list name="SylveOS": build arm-none-eabi-objdump -m armv6 -d zig-out/bin/{{ name }} diff --git a/build.zig b/build.zig @@ -66,7 +66,10 @@ fn lab(name: []const u8, units: []const []const u8, b: *std.Build) !void { defer b.allocator.free(root_src); // Ensure correct imports - const relative_path = b.path("src/lab-runner.zig"); + const lab_runner_path = try std.fmt.allocPrint(b.allocator, "src/{s}-{s}.runner.zig", .{ name, unit }); + defer b.allocator.free(lab_runner_path); + + const relative_path = b.path(lab_runner_path); const path = try relative_path.getPath3(b, null).toString(b.allocator); defer b.allocator.free(path); @@ -92,5 +95,5 @@ pub fn build(b: *std.Build) !void { try handle_lab(lab_name, b); } - _ = try add_exe("SylveOS", b.path("src/root.zig"), b); + _ = try add_exe(@tagName(config.name), b.path("src/root.zig"), b); }