-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Add CMake to Travis CI config #2392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
22a9111
a8f50e8
08935bb
7a2afc8
651cfe6
82ac066
560815e
609e49d
bc8725f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,7 +7,12 @@ language: c++ | |
| # TODO(2019-07-21): Add "ffmpeg=1" if FFmpeg 4.x becomes available in Ubuntu | ||
| env: | ||
| global: | ||
| - COMMON_FLAGS="-j4 test=1 mad=1 faad=1 opus=1 modplug=1 wv=1 hss1394=0 virtualize=0 debug_assertions_fatal=1 verbose=0" | ||
| # For SCons builds | ||
| - SCONSFLAGS="test=1 mad=1 faad=1 opus=1 modplug=1 wv=1 hss1394=0 virtualize=0 debug_assertions_fatal=1 verbose=0" | ||
| # For CMake builds | ||
| - CMAKEFLAGS="-DMAD=ON -DFAAD=ON -DOPUS=ON -DMODPLUG=ON -DWAVPACK=ON -DHSS1394=OFF" | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. FAAD2 should be disabled for macOS builds, both for SCons and CMake. I see errors to load the corresponding dynamic library at runtime during the tests. We could move the corresponding options into the platform-dependent EXTRA flags.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. But we install faad2 via homebrew, strange. |
||
| - GTEST_COLOR=1 | ||
| - CTEST_OUTPUT_ON_FAILURE=1 | ||
|
|
||
| jobs: | ||
| include: | ||
|
|
@@ -27,23 +32,51 @@ jobs: | |
| - python3-setuptools | ||
| - python3-wheel | ||
|
|
||
| - name: Ubuntu/gcc build | ||
| - name: Ubuntu/gcc/SCons build | ||
| os: linux | ||
| dist: xenial | ||
| compiler: gcc | ||
| # Ubuntu Xenial build prerequisites | ||
| env: EXTRA_FLAGS="localecompare=1" | ||
| before_install: | ||
| - sudo apt-get install -y scons | ||
| install: | ||
| - scons $COMMON_FLAGS $EXTRA_FLAGS | ||
| - scons -j "$(nproc)" localecompare=1 | ||
| script: | ||
| # NOTE(sblaisot): 2018-01-02 removing gdb wrapper on linux due to a bug in | ||
| # return code in order to avoid having a successful build when a test fail. | ||
| # https://bugs.launchpad.net/mixxx/+bug/1699689 | ||
| - ./mixxx-test | ||
|
|
||
| - name: OSX/clang build | ||
| - name: Ubuntu/gcc/CMake build | ||
| os: linux | ||
| dist: xenial | ||
| compiler: gcc | ||
| cache: ccache | ||
| # Ubuntu Xenial build prerequisites | ||
| env: CMAKEFLAGS_EXTRA="-DLOCALECOMPARE=ON" | ||
| before_install: | ||
| - sudo apt-get install -y cmake | ||
| - export CMAKE_BUILD_PARALLEL_LEVEL="$(nproc)" | ||
| - cmake --version | ||
| - ccache -s | ||
| install: | ||
| - mkdir cmake_build | ||
| - cd cmake_build | ||
| - cmake -L $CMAKEFLAGS $CMAKEFLAGS_EXTRA .. | ||
| - cmake --build . | ||
| - sudo cmake --build . --target install | ||
| script: | ||
| # Run tests and benchmarks | ||
| - cmake --build . --target test | ||
| - cmake --build . --target benchmark | ||
|
|
||
| - name: OSX/clang/SCons build | ||
| os: osx | ||
| compiler: clang | ||
| cache: | ||
| directories: | ||
| - $HOME/Library/Caches/Homebrew | ||
| - /usr/local/Homebrew | ||
| # Workaround for bug in libopus's opus.h including <opus_multistream.h> | ||
| # instead of <opus/opus_multistream.h>. | ||
| # Virtual X (Xvfb) is needed for analyzer waveform tests | ||
|
|
@@ -52,14 +85,63 @@ jobs: | |
| CXXFLAGS="-isystem /usr/local/include/opus" | ||
| DISPLAY=:99.0 | ||
| before_install: | ||
| - brew install scons | ||
| - export QTDIR="$(find /usr/local/Cellar/qt -d 1 | tail -n 1)" | ||
| - echo "QTDIR=$QTDIR" | ||
| install: | ||
| - scons $COMMON_FLAGS $EXTRA_FLAGS | ||
| # We are hardcoding 4 threads here since "$(sysctl -n hw.ncpu)" only | ||
| # returns 2 and makes the travis job run into a timeout: | ||
| # https://docs.travis-ci.com/user/reference/overview/#virtualization-environments | ||
| - scons -j4 | ||
| script: | ||
| # lldb doesn't provide an easy way to exit 1 on error: | ||
| # https://bugs.llvm.org/show_bug.cgi?id=27326 | ||
| - lldb ./mixxx-test --batch -o run -o quit -k 'thread backtrace all' -k "script import os; os._exit(1)" | ||
| before_cache: | ||
| # Avoid indefinite cache growth | ||
| - brew cleanup | ||
| # Cache only .git files under "/usr/local/Homebrew" so "brew update" | ||
| # does not take 5min every build | ||
| # Source: https://discourse.brew.sh/t/best-practice-for-homebrew-on-travis-brew-update-is-5min-to-build-time/5215/12 | ||
| - find /usr/local/Homebrew \! -regex ".+\.git.+" -delete | ||
|
|
||
| - name: OSX/clang/CMake build | ||
| os: osx | ||
| compiler: clang | ||
| cache: | ||
| ccache: true | ||
| directories: | ||
| - $HOME/Library/Caches/Homebrew | ||
| - /usr/local/Homebrew | ||
| # Workaround for bug in libopus's opus.h including <opus_multistream.h> | ||
| # instead of <opus/opus_multistream.h>. | ||
| # Virtual X (Xvfb) is needed for analyzer waveform tests | ||
| env: >- | ||
| CMAKEFLAGS_EXTRA="-DLOCALECOMPARE=OFF -DCMAKE_PREFIX_PATH=/usr/local/opt/qt5/" | ||
| DISPLAY=:99.0 | ||
| CMAKE_BUILD_PARALLEL_LEVEL=4 | ||
| before_install: | ||
| - brew install ccache | ||
| - export PATH="/usr/local/opt/ccache/bin:$PATH" | ||
| - cmake --version | ||
| - ccache -s | ||
| install: | ||
| - mkdir cmake_build | ||
| - cd cmake_build | ||
| - cmake -L $CMAKEFLAGS $CMAKEFLAGS_EXTRA .. | ||
| - cmake --build . | ||
| - sudo cmake --build . --target install | ||
| script: | ||
| # Run tests and benchmarks | ||
| - cmake --build . --target test | ||
| - cmake --build . --target benchmark | ||
| before_cache: | ||
| # Avoid indefinite cache growth | ||
| - brew cleanup | ||
| # Cache only .git files under "/usr/local/Homebrew" so "brew update" | ||
| # does not take 5min every build | ||
| # Source: https://discourse.brew.sh/t/best-practice-for-homebrew-on-travis-brew-update-is-5min-to-build-time/5215/12 | ||
| - find /usr/local/Homebrew \! -regex ".+\.git.+" -delete | ||
|
|
||
| git: | ||
| depth: 1 | ||
|
|
@@ -105,7 +187,6 @@ addons: | |
| - qt5-default | ||
| - qtscript5-dev | ||
| - qt5keychain-dev | ||
| - scons | ||
| homebrew: | ||
| update: true | ||
| packages: | ||
|
|
@@ -129,7 +210,6 @@ addons: | |
| - protobuf | ||
| - qt5 | ||
| - rubberband | ||
| - scons | ||
| - sound-touch | ||
| - taglib | ||
| - wavpack | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.