问题描述
我正在尝试制作一个使用 Imagemagick 的 py2app
from wand.image import Image
导入在我的机器上运行良好,但在尝试在其他机器上启动应用程序时会导致以下错误:
Traceback (most recent call last):
File "wand/api.pyc",line 151,in <module>
File "wand/api.pyc",line 140,in load_library
OSError: cannot find library; tried paths: []
During handling of the above exception,another exception occurred:
Traceback (most recent call last):
File "/Users/jcampana/Downloads/HEIC sweeper/HEIC sweeper.app/Contents/Resources/__boot__.py",line 110,in <module>
_run()
File "/Users/jcampana/Downloads/HEIC sweeper/HEIC sweeper.app/Contents/Resources/__boot__.py",line 84,in _run
exec(compile(source,path,"exec"),globals(),globals())
File "/Users/jcampana/Downloads/HEIC sweeper/HEIC sweeper.app/Contents/Resources/converter.py",line 7,in <module>
from wand.image import Image
File "wand/image.pyc",line 18,in <module>
File "wand/assertions.pyc",line 155,in <module>
File "wand/color.pyc",line 10,line 177,in <module>
>ImportError: MagickWand shared library not found.
You probably had not installed ImageMagick library.
Try to install:
brew install freetype imagemagick
2021-03-29 20:19:21.001 converter[3593:128301] converter Error
为了解决这个问题,我尝试在 setup.py 选项字段 "packages":"wand"
中包含 Wand 以及使用以下命令包含所有站点包:python3 setup.py py2app --site-packages
但都没有成功。将不胜感激包含 .app 包中的模块的任何帮助。
注意:我还有其他依赖项,例如 from watchdog.observers import Observer
似乎捆绑得很好
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)