Build QT static libraries, with LinuxFB and minimum dependencies.



  • Hi! I need to create application for embedded Linux systems. On this Linux system I have only Linux kernel, modules and Busybox.
    I want create QT windows application and install it to my embedded systems. Now I need only qt base and widgets. How to make do it right and easily?
    My platforms: PC Virtual Box and Raspberry PI for debug. And my ARM Custom Board.
    I try create this application for PC. I download QT sources, build it with configure -static option and install. I also add to PATH variable. But when I build simple application it depend from several libraries. I have this errors when run qmake && make:

    [oleg@reffum qt_static]$ make
    g++ -static -o main main.o main_plugin_import.o   -L/opt/Qt5.8/lib -L/opt/Qt5.8/plugins/platforms -lqwayland-egl -lwayland-egl -lqwayland-generic -lqwayland-xcomposite-egl -lqwayland-xcomposite-glx -lQt5WaylandClient -lXcomposite -lwayland-client -lwayland-cursor -lqxcb -L/opt/Qt5.8/plugins/xcbglintegrations -lqxcb-egl-integration -lqxcb-glx-integration -lQt5XcbQpa -lxcb-xinerama -lQt5LinuxAccessibilitySupport -lQt5AccessibilitySupport -lQt5GlxSupport -lXrender -lxcb-xkb -lxcb-sync -lxcb-xfixes -lxcb-randr -lxcb-image -lxcb-shm -lxcb-keysyms -lxcb-icccm -lxcb-shape -lxcb-glx -lXi -lSM -lICE -lxcb-render-util -lxcb-render -lxkbcommon-x11 -L/opt/Qt5.8/plugins/imageformats -lqgif -lqicns -lqico -lqjp2 -ljasper -lqjpeg -ljpeg -lqmng -lmng -lqtga -lqtiff -ltiff -lqwbmp -lqwebp -lwebp -lwebpdemux -L/opt/Qt5.8/plugins/egldeviceintegrations -lqeglfs-kms-egldevice-integration -lqeglfs-kms-integration -lQt5EglFsKmsSupport -lgbm -ldrm -lqeglfs-x11-integration -lQt5EglFSDeviceIntegration -lQt5EventDispatcherSupport -lQt5ServiceSupport -lQt5ThemeSupport -lQt5DBus -ldbus-1 -lQt5FontDatabaseSupport -lQt5FbSupport -lQt5EglSupport -lXext -lQt5PlatformCompositorSupport -lQt5InputSupport -lmtdev -linput -lxkbcommon -lQt5Gui -lpng16 -lharfbuzz -lQt5DeviceDiscoverySupport -ludev -lQt5Core -licui18n -licuuc -licudata -lm -ldl -lrt -lz -lpcre16 -lgthread-2.0 -lglib-2.0 -lxcb -lX11 -lX11-xcb -lfontconfig -lfreetype -lts -lEGL -lGL -lpthread 
    /usr/bin/ld: cannot find -lwayland-egl
    /usr/bin/ld: cannot find -lXcomposite
    /usr/bin/ld: cannot find -lwayland-client
    /usr/bin/ld: cannot find -lwayland-cursor
    /usr/bin/ld: cannot find -lxcb-xinerama
    /usr/bin/ld: cannot find -lXrender
    /usr/bin/ld: cannot find -lxcb-xkb
    /usr/bin/ld: cannot find -lxcb-sync
    /usr/bin/ld: cannot find -lxcb-xfixes
    /usr/bin/ld: cannot find -lxcb-randr
    /usr/bin/ld: cannot find -lxcb-image
    /usr/bin/ld: cannot find -lxcb-shm
    /usr/bin/ld: cannot find -lxcb-keysyms
    /usr/bin/ld: cannot find -lxcb-icccm
    /usr/bin/ld: cannot find -lxcb-shape
    /usr/bin/ld: cannot find -lxcb-glx
    /usr/bin/ld: cannot find -lXi
    /usr/bin/ld: cannot find -lSM
    /usr/bin/ld: cannot find -lICE
    /usr/bin/ld: cannot find -lxcb-render-util
    /usr/bin/ld: cannot find -lxcb-render
    

  • Lifetime Qt Champion

    Hi and welcome to devnet,

    If you want a full static build then you also need to build Qt with its dependencies as static libraries.

    On a side note, don't forget the licensing implication when doing static builds.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.