From 3d3f1ef913b3a6e4f2ba40c1f3c887ed317fcdc7 Mon Sep 17 00:00:00 2001 From: Willy Sudiarto Raharjo Date: Thu, 2 Nov 2017 23:48:47 +0700 Subject: games/dunelegacy: Patched to support SDL2. Signed-off-by: Willy Sudiarto Raharjo Signed-off-by: David Spencer --- games/dunelegacy/SDL2.patch | 22 ++++++++++++++++++++++ games/dunelegacy/dunelegacy.SlackBuild | 5 ++++- 2 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 games/dunelegacy/SDL2.patch (limited to 'games') diff --git a/games/dunelegacy/SDL2.patch b/games/dunelegacy/SDL2.patch new file mode 100644 index 0000000000..d59da935d8 --- /dev/null +++ b/games/dunelegacy/SDL2.patch @@ -0,0 +1,22 @@ +--- dunelegacy-0.96.4/src/FileClasses/music/DirectoryPlayer.cpp.orig 2017-11-02 23:35:12.597820783 +0700 ++++ dunelegacy-0.96.4/src/FileClasses/music/DirectoryPlayer.cpp 2017-11-02 23:35:30.146839251 +0700 +@@ -61,7 +61,7 @@ + + music = nullptr; + +- Mix_Init(MIX_INIT_FLUIDSYNTH | MIX_INIT_FLAC | MIX_INIT_MP3 | MIX_INIT_OGG); ++ Mix_Init(MIX_INIT_MID | MIX_INIT_FLAC | MIX_INIT_MP3 | MIX_INIT_OGG); + } + + DirectoryPlayer::~DirectoryPlayer() { +--- dunelegacy-0.96.4/src/FileClasses/music/XMIPlayer.cpp.orig 2017-11-02 23:40:31.473154207 +0700 ++++ dunelegacy-0.96.4/src/FileClasses/music/XMIPlayer.cpp 2017-11-02 23:40:55.447179102 +0700 +@@ -32,7 +32,7 @@ + XMIPlayer::XMIPlayer() : MusicPlayer(settings.audio.playMusic, settings.audio.musicVolume) { + music = nullptr; + +- if((Mix_Init(MIX_INIT_FLUIDSYNTH) & MIX_INIT_FLUIDSYNTH) == 0) { ++ if((Mix_Init(MIX_INIT_MID) & MIX_INIT_MID) == 0) { + SDL_Log("XMIPlayer: Failed to init required midi support: %s", SDL_GetError()); + } + } diff --git a/games/dunelegacy/dunelegacy.SlackBuild b/games/dunelegacy/dunelegacy.SlackBuild index 337ce69c54..cb3e6c0770 100644 --- a/games/dunelegacy/dunelegacy.SlackBuild +++ b/games/dunelegacy/dunelegacy.SlackBuild @@ -12,7 +12,7 @@ PRGNAM=dunelegacy VERSION=${VERSION:-0.96.4} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -60,6 +60,9 @@ find -L . \ # Use our CFLAGS. Environment is ignored by configure script. sed -i "s/-O3/$SLKCFLAGS/" configure +# Patched to support SDL 2.0.2 +patch -p1 < $CWD/SDL2.patch + ./configure \ --prefix=/usr \ --bindir=/usr/games \ -- cgit v1.2.3