centos7 如何处理 libQt5Widgets.so.5 问题

今天一同事发过来一个报错信息,提示以下:
error while loading shared libraries: libQt5Widgets.so.5: cannot open shared object file: No such file or directory
查了几个博客分享的解决方法,装了一些包(例如 libGL libGL-devel)等无果,后来发现了一个 rpm 包的网站 rpm.pbone.net,而后安装了一个线上rpm包;
开始提示说有依赖:

[root@log ~]# rpm -ivh ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
获取ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
错误:依赖检测失败:
libQt5Core.so.5()(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5Core.so.5(Qt_5)(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5Core.so.5(Qt_5.6)(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5Core.so.5(Qt_5_PRIVATE_API)(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5DBus.so.5()(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5DBus.so.5(Qt_5)(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5Network.so.5()(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
libQt5Network.so.5(Qt_5)(64bit) 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要
qt5-qtbase(x86-64) = 5.6.2-1.el7 被 qt5-qtbase-gui-5.6.2-1.el7.x86_64 须要centos

而后我安装了 qt5-qtbase
[root@log ~]# yum install -y qt5-qtbase
安装完成后,再执行上条rpm安装时,就OK了
[root@log ~]# rpm -ivh ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
获取ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
准备中... ################################# [100%]
正在升级/安装...
1:qt5-qtbase-gui-5.6.2-1.el7 ################################# [100%]ide

以后再执行命令就不报错了,
[root@log ~]# /home/arith/sources/PredictConsole
PredictConsole v0.9, 2017
Usage:
PredictConsole inFileSale inFileWeather startPredictDay lenth outFile dir网站

  • -inFileSale: An absolute file path of history sale data.
  • -inFileWeather: An absolute file path of history Weather data.
    -startDay: The day start to predict, should early than max date in inFileData. in string type like '2017/1/1'. Default value is 0.
    -lenth: The disired lenth of predicting days, in UINT type. Default value is 7.
    -outFile: An absolute file path of destination predict result, in String type. Default value is 'result+time.csv'.
    -dir: Optional. An absolute directory path which includes the /data subdir, in String type. Default value is './'.

-- 2018-04-23 --ui

今天安装的时候出现了不同的问题。
[root@iZwz9chwdyqnsgcy638aafZ ~]# rpm -ivh ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
Retrieving ftp://mirror.switch.ch/pool/4/mirror/centos/7.4.1708/os/x86_64/Packages/qt5-qtbase-gui-5.6.2-1.el7.x86_64.rpm
error: Failed dependencies:
libEGL.so.1()(64bit) is needed by qt5-qtbase-gui-5.6.2-1.el7.x86_64
libxcb-icccm.so.4()(64bit) is needed by qt5-qtbase-gui-5.6.2-1.el7.x86_64
libxcb-render-util.so.0()(64bit) is needed by qt5-qtbase-gui-5.6.2-1.el7.x86_64.net

后来直接使用 yum install -y qt5-qtbase-gui 安装解决的。。。ci

具体分析待后续相似状况跟进..get

相关文章
相关标签/搜索