mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-10 14:57:52 +00:00
Update .travis.yml
Add build job with libtorrent RC_1_2 branch.
This commit is contained in:
parent
78ab0e4ba9
commit
184ac3e473
117
.travis.yml
117
.travis.yml
@ -8,21 +8,20 @@ dist: xenial
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
matrix:
|
matrix:
|
||||||
# Uncomment when Travis upgraded "Ubuntu 12.04 LTS" to a newer version whose repo will have a more up-to-date libtorrent package
|
- libt_branch=RC_1_1 gui=true build_system=qmake
|
||||||
#- lt_branch=dist gui=true
|
- libt_branch=RC_1_1 gui=false build_system=qmake
|
||||||
#- lt_branch=dist gui=false
|
- libt_branch=RC_1_1 gui=true build_system=cmake
|
||||||
- lt_branch=RC_1_0 gui=true build_system=cmake
|
- libt_branch=RC_1_1 gui=false build_system=cmake
|
||||||
- lt_branch=RC_1_0 gui=false build_system=cmake
|
- libt_branch=RC_1_2 gui=true build_system=qmake
|
||||||
- lt_branch=RC_1_0 gui=true build_system=qmake
|
|
||||||
- lt_branch=RC_1_0 gui=false build_system=qmake
|
|
||||||
global:
|
global:
|
||||||
- secure: "OI9CUjj4lTb0HwwIZU5PbECU3hLlAL6KC8KsbwohG8/O3j5fLcnmDsK4Ad9us5cC39sS11Jcd1kDP2qRcCuST/glVNhLkcjKkiQerOfd5nQ/qL4JYfz/1mfP5mdpz9jHKzpLUIG+TXkbSTjP6VVmsb5KPT+3pKEdRFZB+Pu9+J8="
|
- secure: "OI9CUjj4lTb0HwwIZU5PbECU3hLlAL6KC8KsbwohG8/O3j5fLcnmDsK4Ad9us5cC39sS11Jcd1kDP2qRcCuST/glVNhLkcjKkiQerOfd5nQ/qL4JYfz/1mfP5mdpz9jHKzpLUIG+TXkbSTjP6VVmsb5KPT+3pKEdRFZB+Pu9+J8="
|
||||||
- coverity_branch: coverity_scan
|
- coverity_branch: coverity_scan
|
||||||
|
|
||||||
matrix:
|
matrix:
|
||||||
allow_failures:
|
allow_failures:
|
||||||
- env: lt_branch=RC_1_0 gui=true build_system=cmake
|
- env: libt_branch=RC_1_1 gui=true build_system=cmake
|
||||||
- env: lt_branch=RC_1_0 gui=false build_system=cmake
|
- env: libt_branch=RC_1_1 gui=false build_system=cmake
|
||||||
|
- env: libt_branch=RC_1_2 gui=true build_system=qmake
|
||||||
|
|
||||||
branches:
|
branches:
|
||||||
except:
|
except:
|
||||||
@ -44,7 +43,7 @@ addons:
|
|||||||
project:
|
project:
|
||||||
name: "qbittorrent/qBittorrent"
|
name: "qbittorrent/qBittorrent"
|
||||||
description: "Build submitted via Travis CI"
|
description: "Build submitted via Travis CI"
|
||||||
build_command_prepend: "./bootstrap.sh && ./configure $qbtconf"
|
build_command_prepend: "./bootstrap.sh && ./configure $qmake_conf"
|
||||||
build_command: make
|
build_command: make
|
||||||
branch_pattern: $coverity_branch
|
branch_pattern: $coverity_branch
|
||||||
notification_email: sledgehammer999@qbittorrent.org
|
notification_email: sledgehammer999@qbittorrent.org
|
||||||
@ -55,69 +54,71 @@ addons:
|
|||||||
packages:
|
packages:
|
||||||
# packages list: https://github.com/travis-ci/apt-package-safelist/blob/master/ubuntu-trusty
|
# packages list: https://github.com/travis-ci/apt-package-safelist/blob/master/ubuntu-trusty
|
||||||
- [autoconf, automake, colormake]
|
- [autoconf, automake, colormake]
|
||||||
- [ninja-build]
|
|
||||||
- libssl-dev
|
|
||||||
- [libboost-dev, libboost-system-dev]
|
- [libboost-dev, libboost-system-dev]
|
||||||
|
- libssl-dev
|
||||||
- libtorrent-rasterbar-dev
|
- libtorrent-rasterbar-dev
|
||||||
- [qtbase5-dev, qttools5-dev-tools, libqt5svg5-dev]
|
- [qtbase5-dev, qttools5-dev-tools, libqt5svg5-dev]
|
||||||
|
- zlib1g-dev
|
||||||
|
homebrew:
|
||||||
|
update: true
|
||||||
|
packages:
|
||||||
|
- [ccache, colormake]
|
||||||
|
- boost
|
||||||
|
- libtorrent-rasterbar
|
||||||
|
- openssl
|
||||||
|
- qt
|
||||||
|
- zlib
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
# only allow specific build for coverity scan, others will stop
|
# only allow specific build for coverity scan, others will stop
|
||||||
- if [ "$TRAVIS_BRANCH" = "$coverity_branch" ] && ! [ "$TRAVIS_OS_NAME" = "linux" -a "$lt_branch" = "RC_1_0" -a "$gui" = true -a "$build_system" = "qmake" ]; then exit ; fi
|
- if [ "$TRAVIS_BRANCH" = "$coverity_branch" ] && ! [ "$TRAVIS_OS_NAME" = "linux" -a "$libt_branch" = "RC_1_1" -a "$gui" = "true" -a "$build_system" = "qmake" ]; then exit ; fi
|
||||||
|
|
||||||
- shopt -s expand_aliases
|
- shopt -s expand_aliases
|
||||||
- alias make="colormake -j2" # Using nprocs/2 sometimes may fail (gcc is killed by system)
|
- alias make="colormake -j2" # Using nprocs/2 sometimes may fail (gcc is killed by system)
|
||||||
- qbt_path="$HOME/qbt_install"
|
- qbt_path="$HOME/qbt_install"
|
||||||
- |
|
- qmake_conf="$qmake_conf --prefix=$qbt_path"
|
||||||
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
|
- cmake_conf="$cmake_conf -DCMAKE_INSTALL_PREFIX=$qbt_path"
|
||||||
qbtconf="$qbtconf --prefix="$qbt_path" PKG_CONFIG_PATH=/opt/qt55/lib/pkgconfig:$PKG_CONFIG_PATH"
|
|
||||||
else
|
|
||||||
qbtconf="$qbtconf --prefix="$qbt_path" PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig:$PKG_CONFIG_PATH"
|
|
||||||
CXXFLAGS="$CXXFLAGS -Wno-unused-local-typedefs -Wno-inconsistent-missing-override"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# options for specific branches
|
# options for specific branches
|
||||||
- if [ "$gui" = false ]; then qbtconf="$qbtconf --disable-gui" ; fi
|
|
||||||
- |
|
- |
|
||||||
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
|
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
|
||||||
# setup virtual display for after_success target
|
# setup virtual display for after_success target
|
||||||
if [ "$gui" = true ]; then export "DISPLAY=:99.0" && /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16 ; fi ;
|
if [ "$gui" = "true" ]; then export "DISPLAY=:99.0" && /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16 ; fi ;
|
||||||
|
fi
|
||||||
|
- |
|
||||||
|
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||||
|
CXXFLAGS="$CXXFLAGS -Wno-unused-local-typedefs -Wno-inconsistent-missing-override"
|
||||||
|
|
||||||
|
openssl_root_path="/usr/local/opt/openssl"
|
||||||
|
qmake_conf="$qmake_conf PKG_CONFIG_PATH=$openssl_root_path/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||||
|
cmake_conf="$cmake_conf -DOPENSSL_ROOT_DIR=$openssl_root_path"
|
||||||
|
fi
|
||||||
|
- |
|
||||||
|
if [ "$gui" = "false" ]; then
|
||||||
|
qmake_conf="$qmake_conf --disable-gui"
|
||||||
|
cmake_conf="$cmake_conf -DCMAKE_DISABLE_FIND_PACKAGE_Qt5Widgets=ON"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# print settings
|
# print settings
|
||||||
- echo $lt_branch
|
- echo $libt_branch
|
||||||
- echo $gui
|
- echo $gui
|
||||||
- echo $build_system
|
- echo $build_system
|
||||||
- echo $ltconf
|
- echo $qmake_conf
|
||||||
- echo $qbtconf
|
- echo $cmake_conf
|
||||||
|
|
||||||
install:
|
install:
|
||||||
#- |
|
|
||||||
#if [ "$TRAVIS_OS_NAME" = "linux" ]; then
|
|
||||||
# build libtorrent from source
|
|
||||||
#if [ "$lt_branch" != "dist" ]; then
|
|
||||||
#cd "$HOME" && pwd && git clone --depth 1 https://github.com/arvidn/libtorrent.git --branch $lt_branch
|
|
||||||
#cd libtorrent && ./autotool.sh && ./configure $ltconf && make install
|
|
||||||
#fi
|
|
||||||
#fi
|
|
||||||
- |
|
- |
|
||||||
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||||
# dependencies
|
# dependencies
|
||||||
brew update > /dev/null
|
|
||||||
brew outdated "pkg-config" || brew upgrade "pkg-config"
|
|
||||||
brew install colormake ccache zlib qt openssl libtorrent-rasterbar
|
|
||||||
|
|
||||||
PATH="/usr/local/opt/ccache/libexec:$PATH"
|
PATH="/usr/local/opt/ccache/libexec:$PATH"
|
||||||
brew link --force zlib qt
|
|
||||||
|
brew outdated cmake || brew upgrade cmake
|
||||||
|
brew outdated pkg-config || brew upgrade pkg-config
|
||||||
|
brew link --force qt zlib
|
||||||
|
|
||||||
if [ "$build_system" = "cmake" ]; then
|
if [ "$build_system" = "cmake" ]; then
|
||||||
brew outdated cmake || brew upgrade cmake
|
|
||||||
brew install ninja
|
|
||||||
|
|
||||||
sudo ln -s /usr/local/opt/qt/mkspecs /usr/local/mkspecs
|
sudo ln -s /usr/local/opt/qt/mkspecs /usr/local/mkspecs
|
||||||
sudo ln -s /usr/local/opt/qt/plugins /usr/local/plugins
|
sudo ln -s /usr/local/opt/qt/plugins /usr/local/plugins
|
||||||
|
|
||||||
MY_CMAKE_OPENSSL_HINT="-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl/"
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
- |
|
- |
|
||||||
@ -126,29 +127,31 @@ install:
|
|||||||
ccache -M 512M
|
ccache -M 512M
|
||||||
ccache -V && ccache --show-stats && ccache --zero-stats
|
ccache -V && ccache --show-stats && ccache --zero-stats
|
||||||
fi
|
fi
|
||||||
|
- |
|
||||||
|
# build libtorrent from source
|
||||||
|
if [ "$libt_branch" = "RC_1_2" ]; then
|
||||||
|
cd "$HOME"
|
||||||
|
git clone --depth 1 https://github.com/arvidn/libtorrent.git --branch $libt_branch
|
||||||
|
cd libtorrent && mkdir _build && cd _build
|
||||||
|
CXXFLAGS="$CXXFLAGS -std=c++14" cmake -Ddeprecated-functions=OFF -DOPENSSL_ROOT_DIR="$openssl_root_path" ../
|
||||||
|
make && sudo make install
|
||||||
|
fi
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- if [ "$TRAVIS_BRANCH" = "$coverity_branch" ]; then exit ; fi # skip usual build when running coverity scan
|
- if [ "$TRAVIS_BRANCH" = "$coverity_branch" ]; then exit ; fi # skip usual build when running coverity scan
|
||||||
- |
|
- |
|
||||||
cd "$TRAVIS_BUILD_DIR"
|
cd "$TRAVIS_BUILD_DIR"
|
||||||
if [ "$build_system" = "cmake" ]; then
|
|
||||||
mkdir build
|
|
||||||
cd build
|
|
||||||
if [ "$gui" = "false" ]; then
|
|
||||||
DISABLE_GUI_OPTION="-DCMAKE_DISABLE_FIND_PACKAGE_Qt5Widgets=ON"
|
|
||||||
fi
|
|
||||||
cmake $DISABLE_GUI_OPTION -DCMAKE_INSTALL_PREFIX="$qbt_path" "$MY_CMAKE_OPENSSL_HINT" \
|
|
||||||
-G "Ninja" -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE ..
|
|
||||||
BUILD_TOOL="ninja"
|
|
||||||
fi
|
|
||||||
if [ "$build_system" = "qmake" ]; then
|
if [ "$build_system" = "qmake" ]; then
|
||||||
./bootstrap.sh && ./configure $qbtconf CXXFLAGS="$CXXFLAGS"
|
./bootstrap.sh
|
||||||
BUILD_TOOL="make"
|
./configure $qmake_conf CXXFLAGS="$CXXFLAGS"
|
||||||
|
else
|
||||||
|
mkdir build && cd build
|
||||||
|
cmake $cmake_conf ../
|
||||||
fi
|
fi
|
||||||
- $BUILD_TOOL && $BUILD_TOOL install
|
- make && make install
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- if [ "$gui" = true ]; then qbt_exe="qbittorrent" ; else qbt_exe="qbittorrent-nox" ; fi
|
- if [ "$gui" = "true" ]; then qbt_exe="qbittorrent" ; else qbt_exe="qbittorrent-nox" ; fi
|
||||||
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then cd "$qbt_path/bin" ; fi
|
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then cd "$qbt_path/bin" ; fi
|
||||||
- |
|
- |
|
||||||
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user