Skip to content

[cmake] make fail-on-missing=ON the only behavior, ignore user setting and deprecate build option - #23015

Open
ferdymercury wants to merge 2 commits into
root-project:masterfrom
ferdymercury:failondef
Open

[cmake] make fail-on-missing=ON the only behavior, ignore user setting and deprecate build option#23015
ferdymercury wants to merge 2 commits into
root-project:masterfrom
ferdymercury:failondef

Conversation

@ferdymercury

Copy link
Copy Markdown
Collaborator

This Pull request:

Changes or fixes:

fail-on-missing flag no longer makes any sense: most ROOT builtins already call ROOT_FIND_REQUIRED_DEP which purposely bypasses this flag, so users might be confused about this hybrid undocumented behavior. Now all builtins can be installed via APT or via homebrew, so it's less of an issue.

This allows a huge simplification of search-installed-software, and easens code maintenance and bug fixing of the build system for the developers. The only downside is that some users might need to type a bit more consciously what is ON and OFF. Which some might even welcome, others complain.

Checklist:

  • tested changes locally
  • updated the docs (if necessary)

@guitargeek

Copy link
Copy Markdown
Contributor

Thanks for the initiative! As I see it, the suggested change splits into an uncontroversial and a controversial part.

The uncontroversial part: removing the fail-on-missing=OFF path for all dependencies that back opt-in features, like arrow, which are OFF by default. If one explicitly selects arrow=ON at build time (or implies it with all=ON), then it's pretty annoying if the CMake code disables the feature and proceeds to build ROOT if find_package(Arrow) didn't succeed.

The controversial part: maybe some people relied on the automatic disabling of default features if the dependencies that backed them were not available. Or they relied on the fallback to the builtin version if available.

I think your suggestion would fly if you split it in two parts: first a PR with the uncontroversial part that should sail through, and then a PR for the remaining "controversial" changes.

Would that make sense to you?

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

Test Results

    23 files      23 suites   3d 15h 58m 12s ⏱️
 3 853 tests  3 852 ✅ 0 💤 1 ❌
79 408 runs  79 406 ✅ 1 💤 1 ❌

For more details on these failures, see this check.

Results for commit 5fcc486.

@ferdymercury

Copy link
Copy Markdown
Collaborator Author

Thanks for the feedback !

maybe some people relied on the automatic disabling of default features if the dependencies that backed them were not available.

On the other hand, this is already broken now:

  • If you specify asimage=ON, now it always fail due to the use of ROOT_FIND_REQUIRED_DEP, whereas some time ago, it was disabling it.
  • If you specify opengl=ON, same story

So this PR is making that current behavior consistent through all the build options.

Yes, I could split the PR in two if that helps, but the gain is not high since users can not rely any more on that historical behavior. I prefer annoying (I have to turn things ON/OFF by hand) but coherent behavior (every option behaves likewise) than heterogeneous one (why does one dependency autodisable and another one does not).

What do you think?

@ferdymercury
ferdymercury marked this pull request as ready for review August 5, 2026 06:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants