Skip to content

Commit 465015d

Browse files
committed
Another try.
1 parent b565dab commit 465015d

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

.github/workflows/cmake-sdl2.yml

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,12 +92,13 @@ jobs:
9292
libpng-dev \
9393
libjpeg-dev \
9494
libtiff-dev \
95-
libwebp-dev
95+
libwebp-dev \
96+
libavif-dev
9697
9798
- name: Install Dependencies on macOS
9899
if: matrix.os == 'macos-latest'
99100
run: |
100-
brew install libpng jpeg libtiff webp
101+
brew install libpng jpeg libtiff webp libavif libimageio
101102
102103
- name: Configure SDL with CMake on Linux (x86_64)
103104
if: matrix.os == 'linux' || matrix.os == 'ubuntu-latest'
@@ -123,6 +124,17 @@ jobs:
123124
cmake --build ./build --config Release
124125
cmake --install ./build --config Release --prefix ./install
125126
127+
- name: SDL2Find workaround on unix based OS.
128+
if: runner.os != 'Windows'
129+
run: |
130+
# hide SDL2Config.cmake so find_package(SDL2) uses FindSDL2.cmake module
131+
SDL2_CFG_DIR="SDLImage/SDL/install/lib/cmake/SDL2"
132+
if [ -d "$SDL2_CFG_DIR" ]; then
133+
for f in "$SDL2_CFG_DIR"/SDL2Config*.cmake; do
134+
mv "$f" "${f}.disabled"
135+
done
136+
fi
137+
126138
- name: Install NASM
127139
if: runner.os == 'Windows'
128140
run: choco install nasm
@@ -148,6 +160,11 @@ jobs:
148160
- name: Build SDLImage
149161
run: cmake --build SDLImage/build --config Release
150162

163+
- name: Move Windows binaries
164+
if: matrix.os == 'windows-latest'
165+
run: |
166+
mv SDLImage/build/Release/*.dll SDLImage/build/
167+
151168
- name: Upload Artifacts
152169
uses: actions/upload-artifact@v4.3.4
153170
with:

0 commit comments

Comments
 (0)