How to open a KDE konsole app via QProcess?
Solved
General and Desktop
-
The test app is a widget application which uses
QProcess
to call different terminal emulators likegnome-terminal
, the KDE appkonsole
orxdg-terminal
on different Linux distributions. All my tests where successful except the ones on KDE. There I always end up with/usr/bin/konsole: /home/user/Qt/5.12.5/gcc_64/lib/libQt5Core.so.5: version `Qt_5.9.4_PRIVATE_API' not found (required by /usr/lib64/libKF5XmlGui.so.5)
Exempels to call
konsole
on KDE:QProcess::startDetached("konsole"); QProcess::startDetached("kstart", {"konsole"}); QProcess::startDetached("xdg-terminal");
Is there any possibility to open a KDE
konsole
window even if there is a Qt version mismatch? -
Set the correct PATH before starting the QProcess -> https://doc.qt.io/qt-5/qprocess.html#processEnvironment
-
Thanks, setting the LD_LIBRARY_PATH worked.
environment.insert("LD_LIBRARY_PATH", "/usr/lib64/");
-
@SandyLocke said in How to open a KDE konsole app via QProcess?:
worked
so please mark your post as solved then. Thanks.