From e7336c4e8cc27c91e399617f8a873869bd3ba99b Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Thu, 28 Mar 2024 16:01:19 +0200 Subject: [PATCH] aedi: patch fluidsynth sf3 support detection of sndfile vorbis/mpeg support is a bit broken right now * native target doesn't detect it because of missing flac symbols, can be fixes with `-lFLAC` linker option * cross-compiled target doesn't detect it even with the given linker option --- aedi/target/library_tier2.py | 3 ++- patch/fluidsynth-sf3-support.diff | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 patch/fluidsynth-sf3-support.diff diff --git a/aedi/target/library_tier2.py b/aedi/target/library_tier2.py index c6c36144..4ca6c485 100644 --- a/aedi/target/library_tier2.py +++ b/aedi/target/library_tier2.py @@ -55,7 +55,8 @@ class FluidSynthTarget(base.CMakeStaticDependencyTarget): def prepare_source(self, state: BuildState): state.download_source( 'https://github.com/FluidSynth/fluidsynth/archive/refs/tags/v2.3.5.tar.gz', - 'f89e8e983ecfb4a5b4f5d8c2b9157ed18d15ed2e36246fa782f18abaea550e0d') + 'f89e8e983ecfb4a5b4f5d8c2b9157ed18d15ed2e36246fa782f18abaea550e0d', + patches='fluidsynth-sf3-support') def configure(self, state: BuildState): opts = state.options diff --git a/patch/fluidsynth-sf3-support.diff b/patch/fluidsynth-sf3-support.diff new file mode 100644 index 00000000..b71ab00e --- /dev/null +++ b/patch/fluidsynth-sf3-support.diff @@ -0,0 +1,11 @@ +--- a/cmake_admin/FindSndFile.cmake ++++ b/cmake_admin/FindSndFile.cmake +@@ -70,7 +70,7 @@ + + # Check the features SndFile was built with + # 2024-01-02: Recent versions of libsndfile don't seem to provide a pkgconfig file and older version who did are lacking private libraries like OGG. +-if(FALSE) #PC_SNDFILE_FOUND ++if(TRUE) #PC_SNDFILE_FOUND + if("vorbis" IN_LIST PC_SNDFILE_STATIC_LIBRARIES) + set(SndFile_WITH_EXTERNAL_LIBS TRUE) + endif()