NOISSUE force travis.ci to use precise, fix ppa for Qt

This commit is contained in:
Petr Mrázek 2017-09-25 09:29:54 +02:00
parent f8c5cee982
commit a269e0c92f
2 changed files with 29 additions and 26 deletions

View File

@ -2,29 +2,28 @@
language: cpp language: cpp
cache: apt cache: apt
# Build matrix set up
compiler:
- gcc
# - clang
os:
- linux
# - osx
env:
- QT_VERSION=5.4.2
- QT_VERSION=5.5.1
# - QT_VERSION=5.6.2
matrix: matrix:
exclude: include:
# only use clang on OS X - os: linux
- os: osx dist: precise
sudo: required
compiler: gcc compiler: gcc
# only use the qt available from homebrew env: TRAVIS_DIST=precise QT_VERSION=5.4.2
- os: osx - os: linux
env: QT_VERSION=5.4.2 dist: precise
- os: osx sudo: required
env: QT_VERSION=5.5.1 compiler: gcc
# - os: osx env: TRAVIS_DIST=precise QT_VERSION=5.6.2
# env: QT_VERSION=5.6 - os: linux
dist: trusty
sudo: required
compiler: gcc
env: TRAVIS_DIST=trusty QT_VERSION=5.4.2
- os: linux
dist: trusty
sudo: required
compiler: gcc
env: TRAVIS_DIST=trusty QT_VERSION=5.6.2
# Install dependencies # Install dependencies
install: install:

View File

@ -9,16 +9,20 @@ then
echo $QT_WITHOUT_DOTS echo $QT_WITHOUT_DOTS
echo $QT_PKG_PREFIX echo $QT_PKG_PREFIX
echo $QT_PKG_INSTALL echo $QT_PKG_INSTALL
if [ "$TRAVIS_DIST" = "precise" ]; then
sudo add-apt-repository -y ppa:beineri/opt-${QT_WITHOUT_DOTS} sudo add-apt-repository -y ppa:beineri/opt-${QT_WITHOUT_DOTS}
else
sudo add-apt-repository -y ppa:beineri/opt-${QT_WITHOUT_DOTS}-$TRAVIS_DIST
fi
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test # for a recent GCC sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test # for a recent GCC
sudo add-apt-repository "deb http://llvm.org/apt/precise/ llvm-toolchain-precise-3.5 main" sudo add-apt-repository "deb http://llvm.org/apt/${TRAVIS_DIST}/ llvm-toolchain-${TRAVIS_DIST}-3.5 main"
sudo apt-get update -qq sudo apt-get update -qq
sudo apt-get install ${QT_PKG_PREFIX}base ${QT_PKG_PREFIX}svg ${QT_PKG_PREFIX}tools ${QT_PKG_PREFIX}webkit sudo apt-get install ${QT_PKG_PREFIX}base ${QT_PKG_PREFIX}svg ${QT_PKG_PREFIX}tools
sudo mkdir -p /opt/cmake-3/ sudo mkdir -p /opt/cmake-3/
wget --no-check-certificate http://www.cmake.org/files/v3.2/cmake-3.2.2-Linux-x86_64.sh wget --no-check-certificate http://www.cmake.org/files/v3.9/cmake-3.9.3-Linux-x86_64.sh
sudo sh cmake-3.2.2-Linux-x86_64.sh --skip-license --prefix=/opt/cmake-3/ sudo sh cmake-3.9.3-Linux-x86_64.sh --skip-license --prefix=/opt/cmake-3/
export CMAKE_PREFIX_PATH=/opt/$QT_PKG_INSTALL/lib/cmake export CMAKE_PREFIX_PATH=/opt/$QT_PKG_INSTALL/lib/cmake
export PATH=/opt/cmake-3/bin:/opt/$QT_PKG_INSTALL/bin:$PATH export PATH=/opt/cmake-3/bin:/opt/$QT_PKG_INSTALL/bin:$PATH