git-for-windows / git

A fork of Git containing Windows-specific patches.
http://gitforwindows.org/
Other
8.42k stars 2.56k forks source link

ARM64 (aarch64/ARMv7) on Windows 10: sh.exe "not compatible with the version of Windows you're running" #5292

Open MikeFarrington opened 22 hours ago

MikeFarrington commented 22 hours ago

Setup

git version 2.47.1.windows.1
cpu: aarch64
built from commit: 2cd22437f64229935dc564db969cbcbfed5e9045
sizeof-long: 4
sizeof-size_t: 8
shell-path: D:/git-sdk-arm64-build-installers/usr/bin/sh          <------ this is weird, not a drive or folder on my system
feature: fsmonitor--daemon
libcurl: 8.11.0
OpenSSL: OpenSSL 3.2.3 3 Sep 2024
zlib: 1.3.1
Windows 10 (22H2) on 64-bit ARMv7 (Qualcomm Snapdragon 835 CPU)

Microsoft Windows [Version 10.0.19045.5198]

Mostly defaults. VSCode for GUI, REBASE by default

Editor Option: VisualStudioCode
Custom Editor Path:
Default Branch Option:
Path Option: Cmd
SSH Option: OpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: CRLFAlways
Bash Terminal Option: ConHost
Git Pull Behavior Option: Rebase
Use Credential Manager: Enabled
Performance Tweaks FSCache: Enabled
Enable Symlinks: Disabled
Enable FSMonitor: Disabled

I am running an older ARM on Windows CPU which isn't getting official Windows 11 support from Microsoft but still works well with just about every natively compiled application for Windows on ARM.

Details

I've tried both CMD and PowerShell. Bash will not launch due to error being reported.

.\sh.exe
git fetch
Git to work as expected, without throwing errors about the version of Windows
PS C:\Program Files\Git\bin> .\sh.exe
error launching git: This version of %1 is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher.
PS C:\MyGitProjectFolder> git fetch
error: cannot spawn C:/Program Files/Git/usr/bin/sh.exe: Function not implemented
error: cannot spawn bash: Function not implemented
fatal: could not read Username for 'https://github.com': No such file or directory
Not related to repository
dscho commented 15 hours ago

This is sadly expected. Windows 10 only runs i686 code (also known as x86, i.e. 32-bit AMD/Intel) in emulation, and not x86_64 (also known as x64, i.e. 64-bit AMD/Intel). However, for technical reasons Git Bash does not yet support Windows/ARM64 natively.

I tried to clarify this in this comment.

MikeFarrington commented 7 hours ago

This is sadly expected. Windows 10 only runs i686 code (also known as x86, i.e. 32-bit AMD/Intel) in emulation, and not x86_64 (also known as x64, i.e. 64-bit AMD/Intel). However, for technical reasons Git Bash does not yet support Windows/ARM64 natively.

I tried to clarify this in this comment.

Ah, that explains it. I wonder if the x86/32-bit bash shell should be included for the very few like me who still have these ARMv7 WOA computers in the wild (since there is no upgrade path to Windows 11 w/amd64 WoW emulation)? I know Git for Windows is looking to drop x86 support overall, but maybe this one component can live on in the arm64 package until it has a natively compiled version available.

There's so few of us though that it's probably not worth the effort. Basically, only a handful of Asus NovaGo owners who also happen to use Git.

Unfortunately, the x86 version isn't working under emulation. It just sort of hangs and does nothing on a 'git fetch'.