Git for Mac fails to launch: “illegal instruction”

2020-06-07 08:22发布

...I've looked pretty carefully (I believe), and have been unsuccessful at getting an installation of Git for my Mac.

For various reasons, I'm running 10.6.8 of Mac OS X and will not be changing that anytime soon.

I've already gathered and installed the bundle exposed here:

https://help.github.com/articles/set-up-git

The installation instructions are pretty clear, and it's obvious to me that the package installed. But any attempts to use the git client from the command line result in an "Illegal Instruction" error.

I've sifted pretty carefully through information available here:

http://git-scm.com/book/en/Getting-Started-Installing-Git

There is another bundle that seems to be available. It is called "GitHub for Mac 1.7.5, but it appears to require Mac OS X 10.7 or later.

Has anyone else encountered this difficulty? Must I build from source?

I'm a couple of hours of reading and hacking into this effort? Is there something obvious that I've not considered?

标签: macos git github
7条回答
Lonely孤独者°
2楼-- · 2020-06-07 08:38

Ref : https://help.github.com/articles/does-github-for-mac-run-on-os-x-10-6-snow-leopard

To quote:

Does GitHub for Mac run on OS X 10.6 Snow Leopard?

No, GitHub for Mac requires OS X 10.7 (Lion) or higher.

We made this decision because the app relies on a number of technologies which are not available in Mac OS X 10.6 or earlier. We want to provide the best experience possible for the app's users, so we've made the choice to only support 10.7 and above, and not make earlier versions available.

查看更多
聊天终结者
3楼-- · 2020-06-07 08:41

I had the same problem. There are various methods for downloading and installing git - Try macports or homebrew. The thing that finally worked for me was having xcode 3.2.6 installed with the additional command line tools - version 3.2 that comes with the leopard install disk wasn't enough. You can install xcode etc. from the disk and then run software update to upgrade it to 3.2.6.

查看更多
姐就是有狂的资本
4楼-- · 2020-06-07 08:47

The latest build for Snow Leopard in the official git-osx-installer repo is Git 2.3.5 currently. You can download it from http://sourceforge.net/projects/git-osx-installer/files/git-2.3.5-intel-universal-snow-leopard.dmg/download using web browser. This installation works for me on OS X 10.6.8.

Or you can check yourself for a newer version:
http://sourceforge.net/projects/git-osx-installer/files/

查看更多
爷、活的狠高调
5楼-- · 2020-06-07 08:51

I had this today on Snow Leopard after running the suggested git installer from git-scm. Really horrible. Found that installing Macports using their old Snow Leopard package and then

sudo port install git +svn +doc +bash_completion +gitweb

installs git plus its dependencies and git now works fine; version 1.9.3 installed and working on 10.6.8.

查看更多
乱世女痞
6楼-- · 2020-06-07 08:53

Yes - it seems that it does not support the older OS version (mine was 10.6.8). I upgraded to the newest Mac OS 10.9.4 (the installation will take a while), reinstalled the Git software (note that it will ask for xcode to be installed, which I proceeded), and everything works fine from there. Hope this helps.

查看更多
冷血范
7楼-- · 2020-06-07 08:58

I had this problem and was able to install a working version using Homebrew.

# first uninstall the broken version
# mount the DMG for the broken version using Finder
# "type" this with the tab key! it saves typing and fixes the version number
cd /Volumes/Git\ 2.0.1\ Snow\ Leopard\ Intel\ Universal/
./uninstall.sh
# make bash forget about the uninstalled binary
hash -r
cd

# now install the working version
# assumes you have Homebrew installed
brew install git
git version
查看更多
登录 后发表回答