Skip to content

CMake: Fix accidental variable expansion of WASI #5084

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

Merged
merged 1 commit into from
Sep 20, 2024

Conversation

kateinoigakukun
Copy link
Member

CMake recently introduced a new variable WASI to check if the target platform is WASI (https://gitlab.kitware.com/cmake/cmake/-/merge_requests/9659). However, the change led to WASI being expanded as a variable, which is not what we want in checking the platform name.

To have compatibility with older and newer versions of CMake, we should quote the string WASI to prevent it from being expanded as a variable.

CMake recently introduced a new variable `WASI` to check if the target
platform is WASI (https://gitlab.kitware.com/cmake/cmake/-/merge_requests/9659).
However, the change led to `WASI` being expanded as a variable, which
is not what we want in checking the platform name.

To have compatibility with older and newer versions of CMake, we should
quote the string `WASI` to prevent it from being expanded as a variable.
@MaxDesiatov
Copy link
Contributor

@swift-ci test

@kateinoigakukun kateinoigakukun merged commit c542180 into swiftlang:main Sep 20, 2024
2 of 3 checks passed
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