[Pkg-sdl-commits] [libsdl2-mixer] 01/04: Use better quality sounds than those of freepats
Manuel A. Fernandez Montecelo
mafm at moszumanska.debian.org
Fri Oct 24 23:51:06 UTC 2014
This is an automated email from the git hooks/post-receive script.
mafm pushed a commit to branch master
in repository libsdl2-mixer.
commit 0dbe040a9014caa41266f8845998d669aae63050
Author: Manuel A. Fernandez Montecelo <mafm at debian.org>
Date: Sat Oct 25 00:18:48 2014 +0100
Use better quality sounds than those of freepats
* Copy patch bug-715461-soundfont_paths.patch from sdl-mixer1.2 to use
better quality sounds than those of freepats. Thanks Fabian Greffrath
(Closes: #766019)
---
debian/changelog | 8 ++++
debian/control | 2 +-
debian/patches/bug-715461-soundfont_paths.patch | 49 +++++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 2 +
5 files changed, 61 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index bf55d0c..a49d7ba 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+libsdl2-mixer (2.0.0+dfsg1-4) UNRELEASED; urgency=medium
+
+ * Copy patch bug-715461-soundfont_paths.patch from sdl-mixer1.2 to use
+ better quality sounds than those of freepats. Thanks Fabian Greffrath
+ (Closes: #766019)
+
+ -- Manuel A. Fernandez Montecelo <mafm at debian.org> Sat, 25 Oct 2014 00:11:40 +0100
+
libsdl2-mixer (2.0.0+dfsg1-3) unstable; urgency=low
* Bump Policy Standards-Version to 3.9.5 (no changes needed)
diff --git a/debian/control b/debian/control
index 05f3a3e..8621880 100644
--- a/debian/control
+++ b/debian/control
@@ -25,7 +25,7 @@ Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends: ${shlibs:Depends},
${misc:Depends}
-Recommends: freepats
+Recommends: musescore-soundfont-gm | fluid-soundfont-gm | freepats
Description: Mixer library for Simple DirectMedia Layer 2, libraries
SDL_mixer is a sample multi-channel audio mixer library. It supports any
number of simultaneously playing channels of 16 bit stereo audio, plus a single
diff --git a/debian/patches/bug-715461-soundfont_paths.patch b/debian/patches/bug-715461-soundfont_paths.patch
new file mode 100644
index 0000000..c871aab
--- /dev/null
+++ b/debian/patches/bug-715461-soundfont_paths.patch
@@ -0,0 +1,49 @@
+Description: no sf2 sound fonts loaded by default
+ Introduced in 1.2.12-6 (Thu, 11 Jul 2013 12:17:15 +0100)
+Author: Fabian Greffrath <fabian at greffrath.com>
+Last-Update: 2013-10-09
+Bug-Debian: http://bugs.debian.org/715461
+--- a/mixer.c
++++ b/mixer.c
+@@ -148,6 +148,11 @@
+ {
+ int result = 0;
+
++#ifdef MIX_INIT_SOUNDFONT_PATHS
++ if (!soundfont_paths)
++ soundfont_paths = SDL_strdup(MIX_INIT_SOUNDFONT_PATHS);
++#endif
++
+ if (flags & MIX_INIT_FLUIDSYNTH) {
+ #ifdef USE_FLUIDSYNTH_MIDI
+ if ((initialized & MIX_INIT_FLUIDSYNTH) || Mix_InitFluidSynth() == 0) {
+--- a/music.c
++++ b/music.c
+@@ -1567,6 +1567,7 @@
+ {
+ char *context, *path, *paths;
+ const char* cpaths = Mix_GetSoundFonts();
++ int soundfonts_found = 0;
+
+ if (!cpaths) {
+ Mix_SetError("No SoundFonts have been requested");
+@@ -1586,12 +1587,16 @@
+ for (path = strtok_r(paths, ":;", &context); path; path = strtok_r(NULL, ":;", &context)) {
+ #endif
+ if (!function(path, data)) {
+- SDL_free(paths);
+- return 0;
++ continue;
++ } else {
++ soundfonts_found++;
+ }
+ }
+
+ SDL_free(paths);
+- return 1;
++ if (soundfonts_found > 0)
++ return 1;
++ else
++ return 0;
+ }
+ #endif
diff --git a/debian/patches/series b/debian/patches/series
index e69de29..05533f2 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -0,0 +1 @@
+bug-715461-soundfont_paths.patch
diff --git a/debian/rules b/debian/rules
index 0e9f679..ce2cd78 100755
--- a/debian/rules
+++ b/debian/rules
@@ -6,6 +6,8 @@
MODPLUG_INCLUDE_DIR := -I/usr/include/libmodplug
export DEB_CFLAGS_MAINT_APPEND := -pipe -Wall $(MODPLUG_INCLUDE_DIR)
+# bug #715461, provide default soundfont paths
+export DEB_CPPFLAGS_MAINT_APPEND := -DMIX_INIT_SOUNDFONT_PATHS=\"/usr/share/sounds/sf2/TimGM6mb.sf2:/usr/share/sounds/sf2/FluidR3_GM.sf2\"
export DEB_LDFLAGS_MAINT_APPEND := -Wl,--as-needed
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-sdl/packages/libsdl2-mixer.git
More information about the pkg-sdl-commits
mailing list