0002-cmake-modules-fix-python-detection.patch 1018 B

12345678910111213141516171819202122232425262728
  1. From c29c1e762e126fdb46a19fc15bcb465cf1cd6c76 Mon Sep 17 00:00:00 2001
  2. From: "Yann E. MORIN" <yann.morin.1998@free.fr>
  3. Date: Sun, 7 May 2023 11:18:00 +0200
  4. Subject: [PATCH] cmake/modules: fix python detection
  5. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  6. Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
  7. Upstream: https://github.com/xbmc/xbmc/pull/23230
  8. ---
  9. cmake/modules/FindPython.cmake | 2 +-
  10. 1 file changed, 1 insertion(+), 1 deletion(-)
  11. diff --git a/cmake/modules/FindPython.cmake b/cmake/modules/FindPython.cmake
  12. index 782c0f51f6..a013cccf80 100644
  13. --- a/cmake/modules/FindPython.cmake
  14. +++ b/cmake/modules/FindPython.cmake
  15. @@ -60,7 +60,7 @@ endif()
  16. find_package(Python3 ${VERSION} ${EXACT_VER} COMPONENTS Development)
  17. if(CORE_SYSTEM_NAME STREQUAL linux)
  18. - if(HOST_CAN_EXECUTE_TARGET)
  19. + if(HOST_CAN_EXECUTE_TARGET OR DEFINED PYTHON_EXECUTABLE)
  20. find_package(Python3 ${VERSION} ${EXACT_VER} COMPONENTS Interpreter)
  21. else()
  22. find_package(Python3 COMPONENTS Interpreter)
  23. --
  24. 2.25.1