Python: OSError: cannot load library libcairo.so.2
在新服务器上配置conda 环境,运行相关应用时,提示如下错误:
cannot load library ‘libcairo.so’: libcairo.so: cannot open shared object file: No such file or directory
cannot load library ‘libcairo.2.dylib’: libcairo.2.dylib: cannot open shared object file: No such file or directory
cannot load library ‘libcairo-2.dll’: libcairo-2.dll: cannot open shared object file: No such file or directory
参考网上资料:
安装:pycairo-1.20.1.tar.gz
但还是不行,报错:
后续查阅资料,表明可能是缺少下列包
yum install glib-devel
yum install atk-devel
yum install pango-devel
yum install cairo-devel
安装后问题解决!
参考链接:https://blog.csdn.net/googler_offer/article/details/100673536
由于时间仓促,没有完整记录下相关的参考文章链接 及完整的问题解决流程。仅供大家参考!
在此表示歉意。