How to installing sha1sum in MAC OS?

J4cK picture J4cK · Feb 13, 2015 · Viewed 18.5k times · Source

Problem: To get the sha1sum value of a file in MAC OS i run the following command

sha1sum file_name

The error I got is following

perl version 5.18.2 can't run /usr/bin/sha1sum.  Try the alternative(s):

/usr/bin/sha1sum5.16 (uses perl 5.16)

Run "man perl" for more information about multiple version support in
Mac OS X.

I tried to install textutils and coreutils, but both failed. Can anyone suggest me how I can resolve the issue ? Thanks in advance.

Answer

Federico Hernández picture Federico Hernández · Mar 16, 2017

You can install it in Mac OS using homebrew with brew install md5sha1sum. Got the info from this link https://raamdev.com/2008/howto-install-md5sum-sha1sum-on-mac-os-x/