File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1010 steps :
1111 - uses : actions/checkout@v4
1212 - name : Install build tools
13- run : sudo apt-get update && sudo apt-get install -y cmake ninja-build build-essential
13+ run : >-
14+ sudo apt-get update --allow-releaseinfo-change &&
15+ sudo apt-get install -y
16+ cmake ninja-build build-essential git pkg-config
17+ libasound2-dev libpulse-dev libudev-dev libx11-dev libxext-dev
18+ libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxtst-dev
19+ libwayland-dev libxkbcommon-dev libdrm-dev libgbm-dev
20+ libegl1-mesa-dev libgl1-mesa-dev
21+ libflac-dev libogg-dev libvorbis-dev libmpg123-dev libopusfile-dev
22+ libxmp-dev
23+ - name : Build SDL3
24+ run : |
25+ mkdir -p /tmp/sdl3
26+ cd /tmp/sdl3
27+ git clone --depth 1 --branch release-3.4.0 https://github.com/libsdl-org/SDL.git
28+ cmake -S SDL -B SDL/build -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local
29+ cmake --build SDL/build
30+ sudo cmake --install SDL/build
31+ - name : Build SDL3_mixer
32+ run : |
33+ mkdir -p /tmp/sdl3
34+ cd /tmp/sdl3
35+ git clone --depth 1 https://github.com/libsdl-org/SDL_mixer.git
36+ cmake -S SDL_mixer -B SDL_mixer/build -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local -DSDLMIXER_VENDORED=OFF -DSDLMIXER_MOD_XMP=ON -DSDLMIXER_MOD_XMP_LITE=OFF -DSDLMIXER_MOD_XMP_SHARED=OFF
37+ cmake --build SDL_mixer/build
38+ sudo cmake --install SDL_mixer/build
1439 - name : Configure
1540 run : cmake -S . -B build -G Ninja
1641 - name : Build
Original file line number Diff line number Diff line change @@ -125,7 +125,6 @@ target_include_directories(openfodder PRIVATE
125125 ${CMAKE_CURRENT_BINARY_DIR } /Source )
126126
127127target_compile_definitions (openfodder PRIVATE
128- SDL_ENABLE_OLD_NAMES
129128 UNICODE
130129 _UNICODE
131130 _USE_MATH_DEFINES )
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ class cSound_Amiga : public cSound {
4444
4545 SDL_AudioSpec mAudioSpec ;
4646 SDL_AudioStream* mAudioStream ;
47- SDL_mutex * mLock ;
47+ SDL_Mutex * mLock ;
4848
4949 std::vector<Audio::AudioStream*> mCurrentSfx ;
5050
Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ cSurface::~cSurface() {
7676
7777void cSurface::clearSDLSurface ( uint32 pColor ) {
7878
79- SDL_FillRect ( mSDLSurface , 0 , pColor );
79+ SDL_FillSurfaceRect ( mSDLSurface , nullptr , pColor);
8080}
8181
8282void cSurface::palette_SetToBlack () {
Original file line number Diff line number Diff line change @@ -446,8 +446,8 @@ bool cWindow::isResized() const {
446446 * Is either mouse button currently pressed
447447 */
448448bool cWindow::isMouseButtonPressed_Global () const {
449- return (SDL_GetMouseState (NULL , NULL ) & SDL_BUTTON (SDL_BUTTON_LEFT )) ||
450- (SDL_GetMouseState (NULL , NULL ) & SDL_BUTTON (SDL_BUTTON_RIGHT ));
449+ return (SDL_GetMouseState (NULL , NULL ) & SDL_BUTTON_MASK (SDL_BUTTON_LEFT )) ||
450+ (SDL_GetMouseState (NULL , NULL ) & SDL_BUTTON_MASK (SDL_BUTTON_RIGHT ));
451451}
452452
453453/* *
You can’t perform that action at this time.
0 commit comments