Adrian Brandemuehl | 2ed7435 | 2017-08-23 20:29:57 -0700 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | set -e |
Brian Silverman | 1e5cc02 | 2018-02-03 22:59:48 -0500 | [diff] [blame] | 3 | set -x |
Adrian Brandemuehl | 2ed7435 | 2017-08-23 20:29:57 -0700 | [diff] [blame] | 4 | |
Austin Schuh | 47d8bef | 2020-08-26 21:54:38 -0700 | [diff] [blame] | 5 | # No need to pass this through. It hurts caching. |
| 6 | unset SSH_AUTH_SOCK |
| 7 | |
Austin Schuh | 168524c | 2020-12-27 22:43:42 -0800 | [diff] [blame] | 8 | if [ -n ${BUILDKITE+x} ]; then |
| 9 | buildkite-agent pipeline upload tools/ci/buildkite.yaml |
| 10 | exit 0 |
| 11 | fi |
| 12 | |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 13 | readonly TARGETS='//... @com_github_google_glog//... @com_google_ceres_solver//...' |
Austin Schuh | de82171 | 2019-08-03 18:16:49 -0700 | [diff] [blame] | 14 | readonly M4F_TARGETS='//...' |
James Kuszmaul | baa897a | 2020-12-12 18:17:34 -0800 | [diff] [blame] | 15 | # Sanity check that we are able to build the y2020 roborio code, which confirms |
| 16 | # that we have the platform compatibility for the roborio set up correctly. |
| 17 | readonly ROBORIO_TARGETS="${TARGETS} //y2020:download_stripped" |
Austin Schuh | d7208ba | 2020-12-27 22:43:03 -0800 | [diff] [blame] | 18 | # Stay up forever and use inotify to find changes quickly |
| 19 | readonly STARTUP='--max_idle_secs=0 --watchfs' |
| 20 | readonly COMMON='-c opt --stamp=no --curses=no --color=no --symlink_prefix=/ --disk_cache=~/.cache/bazel/disk_cache/' |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 21 | |
James Kuszmaul | 27da814 | 2019-07-21 16:13:55 -0700 | [diff] [blame] | 22 | # Put everything in different output bases so we can get 5 bazel servers |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 23 | # running and keep them all warm. |
Austin Schuh | 10358f2 | 2019-01-21 20:25:11 -0800 | [diff] [blame] | 24 | |
James Kuszmaul | 2af1ba8 | 2019-02-09 22:16:53 -0800 | [diff] [blame] | 25 | # Include --config=eigen to enable Eigen assertions so that we catch potential |
| 26 | # bugs with Eigen. |
Austin Schuh | d7208ba | 2020-12-27 22:43:03 -0800 | [diff] [blame] | 27 | tools/bazel ${STARTUP} --output_base=../k8_output_base test \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 28 | ${COMMON} \ |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 29 | --config=k8 \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 30 | --config=eigen \ |
| 31 | ${TARGETS} |
| 32 | |
Austin Schuh | d7208ba | 2020-12-27 22:43:03 -0800 | [diff] [blame] | 33 | tools/bazel ${STARTUP} --output_base=../roborio_output_base build \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 34 | ${COMMON} \ |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 35 | --config=roborio \ |
James Kuszmaul | baa897a | 2020-12-12 18:17:34 -0800 | [diff] [blame] | 36 | ${ROBORIO_TARGETS} |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 37 | |
Austin Schuh | d7208ba | 2020-12-27 22:43:03 -0800 | [diff] [blame] | 38 | tools/bazel ${STARTUP} --output_base=../armhf-debian_output_base build \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 39 | ${COMMON} \ |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 40 | --config=armhf-debian \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 41 | ${TARGETS} |
| 42 | |
Austin Schuh | d7208ba | 2020-12-27 22:43:03 -0800 | [diff] [blame] | 43 | tools/bazel ${STARTUP} --output_base=../cortex-m4f_output_base build \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 44 | ${COMMON} \ |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 45 | --config=cortex-m4f \ |
Austin Schuh | 96c7fe4 | 2019-02-18 11:37:49 -0800 | [diff] [blame] | 46 | ${M4F_TARGETS} |