summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2018-02-20 15:36:10 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2018-02-20 15:36:11 +0900
commit47030f9abe0ed076af6465569939740f6a36b1d4 (patch)
treeab392f0da688aceaa708410bb4890cc2787a3291
parentaf8cbfe5151604cd33ad3d6594b108d2937388b8 (diff)
downloadre2-47030f9abe0ed076af6465569939740f6a36b1d4.tar.gz
re2-47030f9abe0ed076af6465569939740f6a36b1d4.tar.bz2
re2-47030f9abe0ed076af6465569939740f6a36b1d4.zip
Imported Upstream version 20170801upstream/20170801
Change-Id: Ifd67eb92502db3e23c10856b1cfca20c95031fe4 Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
-rw-r--r--.travis.yml117
-rw-r--r--CMakeLists.txt3
2 files changed, 120 insertions, 0 deletions
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 0000000..8c9acca
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,117 @@
+language: cpp
+sudo: false
+dist: trusty
+script:
+ - make
+ - make test
+matrix:
+ include:
+
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-4.8
+ env:
+ - MATRIX_EVAL="CC=gcc-4.8 CXX=g++-4.8"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-4.9
+ env:
+ - MATRIX_EVAL="CC=gcc-4.9 CXX=g++-4.9"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-5
+ env:
+ - MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-6
+ env:
+ - MATRIX_EVAL="CC=gcc-6 CXX=g++-6"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-7
+ env:
+ - MATRIX_EVAL="CC=gcc-7 CXX=g++-7"
+
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ - llvm-toolchain-precise-3.5
+ packages:
+ - clang-3.5
+ env:
+ - MATRIX_EVAL="CC=clang-3.5 CXX=clang++-3.5"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ - llvm-toolchain-precise-3.6
+ packages:
+ - clang-3.6
+ env:
+ - MATRIX_EVAL="CC=clang-3.6 CXX=clang++-3.6"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ - llvm-toolchain-precise-3.7
+ packages:
+ - clang-3.7
+ env:
+ - MATRIX_EVAL="CC=clang-3.7 CXX=clang++-3.7"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ - llvm-toolchain-precise-3.8
+ packages:
+ - clang-3.8
+ env:
+ - MATRIX_EVAL="CC=clang-3.8 CXX=clang++-3.8"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ - llvm-toolchain-precise-3.9
+ packages:
+ - clang-3.9
+ env:
+ - MATRIX_EVAL="CC=clang-3.9 CXX=clang++-3.9"
+ - os: linux
+ addons:
+ apt:
+ sources:
+ - llvm-toolchain-trusty-4.0
+ packages:
+ - clang-4.0
+ env:
+ - MATRIX_EVAL="CC=clang-4.0 CXX=clang++-4.0"
+
+before_install:
+ - eval "${MATRIX_EVAL}"
diff --git a/CMakeLists.txt b/CMakeLists.txt
index dd302a4..3e22472 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -29,6 +29,9 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
# CMake defaults to /W3, but some users like /W4 (or /Wall) and /WX,
# so we disable various warnings that aren't particularly helpful.
add_compile_options(/wd4100 /wd4201 /wd4456 /wd4457 /wd4702 /wd4815)
+elseif(CYGWIN OR MINGW)
+ # See https://stackoverflow.com/questions/38139631 for details.
+ add_compile_options(-std=gnu++11)
elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
add_compile_options(-std=c++11)
endif()