blob: 7ca660f91921129640f0a2f6593ef21d0ad77e98 [file] [log] [blame]
Davide Pesavento0bd37312017-08-20 20:21:13 -04001#!/usr/bin/env bash
2set -e
3
4JDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
5source "$JDIR"/util.sh
6
7set -x
8
9if has OSX $NODE_LABELS; then
Ashlesh Gawanded88c1df2017-12-01 10:14:11 -060010 FORMULAE=(boost pkg-config log4cxx openssl)
Davide Pesavento0bd37312017-08-20 20:21:13 -040011 brew update
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[@]}"
22 brew link --force log4cxx
23 brew cleanup
24fi
25
26if has Ubuntu $NODE_LABELS; then
27 sudo apt-get -qq update
28 sudo apt-get -qy install build-essential pkg-config libboost-all-dev \
Ashlesh Gawanded88c1df2017-12-01 10:14:11 -060029 libsqlite3-dev libssl-dev liblog4cxx10-dev
Davide Pesavento0bd37312017-08-20 20:21:13 -040030
31 if [[ $JOB_NAME == *"code-coverage" ]]; then
32 sudo apt-get -qy install lcov libgd-perl python-setuptools
33 sudo easy_install --upgrade gcovr
34 fi
35fi