Use new module API

The new module API now returns the created module as well as taking some
different parameters.
This commit is contained in:
antlilja
2023-03-06 23:15:16 +01:00
parent 070500f5e5
commit d8cfd033b1

View File

@@ -27,8 +27,7 @@ pub fn build(b: *std.Build) void {
if (!std.fs.path.isAbsolute(path)) @panic("Make sure to assign an absolute path to the `registry` option (see: std.Build.pathFromRoot).\n"); if (!std.fs.path.isAbsolute(path)) @panic("Make sure to assign an absolute path to the `registry` option (see: std.Build.pathFromRoot).\n");
generate_cmd.addArg(path); generate_cmd.addArg(path);
b.addModule(.{ _ = b.addModule("vulkan-zig", .{
.name = "vulkan-zig",
.source_file = generate_cmd.addOutputFileArg("vk.zig"), .source_file = generate_cmd.addOutputFileArg("vk.zig"),
}); });
} }