0

I met this error when trying to run "sudo" command on MacOS:

> sudo           
dyld[89850]: Symbol not found: _libiconv
  Referenced from: /opt/local/lib/libintl.8.dylib
  Expected in: /usr/lib/libiconv.2.dylib
[1]    89850 abort      sudo

Anyone can help?

New contributor
Yu Smth is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
5
  • 1
    Is this the standard sudo or one you installed yourself?
    – nohillside
    Sep 23 at 8:23
  • I think it's standard.
    – Yu Smth
    Sep 23 at 8:39
  • 2
    Run which sudo in terminal Sep 23 at 9:00
  • If /opt/local/lib is mentioned it's probably a partially incomplete MacPorts install. It may be the macOS sudo finding a symlink in an old MacPorts lib, whereas the macOS sudo expects it in `/usr/lib'. There may be some library path shenanigans going on. Sep 23 at 11:34
  • I'd also ask you to update the question with the output of /usr/bin/sudo otool -L $(which sudo), but as it's likely to fail if you think your system is using the standard one, given your primary problem, it may be difficult. If you have MacPorts installed, I'd suggest following its uninstall instructions and then reinstalling. Please update your question with your version of macOS, and what hardware. Sep 23 at 12:56

0

You must log in to answer this question.

Browse other questions tagged .