Alexander Afanasyev | f3192eb | 2016-12-19 17:11:20 -0800 | [diff] [blame] | 1 | #!/usr/bin/env bash |
| 2 | set -e |
| 3 | |
| 4 | JDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) |
| 5 | source "$JDIR"/util.sh |
| 6 | |
| 7 | set -x |
| 8 | |
| 9 | if has OSX $NODE_LABELS; then |
Davide Pesavento | 7ef57e2 | 2017-10-28 16:58:43 -0400 | [diff] [blame^] | 10 | FORMULAE=(boost openssl pkg-config) |
Alexander Afanasyev | f3192eb | 2016-12-19 17:11:20 -0800 | [diff] [blame] | 11 | brew update |
Davide Pesavento | 7ef57e2 | 2017-10-28 16:58:43 -0400 | [diff] [blame^] | 12 | if [[ -n $TRAVIS ]]; then |
| 13 | # travis images come with a large number of brew packages |
| 14 | # pre-installed, don't waste time upgrading all of them |
| 15 | for FORMULA in "${FORMULAE[@]}"; do |
| 16 | brew outdated $FORMULA || brew upgrade $FORMULA |
| 17 | done |
| 18 | else |
| 19 | brew upgrade |
| 20 | fi |
| 21 | brew install "${FORMULAE[@]}" |
Alexander Afanasyev | f3192eb | 2016-12-19 17:11:20 -0800 | [diff] [blame] | 22 | brew cleanup |
| 23 | fi |
| 24 | |
| 25 | if has Ubuntu $NODE_LABELS; then |
| 26 | sudo apt-get -qq update |
Davide Pesavento | 7ef57e2 | 2017-10-28 16:58:43 -0400 | [diff] [blame^] | 27 | sudo apt-get -qy install build-essential pkg-config libboost-all-dev \ |
| 28 | libsqlite3-dev libssl-dev |
Alexander Afanasyev | f3192eb | 2016-12-19 17:11:20 -0800 | [diff] [blame] | 29 | fi |