diff --git a/build.zig b/build.zig index b86fd53a..88af7eb7 100644 --- a/build.zig +++ b/build.zig @@ -85,6 +85,15 @@ pub fn build(b: *Build) !void { break :blk mod; }; + // Check compilation + const check = b.step("check", "Check if lightpanda compiles"); + + const check_lib = b.addLibrary(.{ + .name = "lightpanda_check", + .root_module = lightpanda_module, + }); + check.dependOn(&check_lib.step); + { // browser const exe = b.addExecutable(.{ @@ -103,6 +112,12 @@ pub fn build(b: *Build) !void { }); b.installArtifact(exe); + const exe_check = b.addLibrary(.{ + .name = "lightpanda_exe_check", + .root_module = exe.root_module, + }); + check.dependOn(&exe_check.step); + const run_cmd = b.addRunArtifact(exe); if (b.args) |args| { run_cmd.addArgs(args); @@ -132,6 +147,12 @@ pub fn build(b: *Build) !void { }); b.installArtifact(exe); + const exe_check = b.addLibrary(.{ + .name = "snapshot_creator_check", + .root_module = exe.root_module, + }); + check.dependOn(&exe_check.step); + const run_cmd = b.addRunArtifact(exe); if (b.args) |args| { run_cmd.addArgs(args); @@ -170,6 +191,12 @@ pub fn build(b: *Build) !void { }); b.installArtifact(exe); + const exe_check = b.addLibrary(.{ + .name = "legacy_test_check", + .root_module = exe.root_module, + }); + check.dependOn(&exe_check.step); + const run_cmd = b.addRunArtifact(exe); if (b.args) |args| { run_cmd.addArgs(args);