Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. How to add qt libraries to embedded board.
Forum Updated to NodeBB v4.3 + New Features

How to add qt libraries to embedded board.

Scheduled Pinned Locked Moved Mobile and Embedded
qt embeddedlibrarypathlibrariesembedded linux
15 Posts 4 Posters 11.5k Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #3

    Hi and welcome to devnet,

    Just copy the folder where your cross-compiled Qt can be found on your desktop machine in the same place on your device root filesystem e.g. something like /usr/local/Trolltech/Qt-4.8.6-Embedded

    Interested in AI ? www.idiap.ch
    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

    1 Reply Last reply
    0
    • S Offline
      S Offline
      Sung Sean
      wrote on last edited by
      #4

      Did you try "export LD_LIBRARY_PATH=/yourQTlibpath/" ?

      1 Reply Last reply
      0
      • V Offline
        V Offline
        Vijaykumar Ponugoti
        wrote on last edited by
        #5

        Hi,
        Thank you for the support. I have cross compiled Qt4.8.4 and its working on my board.
        Now I am trying to cross compile Qt 5.2. I need few other options to get enabled so I am working on Qt 5.2. But Im getting the following error.
        My qmake.conf file is

        qmake configuration for building with linux-omap5-g++

        MAKEFILE_GENERATOR = UNIX
        CONFIG += incremental gdb_dwarf_index
        QMAKE_INCREMENTAL_STYLE = sublib

        include(../common/linux.conf)
        include(../common/gcc-base-unix.conf)
        include(../common/g++-unix.conf)

        cross compiler

        CROSS_COMPILE = arm-linux-gnueabihf-

        directory search

        QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include
        QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include/libxml2
        QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include/freetype2
        QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include/drm
        QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include/gbm

        QMAKE_LIBDIR += $$[QT_SYSROOT]/lib
        QMAKE_LIBDIR += $$[QT_SYSROOT]/usr/lib

        QMAKE_INCDIR_OPENGL_ES2 = $$[QT_SYSROOT]/usr/include/GLES2
        QMAKE_INCDIR_EGL = $$[QT_SYSROOT]/usr/include/EGL
        QMAKE_LIBDIR_OPENGL_ES2 = $$[QT_SYSROOT]/usr/lib
        QMAKE_LIBDIR_EGL = $$[QT_SYSROOT]/usr/lib

        libraries

        #QMAKE_LIBS = -lxml2 -lz -lfreetype -lexpat -lrt -ldl -lfontconfig -lpng -lpthread
        QMAKE_LIBS = -lz -lfreetype -lexpat -lrt -ldl -lfontconfig -lpng -lpthread
        QMAKE_LIBS_OPENGL_ES2 = -lsrv_um -lGLESv2 -lusc
        QMAKE_LIBS_EGL = -lEGL -lIMGegl
        QMAKE_LIBS_THREAD = -lpthread

        DISTRO_OPTS += hard-float

        compiler flags

        QMAKE_CFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -fPIC -mword-relocations -fpermissive
        QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE

        compiler tools

        QMAKE_CC = $${CROSS_COMPILE}gcc
        QMAKE_CXX = $${CROSS_COMPILE}g++
        QMAKE_LINK = $${QMAKE_CXX}
        QMAKE_LINK_SHLIB = $${QMAKE_CXX}

        QMAKE_AR = $${CROSS_COMPILE}ar cqs
        QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
        QMAKE_STRIP = $${CROSS_COMPILE}strip

        load(qt_config)

        And the error log is as follows.
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$ export ARCH=arm
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$ export PATH=$PATH:/home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$ export CROSS_COMPILE=arm-linux-gnueabihf-
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$ ls
        configure qtandroidextras qtmultimedia qttranslations
        configure.bat qtbase qt.pro qtwebkit
        gnuwin32 qtconnectivity qtquick1 qtwebkit-examples
        LGPL_EXCEPTION.txt qtdeclarative qtquickcontrols qtwinextras
        LICENSE.FDL qtdoc qtscript qtx11extras
        LICENSE.GPL qtgraphicaleffects qtsensors qtxmlpatterns
        LICENSE.LGPL qtimageformats qtserialport README
        LICENSE.PREVIEW.COMMERCIAL qtlocation qtsvg
        qtactiveqt qtmacextras qttools
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$ ./configure -prefix /usr/qte5.2 -release -make libs -make examples -nomake tools -xplatform linux-omap5-g++ -opengl es2 -confirm-license -opensource -no-xcb -no-pch -verbose -kms -sysroot /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -v -no-icu

        • cd qtbase
        • /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtbase/configure -top-level -prefix /usr/qte5.2 -release -make libs -make examples -nomake tools -xplatform linux-omap5-g++ -opengl es2 -confirm-license -opensource -no-xcb -no-pch -verbose -kms -sysroot /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -v -no-icu

        This is the Qt Open Source Edition.

        You are licensed to use this software under the terms of
        the Lesser GNU General Public License (LGPL) versions 2.1.

        You have already accepted the terms of the license.

        arm-linux-gnueabihf-g++ -c -fvisibility=hidden fvisibility.c
        Symbol visibility control enabled.
        arm-linux-gnueabihf-g++ --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -o libtest.so -shared -Wl,-Bsymbolic-functions -fPIC bsymbolic_functions.c
        Symbolic function binding enabled.
        DEFAULT_INCDIRS="/home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3/arm-linux-gnueabihf
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3/backward
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/4.7.3/include
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/4.7.3/include-fixed
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include
        /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include
        "
        DEFAULT_LIBDIRS="/home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/lib
        /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/lib
        /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/4.7.3
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf
        "
        Creating qmake...
        make: Nothing to be done for `first'.
        Running configuration tests...
        Note: PKG_CONFIG_LIBDIR automatically set to /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib/pkgconfig:/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/share/pkgconfig:/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib/arm-linux-gnueabihf/pkgconfig
        Note: PKG_CONFIG_SYSROOT_DIR automatically set to /home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs
        Determining architecture... ()
        arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -g -Wall -W -fPIE -I../../mkspecs/linux-omap5-g++ -I. -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -o arch.o arch.cpp
        arm-linux-gnueabihf-g++ -o arch arch.o -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/lib -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib -lz -lfreetype -lexpat -lrt -ldl -lfontconfig -lpng -lpthread --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.7.3/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lpng
        collect2: error: ld returned 1 exit status
        make: *** [arch] Error 1
        Unable to determine architecture!

        Could not determine the target architecture!
        Turn on verbose messaging (-v) to see the final report.
        Determining architecture... ()
        g++ -c -pipe -g -Wall -W -fPIE -I../../mkspecs/linux-g++ -I. -o arch.o arch.cpp
        g++ -o arch arch.o
        { test -n "" && DESTDIR="" || DESTDIR=.; } && test $(gdb --version | sed -e 's,[^0-9][^0-9]([0-9]).([0-9]).,\1\2,;q') -gt 72 && gdb --nx --batch --quiet -ex 'set confirm off' -ex "save gdb-index $DESTDIR" -ex quit 'arch' && test -f arch.gdb-index && objcopy --add-section '.gdb_index=arch.gdb-index' --set-section-flags '.gdb_index=readonly' 'arch' 'arch' && rm -f arch.gdb-index || true
        Found architecture in binary
        CFG_HOST_ARCH="i386"
        CFG_HOST_CPUFEATURES=""
        System architecture: 'unknown'
        Host architecture: 'i386'
        C++11 auto-detection... ()
        arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 compilation terminated.
        make: *** [pulseaudio.o] Error 1
        PulseAudio disabled.
        OpenGL ES 2.x auto-detection... ()
        arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -fPIC -mword-relocations -fpermissive -Wall -W -fPIE -I../../../mkspecs/linux-omap5-g++ -I. -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/GLES2 -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -o opengles2.o opengles2.cpp
        arm-linux-gnueabihf-g++ -Wl,-O1 -o opengles2 opengles2.o -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/lib -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib -lz -lfreetype -lexpat -lrt -ldl -lfontconfig -lpng -lpthread --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -lsrv_um -lGLESv2 -lusc
        /home/medha/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin/../lib/gcc/arm-linux-gnueabihf/4.7.3/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lpng
        collect2: error: ld returned 1 exit status
        make: *** [opengles2] Error 1
        OpenGL ES 2.x disabled.
        The OpenGL ES 2.0 functionality test failed!
        You might need to modify the include and library search paths by editing
        QMAKE_INCDIR_OPENGL_ES2, QMAKE_LIBDIR_OPENGL_ES2 and QMAKE_LIBS_OPENGL_ES2 in
        /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtbase/mkspecs/linux-omap5-g++.
        medha@C528:~/Qt5.2/qt-everywhere-opensource-src-5.2.0$

        Please help me in this regard.

        Regards,
        Vijay

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #6

          Do you have libpng for ARM ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          V 1 Reply Last reply
          0
          • SGaistS SGaist

            Do you have libpng for ARM ?

            V Offline
            V Offline
            Vijaykumar Ponugoti
            wrote on last edited by
            #7

            Hi SGaist ,
            Thanks for the reply. As you said I have installed libpng and zlib for arm (in my toolchain folder). Now I am able to do configure, make and make install on Qt5.2. But I am still facing problems.
            I have copied all the installed libraries on to my board and when I tried to run application I am facing the following problem.
            **root@dra7xx-evm:~# ./Wid1
            QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
            QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
            This application failed to start because it could not find or load the Qt platform plugin "xcb".

            Available platform plugins are: eglfs, kms, linuxfb, minimal, minimalegl, offscreen.

            Reinstalling the application may fix this problem.
            Aborted
            root@dra7xx-evm:~# ./Wid1 -platform kms
            QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
            QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
            QSocketNotifier: Can only be used with threads started with QThread
            QSocketNotifier: Can only be used with threads started with QThread
            QSocketNotifier: Can only be used with threads started with QThread
            root@dra7xx-evm:~# **

            And I observed that when I gave make install in qt5.2 the log contains some errors as followed(sample of Log).

            cd qmldbg_inspector/ && ( test -e Makefile || /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtbase/bin/qmake /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_inspector/qmldbg_inspector.pro -o Makefile ) && make -f Makefile install
            make[5]: Entering directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_inspector' install -m 755 -p "../../../../plugins/qml1tooling/libqmldbg_inspector.so" "/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/plugins/qml1tooling/libqmldbg_inspector.so" arm-linux-gnueabihf-strip --strip-unneeded "/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/plugins/qml1tooling/libqmldbg_inspector.so" /bin/sh: 1: arm-linux-gnueabihf-strip: not found make[5]: [install_target] Error 127 (ignored) make[5]: Leaving directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_inspector'
            cd qmldbg_tcp_qtquick1/ && ( test -e Makefile || /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtbase/bin/qmake /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_tcp_qtquick1/qmldbg_tcp_qtquick1.pro -o Makefile ) && make -f Makefile install
            make[5]: Entering directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_tcp_qtquick1' install -m 755 -p "../../../../plugins/qml1tooling/libqmldbg_tcp_qtdeclarative.so" "/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/plugins/qml1tooling/libqmldbg_tcp_qtdeclarative.so" arm-linux-gnueabihf-strip --strip-unneeded "/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/plugins/qml1tooling/libqmldbg_tcp_qtdeclarative.so" /bin/sh: 1: arm-linux-gnueabihf-strip: not found make[5]: [install_target] Error 127 (ignored) make[5]: Leaving directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_tcp_qtquick1'
            make[4]: Leaving directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling' make[3]: Leaving directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins'
            make[2]: Leaving directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/src' cd tools/ && ( test -e Makefile || /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtbase/bin/qmake /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/tools/tools.pro -o Makefile ) && make -f Makefile install make[2]: Entering directory /home/medha/Qt5.2/qt-everywhere-opensource-src-5.2.0/qtquick1/tools'
            make[2]: Nothing to be done for `install'.

            And I did not find the fonts folder in the installed path..

            Please Help me in this regard.

            Regards,
            Vijay

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #8

              Missing arm-linux-gnueabihf-strip in your PATH ?

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              V 1 Reply Last reply
              0
              • SGaistS SGaist

                Missing arm-linux-gnueabihf-strip in your PATH ?

                V Offline
                V Offline
                Vijaykumar Ponugoti
                wrote on last edited by
                #9

                Hi SGaist ,
                No. Its not missing.
                medha@C528:~/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin$ ls
                arm-linux-gnueabihf-addr2line* arm-linux-gnueabihf-gfortran*
                arm-linux-gnueabihf-ar* arm-linux-gnueabihf-gprof*
                arm-linux-gnueabihf-as* arm-linux-gnueabihf-ld@
                arm-linux-gnueabihf-c++@ arm-linux-gnueabihf-ld.bfd*
                arm-linux-gnueabihf-c++filt* arm-linux-gnueabihf-ldd*
                arm-linux-gnueabihf-cpp* arm-linux-gnueabihf-ld.gold*
                arm-linux-gnueabihf-ct-ng.config arm-linux-gnueabihf-nm*
                arm-linux-gnueabihf-elfedit* arm-linux-gnueabihf-objcopy*
                arm-linux-gnueabihf-g++* arm-linux-gnueabihf-objdump*
                arm-linux-gnueabihf-gcc@ arm-linux-gnueabihf-pkg-config*
                arm-linux-gnueabihf-gcc-4.7.3* arm-linux-gnueabihf-pkg-config-real*
                arm-linux-gnueabihf-gcc-ar* arm-linux-gnueabihf-ranlib*
                arm-linux-gnueabihf-gcc-nm* arm-linux-gnueabihf-readelf*
                arm-linux-gnueabihf-gcc-ranlib* arm-linux-gnueabihf-size*
                arm-linux-gnueabihf-gcov* arm-linux-gnueabihf-strings*
                arm-linux-gnueabihf-gdb* arm-linux-gnueabihf-strip*

                Rgds,
                Vijay

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #10

                  I didn't doubt that you had them (otherwise you wouldn't have been able to cross-compile at all) However can you confirm that "~/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin" is in your PATH environment variable ?

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  V 2 Replies Last reply
                  0
                  • SGaistS SGaist

                    I didn't doubt that you had them (otherwise you wouldn't have been able to cross-compile at all) However can you confirm that "~/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin" is in your PATH environment variable ?

                    V Offline
                    V Offline
                    Vijaykumar Ponugoti
                    wrote on last edited by Vijaykumar Ponugoti
                    #11

                    medha@C528:~$ export PATH=$PATH:/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin
                    medha@C528:~$ echo $PATH
                    /usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin

                    Actually, If something went wrong how the libraries are being created.? And when I gave "file" command on any of the created library file, it informs that the library is cross compiled for arm.
                    And I tried copying the created libraries onto the filesystem and run some Qt application as follows, after setting the LD_LIBRARY_PATH variable.
                    But I am getting problem.
                    On the target

                    root@dra7xx-evm:~# ./Wid1
                    QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
                    QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
                    This application failed to start because it could not find or load the Qt platform plugin "xcb".

                    Available platform plugins are: eglfs, kms, linuxfb, minimal, minimalegl, offscreen.

                    Reinstalling the application may fix this problem.
                    Aborted
                    root@dra7xx-evm:~# ./Wid1 -platform kms
                    QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
                    QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
                    QSocketNotifier: Can only be used with threads started with QThread
                    QSocketNotifier: Can only be used with threads started with QThread
                    QSocketNotifier: Can only be used with threads started with QThread
                    root@dra7xx-evm:~#

                    What could be the problem? Am I running the application properly?
                    Please help me.

                    1 Reply Last reply
                    0
                    • SGaistS SGaist

                      I didn't doubt that you had them (otherwise you wouldn't have been able to cross-compile at all) However can you confirm that "~/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin" is in your PATH environment variable ?

                      V Offline
                      V Offline
                      Vijaykumar Ponugoti
                      wrote on last edited by
                      #12

                      Hi Gaist,
                      Did you get any idea? what could be the probelm?
                      Plz help me.
                      Regards,
                      Vijay

                      1 Reply Last reply
                      0
                      • SGaistS Offline
                        SGaistS Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on last edited by
                        #13

                        Are you sure that you are using the same Qt on your target than the one you cross-compiled ?

                        Interested in AI ? www.idiap.ch
                        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                        V 1 Reply Last reply
                        0
                        • SGaistS SGaist

                          Are you sure that you are using the same Qt on your target than the one you cross-compiled ?

                          V Offline
                          V Offline
                          Vijaykumar Ponugoti
                          wrote on last edited by Vijaykumar Ponugoti
                          #14

                          @SGaist
                          Yeah, Im sure. I created the make file for application using qmake of the qt5.2 crosscompiled.
                          medha@C528:~/Qtwokspace/Wid1$ ls
                          main.cpp mainwindow.cpp mainwindow.h mainwindow.ui Wid1.pro Wid1.pro.user
                          medha@C528:~/Qtwokspace/Wid1$ /usr/qte5.2/bin/qmake Wid1.pro
                          medha@C528:~/Qtwokspace/Wid1$ ls
                          main.cpp mainwindow.h Makefile Wid1.pro.user
                          mainwindow.cpp mainwindow.ui Wid1.pro
                          medha@C528:~/Qtwokspace/Wid1$ make
                          /usr/qte5.2/bin/uic mainwindow.ui -o ui_mainwindow.h
                          arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -fPIC -mword-relocations -marm -fpermissive -Wall -W -D_REENTRANT -fPIE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/qte5.2/mkspecs/linux-omap5-g++ -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtWidgets -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtGui -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtCore -I. -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -o main.o main.cpp
                          arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -fPIC -mword-relocations -marm -fpermissive -Wall -W -D_REENTRANT -fPIE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/qte5.2/mkspecs/linux-omap5-g++ -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtWidgets -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtGui -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtCore -I. -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -o mainwindow.o mainwindow.cpp
                          /usr/qte5.2/bin/moc -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/qte5.2/mkspecs/linux-omap5-g++ -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtWidgets -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtGui -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtCore -I. -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3 -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3/arm-linux-gnueabihf -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include/c++/4.7.3/backward -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/4.7.3/include -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/4.7.3/include-fixed -I/home/medha/CC/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/lib/gcc/arm-linux-gnueabihf/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include mainwindow.h -o moc_mainwindow.cpp
                          arm-linux-gnueabihf-g++ -c -pipe --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -O3 -march=armv7-a -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -fPIC -mword-relocations -marm -fpermissive -Wall -W -D_REENTRANT -fPIE -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/qte5.2/mkspecs/linux-omap5-g++ -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtWidgets -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtGui -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/include/QtCore -I. -I. -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include -I/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/libxml2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/freetype2 -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/drm -I../../ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/include/gbm -o moc_mainwindow.o moc_mainwindow.cpp
                          arm-linux-gnueabihf-g++ --sysroot=/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs -Wl,-O1 -Wl,-rpath,/usr/qte5.2/lib -o Wid1 main.o mainwindow.o moc_mainwindow.o -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/lib -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/lib -L/home/medha/ti-glsdk_dra7xx-evm_7_00_00_04/targetfs/usr/qte5.2/lib -lQt5Widgets -L/usr/qte5.2/lib -lQt5Gui -lQt5Core -lz -lfreetype -lexpat -lrt -ldl -lfontconfig -lpng -lsrv_um -lGLESv2 -lusc -lpthread
                          medha@C528:~/Qtwokspace/Wid1$ ls
                          main.cpp mainwindow.o moc_mainwindow.o Wid1.pro.user
                          main.o mainwindow.ui ui_mainwindow.h
                          mainwindow.cpp Makefile Wid1
                          mainwindow.h moc_mainwindow.cpp Wid1.pro
                          medha@C528:~/Qtwokspace/Wid1$ file Wid1
                          Wid1: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.31, BuildID[sha1]=0x00c92425a3333130034b285d1b15cbc3954c740b, not stripped
                          medha@C528:~/Qtwokspace/Wid1$

                          1 Reply Last reply
                          0
                          • SGaistS Offline
                            SGaistS Offline
                            SGaist
                            Lifetime Qt Champion
                            wrote on last edited by
                            #15

                            Cross-compiling is one thing, how did you install Qt on your board ?

                            Interested in AI ? www.idiap.ch
                            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                            1 Reply Last reply
                            0

                            • Login

                            • Login or register to search.
                            • First post
                              Last post
                            0
                            • Categories
                            • Recent
                            • Tags
                            • Popular
                            • Users
                            • Groups
                            • Search
                            • Get Qt Extensions
                            • Unsolved