Udpate for Zig 0.13

This commit is contained in:
Frank Denis 2024-05-09 21:46:20 +02:00
parent 996ea4fee3
commit 45478e1dd6

View file

@ -11,13 +11,13 @@ pub fn build(b: *std.Build) !void {
.strip = true, .strip = true,
}); });
minisign.linkLibC(); minisign.linkLibC();
minisign.addLibraryPath(.{ .path = "/opt/homebrew/lib" }); minisign.addLibraryPath(.{ .cwd_relative = "/opt/homebrew/lib" });
minisign.addLibraryPath(.{ .path = "/usr/local/lib" }); minisign.addLibraryPath(.{ .cwd_relative = "/usr/local/lib" });
minisign.linkSystemLibrary("sodium"); minisign.linkSystemLibrary("sodium");
minisign.addIncludePath(.{ .path = "src" }); minisign.addIncludePath(b.path("src"));
minisign.addSystemIncludePath(.{ .path = "/opt/homebrew/include" }); minisign.addSystemIncludePath(.{ .cwd_relative = "/opt/homebrew/include" });
minisign.addSystemIncludePath(.{ .path = "/usr/local/include" }); minisign.addSystemIncludePath(.{ .cwd_relative = "/usr/local/include" });
minisign.defineCMacro("_GNU_SOURCE", "1"); minisign.defineCMacro("_GNU_SOURCE", "1");
const source_files = &.{ "src/base64.c", "src/get_line.c", "src/helpers.c", "src/minisign.c" }; const source_files = &.{ "src/base64.c", "src/get_line.c", "src/helpers.c", "src/minisign.c" };
minisign.addCSourceFiles(.{ .files = source_files }); minisign.addCSourceFiles(.{ .files = source_files });