diff --git a/pkg/cimgui/build.zig b/pkg/cimgui/build.zig index 3ca735383..cf003a0bd 100644 --- a/pkg/cimgui/build.zig +++ b/pkg/cimgui/build.zig @@ -108,9 +108,11 @@ pub fn build(b: *std.Build) !void { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); test_exe.linkLibrary(lib); const tests_run = b.addRunArtifact(test_exe); diff --git a/pkg/fontconfig/build.zig b/pkg/fontconfig/build.zig index 9e4173da8..7171e383a 100644 --- a/pkg/fontconfig/build.zig +++ b/pkg/fontconfig/build.zig @@ -29,9 +29,11 @@ pub fn build(b: *std.Build) !void { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); const tests_run = b.addRunArtifact(test_exe); const test_step = b.step("test", "Run tests"); diff --git a/pkg/freetype/build.zig b/pkg/freetype/build.zig index e9f72210a..304eb2bce 100644 --- a/pkg/freetype/build.zig +++ b/pkg/freetype/build.zig @@ -23,9 +23,11 @@ pub fn build(b: *std.Build) !void { if (target.query.isNative()) { test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); const tests_run = b.addRunArtifact(test_exe.?); const test_step = b.step("test", "Run tests"); diff --git a/pkg/glslang/build.zig b/pkg/glslang/build.zig index 747216a39..a71c78db9 100644 --- a/pkg/glslang/build.zig +++ b/pkg/glslang/build.zig @@ -20,9 +20,11 @@ pub fn build(b: *std.Build) !void { if (target.query.isNative()) { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); test_exe.linkLibrary(lib); const tests_run = b.addRunArtifact(test_exe); diff --git a/pkg/harfbuzz/build.zig b/pkg/harfbuzz/build.zig index 424f2afed..9e588abd8 100644 --- a/pkg/harfbuzz/build.zig +++ b/pkg/harfbuzz/build.zig @@ -43,9 +43,11 @@ pub fn build(b: *std.Build) !void { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); { diff --git a/pkg/highway/build.zig b/pkg/highway/build.zig index 5036316da..9130d7f53 100644 --- a/pkg/highway/build.zig +++ b/pkg/highway/build.zig @@ -95,9 +95,11 @@ pub fn build(b: *std.Build) !void { { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); test_exe.linkLibrary(lib); diff --git a/pkg/macos/build.zig b/pkg/macos/build.zig index ddbeb82c9..de232fecb 100644 --- a/pkg/macos/build.zig +++ b/pkg/macos/build.zig @@ -51,9 +51,11 @@ pub fn build(b: *std.Build) !void { { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); if (target.result.os.tag.isDarwin()) { try apple_sdk.addPaths(b, test_exe); diff --git a/pkg/oniguruma/build.zig b/pkg/oniguruma/build.zig index c23d744df..ff01cb784 100644 --- a/pkg/oniguruma/build.zig +++ b/pkg/oniguruma/build.zig @@ -23,9 +23,11 @@ pub fn build(b: *std.Build) !void { if (target.query.isNative()) { test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); const tests_run = b.addRunArtifact(test_exe.?); const test_step = b.step("test", "Run tests"); diff --git a/pkg/spirv-cross/build.zig b/pkg/spirv-cross/build.zig index ff67e3e72..e3b07a2c6 100644 --- a/pkg/spirv-cross/build.zig +++ b/pkg/spirv-cross/build.zig @@ -15,9 +15,11 @@ pub fn build(b: *std.Build) !void { if (target.query.isNative()) { const test_exe = b.addTest(.{ .name = "test", - .root_source_file = b.path("main.zig"), - .target = target, - .optimize = optimize, + .root_module = b.createModule(.{ + .root_source_file = b.path("main.zig"), + .target = target, + .optimize = optimize, + }), }); test_exe.linkLibrary(lib); const tests_run = b.addRunArtifact(test_exe); diff --git a/pkg/wuffs/build.zig b/pkg/wuffs/build.zig index 4d144e76a..b151892ed 100644 --- a/pkg/wuffs/build.zig +++ b/pkg/wuffs/build.zig @@ -12,9 +12,12 @@ pub fn build(b: *std.Build) !void { }); const unit_tests = b.addTest(.{ - .root_source_file = b.path("src/main.zig"), - .target = target, - .optimize = optimize, + .name = "test", + .root_module = b.createModule(.{ + .root_source_file = b.path("src/main.zig"), + .target = target, + .optimize = optimize, + }), }); unit_tests.linkLibC();