问题描述
我试图在一个新的mac上修改我的 .bashrc
,并使用了一些别名,并且创建了一个 .bash_profile
尝试在打开终端时加载 .bashrc
。但是,每次尝试使用 git
命令时,它都会给我这个错误。
git status
dyld:懒惰符号绑定失败:找不到符号:_iconv_open
引用自:/ usr / bin / git
预计位于:/ opt / local / lib /libiconv.2.dylib
$ b $ dyld:找不到符号:_iconv_open
引用自:/ usr / bin / git
预计位于:/ opt / local / lib / libiconv。 2.dylib
Trace / BPT陷阱:5
我删除了 .bash_profile
,甚至恢复了 .bashrc
,但仍然不好。任何想法?
注意:我已经看过,但他的解决方案似乎不适用于我,因为我现在没有bash_profile了。
创建一个文件〜/ .bash_profile $> c $ c>并在其中放入
PATH = / usr / local / bin:$ PATH:/ opt / local / bin
export PATH
这似乎解决了这个问题。似乎问题出在路径上。
I was trying to fix up my .bashrc
on a new mac with some aliases I had and I had made a .bash_profile
to try to load up the .bashrc
when the terminal was opened. However, it has been giving me this error every time I try to use a git
command.
git status
dyld: lazy symbol binding failed: Symbol not found: _iconv_open
Referenced from: /usr/bin/git
Expected in: /opt/local/lib/libiconv.2.dylib
dyld: Symbol not found: _iconv_open
Referenced from: /usr/bin/git
Expected in: /opt/local/lib/libiconv.2.dylib
Trace/BPT trap: 5
I deleted the .bash_profile
and even reverted back the .bashrc
but still no good. Any ideas?
Side Note: I have looked at Git > dyld: lazy symbol binding failed: Symbol not found: _iconv_open but his solution doesn't seem to work for me as I have no bash_profile at all now.
Coworker figured it out for my situation.
Create a file ~/.bash_profile
and in it put
PATH=/usr/local/bin:$PATH:/opt/local/bin
export PATH
That seemed to fix it. Seems the issue was with the path.
这篇关于Git错误:dyld:懒符号绑定失败:未找到符号:_iconv_open的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!