Skip to content
Snippets Groups Projects
Commit c7c25760 authored by Giovanni Bussi's avatar Giovanni Bussi
Browse files

Multi-OS support in travis

I modified extensively the travis file to allow multi-os support
and to use more recent UBUNTU:
- I upgraded most of the tests to UBUNTU trusty (with gcc 4.8)
- For a couple of tests I switch to UBUNTU precise (with gcc 4.6)
  to be sure we keep compatibility with older compilers
- I removed clang tests from UBUNTU and added OSX tests (both serial and MPI)

Since UBUNTU trusty comes with doxygen 1.8.6, I install doxygen 1.8.7
from source. Notice that this was solved in UBUNTU precise by using
an external ppa database. I prefer install from source here
since in this way we can easily upgrade doxygen to use latest features.

[makedoc]
parent e07d01c2
No related branches found
No related tags found
No related merge requests found
language: cpp language: cpp
env: matrix:
include:
# list of configurations to be attempted: # list of configurations to be attempted:
# MPI + doc # MPI + doc
# this is the "master" one, it is going to update the manual if log contains [makedoc] # this is the "master" one, it is going to update the manual if log contains [makedoc]
- PLUMED_CC=mpicc PLUMED_CXX=mpic++ MAKEDOC=yes ALMOST=yes - os: linux
dist: trusty
sudo: required
env: PLUMED_CC=mpicc PLUMED_CXX=mpic++ MAKEDOC=yes ALMOST=yes
# the following are with debug flags # the following are with debug flags
# I think clang does not support debug-glibcxx, so I skip it here - os: linux
- PLUMED_CC=gcc PLUMED_CXX=g++ CONFIG_FLAGS="--enable-debug --enable-debug-glibcxx" dist: trusty
- PLUMED_CC=mpicc PLUMED_CXX=mpic++ CONFIG_FLAGS="--enable-debug --enable-debug-glibcxx" sudo: required
# then I try serial compilers env: PLUMED_CC=gcc PLUMED_CXX=g++ CONFIG_FLAGS="--enable-debug --enable-debug-glibcxx"
- PLUMED_CC=clang PLUMED_CXX=clang++ - os: linux
- PLUMED_CC=gcc PLUMED_CXX=g++ dist: trusty
sudo: required
env: PLUMED_CC=mpicc PLUMED_CXX=mpic++ CONFIG_FLAGS="--enable-debug --enable-debug-glibcxx"
# then check with different optimization flags # then check with different optimization flags
- PLUMED_CC=clang PLUMED_CXX=clang++ PLUMED_CXXFLAGS=-O3 LAPACK=yes - os: linux
- PLUMED_CC=gcc PLUMED_CXX=g++ PLUMED_CXXFLAGS=-O3 LAPACK=yes dist: trusty
sudo: required
env: PLUMED_CC=gcc PLUMED_CXX=g++ PLUMED_CXXFLAGS=-O3 LAPACK=yes
# then I try serial compiler on UBUNTU precise
- os: linux
dist: precise
sudo: required
env: PLUMED_CC=gcc PLUMED_CXX=g++
# test using external blas with internal lapack # test using external blas with internal lapack
- PLUMED_CC=mpicc PLUMED_CXX=mpic++ PLUMED_CXXFLAGS=-O3 LAPACK=yes CONFIG_FLAGS="--disable-external-lapack" - os: linux
dist: trusty
sudo: required
env: PLUMED_CC=mpicc PLUMED_CXX=mpic++ PLUMED_CXXFLAGS=-O3 LAPACK=yes CONFIG_FLAGS="--disable-external-lapack"
# osx serial
- os: osx
env: PLUMED_CC=clang PLUMED_CXX=clang++ PLUMED_CXXFLAGS=-O3
# osx parallel
- os: osx
env: PLUMED_CC=mpicc PLUMED_CXX=mpic++ PLUMED_CXXFLAGS=-O3
# cppcheck # cppcheck
- CPPCHECK=yes - os: linux
sudo: required
env: CPPCHECK=yes
# Possible additional variables: # Possible additional variables:
# VALGRIND=yes to make valgrind tests, only when log contains string [valgrind] # VALGRIND=yes to make valgrind tests, only when log contains string [valgrind]
install: install:
...@@ -32,25 +56,26 @@ install: ...@@ -32,25 +56,26 @@ install:
- ./.travis/check.log makedoc || MAKEDOC=no - ./.travis/check.log makedoc || MAKEDOC=no
- ./.travis/check.log valgrind || VALGRIND=no - ./.travis/check.log valgrind || VALGRIND=no
- ./.travis/check.log almost || ALMOST=no - ./.travis/check.log almost || ALMOST=no
# update packages
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update > /dev/null ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get update -qq ; fi
# install some package - these are fast, we install them anyway # install some package - these are fast, we install them anyway
- sudo apt-get update -qq - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install -y libmatheval-dev ; fi
- sudo apt-get install -y libmatheval-dev
- if test "$PLUMED_CXX" ; then ./.travis/install.xdrfile ; fi - if test "$PLUMED_CXX" ; then ./.travis/install.xdrfile ; fi
# cppcheck: # cppcheck:
- if test "$CPPCHECK" == yes ; then ./.travis/install.cppcheck 1.69 ; fi - if test "$CPPCHECK" == yes ; then ./.travis/install.cppcheck 1.69 ; fi
# installation of these packages takes a lot of time # installation of these packages takes a lot of time
# we do it only when needed # we do it only when needed
- if test "$PLUMED_CXX" == "mpic++" ; then sudo apt-get install -y libopenmpi1.5-dev openmpi1.5-bin ; fi - if test "$PLUMED_CXX" == "mpic++" -a "$TRAVIS_OS_NAME" == "linux" ; then sudo apt-get install -y libopenmpi-dev openmpi-bin ; fi
- if test "$PLUMED_CXX" == "mpic++" -a "$TRAVIS_OS_NAME" == "osx" ; then brew install openmpi ; fi
- if test "$MAKEDOC" == yes ; then sudo apt-get install -y graphviz ; fi - if test "$MAKEDOC" == yes ; then sudo apt-get install -y graphviz ; fi
# doxygen from its repository (apt-get gets an old version) # install doxygen-latex
# - test "$MAKEDOC" == yes && ./.travis/install.doxygen || true - if test "$MAKEDOC" == yes ; then sudo apt-get install -y doxygen-latex ; fi
# it seems that here we can get precompiled doxygen and latex # then replace doxygen with the desided version
- if test "$MAKEDOC" == yes ; then sudo apt-add-repository -y ppa:libreoffice/ppa ; fi - if test "$MAKEDOC" == yes ; then ./.travis/install.doxygen Release_1_8_7 ; fi
- if test "$MAKEDOC" == yes ; then sudo apt-get update -qq ; fi
- if test "$MAKEDOC" == yes ; then sudo apt-get install -y doxygen doxygen-latex ; fi
- if test "$VALGRIND" == yes ; then sudo apt-get install -y valgrind ; fi - if test "$VALGRIND" == yes ; then sudo apt-get install -y valgrind ; fi
- if test "$LAPACK" == yes ; then sudo apt-get install libatlas-base-dev ; fi - if test "$LAPACK" == yes ; then sudo apt-get -y install libatlas-base-dev ; fi
- if test "$ALMOST" == yes ; then sudo apt-get install libatlas-base-dev ; fi - if test "$ALMOST" == yes ; then sudo apt-get -y install libatlas-base-dev ; fi
- if test "$ALMOST" == yes ; then ./.travis/install.almost ; fi - if test "$ALMOST" == yes ; then ./.travis/install.almost ; fi
- if test "$ALMOST" == yes ; then ENALMOST="--enable-almost" ; fi - if test "$ALMOST" == yes ; then ENALMOST="--enable-almost" ; fi
- if test "$ALMOST" == yes ; then PLUMED_CPPFLAGS="-I$HOME/opt/include -I$HOME/opt/include/almost" ; fi - if test "$ALMOST" == yes ; then PLUMED_CPPFLAGS="-I$HOME/opt/include -I$HOME/opt/include/almost" ; fi
......
...@@ -3,13 +3,6 @@ ...@@ -3,13 +3,6 @@
set -e set -e
set -x set -x
sudo apt-get install -y texlive
sudo apt-get install -y texlive-fonts-extra
sudo apt-get install -y latex-xcolor
sudo apt-get install -y texlive-extra-utils
sudo apt-get install -y texlive-font-utils
sudo apt-get install -y texlive-full
git clone https://github.com/doxygen/doxygen.git git clone https://github.com/doxygen/doxygen.git
cd doxygen cd doxygen
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment