5

So I have a computer that is stuck on Snow Leopard.

How do I install Homebrew on such a old computer? Is this even possible?

I tried the following command:

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

However this gives me an error about needing git and I don't know how to install an old version of that.

5
  • 2
    I'm guessing you've tried to install brew on Snow Leopard? If so, what have you tried? Do you get any error messages?
    – Monomeeth
    Apr 10 '17 at 4:27
  • @Monomeeth yes is throws an error saying I need git. I do not know how to install an old version of git.
    – William
    Apr 10 '17 at 12:09
  • Thanks for that, but can I ask you add to the question the actual Terminal command you tried using? This helps ensure that I (or others) don't suggest what you've already tried. :)
    – Monomeeth
    Apr 10 '17 at 21:41
  • @Monomeeth included the command I'm not sitting at the computer currently but it says I need git
    – William
    Apr 10 '17 at 21:44
  • I've added an answer. Very similar to what you tried but without the /usr/bin/ preceding it. I've just tested it on a Late-2008 MBP running Snow Leopard 10.6.8 and it installs fine (remembering to follow it up with the second command).
    – Monomeeth
    Apr 10 '17 at 22:27
2

If, like me, you're not very familiar with Ruby or curl, here's a verbose (and slightly updated version) to the otherwise excellent answer by @rogerdpack:

  1. Download https://github.com/Homebrew/brew/tarball/master in a browser
  2. Make sure it's saved in ~/Downloads/ (the name will be Homebrew-brew-[latest version number etc.].tar.gz)
  3. Download https://github.com/Homebrew/homebrew-core/tarball/master in a browser
  4. Make sure it's saved in ~/Downloads/ (the name will be Homebrew-homebrew-core-[latest version number].tar)
  5. Save the install file to a file, by running this command in terminal: curl -o ~/Downloads/install.txt https://raw.githubusercontent.com/Homebrew/install/master/install
  6. Edit ~/Downloads/install.txt and A. replace /usr/bin/curl -#{curl_flags} #{BREW_REPO}/tarball/master with cat ~/Downloads/Homebrew-brew-[version number etc.].tar.gz B. replace /usr/bin/curl -#{curl_flags} #{CORE_TAP_REPO}/tarball/master with cat ~/Downloads/Homebrew-homebrew-core-[version number etc.].tar.gz
  7. Install by running this command in terminal: ruby -S ~/Downloads/install.txt

In my case, the exact filenames were Homebrew-brew-1.5.14-3-g94c0d83.tar.gz and Homebrew-homebrew-core-b83864a.tar

2

Apparently the way for Snow Leopard is to "install as normal" however that gives me this

...
curl: (35) error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version
Failed during: /bin/bash -o pipefail -c '/usr/bin/curl -fsSL https://github.com/Homebrew/brew/tarball/master | /usr/bin/tar xz -m --strip 1'
rogers-macbook:temp rdp$ curl https://github.com/Homebrew/brew/tarball/master
curl: (35) error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version

Work around:

curl https://raw.githubusercontent.com/Homebrew/install/master/install > install

now download https://github.com/Homebrew/brew/tarball/master in a browser, ex: to this filename ~/Downloads/Homebrew-brew-1.5.8-16-g1ca2ee6.tar.gz

now edit file named install, replace /usr/bin/curl -#{curl_flags} #{BREW_REPO}/tarball/master with cat ~/Downloads/Homebrew-brew-1.5.8-16-g1ca2ee6.tar.gz

next download https://github.com/Homebrew/homebrew-core/tarball/master in a browser, ex: to ~/Downloads/Homebrew-homebrew-core-bd37905.tar.gz

now edit install file, replace /usr/bin/curl -#{curl_flags} #{CORE_TAP_REPO}/tarball/master with cat ~/Downloads/Homebrew-homebrew-core-bd37905.tar.gz

now run it ruby install

You'll probably still need xcode installed, and use the steps in Brad Bell's answer to use it to install curl.

Another option (untested) might be to install xcode, then build curl locally from source (ex: download https://curl.haxx.se/download/curl-7.59.0.tar.bz2 with a browser, unzip it, build as normal to some temp location), put that location's bin folder first in your PATH, then run the normal homebrew installation instructions.

Tigerbrew might be an option as well.

5
  • What issue is this getting around?
    – William
    Mar 5 '18 at 22:25
  • 1
    This failure when installing: curl: (35) error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version
    – rogerdpack
    Mar 6 '18 at 4:41
  • FYI, the actual issue here is outdated SSL support. You can fix it by using a proxy (without replacing the system curl). Apr 7 at 2:28
  • @Wowfunhappy instructions welcome, I'm not sure how anyway LOL :)
    – rogerdpack
    Apr 7 at 16:55
  • 1
    @rogerdpack I'm trying not to plug my own stuff too much. :) jonathanalland.com/legacy-mac-proxy.html Note that curl ignores the system proxy settings by default, you need to set the HTTPS_PROXY environment variable. Also, I very highly recommend using MacPorts over Homebrew on old systems, because MacPorts actually supports them. Apr 7 at 17:40
2

Don't use Homebrew, use MacPorts!

MacPorts does lots of work to support old versions of OS X. They backport kernel symbols and standard libraries. They maintain bespoke patches and a Snow Leopard build bot. MacPorts might just have the best legacy support of any Mac project under active development, and it's really kind of incredible.

Running Snow Leopard in 2021, and choosing Homebrew over MacPorts, is absolute madness! There is a functionally-equivalent project which actively supports your operating system. Use that one.

1

The current way to install Homebrew in Snow Leopard is to use the following command:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

After running this ensure you follow it up with:

brew update --force

Let me know how you go.

2
  • 1
    I tried this and my git version isn't new enough (which is also why my current installation of homebrew on Lion is broken). Oct 7 '17 at 1:06
  • curl: (35) error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version but see some of the other answers...
    – rogerdpack
    Jun 16 '18 at 23:11
0

After installing Homebrew using the above steps, you still may not be able to install anything with it, because it wants to download packages using the same outdated version of curl. So you'll need to follow up by installing the homebrew version of curl.

  1. Do brew install curl
  2. Note the file that fails to download, i.e. https://curl.haxx.se/download/curl-7.59.0.tar.bz2
  3. Download the file using a browser and place it in ~/Library/Caches/Homebrew
  4. repeat brew install curl
  5. If there are any dependencies that still fail to download, go back to step 2
  6. Because the new curl is keg-only, make it your default by running export PATH="/usr/local/opt/curl/bin:$PATH" as well as placing that in your ~/.bash_profile with echo 'export PATH="/usr/local/opt/curl/bin:$PATH"' >> ~/.bash_profile
  7. If you have more failed downloads with curl: (77) error setting certificate verify locations... download cacert.pem from https://curl.haxx.se/docs/caextract.html and copy it to /usr/local/etc/openssl/cert.pem

You should now have a fully working Homebrew!

3
  • How do I run brew install curl with out hombrew installed?
    – William
    Apr 22 '18 at 1:25
  • @William First you follow the instructions by user1092247 or rogerdpack. The steps by user1092247 worked for me. It installs homebrew, but most brew install ... commands still fail
    – Brad Bell
    Apr 22 '18 at 5:11
  • did you need xcode installed first?
    – rogerdpack
    Jun 16 '18 at 23:13
0

Install the latest version of curl using macport, then install brew (or tigerbrew) using the normal method.

  1. Install macport using an installer that can be downloaded here, choose the one for your version of OS X. Support goes back to 10.4 Tiger. https://github.com/macports/macports-base/releases/tag/v2.6.4

  2. After installing is done. Open a new terminal, and type port install curl

  3. you may also need to install git, port install git

  4. Follow the instruction at https://brew.sh/ to install homebrew /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" 4a. if brew refuse to install because your machine is too old as my early 2006 iMac 20in running on the 32-bit Core Duo. Try tigerbrew ruby -e "$(curl -fsSkL raw.github.com/mistydemeo/tigerbrew/go/install)", which works on my old iMac perfectly.

2
  • 1
    If you install macports then just use that for all. You don't need homebrew. Also macports and homebre don't interact well especially on older versions of OSX
    – mmmmmm
    Apr 7 at 18:25
  • agree. macport is actually a much better choice than homebrew for old mac
    – Kenny Ye
    May 8 at 3:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .