From 2748affea5e758b5217dc82d58d9e35bd86a9132 Mon Sep 17 00:00:00 2001 From: dolichomps Date: Thu, 12 Oct 2023 21:23:44 -0300 Subject: [PATCH] update for zig-0.12.0-dev.890+8c6b0271c --- build.zig | 25 ++++++++++++++++++++----- build.zig.zon | 13 +++++++++++++ 2 files changed, 33 insertions(+), 5 deletions(-) diff --git a/build.zig b/build.zig index f62205ac9..f3f3c496a 100644 --- a/build.zig +++ b/build.zig @@ -59,8 +59,14 @@ pub fn build(b: *std.Build) void { } const flags = [_][]const u8{ "-D_GLFW_WIN32", include_src_flag }; - lib.addCSourceFiles(&base_sources, &flags); - lib.addCSourceFiles(&windows_sources, &flags); + lib.addCSourceFiles(.{ + .files = &base_sources, + .flags = &flags, + }); + lib.addCSourceFiles(.{ + .files = &windows_sources, + .flags = &flags, + }); }, .macos => { lib.linkSystemLibraryName("objc"); @@ -80,8 +86,14 @@ pub fn build(b: *std.Build) void { } const flags = [_][]const u8{ "-D_GLFW_COCOA", include_src_flag }; - lib.addCSourceFiles(&base_sources, &flags); - lib.addCSourceFiles(&macos_sources, &flags); + lib.addCSourceFiles(.{ + .files = &base_sources, + .flags = &flags, + }); + lib.addCSourceFiles(.{ + .files = &macos_sources, + .flags = &flags, + }); }, // everything that isn't windows or mac is linux :P @@ -117,7 +129,10 @@ pub fn build(b: *std.Build) void { flags.append(include_src_flag) catch unreachable; - lib.addCSourceFiles(sources.slice(), flags.slice()); + lib.addCSourceFiles(.{ + .files = sources.slice(), + .flags = flags.slice(), + }); }, } b.installArtifact(lib); diff --git a/build.zig.zon b/build.zig.zon index 8cc07d8e1..2f667ae3e 100644 --- a/build.zig.zon +++ b/build.zig.zon @@ -1,6 +1,19 @@ .{ .name = "glfw", .version = "0.0.0", + .paths = .{ + "src/", + "include/", + "build.zig", + "build.zig.zon", + "LICENSE.md", + "README.md", + "CONTRIBUTORS.md", + ".gitignore", + ".gitattributes", + "update.sh", + "verify.sh", + }, .dependencies = .{ .xcode_frameworks = .{ .url = "https://github.com/hexops/xcode-frameworks-pkg/archive/f8b854f9a1f4b4602b4f998ee42588d524d44e52.tar.gz",