diff --git a/BRANCH_TODO b/BRANCH_TODO index eda7ffa77e11baa73ab405995c5234b09f7ce105..2c256f09e8992587d84fa409d02817ab2d95084a 100644 --- a/BRANCH_TODO +++ b/BRANCH_TODO @@ -1,4 +1,3 @@ -* remove Cache from configurer * implement the build options * finish migrating the rest of the build steps * inspect b4ffb402c082605c4b324e88120306fc8fb3cf32 diff and apply changes as needed (merge conflict) @@ -29,7 +28,8 @@ ## Release Notes -run args are all together now, not observable in configure phase whether run args are provided. +In the Run step, passthru args are all together now, not observable in +configure phase whether run args are provided. ```zig if (b.args) |args| { @@ -42,3 +42,7 @@ if (b.args) |args| { ```zig run_cmd.addPassthruArgs(); ``` + +This removes a capability from build scripts since they can no longer observe +those arguments. In exchange, it means that when changing those arguments, +build scripts need not be rebuilt from source. diff --git a/lib/compiler/configurer.zig b/lib/compiler/configurer.zig index a4e37b50c1a7b40f12a22f23af52d088b34289ec..1b0a87a1e5d160b4ff3cd00c57656584df3fbcad 100644 --- a/lib/compiler/configurer.zig +++ b/lib/compiler/configurer.zig @@ -73,12 +73,6 @@ pub fn main(init: process.Init.Minimal) !void { var graph: std.Build.Graph = .{ .io = io, .arena = arena, - .cache = .{ - .io = io, - .gpa = arena, - .manifest_dir = try local_cache_directory.handle.createDirPathOpen(io, "h", .{}), - .cwd = try process.currentPathAlloc(io, arena), - }, .zig_exe = zig_exe, .environ_map = try init.environ.createMap(arena), .global_cache_root = global_cache_directory, @@ -102,12 +96,6 @@ pub fn main(init: process.Init.Minimal) !void { assert(try graph.wip_configuration.addString("") == .empty); assert(try graph.wip_configuration.addString("root") == .root); - graph.cache.addPrefix(.{ .path = null, .handle = cwd }); - graph.cache.addPrefix(build_root_directory); - graph.cache.addPrefix(local_cache_directory); - graph.cache.addPrefix(global_cache_directory); - graph.cache.hash.addBytes(builtin.zig_version_string); - const builder = try std.Build.create( &graph, build_root_directory, diff --git a/lib/std/Build.zig b/lib/std/Build.zig index 774d7563d246d29f50b0226744b87512fc116da8..edec451b627f79d2f9c09cef9339f3a789c9edb6 100644 --- a/lib/std/Build.zig +++ b/lib/std/Build.zig @@ -83,7 +83,6 @@ pub const Graph = struct { arena: Allocator, system_integration_options: std.StringArrayHashMapUnmanaged(SystemLibraryMode) = .empty, system_package_mode: bool = false, - cache: Cache, zig_exe: []const u8, environ_map: process.Environ.Map, global_cache_root: Cache.Directory,