一. 背景
從向日葵官網下載了linux版向日葵遠程控制端軟件,解壓后直接執行Sunlloginremote發現以下錯誤:
jello@jello:~/sunlogin_remote_linux$ ./SunloginRemote
This application failed to start because it could not find or load the Qt platform plugin "xcb".
Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, xcb.
Reinstalling the application may fix this problem.
Aborted (core dumped)
二. 解決方案
安裝32bit的依賴庫,命令如下:
sudo apt-get install libsm-dev:i386
三. 如何知道缺少sm依賴庫呢?
3.1 先指定一個環境變量以便進入QT的調試模式,將會輸出一些調試信息
export QT_DEBUG_PLUGINS=1
3.2 啟動程序后輸出以下錯誤信息
QLibraryPrivate::loadPlugin failed on "/home/jello/sunlogin_remote_linux/plugins/platforms/libqxcb.so" : "Cannot load library /home/jello/sunlogin_remote_linux/plugins/platforms/libqxcb.so: (libSM.so.6: cannot open shared object file: No such file or directory)"
