Install python3 in Travis MacOS

For some reason, `homebrew install gcovr` now install python3 as
dependency.
This is a dependency since a long time, I don't know why it was not
installing it before.

But the installation fails because it cannot link correctly python3
because python2 is already installed.

Then meson, when it tries to run the conversion script, fails because
the script cannot find python3.

The solution I've found is to unlink python2 and relink python3 to have
a correct installation of python3.
This commit is contained in:
Matthieu Gautier 2020-01-09 10:08:47 +01:00
parent 071e9e3fec
commit 02a0d592f9
1 changed files with 1 additions and 0 deletions

View File

@ -4,6 +4,7 @@ sudo: true
cache: ccache cache: ccache
before_install: before_install:
- PATH=$PATH:$HOME/bin - PATH=$PATH:$HOME/bin
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew unlink python@2; brew link --overwrite python@3; fi
install: travis/install_deps.sh install: travis/install_deps.sh
script: travis/compile.sh script: travis/compile.sh
env: env: