Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

homebrew - force install even with SHA1 mismatch

I'm installing something through homebrew but one of it's dependencies is failing to install, saying that the downloaded artifact has a different SHA1 checksum than what homebrew expects. The culprit is suite-sparse v4.2.1 and from checking the homebrew issue tracker, it seems the owner of this package has a tendency to make changes without bumping versions.

I have a ticket in with the homebrew experts to double check this package and vet the new SHA1. In the meantime..

Is it possible to force homebrew to install a package even if the SHA1 is incorrect?

I don't mind doing a little manual installing, so long as the package remains homebrew friendly and a future brew update will update to the latest version without issues.

like image 427
Sean Connolly Avatar asked Oct 06 '13 11:10

Sean Connolly


1 Answers

Warning: Only use this in cases you know what you are doing and trust the source of the formula AND the downloaded binary. If you randomly come across the SHA mismatch error when installing software via brew, do not proceed and report it here or in the respective formula repository. You might also be able to install an older version if available instead.

Assuming brew install <formula> failed with SHA mismatch:

  1. brew edit <formula> - should open editor
  2. comment out any sha... lines by prefixing with #
  3. save file
  4. brew install <formula>
like image 193
Alexander Klimetschek Avatar answered Oct 15 '22 19:10

Alexander Klimetschek