mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-09 07:51:59 -09:00
package/kodi: needs host-cmake >= 3.24
Building kodi with cmake version 3.22.3 provided by buildroot is broken
-- Found Python3: /home/buildroot/br6/output/per-package/kodi/host/x86_
64-buildroot-linux-gnu/sysroot/usr/include/python3.11 (found suitable
exact version "3.11.4") found components: Development Development.
Module Development.Embed
-- Could NOT find Python3 (missing: Interpreter) (Required is exact
version "3.11")
Reason given by package:
Interpreter: Cannot run the interpreter "/home/buildroot/br6/
output/per-package/kodi/host/x86_64-buildroot-linux-gnu/sysroot/
usr/bin/python3"
CMake Error at cmake/scripts/common/Macros.cmake:432 (message):
PYTHON enabled but not found
Call Stack (most recent call first):
CMakeLists.txt:214 (core_optional_dep)
using this defconfig
BR2_x86_64=y
BR2_TOOLCHAIN_BUILDROOT_CXX=y
BR2_FORCE_HOST_BUILD=y
BR2_PER_PACKAGE_DIRECTORIES=y
BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y
BR2_PACKAGE_KODI=y
BR2_PACKAGE_MESA3D=y
BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_IRIS=y
BR2_PACKAGE_MESA3D_OPENGL_EGL=y
BR2_PACKAGE_MESA3D_OPENGL_ES=y
BR2_PACKAGE_PYTHON3=y
BR2_PACKAGE_PYTHON3_PY_ONLY=y
BR2_PACKAGE_HOST_CMAKE=y
due to "BR2_FORCE_HOST_BUILD=y".
The cmake version provided by my distro is 3.25.1 which works fine.
Adding "CMAKE_FIND_DEBUG_MODE TRUE" to the "find_package(Python3 [...]"
call in Kodi's cmake/modules/FindPython.cmake and comparing the logfile
of both cmake versions shows that 3.25.1 adds
CMAKE_FIND_USE_INSTALL_PREFIX: 1
while searching for python3.
This option was introduced in cmake 3.24:
https://cmake.org/cmake/help/latest/variable/CMAKE_FIND_USE_INSTALL_PREFIX.html
After introducing this fix it turns out that
0002-cmake-modules-fix-python-detection.patch is not needed anymore so
we remove this patch.
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
committed by
Thomas Petazzoni
parent
bb90cbdaa3
commit
327b600041
@@ -1,28 +0,0 @@
|
||||
From c29c1e762e126fdb46a19fc15bcb465cf1cd6c76 Mon Sep 17 00:00:00 2001
|
||||
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
|
||||
Date: Sun, 7 May 2023 11:18:00 +0200
|
||||
Subject: [PATCH] cmake/modules: fix python detection
|
||||
|
||||
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
||||
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
|
||||
Upstream: https://github.com/xbmc/xbmc/pull/23230
|
||||
---
|
||||
cmake/modules/FindPython.cmake | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/cmake/modules/FindPython.cmake b/cmake/modules/FindPython.cmake
|
||||
index 782c0f51f6..a013cccf80 100644
|
||||
--- a/cmake/modules/FindPython.cmake
|
||||
+++ b/cmake/modules/FindPython.cmake
|
||||
@@ -60,7 +60,7 @@ endif()
|
||||
|
||||
find_package(Python3 ${VERSION} ${EXACT_VER} COMPONENTS Development)
|
||||
if(CORE_SYSTEM_NAME STREQUAL linux)
|
||||
- if(HOST_CAN_EXECUTE_TARGET)
|
||||
+ if(HOST_CAN_EXECUTE_TARGET OR DEFINED PYTHON_EXECUTABLE)
|
||||
find_package(Python3 ${VERSION} ${EXACT_VER} COMPONENTS Interpreter)
|
||||
else()
|
||||
find_package(Python3 COMPONENTS Interpreter)
|
||||
--
|
||||
2.25.1
|
||||
|
||||
@@ -66,6 +66,7 @@ menuconfig BR2_PACKAGE_KODI
|
||||
depends on BR2_PACKAGE_PYTHON3
|
||||
depends on !BR2_PACKAGE_PYTHON3_PYC_ONLY
|
||||
select BR2_NEEDS_HOST_JAVA
|
||||
select BR2_HOST_CMAKE_AT_LEAST_3_24
|
||||
select BR2_PACKAGE_FFMPEG
|
||||
select BR2_PACKAGE_FFMPEG_GPL
|
||||
select BR2_PACKAGE_FFMPEG_POSTPROC
|
||||
|
||||
Reference in New Issue
Block a user