zig build: remove --build-runner CLI parameter

There is no concept of a "build runner" any more; it has been split in two:
configurer and maker.

Users of this feature will likely want to no longer override any logic, and
instead consume the configuration file produced by configurer.

If overriding one or the other of these is desired, the feature will need to be
re-introduced (as --override-maker or --override-configurer).
This commit is contained in:
Andrew Kelley
2026-05-25 13:54:20 -07:00
parent 1aa65d094e
commit bd1b47733b
3 changed files with 1 additions and 12 deletions
-1
View File
@@ -342,7 +342,6 @@ pub fn printUsage(sc: *const ScannedConfig, graph: *Graph, w: *Writer) !void {
\\ --cache-dir [path] Override path to local Zig cache directory
\\ --global-cache-dir [path] Override path to global Zig cache directory
\\ --zig-lib-dir [arg] Override path to Zig lib directory
\\ --build-runner [file] Override path to build runner
\\ --seed [integer] For shuffling dependency traversal order (default: random)
\\ --cache-poison[=mode] Override configuration caching behavior
\\ pure (default) Avoid false positive cache hits
-1
View File
@@ -756,7 +756,6 @@ pub const EnvVar = enum {
ZIG_LOCAL_PKG_DIR,
ZIG_LIB_DIR,
ZIG_LIBC,
ZIG_BUILD_RUNNER,
ZIG_BUILD_ERROR_STYLE,
ZIG_BUILD_MULTILINE_ERRORS,
ZIG_VERBOSE_LINK,
+1 -10
View File
@@ -4944,7 +4944,6 @@ fn cmdBuild(
var override_global_cache_dir: ?[]const u8 = EnvVar.ZIG_GLOBAL_CACHE_DIR.get(environ_map);
var override_local_cache_dir: ?[]const u8 = EnvVar.ZIG_LOCAL_CACHE_DIR.get(environ_map);
var override_pkg_dir: ?[]const u8 = EnvVar.ZIG_LOCAL_PKG_DIR.get(environ_map);
var override_make_runner: ?[]const u8 = EnvVar.ZIG_BUILD_RUNNER.get(environ_map);
var maker_optimize_mode: std.builtin.OptimizeMode = if (EnvVar.ZIG_DEBUG_CMD.isSet(environ_map))
.Debug
else
@@ -5074,11 +5073,6 @@ fn cmdBuild(
i += 1;
override_lib_dir = args[i];
continue;
} else if (mem.eql(u8, arg, "--build-runner")) {
if (i + 1 >= args.len) fatal("expected argument after '{s}'", .{arg});
i += 1;
override_make_runner = args[i];
continue;
} else if (mem.eql(u8, arg, "--cache-dir")) {
if (i + 1 >= args.len) fatal("expected argument after '{s}'", .{arg});
i += 1;
@@ -5365,10 +5359,7 @@ fn cmdBuild(
// We want to release all the locks before executing the child process, so we make a nice
// big block here to ensure the cleanup gets run when we extract out our argv.
{
const main_mod_paths: Package.Module.CreateOptions.Paths = if (override_make_runner) |runner| .{
.root = try .fromUnresolved(arena, dirs, &.{fs.path.dirname(runner) orelse "."}),
.root_src_path = fs.path.basename(runner),
} else .{
const main_mod_paths: Package.Module.CreateOptions.Paths = .{
.root = try .fromRoot(arena, dirs, .zig_lib, "compiler"),
.root_src_path = "configurer.zig",
};