Closed itsmattkc closed 1 year ago
I believe homebrew seats a prefix variable that could be used as a bit of a cleaner way of doing this.
Please fix this. 🤕
Is there a reason this can't be merged?
All I did was to find the openssl1.0 version of the lib, symlink the old path to it, and the run the install, and it completed fine:
sudo find /opt -name "libcrypto.a"
/opt/homebrew/Cellar/openssl@1.1/1.1.1m/lib/libcrypto.a
/opt/homebrew/Cellar/openssl@1.0/1.0.2u/lib/libcrypto.a
sudo mkdir /usr/local/opt
sudo ln -s /opt/homebrew/Cellar/openssl@1.0/1.0.2u /usr/local/opt/openssl
brew install sidneys/homebrew/chntpw
sudo rm -fr /usr/local/opt
I'm not 100% sure if this is the best solution, but it does work. Homebrew on M1 appears to use the prefix
/opt/homebrew
rather than/usr/local/opt
used previously and hardcoded into the chntpw Makefile, leading to the following error:This fix checks if the CPU is ARM, and forces the OpenSSL path to
/opt/homebrew
in chntpw if so. There might be a cleaner solution by checking the Homebrew version or something like that, but I'm not overly familiar with how that might work.