GNU bug report logs -
#77431
[PATCH] gnu: zig: Set rss_max to unlimited
Previous Next
Reported by: Tommy Langhelle <tomlanghe <at> gmail.com>
Date: Tue, 1 Apr 2025 14:00:15 UTC
Severity: normal
Tags: patch
Done: Hilton Chain <hako <at> ultrarare.space>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your message dated Sat, 05 Apr 2025 08:50:00 +0800
with message-id <87v7rjmnyf.wl-hako <at> ultrarare.space>
and subject line Re: [PATCH v2] gnu: zig: Set rss_max to unlimited for 0.14
has caused the debbugs.gnu.org bug report #77431,
regarding [PATCH] gnu: zig: Set rss_max to unlimited
to be marked as done.
(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)
--
77431: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=77431
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
Upstream sets this for CI purposes, but it fails my ARM builds. The
limit itself doesn't make too much sense as long as zig builds and the
build host is big enough, so simply allowing unlimited rss should be
fine.
* gnu/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch: New file.
* gnu/packages/zig.scm (zig-0.14)[source]: Add patch.
* gnu/local.mk (dist_patch_DATA): Register it.
---
gnu/local.mk | 1 +
...ax_rss-to-unlimited-for-building-zig.patch | 31 +++++++++++++++++++
gnu/packages/zig.scm | 3 +-
3 files changed, 34 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch
diff --git a/gnu/local.mk b/gnu/local.mk
index f03fcb14fc..63e87a232e 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -2473,6 +2473,7 @@ dist_patch_DATA = \
%D%/packages/patches/zig-0.14-fix-runpath.patch \
%D%/packages/patches/zig-0.14-use-baseline-cpu-by-default.patch \
%D%/packages/patches/zig-0.14-use-system-paths.patch \
+ %D%/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch \
%D%/packages/patches/zsh-egrep-failing-test.patch \
%D%/packages/patches/zuo-bin-sh.patch
diff --git a/gnu/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch b/gnu/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch
new file mode 100644
index 0000000000..d944827353
--- /dev/null
+++ b/gnu/packages/patches/zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch
@@ -0,0 +1,31 @@
+From 408722e084edf0a86066344e29bdfced70679129 Mon Sep 17 00:00:00 2001
+From: Tommy Langhelle <tomlanghe <at> gmail.com>
+Date: Mon, 31 Mar 2025 11:47:12 +0200
+Subject: [PATCH] Set max_rss to unlimited for building zig
+
+https://github.com/ziglang/zig/issues/18263
+
+Upstream sets this for CI purposes, but it fails my ARM builds. The
+limit itself doesn't make too much sense as long as zig builds and the
+build host is big enough, so simply allowing unlimited rss should be
+fine.
+---
+ build.zig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/build.zig b/build.zig
+index 375cb6df09..16862fc5f9 100644
+--- a/build.zig
++++ b/build.zig
+@@ -703,7 +703,7 @@ fn addCompilerStep(b: *std.Build, options: AddCompilerStepOptions) *std.Build.St
+
+ const exe = b.addExecutable(.{
+ .name = "zig",
+- .max_rss = 7_800_000_000,
++ .max_rss = 0,
+ .root_module = compiler_mod,
+ });
+ exe.stack_size = stack_size;
+--
+2.41.0
+
diff --git a/gnu/packages/zig.scm b/gnu/packages/zig.scm
index 733251242e..eb7bda8c62 100644
--- a/gnu/packages/zig.scm
+++ b/gnu/packages/zig.scm
@@ -1871,7 +1871,8 @@ (define-public zig-0.14
(search-patches
"zig-0.14-use-baseline-cpu-by-default.patch"
"zig-0.14-use-system-paths.patch"
- "zig-0.14-fix-runpath.patch"))))
+ "zig-0.14-fix-runpath.patch"
+ "zig-0.14-set-max_rss-to-unlimited-for-building-zig.patch"))))
(inputs
(modify-inputs (package-inputs zig-0.13)
(replace "clang" clang-19)
base-commit: e7aeec67feaa5cf888f0aae14400fc015390aa8e
--
2.41.0
[Message part 3 (message/rfc822, inline)]
On Fri, 04 Apr 2025 19:53:19 +0800,
Tommy Langhelle wrote:
>
> Upstream sets this for CI purposes, but it fails my ARM builds. The
> limit itself doesn't make too much sense as long as zig builds and the
> build host is big enough, so simply allowing unlimited rss should be
> fine.
>
> * gnu/packages/zig.scm (zig-0.14)[source]: Set max_rss to unlimited.
> ---
> gnu/packages/zig.scm | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
Applied as f3a8c28f3f7b5daf95e11826b7cada713c8bfef3, thanks!
This bug report was last modified 49 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.