webgpu: add libs/mach-glfw

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2021-11-05 04:20:09 -07:00 committed by Stephen Gutekanst
parent b2aca7fdde
commit d7be41e35f
3 changed files with 5 additions and 5 deletions

View file

@ -1,7 +1,7 @@
const Builder = @import("std").build.Builder;
const dawn = @import("build_dawn.zig");
const glfw = @import("./libs/dawn/mach-old/glfw/build.zig"); // TODO: mach-old path
const glfw = @import("libs/mach-glfw/build.zig");
pub fn build(b: *Builder) void {
const mode = b.standardReleaseOptions();
@ -24,7 +24,7 @@ pub fn build(b: *Builder) void {
dawn_example.setTarget(target);
dawn.link(b, dawn_example, .{});
glfw.link(b, dawn_example, .{.system_sdk = .{.set_sysroot = false}});
dawn_example.addPackagePath("glfw", "./libs/dawn/mach-old/glfw/src/main.zig"); // TODO: mach-old path
dawn_example.addPackagePath("glfw", "libs/mach-glfw/src/main.zig");
dawn_example.addIncludeDir("libs/dawn/out/Debug/gen/src/include");
dawn_example.addIncludeDir("libs/dawn/out/Debug/gen/src");
dawn_example.addIncludeDir("libs/dawn/src/include");

View file

@ -1,7 +1,6 @@
const std = @import("std");
const Builder = std.build.Builder;
//const glfw = @import("../glfw/build.zig");
const glfw = @import("./libs/dawn/mach-old/glfw/build.zig"); // TODO: mach-old path
const glfw = @import("libs/mach-glfw/build.zig");
pub fn build(b: *Builder) void {
const mode = b.standardReleaseOptions();
@ -18,7 +17,7 @@ pub fn build(b: *Builder) void {
example.setTarget(target);
link(b, example, .{});
glfw.link(b, example, .{.system_sdk = .{.set_sysroot = false}});
example.addPackagePath("glfw", "./libs/dawn/mach-old/glfw/src/main.zig"); // TODO: mach-old path
example.addPackagePath("glfw", "libs/mach-glfw/src/main.zig");
example.addIncludeDir("out/Debug/gen/src/include");
example.addIncludeDir("out/Debug/gen/src");
example.addIncludeDir("examples");

1
webgpu/libs/mach-glfw Symbolic link
View file

@ -0,0 +1 @@
../../glfw