diff --git a/build.zig b/build.zig index 90f7090..1dcf28d 100644 --- a/build.zig +++ b/build.zig @@ -205,8 +205,8 @@ pub fn libresslBuild( // TODO: can we just add this as an install header instead? It's needed during this // build. This mutates the source tree, which is really gross. - const include_dir = try std.fs.cwd().openDir(install_header_prefix ++ "openssl", .{}); - try std.fs.cwd().copyFile(header, include_dir, "opensslconf.h", .{}); + const include_dir = try b.build_root.handle.openDir(install_header_prefix ++ "openssl", .{}); + try b.build_root.handle.copyFile(header, include_dir, "opensslconf.h", .{}); try header_search( b, @@ -312,7 +312,7 @@ pub fn header_search( base: []const u8, skiplist: []const SkipSpec, ) !void { - const dir = try std.fs.cwd().openIterableDir(base, .{}); + const dir = try b.build_root.handle.openIterableDir(base, .{}); var walker = try dir.walk(b.allocator); defer walker.deinit();