| author | |
| committer | |
| log | f52189834c8554f6358244471c789e2233c260f0 |
| tree | 957791cea71422e1e408a63d82e485eb9da2f0f0 |
| parent | fea615710268582f488b894e4276938c5e385636 |
No functional changes. This renames an internal build option to better
reflect how it is used.4 files changed, 10 insertions(+), 10 deletions(-)
build.zig+3-3| ... | ... | @@ -197,7 +197,7 @@ pub fn build(b: *std.Build) !void { |
| 197 | 197 | exe_options.addOption(bool, "llvm_has_xtensa", llvm_has_xtensa); |
| 198 | 198 | exe_options.addOption(bool, "force_gpa", force_gpa); |
| 199 | 199 | exe_options.addOption(bool, "only_c", only_c); |
| 200 | exe_options.addOption(bool, "omit_pkg_fetching_code", only_c); | |
| 200 | exe_options.addOption(bool, "only_core_functionality", only_c); | |
| 201 | 201 | |
| 202 | 202 | if (link_libc) { |
| 203 | 203 | exe.linkLibC(); |
| ... | ... | @@ -353,7 +353,7 @@ pub fn build(b: *std.Build) !void { |
| 353 | 353 | test_cases_options.addOption(bool, "llvm_has_xtensa", llvm_has_xtensa); |
| 354 | 354 | test_cases_options.addOption(bool, "force_gpa", force_gpa); |
| 355 | 355 | test_cases_options.addOption(bool, "only_c", only_c); |
| 356 | test_cases_options.addOption(bool, "omit_pkg_fetching_code", true); | |
| 356 | test_cases_options.addOption(bool, "only_core_functionality", true); | |
| 357 | 357 | test_cases_options.addOption(bool, "enable_qemu", b.enable_qemu); |
| 358 | 358 | test_cases_options.addOption(bool, "enable_wine", b.enable_wine); |
| 359 | 359 | test_cases_options.addOption(bool, "enable_wasmtime", b.enable_wasmtime); |
| ... | ... | @@ -505,7 +505,7 @@ fn addWasiUpdateStep(b: *std.Build, version: [:0]const u8) !void { |
| 505 | 505 | exe_options.addOption(bool, "enable_tracy_callstack", false); |
| 506 | 506 | exe_options.addOption(bool, "enable_tracy_allocation", false); |
| 507 | 507 | exe_options.addOption(bool, "value_tracing", false); |
| 508 | exe_options.addOption(bool, "omit_pkg_fetching_code", true); | |
| 508 | exe_options.addOption(bool, "only_core_functionality", true); | |
| 509 | 509 | |
| 510 | 510 | const run_opt = b.addSystemCommand(&.{ |
| 511 | 511 | "wasm-opt", |
src/Compilation.zig+1-1| ... | ... | @@ -2056,7 +2056,7 @@ pub fn update(comp: *Compilation, main_progress_node: *std.Progress.Node) !void |
| 2056 | 2056 | return; |
| 2057 | 2057 | } |
| 2058 | 2058 | |
| 2059 | if (!build_options.only_c and !build_options.omit_pkg_fetching_code) { | |
| 2059 | if (!build_options.only_c and !build_options.only_core_functionality) { | |
| 2060 | 2060 | if (comp.emit_docs) |doc_location| { |
| 2061 | 2061 | if (comp.bin_file.options.module) |module| { |
| 2062 | 2062 | var autodoc = Autodoc.init(module, doc_location); |
src/main.zig+5-5| ... | ... | @@ -292,7 +292,7 @@ pub fn mainArgs(gpa: Allocator, arena: Allocator, args: []const []const u8) !voi |
| 292 | 292 | mem.eql(u8, cmd, "wasm-ld")) |
| 293 | 293 | { |
| 294 | 294 | return process.exit(try lldMain(arena, args, true)); |
| 295 | } else if (build_options.omit_pkg_fetching_code) { | |
| 295 | } else if (build_options.only_core_functionality) { | |
| 296 | 296 | @panic("only a few subcommands are supported in a zig2.c build"); |
| 297 | 297 | } else if (mem.eql(u8, cmd, "cc")) { |
| 298 | 298 | return buildOutputType(gpa, arena, args, .cc); |
| ... | ... | @@ -680,7 +680,7 @@ const ArgMode = union(enum) { |
| 680 | 680 | |
| 681 | 681 | /// Avoid dragging networking into zig2.c because it adds dependencies on some |
| 682 | 682 | /// linker symbols that are annoying to satisfy while bootstrapping. |
| 683 | const Ip4Address = if (build_options.omit_pkg_fetching_code) void else std.net.Ip4Address; | |
| 683 | const Ip4Address = if (build_options.only_core_functionality) void else std.net.Ip4Address; | |
| 684 | 684 | |
| 685 | 685 | const Listen = union(enum) { |
| 686 | 686 | none, |
| ... | ... | @@ -1179,7 +1179,7 @@ fn buildOutputType( |
| 1179 | 1179 | if (mem.eql(u8, next_arg, "-")) { |
| 1180 | 1180 | listen = .stdio; |
| 1181 | 1181 | } else { |
| 1182 | if (build_options.omit_pkg_fetching_code) unreachable; | |
| 1182 | if (build_options.only_core_functionality) unreachable; | |
| 1183 | 1183 | // example: --listen 127.0.0.1:9000 |
| 1184 | 1184 | var it = std.mem.split(u8, next_arg, ":"); |
| 1185 | 1185 | const host = it.next().?; |
| ... | ... | @@ -3268,7 +3268,7 @@ fn buildOutputType( |
| 3268 | 3268 | return cleanExit(); |
| 3269 | 3269 | }, |
| 3270 | 3270 | .ip4 => |ip4_addr| { |
| 3271 | if (build_options.omit_pkg_fetching_code) unreachable; | |
| 3271 | if (build_options.only_core_functionality) unreachable; | |
| 3272 | 3272 | |
| 3273 | 3273 | var server = std.net.StreamServer.init(.{ |
| 3274 | 3274 | .reuse_address = true, |
| ... | ... | @@ -4415,7 +4415,7 @@ pub fn cmdBuild(gpa: Allocator, arena: Allocator, args: []const []const u8) !voi |
| 4415 | 4415 | .root_src_directory = build_directory, |
| 4416 | 4416 | .root_src_path = build_zig_basename, |
| 4417 | 4417 | }; |
| 4418 | if (!build_options.omit_pkg_fetching_code) { | |
| 4418 | if (!build_options.only_core_functionality) { | |
| 4419 | 4419 | var http_client: std.http.Client = .{ .allocator = gpa }; |
| 4420 | 4420 | defer http_client.deinit(); |
| 4421 | 4421 |
stage1/config.zig.in+1-1| ... | ... | @@ -13,4 +13,4 @@ pub const have_stage1 = false; |
| 13 | 13 | pub const skip_non_native = false; |
| 14 | 14 | pub const only_c = false; |
| 15 | 15 | pub const force_gpa = false; |
| 16 | pub const omit_pkg_fetching_code = true; | |
| 16 | pub const only_core_functionality = true; |