You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/dev-python/pygame_sdl2/files/pygame_sdl2-6.99.12.4-mixer...

44 lines
1.5 KiB

From ced6051f4a4559a725804cc58c079e1efea0a573 Mon Sep 17 00:00:00 2001
From: Markus Koschany <apo@debian.org>
Date: Sat, 11 Nov 2017 23:00:25 +0100
Subject: [PATCH] Fix build failure due to the removal of MIX_INIT_MODPLUG and
the replacement of
MIX_INIT_FLUIDSYNTH with MIX_INIT_MID.
---
include/sdl2_mixer.pxd | 3 +--
src/pygame_sdl2/mixer.pyx | 4 ++--
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/include/sdl2_mixer.pxd b/include/sdl2_mixer.pxd
index 0cea395..4bb0187 100644
--- a/include/sdl2_mixer.pxd
+++ b/include/sdl2_mixer.pxd
@@ -18,10 +18,9 @@ cdef extern from "SDL_mixer.h" nogil:
ctypedef enum MIX_InitFlags:
MIX_INIT_FLAC
MIX_INIT_MOD
- MIX_INIT_MODPLUG
MIX_INIT_MP3
MIX_INIT_OGG
- MIX_INIT_FLUIDSYNTH
+ MIX_INIT_MID
int Mix_Init(int flags)
void Mix_Quit()
diff --git a/src/pygame_sdl2/mixer.pyx b/src/pygame_sdl2/mixer.pyx
index 3c5e185..bea5cbf 100644
--- a/src/pygame_sdl2/mixer.pyx
+++ b/src/pygame_sdl2/mixer.pyx
@@ -81,8 +81,8 @@ def init(frequency=22050, size=MIX_DEFAULT_FORMAT, channels=2, buffer=4096):
if get_init() is not None:
return
- for flag in (MIX_INIT_FLAC, MIX_INIT_MOD, MIX_INIT_MODPLUG,
- MIX_INIT_MP3, MIX_INIT_OGG, MIX_INIT_FLUIDSYNTH):
+ for flag in (MIX_INIT_FLAC, MIX_INIT_MOD,
+ MIX_INIT_MP3, MIX_INIT_OGG, MIX_INIT_MID):
if Mix_Init(flag) != flag:
errors.append("{}\n".format(SDL_GetError()))