mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-10 08:14:09 -09:00
package/fluidsynth: fix download-while-configure since 2.5.7 bump
Since commit
566bdcb97f ("package/fluidsynth:
security bump to version 2.5.7"), fluidsynth tries to download some
"gcem" code during its configure step, which not only violates
Buildroot's policies, but also breaks the build if network is not
available during the build.
To fix this, we add an EXTRA_DOWNLOADS to grab gcem and extract it at
the right place. Some minor fix (submitted upstream) is needed to
ensure the FindGCEM.cmake logic properly finds that gcem is already in
the source tree.
Fixes:
https://autobuild.buildroot.net/results/048df28f6ab97a16731e62d7f56c6eba565cda63/
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
committed by
Julien Olivain
parent
6561717f18
commit
a51521cbe6
@@ -0,0 +1,41 @@
|
||||
From f558b8656efe8bba7dd94f4acfceb1294a7ded22 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
Date: Thu, 27 Aug 2026 08:59:32 +0200
|
||||
Subject: [PATCH] cmake: fix finding bundled GCEM with a sysroot
|
||||
|
||||
CMAKE_FIND_ROOT_PATH_MODE_INCLUDE may be set to ONLY when cross
|
||||
compiling, to ensure that header searches use the target sysroot
|
||||
instead of accidentally finding host headers.
|
||||
|
||||
This causes find_path() to re-root the absolute path to the bundled
|
||||
GCEM headers under the target sysroot, making FindGCEM miss
|
||||
gcem/include/gcem.hpp in situations where
|
||||
CMAKE_FIND_ROOT_PATH_MODE_INCLUDE is set to ONLY.
|
||||
|
||||
To fix this, this commit passes NO_CMAKE_FIND_ROOT_PATH to prevent
|
||||
sysroot re-rooting when searching this source-tree path. It allows to
|
||||
properly detected gcem/include/gcem.hpp and avoid the download if
|
||||
already present.
|
||||
|
||||
Upstream: https://github.com/FluidSynth/fluidsynth/pull/1835
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
cmake_admin/FindGCEM.cmake | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/cmake_admin/FindGCEM.cmake b/cmake_admin/FindGCEM.cmake
|
||||
index 980951cc..e02d97f8 100644
|
||||
--- a/cmake_admin/FindGCEM.cmake
|
||||
+++ b/cmake_admin/FindGCEM.cmake
|
||||
@@ -23,7 +23,7 @@ This will define the following variables:
|
||||
#]=======================================================================]
|
||||
|
||||
# Find the headers and library
|
||||
-find_path(GCEM_INCLUDE_DIR NAMES "gcem.hpp" PATHS "${CMAKE_CURRENT_SOURCE_DIR}/gcem/include")
|
||||
+find_path(GCEM_INCLUDE_DIR NAMES "gcem.hpp" PATHS "${CMAKE_CURRENT_SOURCE_DIR}/gcem/include" NO_CMAKE_FIND_ROOT_PATH)
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
|
||||
--
|
||||
2.55.0
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# Locally computed
|
||||
sha256 ce27840221ab00dd59bf27e85ecbba480c6c2a7c9fbec4243658f68f59c07f4a fluidsynth-2.5.7.tar.gz
|
||||
sha256 34ab0ee87a9eb26d3087fa9b49c2572ea8ee03db0c9705b83648301a3a3fc172 gcem-012ae73c6d0a2cb09ffe86475f5c6fba3926e200.tar.gz
|
||||
sha256 20e50fe7aae3e56378ebf0417d9de904f55a0e61e4df315333e632a4d3555d95 LICENSE
|
||||
|
||||
@@ -12,6 +12,18 @@ FLUIDSYNTH_CPE_ID_VENDOR = fluidsynth
|
||||
FLUIDSYNTH_INSTALL_STAGING = YES
|
||||
FLUIDSYNTH_DEPENDENCIES = libglib2
|
||||
|
||||
FLUIDSYNTH_GCEM_VERSION = 012ae73c6d0a2cb09ffe86475f5c6fba3926e200
|
||||
FLUIDSYNTH_EXTRA_DOWNLOADS = $(call github,kthohr,gcem,$(FLUIDSYNTH_GCEM_VERSION))/gcem-$(FLUIDSYNTH_GCEM_VERSION).tar.gz
|
||||
|
||||
define FLUIDSYNTH_GCEM_EXTRACT
|
||||
$(call suitable-extractor,$(notdir $(FLUIDSYNTH_EXTRA_DOWNLOADS))) \
|
||||
$(FLUIDSYNTH_DL_DIR)/$(notdir $(FLUIDSYNTH_EXTRA_DOWNLOADS)) | \
|
||||
$(TAR) -C $(@D)/ $(TAR_OPTIONS) -
|
||||
rmdir $(@D)/gcem
|
||||
ln -sf gcem-$(FLUIDSYNTH_GCEM_VERSION) $(@D)/gcem
|
||||
endef
|
||||
FLUIDSYNTH_POST_EXTRACT_HOOKS += FLUIDSYNTH_GCEM_EXTRACT
|
||||
|
||||
ifeq ($(BR2_PACKAGE_FLUIDSYNTH_ALSA_LIB),y)
|
||||
FLUIDSYNTH_CONF_OPTS += -Denable-alsa=1
|
||||
FLUIDSYNTH_DEPENDENCIES += alsa-lib
|
||||
|
||||
Reference in New Issue
Block a user