Macports and issues with git

September 29, 2010 § 5 Comments

I was upgrading macports and ruby installation on my mac when I noticed that git stopped working. Every time I ran a git command I got the error below:

dyld: Library not loaded: /opt/local/lib/libiconv.2.dylib
Referenced from: /opt/local/bin/git
Reason: Incompatible library version: git requires version 8.0.0 or later, but libiconv.2.dylib provides version 7.0.0

I checked the libiconv.2.dylib,

> otool-L / opt/local/lib/libiconv.2.dylib
/opt/local/lib/libiconv.2.dylib (compatibility version 8.0.0, current version 8.0.0)
/usr/lib/lib System.B.dylib (compatibility version 1.0.0, current version 125.0.1)

I struggled for hours trying to fix this issue, but was at a loss. Then I viewed already installed libiconv:
> sudo port installed libiconv
The following ports are currently installed:
libiconv@1.13.1_0 (active)

I tried switching back to the older version
> sudo port activate libiconv@1.13_0

And voila, the switch resolved the issue. Hope this helps people that encounter this.

Where Am I?

You are currently browsing entries tagged with git at There is something called standard work, but.

%d bloggers like this: