Alexander Afanasyev | 4d4e725 | 2014-10-25 12:21:53 -0700 | [diff] [blame] | 1 | #!/usr/bin/env bash |
| 2 | set -x |
| 3 | set -e |
| 4 | |
| 5 | git submodule init |
| 6 | git submodule sync |
| 7 | git submodule update |
| 8 | |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 9 | # Cleanup |
| 10 | sudo ./waf -j1 --color=yes distclean |
Alexander Afanasyev | 4d4e725 | 2014-10-25 12:21:53 -0700 | [diff] [blame] | 11 | |
Alexander Afanasyev | 6602b3b | 2016-03-15 14:14:11 -0700 | [diff] [blame] | 12 | if [[ "$JOB_NAME" != *"limited-build" ]]; then |
| 13 | # Configure/build in optimized mode with tests and precompiled headers |
| 14 | ./waf -j1 --color=yes configure --with-tests |
| 15 | ./waf -j1 --color=yes build |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 16 | |
Alexander Afanasyev | 6602b3b | 2016-03-15 14:14:11 -0700 | [diff] [blame] | 17 | # Cleanup |
| 18 | sudo ./waf -j1 --color=yes distclean |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 19 | |
Alexander Afanasyev | 6602b3b | 2016-03-15 14:14:11 -0700 | [diff] [blame] | 20 | # Configure/build in optimized mode without tests and with precompiled headers |
| 21 | ./waf -j1 --color=yes configure |
| 22 | ./waf -j1 --color=yes build |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 23 | |
Alexander Afanasyev | 6602b3b | 2016-03-15 14:14:11 -0700 | [diff] [blame] | 24 | # Cleanup |
| 25 | sudo ./waf -j1 --color=yes distclean |
| 26 | fi |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 27 | |
Alexander Afanasyev | f22ebaf | 2015-12-17 21:23:05 -0800 | [diff] [blame] | 28 | # Configure/build in debug mode |
| 29 | if [[ "$JOB_NAME" == *"code-coverage" ]]; then |
| 30 | COVERAGE="--with-coverage" |
| 31 | fi |
| 32 | ./waf -j1 --color=yes configure --debug --with-tests --without-pch $COVERAGE |
Davide Pesavento | ab1e8f2 | 2014-10-21 22:45:33 +0200 | [diff] [blame] | 33 | ./waf -j1 --color=yes build |
| 34 | |
Alexander Afanasyev | f22ebaf | 2015-12-17 21:23:05 -0800 | [diff] [blame] | 35 | # (tests will be run against debug version) |
Alexander Afanasyev | 4d4e725 | 2014-10-25 12:21:53 -0700 | [diff] [blame] | 36 | |
| 37 | # Install |
| 38 | sudo ./waf -j1 --color=yes install |