git: 33c8125b3e1b - 2021Q4 - games/scummvm: Unbreak build with FLUIDSYNTH=on
Kai Knoblich
kai at FreeBSD.org
Mon Oct 4 09:23:12 UTC 2021
The branch 2021Q4 has been updated by kai:
URL: https://cgit.FreeBSD.org/ports/commit/?id=33c8125b3e1b83ad681f340c1bbf0005e5b0ccae
commit 33c8125b3e1b83ad681f340c1bbf0005e5b0ccae
Author: Kai Knoblich <kai at FreeBSD.org>
AuthorDate: 2021-10-04 09:14:03 +0000
Commit: Kai Knoblich <kai at FreeBSD.org>
CommitDate: 2021-10-04 09:22:24 +0000
games/scummvm: Unbreak build with FLUIDSYNTH=on
After commit 4c2db26adf7d the build, if the non-default option
FLUIDSYNTH is enabled, fails with:
In file included from audio/softsynth/fluidsynth.cpp:32:
In file included from /usr/local/include/fluidsynth.h:100:
[..]
audio/softsynth/fluidsynth.cpp:252:3: error:
no matching function for call to 'fluid_sfloader_set_callbacks'
fluid_sfloader_set_callbacks(soundFontMemoryLoader,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/fluidsynth/sfont.h:172:20: note:
candidate function not viable:
no known conversion from 'int (void *, int, void *)' to
'fluid_sfloader_callback_read_t' (aka 'int (*)(void *, long long, void *)') for 3rd argument
FLUIDSYNTH_API int fluid_sfloader_set_callbacks(fluid_sfloader_t *loader,
^
Obtained from: NetBSD
MFH: 2021Q4
(cherry picked from commit 05a45a5e50775e34b7c949ee3c6607dbb004b3a1)
---
.../files/patch-audio_softsynth_fluidsynth.cpp | 31 ++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/games/scummvm/files/patch-audio_softsynth_fluidsynth.cpp b/games/scummvm/files/patch-audio_softsynth_fluidsynth.cpp
new file mode 100644
index 000000000000..e538d47910b4
--- /dev/null
+++ b/games/scummvm/files/patch-audio_softsynth_fluidsynth.cpp
@@ -0,0 +1,31 @@
+Fix build with FluidSynth >= 2.2.0
+
+Obtained from:
+
+https://github.com/NetBSD/pkgsrc/commit/25b35d66ba06339121f9ed19cc0a307a7b61dfc9
+
+--- audio/softsynth/fluidsynth.cpp.orig 2020-09-13 21:05:37 UTC
++++ audio/softsynth/fluidsynth.cpp
+@@ -144,11 +144,11 @@ static void *SoundFontMemLoader_open(const char *filen
+ return p;
+ }
+
+-static int SoundFontMemLoader_read(void *buf, int count, void *handle) {
++static int SoundFontMemLoader_read(void *buf, long long count, void *handle) {
+ return ((Common::SeekableReadStream *) handle)->read(buf, count) == (uint32)count ? FLUID_OK : FLUID_FAILED;
+ }
+
+-static int SoundFontMemLoader_seek(void *handle, long offset, int origin) {
++static int SoundFontMemLoader_seek(void *handle, long long offset, int origin) {
+ return ((Common::SeekableReadStream *) handle)->seek(offset, origin) ? FLUID_OK : FLUID_FAILED;
+ }
+
+@@ -157,7 +157,7 @@ static int SoundFontMemLoader_close(void *handle) {
+ return FLUID_OK;
+ }
+
+-static long SoundFontMemLoader_tell(void *handle) {
++static long long SoundFontMemLoader_tell(void *handle) {
+ return ((Common::SeekableReadStream *) handle)->pos();
+ }
+ #endif
More information about the dev-commits-ports-all
mailing list