mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-21 16:40:18 +00:00
CI Linux: cache built SDL
This commit is contained in:
30
.github/scripts/Linux/download_build_sdl.sh
vendored
Executable file
30
.github/scripts/Linux/download_build_sdl.sh
vendored
Executable file
@@ -0,0 +1,30 @@
|
||||
#!/bin/sh -eu
|
||||
|
||||
mkdir -p /var/tmp/sdl
|
||||
cd /var/tmp/sdl
|
||||
|
||||
# v2.0.22 requires wayland-client version 1.18.0 but in U18.04 is only 1.16.0
|
||||
curl -sSLO https://github.com/libsdl-org/SDL/releases/download/release-2.0.20/SDL2-2.0.20.tar.gz
|
||||
tar xaf SDL2*tar*
|
||||
cd SDL2-2.0.20
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
sudo make install # SDL needs to be installed here because it is a dependency for the below
|
||||
cd ..
|
||||
|
||||
git clone --depth 1 https://github.com/libsdl-org/SDL_mixer
|
||||
cd SDL_mixer
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
sudo make install
|
||||
cd ..
|
||||
|
||||
# v2.0.18 and further require automake 1.16 but U18.04 has only automake 1.15.1
|
||||
git clone -b release-2.0.15 --depth 1 https://github.com/libsdl-org/SDL_ttf
|
||||
cd SDL_ttf
|
||||
./autogen.sh # to allow automake 1.15.1
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
sudo make install
|
||||
cd ..
|
||||
|
||||
28
.github/scripts/Linux/install_sdl.sh
vendored
28
.github/scripts/Linux/install_sdl.sh
vendored
@@ -1,27 +1,9 @@
|
||||
#!/bin/sh -eu
|
||||
|
||||
sudo aptitude -y build-dep libsdl2 libsdl2-mixer libsdl2-ttf libsdl2-dev:
|
||||
# v2.0.22 requires wayland-client version 1.18.0 but in U18.04 is only 1.16.0
|
||||
curl -sSLO https://github.com/libsdl-org/SDL/releases/download/release-2.0.20/SDL2-2.0.20.tar.gz
|
||||
tar xaf SDL2*tar*
|
||||
cd SDL2-2.0.20
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
cd /var/tmp/sdl/SDL2-2.0.20
|
||||
sudo make install
|
||||
cd ../SDL_mixer
|
||||
sudo make install
|
||||
cd ../SDL_ttf
|
||||
sudo make install
|
||||
cd ..
|
||||
|
||||
git clone --depth 1 https://github.com/libsdl-org/SDL_mixer
|
||||
cd SDL_mixer
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
sudo make install
|
||||
cd ..
|
||||
|
||||
# v2.0.18 and further require automake 1.16 but U18.04 has only automake 1.15.1
|
||||
git clone -b release-2.0.15 --depth 1 https://github.com/libsdl-org/SDL_ttf
|
||||
cd SDL_ttf
|
||||
./autogen.sh # to allow automake 1.15.1
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
sudo make install
|
||||
cd ..
|
||||
|
||||
2
.github/scripts/Linux/prepare.sh
vendored
2
.github/scripts/Linux/prepare.sh
vendored
@@ -26,7 +26,7 @@ sudo apt install libcurl4-nss-dev
|
||||
sudo apt install i965-va-driver-shaders # instead of i965-va-driver
|
||||
sudo apt install uuid-dev # Cineform
|
||||
|
||||
"$GITHUB_WORKSPACE/.github/scripts/Linux/install_sdl.sh"
|
||||
sudo aptitude -y build-dep libsdl2 libsdl2-mixer libsdl2-ttf libsdl2-dev:
|
||||
"$GITHUB_WORKSPACE/.github/scripts/Linux/ffmpeg_deps.sh"
|
||||
|
||||
# Install cross-platform deps
|
||||
|
||||
12
.github/workflows/ccpp.yml
vendored
12
.github/workflows/ccpp.yml
vendored
@@ -104,6 +104,18 @@ jobs:
|
||||
- name: Install Cached FFmpeg
|
||||
if: steps.cache-ffmpeg.outputs.cache-hit == 'true'
|
||||
run: .github/scripts/Linux/install_ffmpeg.sh
|
||||
- name: Cache SDL
|
||||
id: cache-sdl
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: '/var/tmp/sdl'
|
||||
key: cache-sdl-${{ runner.os }}-${{ hashFiles( '.github/scripts/Linux/download_build_sdl.sh' ) }}
|
||||
- name: Build SDL
|
||||
if: steps.cache-sdl.outputs.cache-hit != 'true'
|
||||
run: .github/scripts/Linux/download_build_sdl.sh
|
||||
- name: Install Cached SDL
|
||||
if: steps.cache-sdl.outputs.cache-hit == 'true'
|
||||
run: .github/scripts/Linux/install_sdl.sh
|
||||
- name: configure
|
||||
run: "./autogen.sh --enable-plugins ${{ env.CUDA_FEATURES }} ${{ env.FEATURES }} --enable-alsa --enable-v4l2 --enable-vulkan=auto || { RC=$?; cat config.log; exit $RC; }"
|
||||
- name: make
|
||||
|
||||
Reference in New Issue
Block a user