Added way for dependencies to use options and fixed compilation of ImGui with SDL3 backend.

This commit is contained in:
2025-03-13 09:57:39 +01:00
parent 71f8631e48
commit 283aa0f99c
3 changed files with 34 additions and 11 deletions

View File

@@ -91,8 +91,12 @@ def _git_recipe(env: Environment, globals: dict, repo_name, repo_url, cook_fn, v
else:
return [(0, 0, 0)]
def _dependencies(env: Environment, version) -> 'dict':
return dependencies_cb(env, version)
def _dependencies(env: Environment, version, options: dict) -> 'dict':
dependencies_signature = inspect.signature(dependencies_cb)
kwargs = {}
if 'options' in dependencies_signature.parameters:
kwargs['options'] = options
return dependencies_cb(env, version, **kwargs)
def _cook(env: Environment, version, options: dict = {}) -> dict:
if 'ref' in options: