How to fix Homebrew install failing with "Error: Failed to install Homebrew Portable Ruby"
Asked Answered
C

2

5

Here's some info:

  • I do not have admin privileges to my machine.
  • I'm running macOS Catalina 10.15.5.
  • I use zshell.
  • I have Xcode command-line tools 11.5 but NOT XCode itself.
  • I'm running Ruby v2.6.3p62 (2019-04-16 revision 67580) [universal.x86_64-darwin19]

When running the install command on the Homebrew page I get the following error:

==> Downloading https://homebrew.bintray.com/bottles-portable-ruby/portable-ruby-2.6.3_2.yosemite.bottle.tar.gz
################################################                                                                                                                                                           24.1%
curl: (56) LibreSSL SSL_read: SSL_ERROR_SYSCALL, errno 54
Error: Checksum mismatch.
Expected: b065e5e3783954f3e65d8d3a6377ca51649bfcfa21b356b0dd70490f74c6bd86
  Actual: be732ceabd97bbe69929621075c00c2e1709e30b8ab9a9ba3b7064a14ad6bbff
 Archive: /Users/e113991/Library/Caches/Homebrew/portable-ruby-2.6.3_2.yosemite.bottle.tar.gz
To retry an incomplete download, remove the file above.
Error: Failed to install Homebrew Portable Ruby (and your system version is too old)!
Failed during: /usr/local/bin/brew update --force --quiet

Running brew doctor reminds me:

Error: Failed to install Homebrew Portable Ruby (and your system version is too old)!

Notice it is installing Yosemite, not Catalina. Why? I tried to use git clone to copy it to my usr/local directory but I don't have write privileges to that. I tried every other solution on Stack Overflow to no avail.

Carline answered 11/3, 2021 at 21:23 Comment(7)
Is your copy of command line tools up to date? Mine shows "xcode-select version 2384" in response to xcode-select -v .Chiliad
xcode-select version 2373. I feel like that should be sufficient. Thanks thoughCarline
This may be of interest to you.Chiliad
I stand correct @pjs! However, I can use git. Maybe this version limits Homebrew though? Since i don't have admin privileges, I'm having a hard time getting xcode installed. I guess I'll elevate to management to try to get XCode. Hopefully that will fix. Thank you!Carline
So I installed XCode and removed & reinstalled the command line tools. Still getting the same error. Any other ideas?Carline
Sorry to hear that! When you ran XCode the first time, did you install the additional tools when prompted? Also, once that's complete go to XCode -> Preferences -> Locations and make sure the "Command Line Tools:" selector points to the latest and greatest. If that doesn't fix it, I'm out of ideas.Chiliad
I did what you suggested last and it still doesn't install. Thank you for your efforts.Carline
R
1

I ran into the same problem when trying to install on my Macbook (Mojave 10.14.6 XCode 11.3 CLT 11.3).

For me, it turned out that access to the internet for brew was blocked without notice by a firewall in the background. Simply adding a rule did the trick.

Ranitta answered 25/3, 2021 at 13:2 Comment(0)
V
0

it worked by disabling VPN for me, same firewall block issue.

Voluble answered 16/7 at 3:55 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.