language: cpp
compiler:
  - gcc
  - clang

sudo: required
dist: trusty

before_install:
  # Add repositories
  - sudo add-apt-repository -y 'deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-3.8 main'
  - wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
  - sudo apt-get update -qq

  # Install Clang + LLVM
  - sudo apt-get install -y llvm-3.8-dev libclang-3.8-dev clang-3.8
  - sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-3.8 20
  - sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-3.8 20
  - sudo rm /usr/local/clang-3.5.0/bin/clang
  - sudo rm /usr/local/clang-3.5.0/bin/clang++

  # Other dependencies
  - sudo apt-get install -y libedit-dev

script:
  - cmake . -DLLVM_DIR=/usr/lib/llvm-3.8/share/llvm/cmake/
  - make -j 2
  - make test

language: cpp
compiler:
  - gcc
  - clang

sudo: required
dist: trusty

before_install:
  # Add repositories
  - sudo add-apt-repository -y 'deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-3.9 main'
  - wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
  - sudo apt-get update -qq

  # Remove existing LLVM
  - sudo apt-get remove llvm

  # Install Clang + LLVM
  - sudo apt-get install -y llvm-3.9-dev libclang-3.9-dev clang-3.9
  - sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-3.9 20
  - sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-3.9 20
  - sudo rm /usr/local/clang-3.5.0/bin/clang
  - sudo rm /usr/local/clang-3.5.0/bin/clang++

  # Other dependencies
  - sudo apt-get install -y libedit-dev

script:
  - cmake . -DLLVM_DIR=/usr/lib/llvm-3.9/lib/cmake/llvm
  - make -j 2
  - make test

Update Travis to LLVM 3.9 to fix CI
Update Travis to LLVM 3.9 to fix CI
