Skip to content

Commit 1b278ce

Browse files
committed
Update build.zig for 0.16 fs.Dir -> Io.Dir
1 parent 25dc764 commit 1b278ce

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

build.zig

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ pub fn build(b: *std.Build) void {
6868
defer b.allocator.free(cache_include);
6969

7070
// TODO: Remove compatibility shim when Zig 0.16.0 is the minimum required version.
71-
const open_dir_opts: std.fs.Dir.OpenOptions = if (@hasField(std.fs.Dir.OpenOptions, "follow_symlinks"))
71+
const open_dir_opts: std.Io.Dir.OpenOptions = if (@hasField(std.Io.Dir.OpenOptions, "follow_symlinks"))
7272
.{ .access_sub_paths = true, .follow_symlinks = false }
7373
else
7474
.{ .access_sub_paths = true, .no_follow = true };
75-
var dir = std.fs.openDirAbsolute(cache_include, open_dir_opts) catch @panic("No emscripten cache. Generate it!");
76-
dir.close();
75+
var dir = std.Io.Dir.openDirAbsolute(mod.owner.graph.io, cache_include, open_dir_opts) catch @panic("No emscripten cache. Generate it!");
76+
dir.close(mod.owner.graph.io);
7777

7878
mod.addIncludePath(.{ .cwd_relative = cache_include });
7979
},

0 commit comments

Comments
 (0)