diff options
Diffstat (limited to 'chapter8/ninja.sh')
-rw-r--r-- | chapter8/ninja.sh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/chapter8/ninja.sh b/chapter8/ninja.sh new file mode 100644 index 0000000..3f93e56 --- /dev/null +++ b/chapter8/ninja.sh @@ -0,0 +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 |