use a separate build.zig for the example

This gives a more concrete example of how to use vulkan-zig, including
build commands as how a downstream user would use vulkan-zig.
This commit is contained in:
Robin Voetter
2024-04-28 22:22:01 +02:00
parent 1fdb930ae3
commit 7ac69f90ef
5 changed files with 108 additions and 86 deletions

View File

@@ -1,6 +1,10 @@
const std = @import("std");
const generator = @import("vulkan/generator.zig");
pub const generateVk = generator.generate;
pub const VkGenerateStep = @import("vulkan/build_integration.zig").GenerateStep;
pub const ShaderCompileStep = @import("build_integration.zig").ShaderCompileStep;
fn invalidUsage(prog_name: []const u8, comptime fmt: []const u8, args: anytype) noreturn {
std.log.err(fmt, args);
std.log.err("see {s} --help for usage", .{prog_name});
@@ -127,3 +131,9 @@ pub fn main() void {
std.process.exit(1);
};
}
test "main" {
_ = @import("xml.zig");
_ = @import("vulkan/c_parse.zig");
}