.netcore在linux上使用FreeSpire.Doc向Word中添加图片报错:System.DllNotFoundException: Unable to load shared library 'libgdiplus' or one of its dependencies.

按照网上的做法ubuntu安装libgdiplus后又报了另一个错误:

System.DllNotFoundException: Unable to load shared library 'libSkiaSharp' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: liblibSkiaSharp: cannot open shared object file: No such file or directory

最终搜索到libgdiplus更简单的解决方案:nuget安装SkiaSharp.NativeAssets.Linux.NoDependencies包解决

 

 

https://stackoverflow.com/questions/53693042/dllnotfoundexception-using-skiasharp-1-68-on-linux

 

word转pdf发现有乱码,查找一番后发现是linux缺少中文字体,执行如下命令

sudo apt-get install fonts-wqy-zenhei

安装完中文字体 问题解决

posted @ 2021-10-12 20:14  Ace001  阅读(1071)  评论(3编辑  收藏  举报