Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

install_name_tool reporting malformed object

Everytime I try to use install_name_tool on my machine it reports the following

install_name_tool: object: Abacate malformed object (unknown load command 4)

I read that it could be an error when building the binary. In order to check I create the simplest hello world c++ program and try to change something using install_name_tool. Didn't work. What Am I doing wrong?

Currently I have XCode 4.2 running Snow Leopard OS.

like image 469
McLeary Avatar asked Feb 03 '23 05:02

McLeary


2 Answers

Apparently install_name_tool is not updated when XCode is updated. You need to install the Command Line Tools from XCode Preferences. See also install_name_tool on OS X Lion. This resolved the same error for me.

like image 152
Maarten O. Avatar answered Feb 20 '23 10:02

Maarten O.


Managed to make it work with Mac OS 10.9.3

https://github.com/Homebrew/homebrew/issues/26544

$$:~ otool -L /usr/bin/install_name_tool

/usr/bin/install_name_tool: /usr/lib/libxcselect.dylib (compatibility version 1.0.0, current version 1.0.0) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)

$$:~ pkgutil --file-info /usr/bin/install_name_tool

volume: / path: /usr/bin/install_name_tool pkgid: com.apple.pkg.Essentials pkg-version: 10.9.0.1.1.1306847324 install-time: 1390577801 uid: 0 gid: 0 mode: 755

No more errors on wget:

$$:~ wget dyld: Library not loaded:

@@HOMEBREW_PREFIX@@/opt/openssl/lib/libssl.1.0.0.dylib Referenced from: /usr/local/bin/wget Reason: image not found

like image 25
trigas Avatar answered Feb 20 '23 10:02

trigas