0fddd045f88e introduced python3 dependency, require it to quick early.

Signed-off-by: Petr Vorel <pvo...@suse.cz>
---
Hi all,

RFC because I'm not sure if previous failed build wasn't better:

        GENHDR  drivers/gpu/drm/msm/generated/a2xx.xml.h
        /bin/sh: python3: not found

This way it's documented, but CONFIG_DRM_MSM just silently disappears
from .config. Also because depends on $(success ..) is not evaluated
(understand, some expressions can be really long) one see only:
Depends on: n [=n].

I was thinking about testing via $(PYTHON3) -m "xml.parsers.expat",
but because expat parser (and other modules) should be part the official
python3 and are installed even on minimal python3 installations (e.g.
python3-minimal on Debian). Therefore depending on "$(PYTHON3) -V"
should be enough.

Kind regards,
Petr

 drivers/gpu/drm/msm/Kconfig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/msm/Kconfig b/drivers/gpu/drm/msm/Kconfig
index 90c68106b63b..2cf4573a2ff1 100644
--- a/drivers/gpu/drm/msm/Kconfig
+++ b/drivers/gpu/drm/msm/Kconfig
@@ -11,6 +11,7 @@ config DRM_MSM
        depends on QCOM_LLCC || QCOM_LLCC=n
        depends on QCOM_COMMAND_DB || QCOM_COMMAND_DB=n
        depends on PM
+       depends on $(success,$(PYTHON3) -V)
        select IOMMU_IO_PGTABLE
        select QCOM_MDT_LOADER if ARCH_QCOM
        select REGULATOR
@@ -36,7 +37,7 @@ config DRM_MSM
        select PM_GENERIC_DOMAINS
        select TRACE_GPU_MEM
        help
-         DRM/KMS driver for MSM/snapdragon.
+         DRM/KMS driver for MSM/snapdragon.  Requires python3.
 
 config DRM_MSM_GPU_STATE
        bool
-- 
2.47.0

Reply via email to