Skip to content

Commit

Permalink
fix: build.zig updates
Browse files Browse the repository at this point in the history
  • Loading branch information
nilslice committed Jan 4, 2024
1 parent 6ff6fe6 commit eac6e1e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const builtin = @import("builtin");
pub fn build(b: *std.Build) void {
comptime {
const current_zig = builtin.zig_version;
const min_zig = std.SemanticVersion.parse("0.12.0-dev.64+b835fd90c") catch unreachable; // std.json.ArrayHashMap
const min_zig = std.SemanticVersion.parse("0.12.0-dev.2030+2ac315c24") catch unreachable; // std.json.ArrayHashMap
if (current_zig.order(min_zig) == .lt) {
@compileError(std.fmt.comptimePrint("Your Zig version v{} does not meet the minimum build requirement of v{}", .{ current_zig, min_zig }));
}
Expand All @@ -16,7 +16,7 @@ pub fn build(b: *std.Build) void {
});

const pdk_module = b.addModule("extism-pdk", .{
.source_file = .{ .path = "src/main.zig" },
.root_source_file = .{ .path = "src/main.zig" },
});

var basic_example = b.addExecutable(.{
Expand All @@ -25,8 +25,8 @@ pub fn build(b: *std.Build) void {
.target = target,
.optimize = optimize,
});
basic_example.addModule("extism-pdk", pdk_module);
basic_example.rdynamic = true;
basic_example.root_module.addImport("extism-pdk", pdk_module);

b.installArtifact(basic_example);
const basic_example_step = b.step("basic_example", "Build basic_example");
Expand Down

0 comments on commit eac6e1e

Please sign in to comment.