diff --git a/build.zig b/build.zig index 0816d22..ef3c3f8 100644 --- a/build.zig +++ b/build.zig @@ -6,7 +6,7 @@ const std = @import("std"); // for defining build steps and express dependencies between them, allowing the // build runner to parallelize the build automatically (and the cache system to // know when a step doesn't need to be re-run). -pub fn build(b: *std.Build) void { +pub fn build(b: *std.Build) !void { // Standard target options allow the person running `zig build` to choose // what target to build for. Here we do not override the defaults, which // means any target is allowed, and the default is native. Other options @@ -67,7 +67,11 @@ pub fn build(b: *std.Build) void { patch_cmd.addArg(s.orig); patch_cmd.addArg(s.new); } - patch_cmd.addFileArg(upstream.path("src/utilities.c")); + const util_src = try std.fs.path.join(b.allocator, &.{ + "src", + "utilities.c", + }); + patch_cmd.addFileArg(upstream.path(util_src)); patch_cmd.step.dependOn(&download_link_step.step); const lib = b.addLibrary(.{