diff --git a/erts/etc/win32/wsl_tools/SetupWSLcross.bat b/erts/etc/win32/wsl_tools/SetupWSLcross.bat index 0e8d9348c188..af33cfccf3a8 100644 --- a/erts/etc/win32/wsl_tools/SetupWSLcross.bat +++ b/erts/etc/win32/wsl_tools/SetupWSLcross.bat @@ -4,6 +4,9 @@ rem Usage: eval `cmd.exe /c SetupWSLcross.bat x64` IF "%~1"=="x86" GOTO search IF "%~1"=="x64" GOTO search +IF "%~1"=="arm64" GOTO search +IF "%~1"=="amd64_arm64" GOTO search +IF "%~1"=="x64_arm64" GOTO search GOTO badarg @@ -67,7 +70,12 @@ GOTO no_vcvars :continue -FOR /F "delims==" %%F IN ('where cl.exe') DO SET _cl_exec_=%%F +FOR /F "delims==" %%F IN ('where cl.exe') DO ( + SET _cl_exec_=%%F + goto set_cl_path +) + +:set_cl_path FOR %%F IN ("%_cl_exec_%") DO SET CL_PATH=%%~dpF FOR /F "delims==" %%F IN ('where rc.exe') DO SET _rc_exec_=%%F @@ -87,7 +95,7 @@ wsl.exe echo "# Eval this file eval \`cmd.exe /c SetupWSLcross.bat\`" exit :badarg -echo "Bad TARGET or not specified: %~1 expected x86 or x64" +echo "Bad TARGET or not specified: %~1 expected x86, x64, arm64 or amd64_arm64(x64_arm64)" exit :no_vcvars