diff --git a/.travis.yml b/.travis.yml index ad5d948ff2..0eadf5e3cc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,29 +1,39 @@ -# Linux Build Configuration for Travis - language: cpp os: - linux # Use Ubuntu 14.04 LTS (Trusty) as the Linux testing environment. -sudo: required dist: trusty +sudo: false -env: - # Each line is a set of environment variables set before a build. - # Thus each line represents a different build configuration. - - BUILD_TYPE=Release - - BUILD_TYPE=Debug +git: + depth: false + +addons: + apt: + sources: + - llvm-toolchain-trusty + - ubuntu-toolchain-r-test + packages: + - llvm-7-tools + - llvm-7-dev + - python3 compiler: - gcc - clang -# To avoid Go bindings related issues in LIT tests, hide Go binaries from CMake -install: - - rm -f `which go` +env: + - BUILD_TYPE=Release + - BUILD_TYPE=Debug script: - mkdir build && cd build - - cmake -D CMAKE_VERBOSE_MAKEFILE:BOOL=OFF -D CMAKE_COLOR_MAKEFILE:BOOL=ON -D LLVM_INCLUDE_EXAMPLES:BOOL=OFF -D LLVM_INCLUDE_TESTS:BOOL=ON -D LLVM_BUILD_TESTS:BOOL=ON -D LLVM_TARGETS_TO_BUILD="X86" -D LLVM_LIT_ARGS:STRING="-sv --no-progress-bar" -G "Unix Makefiles" -D CMAKE_BUILD_TYPE:STRING=${BUILD_TYPE} .. - - make check-llvm -j 2 + - cmake .. + -DCMAKE_COLOR_MAKEFILE=ON + -DCMAKE_BUILD_TYPE=${BUILD_TYPE} + -DLLVM_EXTERNAL_LIT="/usr/lib/llvm-7/build/utils/lit/lit.py" + -DCMAKE_INSTALL_PREFIX=../install/ + -G "Unix Makefiles" + - make && make test && make install