Enable support for version specification inside samples/cmake/FindWASISDK.cmake#4212
Enable support for version specification inside samples/cmake/FindWASISDK.cmake#4212Zelzahn wants to merge 1 commit intobytecodealliance:mainfrom
samples/cmake/FindWASISDK.cmake#4212Conversation
|
Hi, I already had a look at both, to be clear the issue isn't that you can't give a version. The issue is that if you have multiple |
If you refer to the installation script for CI, you will find the assumption about wasi-sdk is that there is always a symlink named /opt/wasi-sdk targeting a directory /opt/wasi-sdk-xxx. With that, I guess we can modify the FindWASISDK in the following ways:
FindWASISDK.cmake should not search for the correct wasi-sdk if there are multiple versions. Developers should prepare for that. |
| find_path(WASISDK_HOME | ||
| NAMES share/wasi-sysroot | ||
| PATHS ${WASISDK_SEARCH_PATH} | ||
| VALIDATOR check_version |
There was a problem hiding this comment.
VALIDATOR is documented as a cmake 3.25 feature.
https://cmake.org/cmake/help/latest/command/find_path.html
in most places we still use cmake_minimum_required (VERSION 3.14).
|
Yeah, I need to have multiple
I agree, I propose that I then close this PR and open a new one where I modify |
Currently, it is not possible to select a specific WASI SDK version to use in a sample. Thus, I modified the
FindWASISDK.cmaketo let me do this.I'm no CMake expert, so feedback is greatly appreciated.