forked from stan-dev/rstan
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
57 lines (47 loc) · 1.79 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
cache: apt
language: cpp
compiler:
- gcc
- clang
env:
global:
- R_LIBS_USER=~/personal_library
matrix:
- CXX_OLEVEL=0
- CXX_OLEVEL=3
matrix:
allow_failures:
- env: CXX_OLEVEL=0
- compiler: clang
install:
- sudo add-apt-repository "deb http://cran.rstudio.com/bin/linux/ubuntu `lsb_release -cs`/"
- sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E084DAB9
- sudo apt-get update
- sudo apt-get install r-base-dev qpdf texinfo texlive-latex-extra texlive-fonts-recommended texlive-fonts-extra ccache
- ccache --max-size 8G
- "[ ! -d ~/$R_LIBS_USER ] && mkdir $R_LIBS_USER"
- R --version
- R -e '.libPaths(); sessionInfo()'
# - Rscript -e 'install.packages(c("Rcpp", "coda", "inline", "RUnit"), dep = !TRUE, repos = "http://cran.rstudio.org")'
before_script:
- cd stan && git fetch && git checkout origin/develop && cd ..
- echo "CXX = ccache `R CMD config CXX`" >> ./rstan/R_Makevars
- echo "CXXFLAGS = `R CMD config CXXFLAGS`" >> ./rstan/R_Makevars
- export CLANG_EXTRA_ARG=""
- if [[ $CXX = "clang++" ]] ; then export CLANG_EXTRA_ARG=" -Qunused-arguments -fcolor-diagnostics " ; fi
- sed -i "s/g++/${CXX}${CLANG_EXTRA_ARG}/" ./rstan/R_Makevars
- sed -i "s/O[0-3]/O$CXX_OLEVEL/" ./rstan/R_Makevars
- more ./rstan/R_Makevars
- mkdir -p ~/.R/
- cat ./rstan/R_Makevars > ~/.R/Makevars
- more ~/.R/Makevars
notifications:
email:
# recipients:
# - stan-buildbot@googlegroups.com
on_success: change
on_failure: always
script:
- cd rstan && make install_pre_rpkg && make build NOTBUILD=true && R CMD INSTALL rstan --no-docs --no-html && git clean -f -x && make build BUILD_OPTS="--no-build-vignettes --no-manual" && make install && make check && cd tests && R -q -f runRunitTests.R
after_script:
- ccache -s