aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGennadiy Civil <gennadiycivil@users.noreply.github.com>2019-02-05 12:12:38 -0500
committerGitHub <noreply@github.com>2019-02-05 12:12:38 -0500
commit9a502a5b14b4a6160103c1f2c64331772878d86a (patch)
treea1ea429164c5eec3c10480228b5ab00bfc375101
parente28b50609e7886fbc2873c44bf0d2819fdf1d6fd (diff)
parent9df5475b8267e3b6e485bcb55febd208149e96af (diff)
downloadgoogletest-9a502a5b14b4a6160103c1f2c64331772878d86a.tar.gz
googletest-9a502a5b14b4a6160103c1f2c64331772878d86a.tar.bz2
googletest-9a502a5b14b4a6160103c1f2c64331772878d86a.zip
Merge pull request #2100 from ngie-eign/test-clang-osx-every-travis-run
Test out changes with clang/OSX each PR using Travis CI
-rw-r--r--.travis.yml9
-rwxr-xr-xci/env-osx.sh8
-rwxr-xr-xci/install-osx.sh3
3 files changed, 17 insertions, 3 deletions
diff --git a/.travis.yml b/.travis.yml
index b11fc641..4b90bd06 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -48,8 +48,8 @@ matrix:
compiler: gcc
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS=-std=c++11 HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp
- os: osx
+ compiler: clang
env: BUILD_TYPE=Release VERBOSE=1 CXX_FLAGS=-std=c++11 HOMEBREW_LOGS=~/homebrew-logs HOMEBREW_TEMP=~/homebrew-temp
- if: type != pull_request
# These are the install and build (script) phases for the most common entries in the matrix. They could be included
# in each entry in the matrix, but that is just repetitive.
@@ -73,6 +73,13 @@ addons:
packages:
- g++-4.9
- clang-3.9
+ update: true
+ homebrew:
+ packages:
+ - ccache
+ - gcc@4.9
+ - llvm@3.9
+ update: true
notifications:
email: false
diff --git a/ci/env-osx.sh b/ci/env-osx.sh
index 03c2d15d..9c421e14 100755
--- a/ci/env-osx.sh
+++ b/ci/env-osx.sh
@@ -37,5 +37,11 @@
#
if [ "${TRAVIS_OS_NAME}" = "osx" ]; then
- if [ "$CXX" = "clang++" ]; then export CXX="clang++-3.9" CC="clang-3.9"; fi
+ if [ "$CXX" = "clang++" ]; then
+ # $PATH needs to be adjusted because the llvm tap doesn't install the
+ # package to /usr/local/bin, etc, like the gcc tap does.
+ # See: https://github.com/Homebrew/legacy-homebrew/issues/29733
+ clang_version=3.9
+ export PATH="/usr/local/opt/llvm@${clang_version}/bin:$PATH";
+ fi
fi
diff --git a/ci/install-osx.sh b/ci/install-osx.sh
index 6550ff51..f2baebd2 100755
--- a/ci/install-osx.sh
+++ b/ci/install-osx.sh
@@ -36,4 +36,5 @@ if [ "${TRAVIS_OS_NAME}" != "osx" ]; then
exit 0
fi
-brew install ccache
+brew update
+brew install ccache gcc@4.9 llvm@3.9