diff options
author | William Harrington <kb0iic@berzerkula.org> | 2021-04-06 14:09:59 -0500 |
---|---|---|
committer | William Harrington <kb0iic@berzerkula.org> | 2021-04-06 14:09:59 -0500 |
commit | af28b78b8e659f995b39a5dde2ce2cef0da9fbe0 (patch) | |
tree | a80d4cfef7713f7aa26137c0da553358af4cd7b2 /chapter8/ninja.sh | |
parent | 783a4c48e04e81783848f0cb0f757f6a836d7f6e (diff) |
Add chapter8 script commands.
Diffstat (limited to 'chapter8/ninja.sh')
-rw-r--r-- | chapter8/ninja.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/chapter8/ninja.sh b/chapter8/ninja.sh index 7a693aa..3f93e56 100644 --- a/chapter8/ninja.sh +++ b/chapter8/ninja.sh @@ -1,3 +1,16 @@ #!/bin/bash +export NINJAJOBS=4 +sed -i '/int Guess/a \ + int j = 0;\ + char* jobs = getenv( "NINJAJOBS" );\ + if ( jobs != NULL ) j = atoi( jobs );\ + if ( j > 0 ) return j;\ +' src/ninja.cc + +python3 configure.py --bootstrap + +install -vm755 ninja /usr/bin/ +install -vDm644 misc/bash-completion /usr/share/bash-completion/completions/ninja +install -vDm644 misc/zsh-completion /usr/share/zsh/site-functions/_ninja |