From 5c1cb5e5bcc279a38b3947e9050ef4cd9e4ae0fd Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Thu, 8 Aug 2024 02:16:19 +0300 Subject: py: gen-py-controls: Use Control class Replace manual extraction of data from YAML with the Control helper class. This centralizes YAML parsing and avoids manual mistakes. In order to import the controls module, add the utils/codegen/ directory to the PYTHONPATH through the Python build environment. Signed-off-by: Laurent Pinchart Reviewed-by: Tomi Valkeinen Reviewed-by: Paul Elder --- utils/codegen/meson.build | 1 + 1 file changed, 1 insertion(+) (limited to 'utils') diff --git a/utils/codegen/meson.build b/utils/codegen/meson.build index fb2196ee..adf33bba 100644 --- a/utils/codegen/meson.build +++ b/utils/codegen/meson.build @@ -5,6 +5,7 @@ py_build_env = environment() # \todo Investigate usage of PYTHONPYCACHEPREFIX for Python >= 3.8 py_build_env.set('PYTHONDONTWRITEBYTECODE', '1') +py_build_env.prepend('PYTHONPATH', meson.current_source_dir()) py_modules += ['jinja2', 'yaml'] -- cgit v1.2.1