Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Static linking on OpenSUSE then deploying on Ubuntu - which libraries to link?



  • After successfully linking my application to the static library in OpenSUSE, I copied it over to a qt-less Ubuntu machine only to find that xkbcommon and EGL are missing from the executable.

    I run ldd on my application in OpenSUSE, and this is what I get:

    @ linux-vdso.so.1 (0x00007fff5cdfe000)
    libX11-xcb.so.1 => /usr/lib64/libX11-xcb.so.1 (0x00007f2e9336f000)
    libXi.so.6 => /usr/lib64/libXi.so.6 (0x00007f2e9315f000)
    libSM.so.6 => /usr/lib64/libSM.so.6 (0x00007f2e92f57000)
    libICE.so.6 => /usr/lib64/libICE.so.6 (0x00007f2e92d3b000)
    libxcb.so.1 => /usr/lib64/libxcb.so.1 (0x00007f2e92b1c000)
    libfontconfig.so.1 => /usr/lib64/libfontconfig.so.1 (0x00007f2e928df000)
    libfreetype.so.6 => /usr/lib64/libfreetype.so.6 (0x00007f2e9264d000)
    libXrender.so.1 => /usr/lib64/libXrender.so.1 (0x00007f2e92443000)
    libXext.so.6 => /usr/lib64/libXext.so.6 (0x00007f2e92231000)
    libX11.so.6 => /usr/lib64/libX11.so.6 (0x00007f2e91ef3000)
    libEGL.so.1 => /usr/lib64/libEGL.so.1 (0x00007f2e91cd2000)
    libdl.so.2 => /lib64/libdl.so.2 (0x00007f2e91ace000)
    librt.so.1 => /lib64/librt.so.1 (0x00007f2e918c6000)
    libGL.so.1 => /usr/X11R6/lib64/libGL.so.1 (0x00007f2e916e4000)
    libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f2e914c6000)
    libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00007f2e911be000)
    libm.so.6 => /lib64/libm.so.6 (0x00007f2e90ebb000)
    libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f2e90ca4000)
    libc.so.6 => /lib64/libc.so.6 (0x00007f2e908f5000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f2e93571000)
    libuuid.so.1 => /usr/lib64/libuuid.so.1 (0x00007f2e906f0000)
    libXau.so.6 => /usr/lib64/libXau.so.6 (0x00007f2e904ec000)
    libexpat.so.1 => /usr/lib64/libexpat.so.1 (0x00007f2e902c2000)
    libz.so.1 => /lib64/libz.so.1 (0x00007f2e900ac000)
    libpng16.so.16 => /usr/lib64/libpng16.so.16 (0x00007f2e8fe6f000)
    libxcb-dri2.so.0 => /usr/lib64/libxcb-dri2.so.0 (0x00007f2e8fc6a000)
    libxcb-xfixes.so.0 => /usr/lib64/libxcb-xfixes.so.0 (0x00007f2e8fa63000)
    libgbm.so.1 => /usr/lib64/libgbm.so.1 (0x00007f2e8f85c000)
    libwayland-client.so.0 => /usr/lib64/libwayland-client.so.0 (0x00007f2e8f64f000)
    libwayland-server.so.0 => /usr/lib64/libwayland-server.so.0 (0x00007f2e8f43f000)
    libudev.so.1 => /usr/lib64/libudev.so.1 (0x00007f2e8f22d000)
    libdrm.so.2 => /usr/lib64/libdrm.so.2 (0x00007f2e8f021000)
    libatiuki.so.1 => /usr/lib64/libatiuki.so.1 (0x00007f2e9364c000)
    libffi.so.4 => /usr/lib64/libffi.so.4 (0x00007f2e8ee19000)
    libselinux.so.1 => /lib64/libselinux.so.1 (0x00007f2e8ebf5000)
    libpcre.so.1 => /usr/lib64/libpcre.so.1 (0x00007f2e8e98f000) @

    Am I supposed to statically link all of these before deployment?


Log in to reply