From 5ec59f2a01e268cdbd85f4a2babc62f9996513b7 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Fri, 20 Oct 2023 21:54:27 -0700 Subject: [PATCH] build.zig: building on macos takes more memory Previous commit caused this error to be printed: zig build-exe zig Debug aarch64-macos-none: error: memory usage peaked at 6323765248 bytes, exceeding the declared upper bound of 5200000000 --- build.zig | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build.zig b/build.zig index d58c32d642..7140bb32ca 100644 --- a/build.zig +++ b/build.zig @@ -578,7 +578,10 @@ fn addCompilerStep( .root_source_file = .{ .path = "src/main.zig" }, .target = target, .optimize = optimize, - .max_rss = 5_200_000_000, + .max_rss = if (target.getObjectFormat() == .macho) + 6_350_000_000 + else + 5_200_000_000, }); exe.stack_size = stack_size; exe.addAnonymousModule("aro", .{