-
Notifications
You must be signed in to change notification settings - Fork 30k
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
Fix Visual Studio installation detection for Arm64 #46420
Fix Visual Studio installation detection for Arm64 #46420
Conversation
3aca22a
to
446769c
Compare
@nodejs/platform-windows-arm |
970358a
to
d0517b9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These changes break building on Windows x64.
@rem also if both are x86 | ||
if %target_arch%==x86 if %msvs_host_arch%==x86 set vcvarsall_arg=x86 | ||
@rem unless both the host and the target are the same | ||
if %target_arch%==%msvs_host_arch% set vcvarsall_arg=%target_arch% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fails on Windows x64, since it compares "x64" to "amd64"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, thank you. Let me fix that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be fixed now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the delay, I was OOF last week. Yes, this is fixed now.
d0517b9
to
0cb7257
Compare
This might supersede #44226 in which I added VS2022-specific logic for ARM64, since VS2019 is not supported on that platform. But since MS actively discourages VS2019 installation on ARM64 devices, your approach in this PR is probably better and more future-proof. |
@pbo-linaro Does this look ok to you? |
@StefanStojanovic will look into this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM if cross-compilation passes in CI.
0cb7257
to
a054cac
Compare
I didn't think we had cross-compilation in the main CI just now so I don't think that scenario will be tested, unelss I'm missing something. |
In the node-compile-windows job, there is a win-vs2019-arm64 configuration, so although we are currently not testing ARM64 in the CI, we should be able to see if the cross-compilation passes at least. |
a054cac
to
13d07b5
Compare
Please, let me know if there is anything specific I can do for finishing this PR on my end. |
Landed in 0abe5ec |
PR-URL: #46420 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <rlau@redhat.com>
PR-URL: #46420 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <rlau@redhat.com>
PR-URL: #46420 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <rlau@redhat.com>
When
vcbuild.bat arm64
was run on Windows Arm64 machine, thevswhere_usability_wrapper.cmd
was detecting proper installation of Visual Studio according to presence of x64 Build Tools which fails when there is only Arm64 version of the Build Tools.