如何解决安装python时出错:/usr/lib/qgis/crssync:符号查找错误:/usr/lib/libgdal.so.26:未定义符号:GEOSMakeValid_r
在 Ubuntu 18.04.5 LTS 上,尝试安装 python3-venv
或尝试卸载 python3.8
时,我收到以下错误,该错误从以下行开始:
/usr/lib/qgis/crssync: symbol lookup error: /usr/lib/libgdal.so.26: undefined symbol: GEOSMakeValid_r
有人可以帮我解决这个问题吗?可能出了什么问题? 提前致谢!
❯ sudo apt-get install python3-venv
Reading package lists... Done
Building dependency tree
Reading state information... Done
python3-venv is already the newest version (3.6.7-1~18.04).
0 upgraded,0 newly installed,0 to remove and 3 not upgraded.
4 not fully installed or removed.
After this operation,0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up qgis-providers (3.10.12+dfsg-1~bionic1) ...
/usr/lib/qgis/crssync: symbol lookup error: /usr/lib/libgdal.so.26: undefined symbol: GEOSMakeValid_r
dpkg: error processing package qgis-providers (--configure):
installed qgis-providers package post-installation script subprocess returned error exit status 127
dpkg: dependency problems prevent configuration of qgis:
qgis depends on qgis-providers (= 3.10.12+dfsg-1~bionic1); however:
Package qgis-providers is not configured yet.
dpkg: error processing package qgis (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python3-qgis:
python3-qgis depends on qgis-providers (= 3.10.12+dfsg-1~bionic1); however:
Package qgis-providers is not configured yet.
dpkg: error processing package python3-qgis (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of qgis-plugin-grass:
qgis-plugin-grass depends on qgis (= 3.10.12+dfsg-1~bionic1); however:
Package qgis is not configured yet.
dpkg: error processing package qgis-plugin-grass (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because MaxReports is reached already
Errors were encountered while processing:
qgis-providers
qgis
python3-qgis
qgis-plugin-grass
E: Sub-process /usr/bin/dpkg returned an error code (1)
解决方法
尝试在 ubuntu 18.04 上安装 qgis 时遇到了同样的问题和错误消息。
根据此讨论中的提示 https://github.com/OSGeo/gdal/issues/2214,问题似乎是 gdal 需要 geos-3.8.0 或更新版本,而在我的系统上安装了 geos-3.5.0。
从源代码手动安装 geos-3.8.1(在此处找到:https://trac.osgeo.org/geos/)解决了问题并允许我安装 qgis。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。