dyld: Library not loaded: @rpath/libswiftDispatch.dylib

六眼飞鱼酱① 提交于 2019-12-05 17:48:36

I am using AVG Free for Mac. Yesterday it removed libswiftDispatch.dylib to quarantine because of 'MacOS:BitCoinMiner-AS'. This seems like a false positive, see: https://discussions.agilebits.com/discussion/86860/avg-quarantined-1password-libswiftdispatch-dylib/p2 https://forum.avast.com/index.php?topic=216164.msg1449648#msg1449648 (AVG and Avast are the same company)

So for me the fix was restoring this file from quarantine.

Evgeny Karkan

Looks like you are using Swift code in Objective-C project, right?
If so please be aware that:

"If you are building an app that does not use Swift but embeds content such as a framework that does, Xcode will not include these libraries in your app."

Apple docs

To fix your problem try the following steps:

  • go to your app target's Build Settings in Xcode
  • find Always Embed Swift Standard Libraries setting
  • set it from NO (which is default for Obj-C projects) to YES

After it clean the project (Shift+Cmd+K) and then build (Cmd+B) it again.

I have just encountered the same problem. This occurred following the install of the High Sierra Supplemental update 10.13.3 supplemental. The same library appears to be referenced by git, so git on my machine is failing.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!