Qt5 Delarative on BoundaryDevices Nitrogen6x
-
Hi.
I'm not sure where to put ths question, but I try:
I try to build, using buildroot-2013.08, the nitrogen6x_defconfig. It builds "out-of-the-box", but I need Qt5 Declarative.
The problem is that Qt5 Declarative need an OpenGL-capable backend. I found out how to make the configuration-system to give me the opportunity to select Qt5 Declarative: I had to use eglibc instead of uclibc, and when I did I got the possibility to set gpu-viv-bin-mx6q (BR2_PACKAGE_GPU_VIV_BIN_MX6Q) in the Freescale i.MX libraries which in turn let me select Qt5 Declarative.
The problem is that it will not build, and I do not know how to fix it. It stops during Qt build when Qt is trying to find the capabilities og the target. There are obviously some library missing, but I cannot figure it out. Here is a extract of the bottom of the log:
OpenGL ES 2.x auto-detection... ()
gmake[1]: Entering directory/home/espenfk/imx6/buildroot-2013.08/output/build/qt5base-5.0.2/config.tests/unix/opengles2' /home/espenfk/imx6/buildroot-2013.08/output/host/usr/bin/arm-buildroot-linux-gnueabi-g++ -c -pipe -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -pipe -Os --sysroot=/home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot -O2 -O3 -Wall -W -fPIE -I../../../mkspecs/devices/linux-buildroot-g++ -I. -I/home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/include -o opengles2.o opengles2.cpp /home/espenfk/imx6/buildroot-2013.08/output/host/usr/bin/arm-buildroot-linux-gnueabi-g++ -Wl,-O1 -o opengles2 opengles2.o -lrt -lpthread -ldl --sysroot=/home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot -lGLESv2 /home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/lib/libGLESv2.so: undefined reference to
gcoOS_Signal'
/home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/lib/libGLESv2.so: undefined reference togcoOS_StrLen' ... /home/espenfk/imx6/buildroot-2013.08/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/lib/libGLESv2.so: undefined reference to
gcoSTREAM_Unlock'
collect2: error: ld returned 1 exit status
gmake[1]: *** [opengles2] Error 1
gmake[1]: Leaving directory `/home/espenfk/imx6/buildroot-2013.08/output/build/qt5base-5.0.2/config.tests/unix/opengles2'
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/espenfk/imx6/buildroot-2013.08/output/build/qt5base-5.0.2/mkspecs/devices/linux-buildroot-g++.
make: *** [/home/espenfk/imx6/buildroot-2013.08/output/build/qt5base-5.0.2/.stamp_configured] Error 1The references gcoOS_* (and there are a lot of them not all staring on "gco"). I think they have something to do with gpu-viv, but I do not understand how. There are no missing libs in the link command above, only -lGLESv2, so where should the symbols come from?
Someone?
Sp1
-
i have same error.
Have you found any solution?Thanks,
jigar -
They come from libGAL I think. That's why qtbase/mkspecs/devices/linux-imx6-g++ contains QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL -lGAL
Did you configure with -device imx6 (or linux-imx6-g++ or similar) ?
Then again 5.0.2 might be too old and may not have the proper makespecs for imx6.
-
I tried to configure Qt5 using this command
./configure v -opensource -confirm-license -no-pch -no-xcb -no-opengl -opengl es2 -make libs -device imx6 -compile-examples -device-option CROSS_COMPILE=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi -sysroot /ltib_install/ltib/rootfs -no-gcc-sysroot -prefix /opt/qt5
I am getting below error..
opengles2.cpp:45:25: fatal error: GLES2/gl2.h: No such file or directory
compilation terminated.
make: *** [opengles2.o] 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/jigar/qt5/qtbase/mkspecs/devices/linux-imx6-g++.my qmake.conf file is like this..
qmake configuration for the Freescale iMX6 boards (single, dual and quad)
This mkspec is based and tested on the ltib-source-release 3.0.15
Building ltib including glib, gpu-drivers and what ever you want to use (e.g. dbus or fontconfig)
This mkspec is tested with a framebuffer (eglfs) configuration (not testes with X11)
A typical configure line looks like:
/home/tsenyk/qt5/qt5/configure -opensource -confirm-license -make libs -device imx6
device-option CROSS_COMPILE=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi
-sysroot <path-to-your-ltib-install>/rootfs -no-gcc-sysroot
-prefix /usr/local/Qt-5.0.0/Qt5-imx6-1NOTE: currently ltib doesn’t produce a proper staging/sysroot-filessystem.
If gcc’s —sysroot is used, the toolchain doesn’t find basic binaries (e.g. crt1.o),
therefore you have to pass -no-gcc-sysroot to configure if you pass -sysroot to configure!
include(../common/linux_device_pre.conf)
EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfshooks_imx6.cpp
QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include
QMAKE_LIBDIR += $$[QT_SYSROOT]/usr/lib
QMAKE_LIBS_EGL += -lEGL
QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL -lGAL
QMAKE_LIBS_OPENVG += -lOpenVG -lEGL -lGAL
QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib
IMX6_CFLAGS = -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1
IMX6_CFLAGS_RELEASE = -O2 $$IMX6_CFLAGS
QMAKE_CFLAGS_RELEASE += $$IMX6_CFLAGS_RELEASE
QMAKE_CXXFLAGS_RELEASE += $$IMX6_CFLAGS_RELEASE
QMAKE_CFLAGS_DEBUG += $$IMX6_CFLAGS
QMAKE_CXXFLAGS_DEBUG += $$IMX6_CFLAGS
include(../common/linux_arm_device_post.conf)
load(qt_config) -
Ok that looks good. But do you have the GLES2 headers and libs in your sysroot? That is, under /ltib_install/ltib/rootfs ?
-
Hello ,
I tried ./configure v -opensource -confirm-license -no-pch -no-xcb -no-opengl -make libs -device imx6 -compile-examples -device-option CROSS_COMPILE=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi -sysroot /ltib_install/ltib/rootfs -no-gcc-sysroot -prefix /opt/qt5Just omit "-opengl es2". and it is working now.
I am followinf below link to cross compile qt 5.
https://community.freescale.com/docs/DOC-94066But on step 8 i have a problem again because now i don't have a "qtjsbackend" directory in my installed qt5 directory.
Do you have any idea?
i am confused whether i configured qt5 correctly or not. -
Ok but keep in mind that now you are building Qt without OpenGL support (meaning also no Qt Quick 2).
-
okay.
so now may be i need to configure again because i need QT GUI.And also i am not getting "qtjsbackend" directory when i did without opengl es 2.
so i dont think i can go ahead. -
again when i tried to call configuration file using following script .
./configure -v -opensource -confirm-license -no-pch -no-xcb -no-opengl -opengl es2 -make libs -device imx6 -compile-examples -device-option CROSS_COMPILE=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi- -sysroot /home/jigar/ltib_install/ltib/rootfs -no-gcc-sysroot -prefix /opt/qt5
I got error
opengles2.cpp:45:25: fatal error: GLES2/gl2.h: No such file or directory
compilation terminated.
make: *** [opengles2.o] 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/jigar/qt5/qtbase/mkspecs/devices/linux-imx6-g++. -
Because you do not have the necessary headers and libraries (gl2.h, libGLESv2.so, etc.) in your sysroot.
-
so now how can i add this liabraries in my rootfs?
because when i configured LTIB, i did not find any think related to open gl ES2.0.