Merge pull request #194 from google/travis

Add basic Travis-CI support.
This commit is contained in:
FrankGalligan 2017-09-08 08:22:17 -07:00 committed by GitHub
commit 5da5579bc1
2 changed files with 39 additions and 1 deletions

38
.travis.yml Normal file
View File

@ -0,0 +1,38 @@
cache: ccache
language: cpp
matrix:
include:
- os: linux
dist: trusty
compiler: clang
- os: linux
dist: trusty
compiler: gcc
- os: osx
osx_image: xcode8.3
compiler: clang
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- ccache
- cmake
before_install:
- if [[ "${TRAVIS_OS_NAME}" == "osx" ]]; then brew install ccache; fi
script:
# Output version info for compilers, cmake, and make
- ${CC} -v
- ${CXX} -v
- cmake --version
- make --version
# Clone googletest
- pushd .. && git clone https://github.com/google/googletest.git && popd
# Configure and build
- mkdir _travis_build && cd _travis_build
- cmake -G "Unix Makefiles" -DENABLE_TESTS=ON -DENABLE_CCACHE=ON ..
- make -j
- ./draco_tests

View File

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5)
cmake_minimum_required(VERSION 3.2)
project(draco C CXX)
set(draco_root "${CMAKE_CURRENT_SOURCE_DIR}")