From 0b9c77102746980463386d0443a6fcf708e4be5c Mon Sep 17 00:00:00 2001 From: Rafael Kitover Date: Sat, 31 Aug 2019 23:46:25 +0000 Subject: [PATCH] travis: more ubuntu dists, fix mac cache Include xenial and bionic in the travis build matrix, alongside trusty. In `installdeps` check for the existance of `libswresample-dev` before installing it because trusty does not have it, it uses libav instead of ffmpeg. For this reason, ffmpeg is not built on trusty. Turn off the `xvfb-run` test on bionic and xenial because it fails for some reason. Use `-DENABLE_FFMPEG=OFF` for xenial because the ffmpeg code currently fails to compile with that version. Stop trying to cache `/usr/local` for the mac build, storing the build archive takes longer than installing the homebrew packages. Signed-off-by: Rafael Kitover --- .travis.yml | 36 ++++++++++++++++++++++++++++++++++-- installdeps | 5 ++++- 2 files changed, 38 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index c3e77ba6..84b00b9b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,7 +7,40 @@ services: matrix: fast_finish: true include: - - env: BUILD_ENV=ubuntu + - env: BUILD_ENV=ubuntu-bionic + language: cpp + os: linux + dist: bionic + before_script: + - ./installdeps + script: + - mkdir build + - cd build + - cmake .. -DENABLE_SDL=ON + - make -j2 +# xvfb fails on bionic for some reason +# - xvfb-run ./visualboyadvance-m --help + cache: + directories: + - "$HOME/.ccache" + - env: BUILD_ENV=ubuntu-xenial + language: cpp + os: linux + dist: xenial + before_script: + - ./installdeps + script: + - mkdir build + - cd build +# ffmpeg currently broken on xenial + - cmake .. -DENABLE_SDL=ON -DENABLE_FFMPEG=OFF + - make -j2 +# xvfb fails on xenial too +# - xvfb-run ./visualboyadvance-m --help + cache: + directories: + - "$HOME/.ccache" + - env: BUILD_ENV=ubuntu-trusty language: cpp os: linux dist: trusty @@ -78,7 +111,6 @@ matrix: cache: directories: - "$HOME/.ccache" - - /usr/local notifications: webhooks: diff --git a/installdeps b/installdeps index 13051fc2..8e1f4f65 100755 --- a/installdeps +++ b/installdeps @@ -302,7 +302,10 @@ debian_installdeps() { glew_lib=$(apt-cache search libglew | grep '^libglew[0-9]' | sed 's/ - .*//') - check sudo apt-get -qy install build-essential g++ nasm cmake ccache gettext zlib1g-dev libgl1-mesa-dev libavcodec-dev libavformat-dev libswscale-dev libavutil-dev libgettextpo-dev libpng-dev libsdl2-dev libsdl2-2.0 libglu1-mesa-dev libglu1-mesa libgles2-mesa-dev libsfml-dev $sfml_libs $glew_lib libopenal-dev libwxgtk3.0-dev libwxgtk3.0 libgtk2.0-dev libgtk-3-dev ccache zip + # not present in trusty + libswresample_dev=$(apt-cache search libswresample-dev | awk '{print $1}') + + check sudo apt-get -qy install build-essential g++ nasm cmake ccache gettext zlib1g-dev libgl1-mesa-dev libavcodec-dev libavformat-dev libswscale-dev libavutil-dev $libswresample_dev libgettextpo-dev libpng-dev libsdl2-dev libsdl2-2.0 libglu1-mesa-dev libglu1-mesa libgles2-mesa-dev libsfml-dev $sfml_libs $glew_lib libopenal-dev libwxgtk3.0-dev libwxgtk3.0 libgtk2.0-dev libgtk-3-dev ccache zip else case "$target" in mingw-w64-i686)