set $NINJAFLAGS to make sure Ninja doesn't use all visible cores when building Qt5#2338
Conversation
… building Qt5 (fixes easybuilders#2076)
|
Test report by @branfosj Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
Test report by @branfosj Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
Test report by @branfosj Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
@branfosj suggested that we should find a more general place to add Just doing so in the |
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
| # so $NINJAFLAGS is set to control number of parallel processes used by Ninja | ||
| if LooseVersion(self.version) >= LooseVersion('5'): | ||
| if get_software_root('Ninja'): | ||
| env.setvar('NINJAFLAGS', '-j%s' % self.cfg['parallel']) |
There was a problem hiding this comment.
It's likely a bad idea to overwrite NINJAFLAGS like this. User could have set it for some reason. And it should check if "-j" is already in NINJAFLAGS and not override it if it is...
There was a problem hiding this comment.
Should one add this variable on ninja itself? Or make ninja respect parallel?
There was a problem hiding this comment.
I've just figured out that $NINJAFLAGS is very specific to Qt5, so in that case I'd argue that ignoring $NINJAFLAGS if it's set already actually makes total sense (you don't want a random value for a pretty generically named environment variable like $NINJAFLAGS to mess up your Qt5 build).
|
This one could use a bit of revisiting from @boegel |
|
@akesandgren We should probably do this on the framework side, not just for |
|
I did a bit more digging, and apparently |
… procedure, not a generic thing for Ninja
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 1 out of 1 (1 easyconfigs in total) |
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 3 out of 3 (3 easyconfigs in total) |
|
Test report by @boegel Overview of tested easyconfigs (in order)
Build succeeded for 5 out of 5 (5 easyconfigs in total) |
|
Going in, thanks @boegel! |
(created using
eb --new-pr)fixes #2076