Skip to content

Strip whitespace from OPTION_VALUE (fixes #635) #657

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dwuertz
Copy link

@dwuertz dwuertz commented Apr 8, 2025

If key and value in OPTIONS lines are separated by more than a single space, the remaining whitespace is currently included in the OPTION_KEY, apparently causing the setting to be ignored (see #635), for some reason I don't fully understand. Stripping the excess whitespace fixes #635 and seems to be a reasonable thing to do in general.

@flagarde
Copy link
Contributor

Maybe CPM should force -D := (https://cmake.org/cmake/help/latest/manual/cmake.1.html#cmdoption-cmake-D) syntax

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.

OPTIONS in CPMAddPackage does not like multiple whitespace
2 participants