From cc365ba73334e11965421c47764e87b5b7aa85fe Mon Sep 17 00:00:00 2001 From: Eva Isabella Luna Date: Wed, 28 May 2025 20:43:38 -0600 Subject: [PATCH] [Build] Add TOO_MANY_CORES The JDK needs a *lot* of RAM to compile, and this scales with the number of jobs you run. This variable should make it a little more tolerable. --- 6_buildjdk.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/6_buildjdk.sh b/6_buildjdk.sh index 81319cd..4b6b20f 100755 --- a/6_buildjdk.sh +++ b/6_buildjdk.sh @@ -140,6 +140,12 @@ else jobs=$(nproc) fi +# Failsafe environment variable for computers with too many cores +# i.e. Cart's 7K62 +if [[ "$TOO_MANY_CORES" == "1" ]]; then + jobs=6 +fi + echo Running ${jobs} jobs to build the jdk cd build/${JVM_PLATFORM}-${TARGET_JDK}-${JVM_VARIANTS}-${JDK_DEBUG_LEVEL}