switch to kitware's ninja as the default upstream for ninja and configure it to respect jobserver in spack env depfile -o Makefile
#44166
Labels
spack env depfile -o Makefile
#44166
Summary
Right now if you use
spack env depfile -o Makefile; make -j $(nproc)
you get more build threads than$(nproc)
because ninja doesn't understand posix jobservers and spawns more threads than it should. The Kitware fork of ninja has the necessary patches to make this work.Rationale
The Ninja authors are extremely resistant to adding new features, and larger features languish for years without being merged, and kitware in addition to being responsible maintainers of cmake maintains a fork of ninja that is widely adopted by the broader community (it's what you get when you
pip install ninja
).Description
The only alternatives are 1) to ignore this and suffer ninja not respecting the jobsever. or 2) maintain the patches ourselves (more work), 3) somehow get the Ninja authors to merge ninja-build/ninja#1139
Additional information
No response
General information
The text was updated successfully, but these errors were encountered: