Remove libwayland dependency on project
-
Hello,
I have written a C++ QT program which builds up on QT5.9.5.
Whenever I compile the program for Linux (amd64), it is linked agains:
- libwayland-client.so.0
- libwayland-server.so.0
I do not see the word "wayland" anywhere during the compile / linking process. So I strongly assume that it is somehow linked indirectly by QT5.9.5. I have analyzed the binary file using "ldd".
However, I do not need it.
The question now is, how can I get rid of this linkage?
I have a QT .pro file and standard QT5.9.5 installed on my machine.Is there a switch like:
QT -= waylandI can use in my .pro file for that?
And if yes, where can I find all possible switches for QT? This must be somewhere in the QT documentation, but I am not able to find it.
Thank you! Kind Regards,
W -
check if you are using wayland. If x11 is used, wayland lib is not needed.
echo $XDG_SESSION_TYPEalso it could be the case that qt was installed under wayland. Then you switched to x11. If yes, purge qt and reinstall in under x11.
@W-U said in Remove libwayland dependency on project:
Is there a way to install "qt5.9.5" from official binaries without wayland support, but only X11 maybe?
dont think so. you will have to compile Qt yourself.
@JoeCFD
it doesnt matter what the current runtime environment is. The lib is linked against libwayland, thats it. -
Hello,
I have written a C++ QT program which builds up on QT5.9.5.
Whenever I compile the program for Linux (amd64), it is linked agains:
- libwayland-client.so.0
- libwayland-server.so.0
I do not see the word "wayland" anywhere during the compile / linking process. So I strongly assume that it is somehow linked indirectly by QT5.9.5. I have analyzed the binary file using "ldd".
However, I do not need it.
The question now is, how can I get rid of this linkage?
I have a QT .pro file and standard QT5.9.5 installed on my machine.Is there a switch like:
QT -= waylandI can use in my .pro file for that?
And if yes, where can I find all possible switches for QT? This must be somewhere in the QT documentation, but I am not able to find it.
Thank you! Kind Regards,
W@W-U
if you check with ldd the wayland dependency might also come from another dependency.
For example libQt5Gui.so might already have the dependency, because it was configured this way? So check each dependency libs for their dependencies.Try
readelf -d myApp | grep NEEDED
to show the direct dependencies. -
Ok, yes. I thought about that also.
It seems that libQt5WebEngine.so uses for example wayland.Is there a way to install "qt5.9.5" from official binaries without wayland support, but only X11 maybe?
-
check if you are using wayland. If x11 is used, wayland lib is not needed.
echo $XDG_SESSION_TYPEalso it could be the case that qt was installed under wayland. Then you switched to x11. If yes, purge qt and reinstall in under x11.
@W-U said in Remove libwayland dependency on project:
Is there a way to install "qt5.9.5" from official binaries without wayland support, but only X11 maybe?
dont think so. you will have to compile Qt yourself.
@JoeCFD
it doesnt matter what the current runtime environment is. The lib is linked against libwayland, thats it.