chromium: try to hack around Hydra problems

Discussion: https://github.com/NixOS/nixpkgs/commit/e8f1ddcbd1d
This commit is contained in:
Vladimír Čunát 2017-09-01 12:24:47 +02:00
parent 7b6251b4dc
commit 017561209e
No known key found for this signature in database
GPG Key ID: E747DF1F9575A3AA

View File

@ -228,9 +228,14 @@ let
'';
buildPhase = let
# Build paralelism: on Hydra the build was frequently running into memory
# exhaustion, and even other users might be running into similar issues.
# -j is halved to avoid memory problems, and -l is slightly increased
# so that the build gets slight preference before others
# (it will often be on "critical path" and at risk of timing out)
buildCommand = target: ''
ninja -C "${buildPath}" \
-j$NIX_BUILD_CORES -l$NIX_BUILD_CORES \
-j$(( ($NIX_BUILD_CORES+1) / 2 )) -l$(( $NIX_BUILD_CORES+1 )) \
"${target}"
'' + optionalString (target == "mksnapshot" || target == "chrome") ''
paxmark m "${buildPath}/${target}"