language: r
r: bioc-devel
sudo: required

r_packages:
  - devtools
  - knitr
  - XML
  - plyr
  - doParallel
  - foreach
  - iterators

addons:
  apt:
    packages:
    - libnetcdf-dev
    - netcdf-bin

# Set CXX1X for R-devel, as R-devel does not detect CXX1X support for gcc 4.6.3,
# Thanks to jimhester pointing this out!
before_install:
  - if [[ "$TRAVIS_R_VERSION_STRING" = 'bioc-devel' ]]; then mkdir ~/.R && echo 'CXX1X=g++ -std=c++0x -g -O2 -fPIC' > ~/.R/Makevars; fi
  - curl -OL http://raw.github.com/craigcitro/r-travis/master/scripts/travis-tool.sh
  - chmod 755 ./travis-tool.sh
  - ./travis-tool.sh bootstrap

## Work around timeout, following 
## https://github.com/craigcitro/r-travis/wiki

script:
  - travis_wait ./travis-tool.sh run_tests