pololu / nixcrpkgs

Tools for cross-compiling standalone applications using Nix.
Other
200 stars 17 forks source link

honor NIX_BUILD_CORES when build environment #6

Closed lulitao1997 closed 3 years ago

lulitao1997 commented 3 years ago

see https://nixos.org/manual/nix/unstable/advanced-topics/cores-vs-jobs.html

It is up to the derivations' build script to respect host's requested cores-per-build by following the value of the NIX_BUILD_CORES environment variable.

this PR allow us to enable parallel build by using nix-build -A linux64.hello --cores $(nproc)

DavidEGrayson commented 3 years ago

Thanks. I merged it in.