Skip to content

Commit 6641e91

Browse files
committed
Revert "[WASI] use WASI_SDK22_PATH variable (dotnet#104379)"
This reverts commit 812cb93.
1 parent b5bc2c3 commit 6641e91

File tree

20 files changed

+68
-94
lines changed

20 files changed

+68
-94
lines changed

eng/native/gen-buildsys.cmd

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -60,20 +60,19 @@ if /i "%__Arch%" == "wasm" (
6060
set __UseEmcmake=1
6161
)
6262
if /i "%__Os%" == "wasi" (
63-
set "__repoRoot=!__repoRoot:\=/!"
64-
if "%WASI_SDK22_PATH%" == "" (
63+
if "%WASI_SDK_PATH%" == "" (
6564
if not exist "%__repoRoot%\src\mono\wasi\wasi-sdk" (
66-
echo Error: Should set WASI_SDK22_PATH environment variable pointing to WASI SDK root.
65+
echo Error: Should set WASI_SDK_PATH environment variable pointing to WASI SDK root.
6766
exit /B 1
6867
)
6968

70-
set "WASI_SDK22_PATH=%__repoRoot%\src\mono\wasi\wasi-sdk"
69+
set "WASI_SDK_PATH=%__repoRoot%\src\mono\wasi\wasi-sdk"
7170
)
7271
:: replace backslash with forward slash and append last slash
73-
set "WASI_SDK22_PATH=!WASI_SDK22_PATH:\=/!"
74-
if not "!WASI_SDK22_PATH:~-1!" == "/" set "WASI_SDK22_PATH=!WASI_SDK22_PATH!/"
72+
set "WASI_SDK_PATH=!WASI_SDK_PATH:\=/!"
73+
if not "!WASI_SDK_PATH:~-1!" == "/" set "WASI_SDK_PATH=!WASI_SDK_PATH!/"
7574
set __CmakeGenerator=Ninja
76-
set __ExtraCmakeParams=%__ExtraCmakeParams% -DCLR_CMAKE_TARGET_OS=wasi -DCLR_CMAKE_TARGET_ARCH=wasm "-DWASI_SDK_PREFIX=!WASI_SDK22_PATH!" "-DCMAKE_TOOLCHAIN_FILE=!WASI_SDK22_PATH!share/cmake/wasi-sdk.cmake" "-DCMAKE_SYSROOT=!WASI_SDK22_PATH!share/wasi-sysroot"
75+
set __ExtraCmakeParams=%__ExtraCmakeParams% -DCLR_CMAKE_TARGET_OS=wasi -DCLR_CMAKE_TARGET_ARCH=wasm "-DWASI_SDK_PREFIX=!WASI_SDK_PATH!" "-DCMAKE_TOOLCHAIN_FILE=!WASI_SDK_PATH!/share/cmake/wasi-sdk.cmake" "-DCMAKE_SYSROOT=!WASI_SDK_PATH!/share/wasi-sysroot"
7776
)
7877
) else (
7978
set __ExtraCmakeParams=%__ExtraCmakeParams% "-DCMAKE_SYSTEM_VERSION=10.0"

eng/native/gen-buildsys.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
#
55

66
scriptroot="$( cd -P "$( dirname "$0" )" && pwd )"
7-
reporoot="$(cd "$scriptroot"/../..; pwd -P)"
87

98
if [[ "$#" -lt 4 ]]; then
109
echo "Usage..."
@@ -98,7 +97,7 @@ if [[ "$host_arch" == "wasm" ]]; then
9897
if [[ "$target_os" == "browser" ]]; then
9998
cmake_command="emcmake $cmake_command"
10099
elif [[ "$target_os" == "wasi" ]]; then
101-
cmake_extra_defines="$cmake_extra_defines -DCLR_CMAKE_TARGET_OS=wasi -DCLR_CMAKE_TARGET_ARCH=wasm -DWASI_SDK_PREFIX=$WASI_SDK22_PATH -DCMAKE_TOOLCHAIN_FILE=${WASI_SDK22_PATH}share/cmake/wasi-sdk.cmake" "-DCMAKE_SYSROOT=${WASI_SDK22_PATH}share/wasi-sysroot"
100+
true
102101
else
103102
echo "target_os was not specified"
104103
exit 1

eng/testing/tests.wasi.targets

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@
1313
>true</InstallWasmtimeForTests>
1414

1515
<!--<InstallWorkloadUsingArtifactsDependsOn>_GetWorkloadsToInstall;$(InstallWorkloadUsingArtifactsDependsOn)</InstallWorkloadUsingArtifactsDependsOn>-->
16-
<WASI_SDK22_PATH Condition="'$(WASI_SDK22_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(MonoProjectRoot), 'wasi', 'wasi-sdk'))</WASI_SDK22_PATH>
17-
<WASI_SDK22_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK22_PATH)').Replace('\', '/'))</WASI_SDK22_PATH>
16+
<WASI_SDK_PATH Condition="'$(WASI_SDK_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(MonoProjectRoot), 'wasi', 'wasi-sdk'))</WASI_SDK_PATH>
1817

1918
<_BundleAOTTestWasmAppForHelixDependsOn>$(_BundleAOTTestWasmAppForHelixDependsOn);PrepareForWasiBuildApp;_PrepareForAOTOnHelix</_BundleAOTTestWasmAppForHelixDependsOn>
2019
</PropertyGroup>

src/libraries/sendtohelix-wasi.targets

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,7 @@
4646
<IncludeHelixCorrelationPayload>false</IncludeHelixCorrelationPayload>
4747
<EnableDefaultBuildHelixWorkItems>false</EnableDefaultBuildHelixWorkItems>
4848

49-
<WASI_SDK22_PATH Condition="'$(WASI_SDK22_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(RepoRoot), 'src', 'mono', 'wasi', 'wasi-sdk'))</WASI_SDK22_PATH>
50-
<WASI_SDK22_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK22_PATH)').Replace('\', '/'))</WASI_SDK22_PATH>
49+
<WASI_SDK_PATH Condition="'$(WASI_SDK_PATH)' == ''">$(RepoRoot)src\mono\wasi\wasi-sdk\</WASI_SDK_PATH>
5150
<WasiBuildTargetsDir>$([MSBuild]::NormalizeDirectory('$(RepoRoot)', 'src', 'mono', 'wasi', 'build'))</WasiBuildTargetsDir>
5251
<WasiSdkDirForHelixPayload>$(HelixDependenciesStagingPath)$(WorkItemPrefix)wasi-sdk</WasiSdkDirForHelixPayload>
5352
<WasmtimeDirForHelixPayload>$(HelixDependenciesStagingPath)$(WorkItemPrefix)wasmtime</WasmtimeDirForHelixPayload>
@@ -64,7 +63,7 @@
6463
</PropertyGroup>
6564

6665
<ItemGroup>
67-
<HelixDependenciesToStage Condition="'$(NeedsWasiSdk)' == 'true'" SourcePath="$(WASI_SDK22_PATH)" Include="$(WasiSdkDirForHelixPayload)" />
66+
<HelixDependenciesToStage Condition="'$(NeedsWasiSdk)' == 'true'" SourcePath="$(WASI_SDK_PATH)" Include="$(WasiSdkDirForHelixPayload)" />
6867
<HelixDependenciesToStage Condition="'$(NeedsWasmtime)' == 'true'" SourcePath="$(WasmtimeDir)" Include="$(WasmtimeDirForHelixPayload)" />
6968
</ItemGroup>
7069

@@ -74,7 +73,7 @@
7473
<HelixPreCommand Include="export XHARNESS_LOG_WITH_TIMESTAMPS=true" />
7574
<HelixPreCommand Include="export WASMTIME_BACKTRACE_DETAILS=1" />
7675
<HelixPreCommand Condition="'$(NeedsWasmtime)' == 'true'" Include="export PATH=$HELIX_CORRELATION_PAYLOAD/wasmtime:$PATH" />
77-
<HelixPreCommand Condition="'$(NeedsWasiSdk)' == 'true'" Include="export PATH=$HELIX_CORRELATION_PAYLOAD/build/wasi-sdk/bin:$PATH" />
76+
<HelixPreCommand Condition="'$(NeedsWasiSdk)' == 'true'" Include="export PATH=$HELIX_CORRELATION_PAYLOAD/wasi-sdk:$PATH" />
7877
</ItemGroup>
7978

8079
<ItemGroup Condition="'$(WindowsShell)' == 'true'">
@@ -83,7 +82,7 @@
8382
<HelixPreCommand Include="set XHARNESS_LOG_WITH_TIMESTAMPS=true" />
8483
<HelixPreCommand Include="set WASMTIME_BACKTRACE_DETAILS=1" />
8584
<HelixPreCommand Condition="'$(NeedsWasmtime)' == 'true'" Include="set PATH=%HELIX_CORRELATION_PAYLOAD%\wasmtime%3B%PATH%" />
86-
<HelixPreCommand Condition="'$(NeedsWasiSdk)' == 'true'" Include="set PATH=%HELIX_CORRELATION_PAYLOAD%\build\wasi-sdk\bin%3B%PATH%" />
85+
<HelixPreCommand Condition="'$(NeedsWasiSdk)' == 'true'" Include="set PATH=%HELIX_CORRELATION_PAYLOAD%\wasi-sdk%3B%PATH%" />
8786
</ItemGroup>
8887

8988
<PropertyGroup Condition="'$(Scenario)' == 'BuildWasmApps'">
@@ -93,8 +92,8 @@
9392
</PropertyGroup>
9493

9594
<ItemGroup Condition="'$(Scenario)' == 'BuildWasmApps'">
96-
<HelixPreCommand Condition="'$(WindowsShell)' == 'true'" Include="set &quot;WASI_SDK22_PATH=%HELIX_CORRELATION_PAYLOAD%\build\wasi-sdk&quot;" />
97-
<HelixPreCommand Condition="'$(WindowsShell)' != 'true'" Include="export &quot;WASI_SDK22_PATH=$HELIX_CORRELATION_PAYLOAD/build/wasi-sdk&quot;" />
95+
<HelixPreCommand Condition="'$(WindowsShell)' == 'true'" Include="set &quot;WASI_SDK_PATH=%HELIX_CORRELATION_PAYLOAD%\build\wasi-sdk&quot;" />
96+
<HelixPreCommand Condition="'$(WindowsShell)' != 'true'" Include="export &quot;WASI_SDK_PATH=$HELIX_CORRELATION_PAYLOAD/build/wasi-sdk&quot;" />
9897
</ItemGroup>
9998

10099
<PropertyGroup Condition="'$(NeedsWasiSdk)' == 'true'">

src/libraries/sendtohelixhelp.proj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@
355355
<!--
356356
Helix tasks will attempt to write a .payload file to the payload directory. But if the
357357
directory is not writable, for example when it is a system installed dependency like
358-
`WASI_SDK22_PATH=/usr/local/wasi-sdk`
358+
`WASI_SDK_PATH=/usr/local/wasi-sdk`
359359
.. then we need to stage that before passing the path to helix like under `artifacts/obj/helix-staging`
360360
-->
361361
<Target Name="StageDependenciesForHelix" Condition="@(__HelixDependenciesToStageThatDontExist->Count()) > 0">

src/mono/Directory.Build.props

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,14 @@
3232
<EMSDK_PATH Condition="Exists('$(ProvisionEmscriptenDir)') and '$(EMSDK_PATH)' == ''">$(ProvisionEmscriptenDir.Replace('\', '/'))</EMSDK_PATH>
3333
</PropertyGroup>
3434

35-
<!-- Directory to provision and use WASI sdk if WASI_SDK22_PATH env variable is not set -->
35+
<!-- Directory to provision and use WASI sdk if WASI_SDK_PATH env variable is not set -->
3636
<PropertyGroup Condition="'$(TargetsWasi)' == 'true'">
37-
<WASI_SDK22_PATH Condition="'$(WASI_SDK22_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(MSBuildThisFileDirectory), 'wasi', 'wasi-sdk'))</WASI_SDK22_PATH>
38-
<WASI_SDK22_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK22_PATH)').Replace('\', '/'))</WASI_SDK22_PATH>
39-
<ShouldProvisionWasiSdk Condition="!Exists($(WASI_SDK22_PATH))">true</ShouldProvisionWasiSdk>
37+
<!-- force download temmporarily https://github.com/dotnet/runtime/issues/101528
38+
<WASI_SDK_PATH Condition="'$(WASI_SDK_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(MSBuildThisFileDirectory), 'wasi', 'wasi-sdk'))</WASI_SDK_PATH>
39+
-->
40+
<WASI_SDK_PATH>$([MSBuild]::NormalizeDirectory($(MSBuildThisFileDirectory), 'wasi', 'wasi-sdk'))</WASI_SDK_PATH>
41+
<WASI_SDK_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK_PATH)').Replace('\', '/'))</WASI_SDK_PATH>
42+
<ShouldProvisionWasiSdk Condition="!Exists($(_ProvisionWasiSdkDir))">true</ShouldProvisionWasiSdk>
4043
</PropertyGroup>
4144

4245
<PropertyGroup>

src/mono/mono.proj

Lines changed: 10 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@
125125
<Error Condition="('$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsMacCatalyst)' == 'true') and !$([MSBuild]::IsOSPlatform('OSX'))" Text="Error: $(TargetOS) can only be built on macOS." />
126126
<Error Condition="('$(TargetsAndroid)' == 'true' or '$(TargetsLinuxBionic)' == 'true') and '$(Platform)' != 'x64' and '$(Platform)' != 'x86' and '$(Platform)' != 'arm64' and '$(Platform)' != 'arm'" Text="Error: Invalid platform for $(TargetOS): $(Platform)." />
127127
<Error Condition="'$(TargetsBrowser)' == 'true' and '$(EMSDK_PATH)' == '' and '$(SkipMonoCrossJitConfigure)' != 'true'" Text="The EMSDK_PATH environment variable should be set pointing to the emscripten SDK root dir."/>
128-
<Error Condition="'$(TargetsWasi)' == 'true' and '$(WASI_SDK22_PATH)' == '' and '$(SkipMonoCrossJitConfigure)' != 'true'" Text="The WASI_SDK22_PATH environment variable should be set pointing to the WASI SDK root dir."/>
128+
<Error Condition="'$(TargetsWasi)' == 'true' and '$(WASI_SDK_PATH)' == '' and '$(SkipMonoCrossJitConfigure)' != 'true'" Text="The WASI_SDK_PATH environment variable should be set pointing to the WASI SDK root dir."/>
129129
<Error Condition="('$(TargetsAndroid)' == 'true' or '$(TargetsLinuxBionic)' == 'true') and '$(ANDROID_NDK_ROOT)' == '' and '$(SkipMonoCrossJitConfigure)' != 'true'" Text="Error: You need to set the ANDROID_NDK_ROOT environment variable pointing to the Android NDK root." />
130130
<Error Condition="'$(HostOS)' == 'windows' and ('$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsMacCatalyst)' == 'true')" Text="Error: Mono runtime for $(TargetOS) can't be built on Windows." />
131131

@@ -302,7 +302,7 @@ JS_ENGINES = [NODE_JS]
302302
</PropertyGroup>
303303
</Target>
304304

305-
<!-- Sets up WASI SDK if you don't have the WASI_SDK22_PATH env variable set -->
305+
<!-- Sets up WASI SDK if you don't have the WASI_SDK_PATH env variable set -->
306306
<Target Name="ProvisionWasiSdk"
307307
Condition="'$(ShouldProvisionWasiSdk)' == 'true' and '$(SkipMonoCrossJitConfigure)' != 'true'">
308308
<ReadLinesFromFile File="$(MSBuildThisFileDirectory)/wasi/wasi-sdk-version.txt">
@@ -317,36 +317,20 @@ JS_ENGINES = [NODE_JS]
317317
<WasiSdkUrl Condition="'$(HostOS)' == 'windows'" >https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-$(WasiSdkVersion)/wasi-sdk-$(WasiSdkVersion).0.m-mingw.tar.gz</WasiSdkUrl>
318318
</PropertyGroup>
319319

320-
<RemoveDir Directories="$(WASI_SDK22_PATH)" />
321-
<Exec Command="curl -L -o wasi-sdk-$(WasiSdkVersion).0.tar.gz $(WasiSdkUrl) &amp;&amp; mkdir -p $(WASI_SDK22_PATH) &amp;&amp; tar --strip-components=1 -xzf wasi-sdk-$(WasiSdkVersion).0.tar.gz -C $(WASI_SDK22_PATH) &amp;&amp; cp $(WasiLocalPath)/wasi-sdk-version.txt $(WASI_SDK22_PATH)wasi-sdk-version.txt"
320+
<RemoveDir Directories="$(WASI_SDK_PATH)" />
321+
<Exec Command="curl -L -o wasi-sdk-$(WasiSdkVersion).0.tar.gz $(WasiSdkUrl) &amp;&amp; mkdir -p $(WASI_SDK_PATH) &amp;&amp; tar --strip-components=1 -xzf wasi-sdk-$(WasiSdkVersion).0.tar.gz -C $(WASI_SDK_PATH) &amp;&amp; cp $(WasiLocalPath)/wasi-sdk-version.txt $(WASI_SDK_PATH)/wasi-sdk-version.txt"
322322
Condition="'$(HostOS)' != 'windows'"
323323
WorkingDirectory="$(ArtifactsObjDir)"
324324
IgnoreStandardErrorWarningFormat="true" />
325325

326-
<!--
327-
Temporary WASI-SDK 22 workaround #2: The version of `wasm-component-ld` that
328-
ships with WASI-SDK 22 contains a
329-
[bug](https://github.com/bytecodealliance/wasm-component-ld/issues/22) which
330-
has been fixed in a v0.5.3 of that utility, so we upgrade it here.
331-
-->
332-
<Exec Command="curl -L -o wasm-component-ld-v0.5.4-x86_64-linux.tar.gz https://github.com/bytecodealliance/wasm-component-ld/releases/download/v0.5.4/wasm-component-ld-v0.5.4-x86_64-linux.tar.gz &amp;&amp; mkdir -p $(WASI_SDK22_PATH)wasm-component &amp;&amp; tar --strip-components=1 -xzf wasm-component-ld-v0.5.4-x86_64-linux.tar.gz -C $(WASI_SDK22_PATH)wasm-component &amp;&amp; cp $(WASI_SDK22_PATH)wasm-component/wasm-component-ld $(WASI_SDK22_PATH)bin/wasm-component-ld"
333-
Condition="'$(HostOS)' != 'windows'"
334-
WorkingDirectory="$(ArtifactsObjDir)"
335-
IgnoreStandardErrorWarningFormat="true" />
336-
337-
<Exec Command="powershell -NonInteractive -command &quot;&amp; $(WasiLocalPath)\provision.ps1 -WasiSdkUrl $(WasiSdkUrl) -WasiSdkVersion $(WasiSdkVersion) -WasiSdkPath $(WASI_SDK22_PATH) -WasiLocalPath $(WasiLocalPath); Exit $LastExitCode &quot;"
326+
<Exec Command="powershell -NonInteractive -command &quot;&amp; $(WasiLocalPath)\provision.ps1 -WasiSdkUrl $(WasiSdkUrl) -WasiSdkVersion $(WasiSdkVersion) -WasiSdkPath $(WASI_SDK_PATH) -WasiLocalPath $(WasiLocalPath); Exit $LastExitCode &quot;"
338327
Condition="'$(HostOS)' == 'windows'"
339328
WorkingDirectory="$(ArtifactsObjDir)"
340329
IgnoreStandardErrorWarningFormat="true" />
341-
342-
<Copy SourceFiles="$(MSBuildThisFileDirectory)/wasi/wasi-sdk/share/wasi-sysroot/include/wasm32-wasi-threads/pthread.h"
343-
DestinationFiles="$(MSBuildThisFileDirectory)/wasi/wasi-sdk/share/wasi-sysroot/include/wasm32-wasip2/pthread.h"
344-
/>
345-
346330
</Target>
347331

348332
<Target Name="ValidateWasiSdk" Condition="'$(SkipMonoCrossJitConfigure)' != 'true'">
349-
<ReadLinesFromFile File="$(WASI_SDK22_PATH)wasi-sdk-version.txt">
333+
<ReadLinesFromFile File="$(WASI_SDK_PATH)/wasi-sdk-version.txt">
350334
<Output TaskParameter="Lines" ItemName="_ActualVersionLines" />
351335
</ReadLinesFromFile>
352336
<ReadLinesFromFile File="$(MSBuildThisFileDirectory)/wasi/wasi-sdk-version.txt">
@@ -356,7 +340,7 @@ JS_ENGINES = [NODE_JS]
356340
<ActualWasiSdkVersion>%(_ActualVersionLines.Identity)</ActualWasiSdkVersion>
357341
<ExpectedWasiSdkVersion>%(_ExpectedVersionLines.Identity)</ExpectedWasiSdkVersion>
358342
</PropertyGroup>
359-
<Error Text="Expected version: %(_ExpectedVersionLines.Identity) and actual version: %(_ActualVersionLines.Identity) of WASI SDK does not match. Please delete $(WASI_SDK22_PATH) folder to provision a new version."
343+
<Error Text="Expected version: %(_ExpectedVersionLines.Identity) and actual version: %(_ActualVersionLines.Identity) of WASI SDK does not match. Please delete $(WASI_SDK_PATH) folder to provision a new version."
360344
Condition="'$(ActualWasiSdkVersion)' != '$(ExpectedWasiSdkVersion)'" />
361345
</Target>
362346

@@ -738,14 +722,13 @@ JS_ENGINES = [NODE_JS]
738722

739723
<PropertyGroup>
740724
<EMSDK_PATH>$([MSBuild]::EnsureTrailingSlash('$(EMSDK_PATH)').Replace('\', '/'))</EMSDK_PATH>
741-
<WASI_SDK22_PATH Condition="'$(WASI_SDK22_PATH)' == ''">$([MSBuild]::NormalizeDirectory($(MSBuildThisFileDirectory), 'wasi', 'wasi-sdk'))</WASI_SDK22_PATH>
742-
<WASI_SDK22_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK22_PATH)').Replace('\', '/'))</WASI_SDK22_PATH>
725+
<WASI_SDK_PATH>$([MSBuild]::EnsureTrailingSlash('$(WASI_SDK_PATH)').Replace('\', '/'))</WASI_SDK_PATH>
743726
<_EmsdkEnvScriptPath>$([MSBuild]::NormalizePath('$(EMSDK_PATH)', 'emsdk_env$(ScriptExt)'))</_EmsdkEnvScriptPath>
744727

745728
<_MonoCMakeConfigureCommand>cmake @(_MonoCMakeArgs, ' ') $(MonoCMakeExtraArgs) &quot;$(MonoProjectRoot.TrimEnd('\/'))&quot;</_MonoCMakeConfigureCommand>
746729
<_MonoCMakeConfigureCommand Condition="'$(TargetsBrowser)' != 'true' and '$(TargetsWasi)' != 'true' and '$(_MonoSkipInitCompiler)' != 'true' and '$(HostOS)' != 'windows'">sh -c 'build_arch=&quot;$(_CompilerTargetArch)&quot; compiler=&quot;$(MonoCCompiler)&quot; . &quot;$(RepositoryEngineeringCommonDir)native/init-compiler.sh&quot; &amp;&amp; @(_MonoBuildEnv, ' ') $(_MonoCMakeConfigureCommand)'</_MonoCMakeConfigureCommand>
747730
<_MonoCMakeConfigureCommand Condition="'$(TargetsBrowser)' != 'true' and '$(TargetsWasi)' != 'true' and '$(_MonoSkipInitCompiler)' == 'true' and '$(HostOS)' != 'windows'">$(_MonoCCOption) $(_MonoCXXOption) @(_MonoBuildEnv, ' ') $(_MonoCMakeConfigureCommand)</_MonoCMakeConfigureCommand>
748-
<_MonoCMakeConfigureCommand Condition="'$(TargetsWasi)' == 'true'">$(_MonoCMakeConfigureCommand) -DWASI_SDK_PREFIX=$(WASI_SDK22_PATH) -DCMAKE_SYSROOT=$(WASI_SDK22_PATH)share/wasi-sysroot -DCMAKE_TOOLCHAIN_FILE=$(WASI_SDK22_PATH)share/cmake/wasi-sdk.cmake -DCMAKE_CXX_FLAGS="--sysroot=$(WASI_SDK22_PATH)share/wasi-sysroot"</_MonoCMakeConfigureCommand>
731+
<_MonoCMakeConfigureCommand Condition="'$(TargetsWasi)' == 'true'">$(_MonoCMakeConfigureCommand) -DWASI_SDK_PREFIX=$(WASI_SDK_PATH) -DCMAKE_SYSROOT=$(WASI_SDK_PATH)share/wasi-sysroot -DCMAKE_TOOLCHAIN_FILE=$(WASI_SDK_PATH)share/cmake/wasi-sdk.cmake -DCMAKE_CXX_FLAGS="--sysroot=$(WASI_SDK_PATH)share/wasi-sysroot"</_MonoCMakeConfigureCommand>
749732

750733
<_MonoCMakeConfigureCommand Condition="'$(TargetsBrowser)' != 'true' and '$(TargetsWasi)' != 'true' and '$(HostOS)' == 'windows'">call &quot;$(RepositoryEngineeringDir)native\init-vs-env.cmd&quot; $(_CompilerTargetArch) &amp;&amp; cd /D &quot;$(MonoObjDir)&quot; &amp;&amp; @(_MonoBuildEnv, ' ') $(_MonoCMakeConfigureCommand)</_MonoCMakeConfigureCommand>
751734
<_MonoCMakeConfigureCommand Condition="'$(TargetsBrowser)' == 'true' and '$(HostOS)' != 'windows'">bash -c 'source $(_EmsdkEnvScriptPath) 2>&amp;1 &amp;&amp; emcmake $(_MonoCMakeConfigureCommand)'</_MonoCMakeConfigureCommand>
@@ -941,7 +924,7 @@ JS_ENGINES = [NODE_JS]
941924
<MonoAotCrossOffsetsToolParams Condition="'$(MonoAotOffsetsPrefix)' != ''" Include="--prefix=&quot;$(MonoAotOffsetsPrefix)&quot;" />
942925
<MonoAotCrossOffsetsToolParams Condition="'$(MonoAotCMakeSysroot)' != ''" Include="--sysroot=&quot;$(MonoAotCMakeSysroot)&quot;" />
943926
<MonoAotCrossOffsetsToolParams Condition="'$(TargetsBrowser)' == 'true'" Include="--emscripten-sdk=&quot;$([MSBuild]::NormalizePath('$(EMSDK_PATH)', 'emscripten').TrimEnd('\/'))&quot;" />
944-
<MonoAotCrossOffsetsToolParams Condition="'$(TargetsWasi)' == 'true'" Include="--sysroot=&quot;$([MSBuild]::NormalizePath('$(WASI_SDK22_PATH)', 'share/wasi-sysroot'))&quot; --wasi-sdk=&quot;$([MSBuild]::NormalizePath('$(WASI_SDK22_PATH)').TrimEnd('\/'))&quot;" />
927+
<MonoAotCrossOffsetsToolParams Condition="'$(TargetsWasi)' == 'true'" Include="--sysroot=&quot;$([MSBuild]::NormalizePath('$(WASI_SDK_PATH)', 'share/wasi-sysroot'))&quot; --wasi-sdk=&quot;$([MSBuild]::NormalizePath('$(WASI_SDK_PATH)').TrimEnd('\/'))&quot;" />
945928
</ItemGroup>
946929

947930
<!--

0 commit comments

Comments
 (0)