Skip to content

Conversation

@themuffinator
Copy link
Owner

Summary

  • add Meson version detection and use the new cmake.subproject_options API when available while keeping compatibility with older Meson releases
  • extend the freetype2 and RmlUi packagefiles to mirror the same conditional handling of cmake option objects

Testing

  • not run (Meson is unavailable in the execution environment)

https://chatgpt.com/codex/tasks/task_e_68e662b1b25083288417dbbfdc906491

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting

Comment on lines 478 to 482
freetype = disabler()
if not freetype_opt.disabled() and (client_ui_enabled or freetype_opt.enabled())
freetype = dependency('freetype2', required: freetype_opt.enabled())

if not freetype.found() and freetype_opt.allowed()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Allow freetype subproject fallback when feature is enabled

When the build is invoked with -Dfreetype=enabled and the system does not already provide FreeType, the first dependency('freetype2', required: freetype_opt.enabled()) call aborts the configure step before the later block that configures the bundled CMake subproject can run. That makes it impossible to build the optional wrap even though the commit introduces the logic for it. The dependency lookup should remain non‑required and let the explicit error after the fallback handle the "enabled but not found" case so the wrap can satisfy the request.

Useful? React with 👍 / 👎.

Comment on lines 516 to 521
rmlui = disabler()
if not rmlui_opt.disabled() and (client_ui_enabled or rmlui_opt.enabled())
rml_modules = ['RmlUi::RmlUi', 'RmlUi::Controls', 'RmlUi::Debugger']
rmlui = dependency('RmlUi', method: 'cmake', modules: rml_modules, required: rmlui_opt.enabled())

if not rmlui.found() and rmlui_opt.allowed()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge RmlUi fallback is bypassed when option is forced on

The same pattern appears in the RmlUi block: if the user passes -Drmlui=enabled without a preinstalled RmlUi, dependency('RmlUi', …, required: rmlui_opt.enabled()) fails immediately and the subsequent code that configures the bundled subproject never executes. As a result the feature cannot be enabled via the wrap even though the logic exists. Make the initial dependency optional and rely on the later error('RmlUi support requested…') to reject the configuration after attempting the fallback.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants