-
Notifications
You must be signed in to change notification settings - Fork 2.6k
cmd\git.exe crashing when ARM64 folder is present in Git installation (git-wrapper) #3083
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
cmd\git.exe crashing when ARM64 folder is present in Git installation (git-wrapper) #3083
Comments
Oh, that's most likely because we pass |
That seems like we'll need to check that as well. If I understand the current state of Windows on ARM correctly, you shouldn't be able to execute an actual AMD64 build, so this command seems to output incorrect information. |
I think that's a shortcoming in the CMake-based build.
I don't really have any time to investigate now, maybe you could follow the Blame to see whether we should not have passed |
The CMake build seems to set git/contrib/buildsystems/CMakeLists.txt Line 197 in 4321276
|
When calling `cmd\git.exe`, we now really want `msystem_bin` _not_ to be `NULL`. This partially fixes git-for-windows/git#3083. Signed-off-by: Johannes Schindelin <[email protected]>
@dennisameling re: the segmentation fault, can you see whether git-for-windows/MINGW-packages#47 fixes your issue? |
But we do, don't we? See git/contrib/buildsystems/CMakeLists.txt Line 64 in 4321276
|
This comment has been minimized.
This comment has been minimized.
We specify a |
I think microsoft/vcpkg#16111 might fix that. |
Setup
defaults?
to the issue you're seeing?
See more details below
Details
CMD/PowerShell (Git Bash works correctly since it's not using
cmd\git.exe
).Minimal, Complete, and Verifiable example
this will help us understand the issue.
the actual git version
program crashed
Attempt to debug with
printf
I first added some
printf
statements togit-wrapper.c
:So it seems to crash at the line
wcscpy(msystem_bin, L"arm64/bin");
:https://github.com/git-for-windows/MINGW-packages/blob/e365c848ca812211f7118774d44ec1860ebaedba/mingw-w64-git/git-wrapper.c#L141_L142
Attempt to debug with
gdb
gdb
, following the steps at https://github.com/git-for-windows/git/wiki/Debugging-Git#debugging-crashes-segmentation-faults, let me know if I missed something.I added a breakpoint to the
wcscpy
command mentioned above, and after it. Indeed looks like that's the culprit:Additional background
Please note that
cmd\git.exe
only crashes if running on ARM64 and anarm64/bin
folder is present. Running ARM64 Git for Windows through Git Bash works without any issues, so thegit-wrapper
is most likely the issue here.This is probably related to the change introduced in git-for-windows/MINGW-packages#46, but back then everything seemed to work, even when the
arm64/bin
folder was present. My apologies in case I tested incorrectly back then, I might simply have missed this bug.Please let me know if I can provide additional context.
The text was updated successfully, but these errors were encountered: