diff options
author | Profpatsch <mail@profpatsch.de> | 2021-03-26 11:59:48 +0100 |
---|---|---|
committer | Profpatsch <mail@profpatsch.de> | 2021-03-26 11:59:48 +0100 |
commit | 0bb003b121330ff57cdcf41909085eb6c1f2396b (patch) | |
tree | 25b9359f2c7d4a57daa7d67a50170761c67a9538 /pkgs | |
parent | 165a0b1a67b5000fc3d2fcba1936d8595a24eed8 (diff) |
pkgs/profpatsch/write-rust: use s6-portable-utils
We had a bunch of instances of https://github.com/NixOS/nix/issues/2176, where nix would exit with a “killed by signal 9” error. According to Eelco in that issue, this is perfectly normal behaviour of course, and appears if the last command in a loop closes `stdout` or `stdin`, then the builder will SIGKILL it immediately. This is of course also a perfectly fine error message for that case. It turns out that mainly GNU coreutils exhibit this behaviour … Let’s see if using a more sane tool suite fixes that.
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/profpatsch/write-rust.nix | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/profpatsch/write-rust.nix b/pkgs/profpatsch/write-rust.nix index adb10950..bb114117 100644 --- a/pkgs/profpatsch/write-rust.nix +++ b/pkgs/profpatsch/write-rust.nix @@ -1,13 +1,13 @@ { pkgs, runExeclineLocal, getBins, drvSeqL }: let - bins = getBins pkgs.coreutils [ "ln" "ls" "touch" ]; + bins = getBins pkgs.s6-portable-utils [ "s6-ln" "s6-ls" "s6-touch" ]; writeRustSimple = name: args: srcFile: linkTo name "${writeRustSimpleBin name args srcFile}/bin/${name}"; linkTo = name: path: runExeclineLocal name {} [ "importas" "out" "out" - bins.ln "-sT" path "$out" + "if" [ bins.s6-ln "-sT" path "$out" ] ]; writeRustSimpleBin = name: { dependencies ? [], ... }@args: srcFile: pkgs.buildRustCrate ({ @@ -51,12 +51,12 @@ let tests = runExeclineLocal "${rustDrv.name}-tests-run" {} [ "importas" "out" "out" "if" [ - "pipeline" [ bins.ls "${crate true}/tests" ] + "pipeline" [ bins.s6-ls "${crate true}/tests" ] "forstdin" "-o0" "test" "importas" "test" "test" "${crate true}/tests/$test" ] - bins.touch "$out" + bins.s6-touch "$out" ]; in drvSeqL [ tests ] (crate false); |