diff --git a/build.zig b/build.zig index 387aa7b..a600bb8 100644 --- a/build.zig +++ b/build.zig @@ -13,7 +13,6 @@ pub fn build(b: *std.Build) void { .name = "zig_squashfs", .root_module = lib_mod, }); - b.installArtifact(lib); const exe_mod = b.createModule(.{ .root_source_file = b.path("src/main.zig"), .target = target, @@ -21,14 +20,20 @@ pub fn build(b: *std.Build) void { }); const exe = b.addExecutable(.{ .linkage = .static, - .name = "unsquashfs", + .name = "zig-unsquashfs", .root_module = exe_mod, }); + b.installArtifact(lib); b.installArtifact(exe); const lib_unit_tests = b.addTest(.{ .root_module = lib_mod, }); + const exe_unit_test = b.addTest(.{ + .root_module = exe_mod, + }); const run_lib_unit_tests = b.addRunArtifact(lib_unit_tests); + const run_exe_unit_tests = b.addRunArtifact(exe_unit_test); const test_step = b.step("test", "Run unit tests"); test_step.dependOn(&run_lib_unit_tests.step); + test_step.dependOn(&run_exe_unit_tests.step); } diff --git a/build.zig.zon b/build.zig.zon index e676982..4d028e2 100644 --- a/build.zig.zon +++ b/build.zig.zon @@ -54,8 +54,8 @@ "build.zig", "build.zig.zon", "src", - // For example... - //"LICENSE", - //"README.md", + + "LICENSE", + "README.md", }, }