Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* Re: [Buildroot] buildroot Qt Raspberry Pi3b+
       [not found] <VI1PR03MB3677C9B45913A7CCF071B6B8A9579@VI1PR03MB3677.eurprd03.prod.outlook.com>
@ 2022-01-17 23:45 ` Richard Ash
  0 siblings, 0 replies; only message in thread
From: Richard Ash @ 2022-01-17 23:45 UTC (permalink / raw)
  To: Tomaž Smodiš; +Cc: buildroot

On Mon, 17 Jan 2022 19:29:49 +0100
Tomaž Smodiš <tomazsmodis73@hotmail.com> wrote:

> HI
> 
> I am trying to build Qt everywhere 5.12.5 against buildroot Raspberry 
> Pi3b+ image/sysroot. I use linaro 7.5 compiler.
Did you configure and build buildroot using the linaro compiler? If
not, then it's very unlikely to work.

> I rsync the sd card rootfs into sysroot on my host computer.

That's not the sysroot at all. The SD card contents only has the
runtime libraries needed to run binaries. It does not have the headers
and static libraries needed to compile software. They are found in the
output/staging directory from buildroot (which you will notice is a lot
bigger than the target directory!

As a minimum, you need to be using the buildroot staging directory as
your sysroot. But the bigger question is "why bother"? Buildroot has
packages for qt5 so you can just get buildroot to compile whichever
bits of QT you need as part of the system, without having to do it by
hand.
https://git.busybox.net/buildroot/tree/package/qt5

Richard

 Then I
> run:
> 
> ./configure -release -opengl es2 -device linux-rasp-pi-g++ 
> -device-option 
> CROSS_COMPILE=~/RaspberryPiEGLFS/toolsNEW/bin/arm-linux-gnueabihf- 
> -sysroot ~/RaspberryPiEGLFS/sysroot -opensource -confirm-license
> -skip qtwayland -skip qtlocation -skip qtscript -make libs -prefix 
> /usr/local/qt5pi -extprefix ~/RaspberryPiEGLFS/qt5pi -hostprefix 
> ~/RaspberryPiEGLFS/qt5 -no-use-gold-linker -v -no-gbm
> 
> It starts to configure but I got error:
> 
> Running configuration tests...
> 
>   *
> /home/tomaz/RaspberryPiEGLFS/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-g++
> -dumpmachine
> 
>     arm-linux-gnueabihf
>     Checking for valid makespec...
> 
>   * cd
>     /home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/config.tests/verifyspec
>     &&
>     /home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/qtbase/bin/qmake
>     "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG +=
>     shared warn_off console single_arch" "QMAKE_CFLAGS +=
>     --sysroot=/home/tomaz/RaspberryPiEGLFS/sysroot" "QMAKE_CXXFLAGS +=
>     --sysroot=/home/tomaz/RaspberryPiEGLFS/sysroot" "QMAKE_LFLAGS +=
>     --sysroot=/home/tomaz/RaspberryPiEGLFS/sysroot" -early "CONFIG +=
>     cross_compile"
>     /home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/qtbase/config.tests/verifyspec
>   * cd
>     /home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/config.tests/verifyspec
>     && MAKEFLAGS= /usr/bin/make clean && MAKEFLAGS= /usr/bin/make
> 
>     rm -f verifyspec.o
>     rm -f *~ core *.core
>     /home/tomaz/RaspberryPiEGLFS/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-g++
>     -c -pipe -marm -mfpu=vfp -mtune=arm1176jzf-s -march=armv6zk
>     -mabi=aapcs-linux -mfloat-abi=hard
>     --sysroot=/home/tomaz/RaspberryPiEGLFS/sysroot -O2 -std=gnu++11 -w
>     -fPIC
>     -I/home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/qtbase/config.tests/verifyspec
>     -I.
>     -I/home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/qtbase/mkspecs/devices/linux-rasp-pi-g++
>     -o verifyspec.o
>     /home/tomaz/RaspberryPiEGLFS/qt-everywhere-src-5.12.5/qtbase/config.tests/verifyspec/verifyspec.cpp
>     /home/tomaz/RaspberryPiEGLFS/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-g++
>     -mfloat-abi=hard --sysroot=/home/tomaz/RaspberryPiEGLFS/sysroot
>     -Wl,-O1
>     -Wl,-rpath-link,/home/tomaz/RaspberryPiEGLFS/sysroot/opt/vc/lib
>     -Wl,-rpath-link,/home/tomaz/RaspberryPiEGLFS/sysroot/usr/lib/arm-linux-gnueabihf
>     -Wl,-rpath-link,/home/tomaz/RaspberryPiEGLFS/sysroot/lib/arm-linux-gnueabihf
>     -o verifyspec verifyspec.o
>     /home/tomaz/RaspberryPiEGLFS/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/../lib/gcc/arm-linux-gnueabihf/4.8.3/../../../../arm-linux-gnueabihf/bin/ld:
>     cannot find -lm
>     collect2: error: ld returned 1 exit status
>     make: *** [Makefile:68: verifyspec] Error 1
>     Note: Also available for Linux: linux-clang linux-icc
> 
> ERROR: Cannot compile a minimal program. The toolchain or QMakeSpec
> is broken.
> 
> 
> Minimal program? What am I missing?
> 
> Thomas
> 
> p.s. If I rsync full OS Buster image/rootfs into sysroot on my host
> it configures ok. I can make and make install the Qt binaries. I can 
> compile Qt app against Buster/Raspbian sysroot. Then I run buildroot 
> Raspberry Pi OS that I have build and wrtten on another sc card and
> it runs/loads ok. The I copy my Qt elf file to buildroots directory
> and I get ld.so/libc.so/interpreter problem! I understand this issue
> and I think if I could build Qt eveywhere against buildroots rootfs
> it would be ok!?
> 

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-01-17 23:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <VI1PR03MB3677C9B45913A7CCF071B6B8A9579@VI1PR03MB3677.eurprd03.prod.outlook.com>
2022-01-17 23:45 ` [Buildroot] buildroot Qt Raspberry Pi3b+ Richard Ash

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox