-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rapids_cpm_package_override: Always load overrides #778
base: branch-25.04
Are you sure you want to change the base?
rapids_cpm_package_override: Always load overrides #778
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK I think this makes sense. At first I was concerned that the override would bypass the env var but if we're only doing this for accessing the package metadata then I think it makes sense.
if(DEFINED CPM_${package_name}_SOURCE) | ||
set_property(GLOBAL PROPERTY rapids_cpm_${normalized_pkg_name}_override_ignored "ON") | ||
continue() | ||
else() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor nit: no need for else()
due to continue()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I want the rapids_cpm_${normalized_pkg_name}_override_ignored
to exist after any parsing has occured.
This gives us a ternary to determine that parsing has occured plus the outcome.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No I mean that
if(cond)
continue()
else()
foo()
endif()
is identical to
if(cond)
continue()
endif()
foo()
Description
rapids-cmake will now always load override entries from disk and populate the internal json state. In the case of
CPM_<pkg>_SOURCE
this information will still be ignored. This gives advanced users a consistent behavior when callingrapids_cpm_package_details
Checklist