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

qtbase. 5.12.4 For BeagleBone Black



  • Hi,
    I am trying to cross compile qtbase.git 5.12.4 for beaglebone
    Current BBB distro is:
    Linux beaglebone 4.14.108-ti-r108 #1 SMP PREEMPT Tue Jun 18 05:11:38 UTC 2019 armv7l GNU/Linux

    Current QT is: QT Version: 5.7.1 installed from apt debina repos.
    I am trying to cross compile the QT5.12.4
    I am using the cross compiler form https://github.com/RobertCNelson/ti-linux-kernel-dev which is.

    ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ --version
    arm-linux-gnueabihf-g++ (Linaro GCC 7.4-2019.02) 7.4.1 20181213 [linaro-7.4-2019.02 revision 56ec6f6b99cc167ff0c2f8e1a2eed33b1edc85d4]
    Copyright (C) 2017 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    

    My commands are:

    export BBB_SDK=..
    export PATH=$PATH:${BBB_SDK}/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin
    export BBB_TC=arm-linux-gnueabihf-
    
    ./configure -release -opengl es2 -device linux-beagleboard-g++ -device-option CROSS_COMPILE=$BBB_TC -sysroot $BBB_SDK/deploy/targetNFS -opensource -confirm-license -make libs -prefix /usr/local/qt5bbb_b -extprefix ~/bbb_b/qt5bbb -hostprefix ~/bbb_b/qt5 -no-use-gold-linker -v -no-gbm 
    
    
    

    The deploy/targetNFS has a full OS rsynched there,

    The config fails

    Checking for valid makespec... 
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && /BOARDS/BBB/ti-linux-kernel-dev/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" "QMAKE_CFLAGS += --sysroot=../deploy/targetNFS" "QMAKE_CXXFLAGS += --sysroot=../deploy/targetNFS" "QMAKE_LFLAGS += --sysroot=../deploy/targetNFS" -early "CONFIG += cross_compile" /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && MAKEFLAGS= /usr/bin/make clean && MAKEFLAGS= /usr/bin/make
    > rm -f verifyspec.o
    > rm -f *~ core *.core
    > arm-linux-gnueabihf-g++ -c -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -mfloat-abi=hard --sysroot=../deploy/targetNFS -O2 -O3 -w -fPIC  -I. -I/BOARDS/BBB/ti-linux-kernel-dev/qtbase/mkspecs/devices/linux-beagleboard-g++ -o verifyspec.o verifyspec.cpp
    
    > arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=../deploy/targetNFS -Wl,-O1 -o verifyspec verifyspec.o     -lrt -lpthread -ldl 
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find crt1.o: No such file or directory
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find crti.o: No such file or directory
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lrt
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lpthread
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -ldl
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lm
    > collect2: error: ld returned 1 exit status
    > Makefile:68: recipe for target 'verifyspec' failed
    > make: *** [verifyspec] Error 1
    Note: Also available for Linux: linux-clang linux-icc
    
    ERROR: Cannot compile a minimal program. The toolchain or QMakeSpec is broken.
    /BOARDS/BBB/ti-linux-kernel-dev
    
    

    Though, manually repeating the failed steps is the same

    cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec
    
    prompt$:/BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec$ /BOARDS/BBBti-linux-kernel-dev/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" "QMAKE_CFLAGS += --sysroot=../deploy/targetNFS" "QMAKE_CXXFLAGS += --sysroot=../deploy/targetNFS" "QMAKE_LFLAGS += --sysroot=../deploy/targetNFS" -early "CONFIG += cross_compile" /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec
    
    prompt$:/BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec$ 
    
    prompt$:arm-linux-gnueabihf-g++ -c -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -mfloat-abi=hard --sysroot=../deploy/targetNFS -O2 -O3 -w -fPIC  -I. -I/BOARDS/BBB/ti-linux-kernel-dev/qtbase/mkspecs/devices/linux-beagleboard-g++ -o verifyspec.o verifyspec.cpp
    
    ls
    Makefile  verifyspec.cpp  verifyspec.o  verifyspec.pro
    
    # then
    prompt$:arm-linux-gnueabihf-g++ -c -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -mfloat-abi=hard --sysroot=../deploy/targetNFS -O2 -O3 -w -fPIC  -I. -I/BOARDS/BBB/ti-linux-kernel-dev/qtbase/mkspecs/devices/linux-beagleboard-g++ -o verifyspec.o verifyspec.cpp
    arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=../deploy/targetNFS -Wl,-O1 -o verifyspec verifyspec.o     -lrt -lpthread -ld
    
    arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=../deploy/targetNFS -Wl,-O1 -o verifyspec verifyspec.o     -lrt -lpthread -ld
    
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find crt1.o: No such file or directory
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find crti.o: No such file or directory
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lrt
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lpthread
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -ld
    /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lm
    collect2: error: ld returned 1 exit status
    
    
    

    Anyone have any workaround or where to look

    Thank you



  • Hi,
    I found some glitches in the config.

    New config

    BBB_SDK=$(pwd)
    pushd qtbase
    git clean -dfx
    
    export PATH=${BBB_SDK}/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/:$PATH
    #export LD_LIBRARY_PATH=$BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf:$LD_LIBRARY_PATH
    #export LDFLAGS='-L$BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf -fuse-ld=bfd'
    #export CFLAGS="--sysroot=$BBB_SDK/deploy/targetNFS/lib/arm-linux-gnueabihf"
    export BBB_TC=arm-linux-gnueabihf-
    echo $PATH
    arm-linux-gnueabihf-g++
    
    read g
     
    ./configure -release -opengl es2 -device linux-beagleboard-g++ -device-option CROSS_COMPILE=$BBB_TC -sysroot $BBB_SDK/deploy/targetNFS -opensource -confirm-license -make libs -prefix $BBB_SDK/deploy/targetNFS -extprefix $BBB_SDK/deploy/targetNFS -hostprefix ~/bbb_b/qt5 -no-use-gold-linker -v -no-gbm 
    
    #-libdir $BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf
    
    popd
    
    
    

    Now I am running into these.

    
    Running configuration tests...
    Checking for machine tuple... 
    + arm-linux-gnueabihf-g++ -dumpmachine
    > arm-linux-gnueabihf
    test config.qtbase.tests.machineTuple succeeded
    Checking for valid makespec... 
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && /BOARDS/BBB/ti-linux-kernel-dev/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" "QMAKE_CFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" "QMAKE_CXXFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" "QMAKE_LFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" -early "CONFIG += cross_compile" /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec
    > Info: creating stash file /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/.qmake.stash
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && MAKEFLAGS= /usr/bin/make
    > arm-linux-gnueabihf-g++ -c -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -mfloat-abi=hard --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS -O2 -O3 -w -fPIC  -I. -I/BOARDS/BBB/ti-linux-kernel-dev/qtbase/mkspecs/devices/linux-beagleboard-g++ -o verifyspec.o verifyspec.cpp
    > arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS -Wl,-O1 -o verifyspec verifyspec.o     -lrt -lpthread -ldl 
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: warning: libm.so.6, needed by /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so, not found (try using -rpath or -rpath-link)
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `acos@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `hypot@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `cos@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `fmod@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `tan@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `atan@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `asin@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sqrt@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `ceil@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `atan2@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sin@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `tanh@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sinh@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `pow@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `log@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `floor@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `log10@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `exp@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `cosh@GLIBC_2.4'
    > collect2: error: ld returned 1 exit status
    > Makefile:68: recipe for target 'verifyspec' failed
    > make: *** [verifyspec] Error 1
    Note: Also available for Linux: linux-clang linux-icc
    
    ERROR: Cannot compile a minimal program. The toolchain or QMakeSpec is broken.
    /BOARDS/BBB/ti-linux-kernel-dev
    
    


  • @comarius said in qtbase. 5.12.4 For BeagleBone Black:

    Hi,
    I found some glitches in the config.

    New config

    BBB_SDK=$(pwd)
    pushd qtbase
    git clean -dfx
    
    export PATH=${BBB_SDK}/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/:$PATH
    #export LD_LIBRARY_PATH=$BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf:$LD_LIBRARY_PATH
    #export LDFLAGS='-L$BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf -fuse-ld=bfd'
    #export CFLAGS="--sysroot=$BBB_SDK/deploy/targetNFS/lib/arm-linux-gnueabihf"
    export BBB_TC=arm-linux-gnueabihf-
    echo $PATH
    arm-linux-gnueabihf-g++
    
    read g
     
    ./configure -release -opengl es2 -device linux-beagleboard-g++ -device-option CROSS_COMPILE=$BBB_TC -sysroot $BBB_SDK/deploy/targetNFS -opensource -confirm-license -make libs -prefix $BBB_SDK/deploy/targetNFS -extprefix $BBB_SDK/deploy/targetNFS -hostprefix ~/bbb_b/qt5 -no-use-gold-linker -v -no-gbm 
    
    #-libdir $BBB_SDK/deploy/targetNFS/usr/lib/arm-linux-gnueabihf
    
    popd
    
    
    

    Now I am running into these.

    
    Running configuration tests...
    Checking for machine tuple... 
    + arm-linux-gnueabihf-g++ -dumpmachine
    > arm-linux-gnueabihf
    test config.qtbase.tests.machineTuple succeeded
    Checking for valid makespec... 
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && /BOARDS/BBB/ti-linux-kernel-dev/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" "QMAKE_CFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" "QMAKE_CXXFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" "QMAKE_LFLAGS += --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS" -early "CONFIG += cross_compile" /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec
    > Info: creating stash file /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/.qmake.stash
    + cd /BOARDS/BBB/ti-linux-kernel-dev/qtbase/config.tests/verifyspec && MAKEFLAGS= /usr/bin/make
    > arm-linux-gnueabihf-g++ -c -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb -mfloat-abi=hard --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS -O2 -O3 -w -fPIC  -I. -I/BOARDS/BBB/ti-linux-kernel-dev/qtbase/mkspecs/devices/linux-beagleboard-g++ -o verifyspec.o verifyspec.cpp
    > arm-linux-gnueabihf-g++ -mfloat-abi=hard --sysroot=/BOARDS/BBB/ti-linux-kernel-dev/deploy/targetNFS -Wl,-O1 -o verifyspec verifyspec.o     -lrt -lpthread -ldl 
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/bin/ld: warning: libm.so.6, needed by /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so, not found (try using -rpath or -rpath-link)
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `acos@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `hypot@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `cos@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `fmod@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `tan@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `atan@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `asin@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sqrt@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `ceil@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `atan2@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sin@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `tanh@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `sinh@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `pow@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `log@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `floor@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `log10@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `exp@GLIBC_2.4'
    > /BOARDS/BBB/ti-linux-kernel-dev/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/7.4.1/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `cosh@GLIBC_2.4'
    > collect2: error: ld returned 1 exit status
    > Makefile:68: recipe for target 'verifyspec' failed
    > make: *** [verifyspec] Error 1
    Note: Also available for Linux: linux-clang linux-icc
    
    ERROR: Cannot compile a minimal program. The toolchain or QMakeSpec is broken.
    /BOARDS/BBB/ti-linux-kernel-dev
    
    

    I got some progress.

    mkspecs/devices/linux-beaglebone-g++/qmake.config

    #
    # qmake configuration for the BeagleBoard and BeagleBoard xM boards
    # http://beagleboard.org/
    
    MAKEFILE_GENERATOR      = UNIX
    CONFIG                 += incremental
    QMAKE_INCREMENTAL_STYLE = sublib
    
    include(../../common/linux.conf)
    include(../../common/gcc-base-unix.conf)
    include(../../common/g++-unix.conf)
    
    load(device_config)
    
    QT_QPA_DEFAULT_PLATFORM = eglfs
    
    # modifications to g++.conf
    QMAKE_CC                = $${CROSS_COMPILE}gcc
    QMAKE_CXX               = $${CROSS_COMPILE}g++
    QMAKE_LINK              = $${QMAKE_CXX}
    QMAKE_LINK_SHLIB        = $${QMAKE_CXX}
    
    # modifications to linux.conf
    QMAKE_AR                = $${CROSS_COMPILE}ar cqs
    QMAKE_OBJCOPY           = $${CROSS_COMPILE}objcopy
    QMAKE_NM                = $${CROSS_COMPILE}nm -P
    QMAKE_STRIP             = $${CROSS_COMPILE}strip
    
    COMPILER_FLAGS          = -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mthumb
    
    #modifications to gcc-base.conf
    QMAKE_CFLAGS           += $${COMPILER_FLAGS}
    QMAKE_CXXFLAGS         += $${COMPILER_FLAGS}
    QMAKE_CXXFLAGS_RELEASE += -O3
    
    # ROOT_FS
    # mco-mco
    # SET(LDFLAGS "-Wl,-rpath-link,$(ROOT_FS)/lib/arm-linux-gnueabihf")
    # mco-mco
    QMAKE_LFLAGS += "-Wl,-rpath-link,$(ROOT_FS)/lib/arm-linux-gnueabihf"
    
    QMAKE_LIBS             += -lrt -lpthread -ldl
    
    # Extra stuff (OpenGL, DirectFB, ...)
    QMAKE_INCDIR_EGL        = $(ROOT_FS)/usr/include $(ROOT_FS)/usr/include/GL
    QMAKE_LIBDIR_EGL        = $(ROOT_FS)/usr/lib $(ROOT_FS)/usr/lib/arm-linux-gnueabihf/
    
    QMAKE_INCDIR_OPENGL_ES2 = $${QMAKE_INCDIR_EGL}
    QMAKE_LIBDIR_OPENGL_ES2 = $${QMAKE_LIBDIR_EGL}
    QMAKE_INCDIR_OPENVG     = $${QMAKE_INCDIR_EGL}
    QMAKE_LIBDIR_OPENVG     = $${QMAKE_LIBDIR_EGL}
    
    QMAKE_LIBS_EGL          = -lEGL -lIMGegl -lsrv_um
    QMAKE_LIBS_OPENGL_ES2   = -lGLESv2 $${QMAKE_LIBS_EGL}
    QMAKE_LIBS_OPENVG       = -lOpenVG $${QMAKE_LIBS_EGL}
    
    DISTRO_OPTS += hard-float
    
    # No need for any special EGL device integration.
    # Prioritize the default, compiled-in integration over any plugins.
    EGLFS_DEVICE_INTEGRATION = none
    
    include(../common/linux_arm_device_post.conf)
    
    load(qt_config)
    

    script for configure

    #!/bin/bash
    
    # ln -sf ./lib/arm-linux-gnueabihf/librt.so.1 ./usr/lib/arm-linux-gnueabihf/librt.so
    # ln -sf ./lib/arm-linux-gnueabihf/libdl.so.2 ./usr/lib/arm-linux-gnueabihf/libdl.so
    # ln -sf ./lib/arm-linux-gnueabihf/libglib-2.0.so.0 ./usr/lib/arm-linux-gnueabihf/libglib-2.0.so
    # ln -sf ./lib/arm-linux-gnueabihf/libm.so.6 ./usr/lib/arm-linux-gnueabihf/libm.so
    
    #./mkspecs/devices/linux-beagleboard-g++/
    BBB_SDK=$(pwd)
    pushd qtbase
    git clean -dfx
    
    export ROOT_FS=$BBB_SDK/deploy/targetNFS
    export PATH=${BBB_SDK}/dl/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/:$PATH:$ROOT_FS/lib/arm-linux-gnueabihf
    export LD_LIBRARY_PATH=$ROOT_FS/usr/lib/arm-linux-gnueabihf:$ROOT_FS/lib/arm-linux-gnueabihf:$LD_LIBRARY_PATH:
    export LDFLAGS='-L$ROOT_FS/usr/lib/arm-linux-gnueabihf -L$ROOT_FS/lib/arm-linux-gnueabihf'
    export CFLAGS='-L$ROOT_FS/usr/lib/arm-linux-gnueabihf -L$ROOT_FS/lib/arm-linux-gnueabihf'
    
    #rpath-link=$ROOT_FS/usr/lib/arm-linux-gnueabihf
    # export LDFLAGS='-L$ROOT_FS/usr/lib/arm-linux-gnueabihf -fuse-ld=bfd'
    #export CFLAGS="--sysroot=$ROOT_FS/lib/arm-linux-gnueabihf"
    export BBB_TC=arm-linux-gnueabihf-
    echo $PATH
    #arm-linux-gnueabihf-g++
    
    ./configure -platform linux-g++-64 -release -opengl es2 -device linux-beagleboard-g++ -device-option CROSS_COMPILE=$BBB_TC -sysroot $ROOT_FS -opensource -confirm-license -make libs -prefix $ROOT_FS -extprefix $ROOT_FS -hostprefix ~/bbb_b/qt5 -no-use-gold-linker -v -no-gbm -libdir /lib/arm-linux-gnueabihf
    
    #-libdir $ROOT_FS/usr/lib/arm-linux-gnueabihf
    
    popd
    

    Result

    
    Configure summary:
    
    Building on: linux-g++-64 (x86_64, CPU features: mmx sse sse2)
    Building for: devices/linux-beagleboard-g++ (arm, CPU features: neon)
    Target compiler: gcc 7.4.1
    Configuration: cross_compile compile_examples largefile neon precompile_header shared rpath release c++11 c++14 c++1z concurrent dbus reduce_exports stl
    Build options:
      Mode ................................... release
      Optimize release build for size ........ no
      Building shared libraries .............. yes
      Using C standard ....................... C11
      Using C++ standard ..................... C++1z
      Using ccache ........................... no
      Using gold linker ...................... no
      Using new DTAGS ........................ no
      Using precompiled headers .............. yes
      Using LTCG ............................. no
      Target compiler supports:
        NEON ................................. yes
      Build parts ............................ libs
    Qt modules and options:
      Qt Concurrent .......................... yes
      Qt D-Bus ............................... yes
      Qt D-Bus directly linked to libdbus .... no
      Qt Gui ................................. yes
      Qt Network ............................. yes
      Qt Sql ................................. yes
      Qt Testlib ............................. yes
      Qt Widgets ............................. yes
      Qt Xml ................................. yes
    Support enabled for:
      Using pkg-config ....................... yes
      udev ................................... no
      Using system zlib ...................... no
    Qt Core:
      DoubleConversion ....................... yes
        Using system DoubleConversion ........ no
      GLib ................................... no
      iconv .................................. yes
      ICU .................................... no
      Tracing backend ........................ <none>
      Logging backends:
        journald ............................. no
        syslog ............................... no
        slog2 ................................ no
      Using system PCRE2 ..................... no
    Qt Network:
      getifaddrs() ........................... yes
      IPv6 ifname ............................ yes
      libproxy ............................... no
      Linux AF_NETLINK ....................... yes
      OpenSSL ................................ no
        Qt directly linked to OpenSSL ........ no
      OpenSSL 1.1 ............................ no
      DTLS ................................... no
      SCTP ................................... no
      Use system proxies ..................... yes
    Qt Gui:
      Accessibility .......................... yes
      FreeType ............................... yes
        Using system FreeType ................ no
      HarfBuzz ............................... yes
        Using system HarfBuzz ................ no
      Fontconfig ............................. no
      Image formats:
        GIF .................................. yes
        ICO .................................. yes
        JPEG ................................. yes
          Using system libjpeg ............... no
        PNG .................................. yes
          Using system libpng ................ no
      EGL .................................... no
      OpenVG ................................. no
      OpenGL:
        Desktop OpenGL ....................... no
        OpenGL ES 2.0 ........................ no
        OpenGL ES 3.0 ........................ no
        OpenGL ES 3.1 ........................ no
        OpenGL ES 3.2 ........................ no
      Vulkan ................................. no
      Session Management ..................... yes
    Features used by QPA backends:
      evdev .................................. yes
      libinput ............................... no
      INTEGRITY HID .......................... no
      mtdev .................................. no
      tslib .................................. no
      xkbcommon .............................. no
      X11 specific:
        XLib ................................. no
        XCB Xlib ............................. no
        EGL on X11 ........................... no
    QPA backends:
      DirectFB ............................... no
      EGLFS .................................. no
      LinuxFB ................................ yes
      VNC .................................... yes
      Mir client ............................. no
    Qt Sql:
      SQL item models ........................ yes
    Qt Widgets:
      GTK+ ................................... no
      Styles ................................. Fusion Windows
    Qt PrintSupport:
      CUPS ................................... no
    Qt Sql Drivers:
      DB2 (IBM) .............................. no
      InterBase .............................. no
      MySql .................................. no
      OCI (Oracle) ........................... no
      ODBC ................................... no
      PostgreSQL ............................. no
      SQLite2 ................................ no
      SQLite ................................. yes
        Using system provided SQLite ......... no
      TDS (Sybase) ........................... no
    Qt Testlib:
      Tester for item models ................. yes
    
    Note: -libdir is not a subdirectory of -prefix.
    
    Note: PKG_CONFIG_LIBDIR automatically set to /BOARDS/BBB_TOW/ti-linux-kernel-dev/deploy/targetNFS/usr/lib/pkgconfig:/BOARDS/BBB_TOW/ti-linux-kernel-dev/deploy/targetNFS/usr/share/pkgconfig:/BOARDS/BBB_TOW/ti-linux-kernel-dev/deploy/targetNFS/usr/lib/arm-linux-gnueabihf/pkgconfig
    
    Note: PKG_CONFIG_SYSROOT_DIR automatically set to /BOARDS/BBB_TOW/ti-linux-kernel-dev/deploy/targetNFS
    
    ERROR: Feature 'opengles2' was enabled, but the pre-condition 'config.win32 || (!config.watchos && !features.opengl-desktop && libs.opengl_es2)' failed.
    
    ERROR: The OpenGL functionality tests 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 the mkspec for your platform.
    /BOARDS/BBB_TOW/ti-linux-kernel-dev
    
    


  • RESOLVED

    mkspecs/ needed -L patch to find libs

    Thank you.



  • @comarius said in qtbase. 5.12.4 For BeagleBone Black:

    RESOLVED

    mkspecs/ needed -L patch to find libs

    Thank you.

    [https://comarius.blogspot.com/2019/07/beaglebone-black-egl-and-open-gl.html](link url)


Log in to reply