Closed UniqMartin closed 9 years ago
Thanks for the offer! The C library dependencies have always been a PITA, on all platforms.
This is why there is no active code in the master branch that uses any C libraries; everything is now pure Python, so this should no longer be an issue. A stable release based on the current master branch is forthcoming.
Linux/OSX/Windows users can just run setup.py install
to get up and running, though Python2 users are encouraged to install the python-lzma
module (this module is now standard in Python3); see the INSTALL.md file for more info.
Thanks for the quick response! I had failed to see that the only code referencing a shared library (binwalk.modules.hashmatch.HashMatch
using libfuzzy
) was no longer active …
One of the easiest and probably most common way to obtain
binwalk
on OS X is via Homebrew. However, the experience is suboptimal for people with a non-standard installation (i.e. install location is not/usr/local
). I'd like to help address that.The problem is inside src/binwalk/core/C.py, lines 128–131, that searches the following directories on OS X:
libs
directory (no longer needed since there are no longer any bundled libraries?)./opt/local/lib
(standard MacPorts installation)./usr/local/lib
(standard Homebrew installation)./usr/local/Cellar/<package>/<version>/lib
(package-specific prefix of a standard Homebrew installation).libfuzzy
that is part of thessdeep
package (“formula” in Homebrew-lingo), but the<package>
part is substituted with*fuzzy*
, so this never yields anything.My idea for a solution would be:
setup.py
, offer a switch--library-search-prefix=
that would default to/usr/local
.src/binwalk/core/C.py
.find_library
in theLibrary
class instead of the various hard-coded paths. (This could even be extended to all non-Windows platforms, not just OS X.)If this is an acceptable solution, I can try to come up with a pull request that implements this, though my Python skills are quite limited.