Hi all,
I'm trying to get a working setup going for my i.MX6 reference board (Nitrogen6x). I have the latest BSP (dizzy) and I had no problems building and running the fsl-image-multimedia-full image from sources/meta-fsl-demos/recipes-fsl/images. I was even able to validate both gstreamer-0.10 and gstreamer1.0 that were built into the rootfs using the following commands:
# gst-launch-0.10 mfw_v4lsrc ! mfw_v4lsink
# gst-launch-1.0 imxv4l2src ! imxg2dvideosink
The trouble came when I tried to create my own image. In my target environment I will be running Qt 5.4.0 and displaying directly to the LinuxFB. So I have no need for any window environments. I copied the fsl-image-multimedia recipe and created my own, but used DISTRO_FEATURES_remove to remove X11, Wayland, and DirectFB from the image. I did a build and everything seemed to go fine. I was even able to validate GStreamer was working in that image too. So I used the rootfs that was created to cross-build Qt. The build failed with undefined references to several functions in QEglFSimx6Hooks: fbCreateWindow, fbGetDisplayByIndex, etc.
This told me the GPU libraries were off. I did a little investigating and found that the GPU libraries built into the rootfs of my new image still appear to be the X11 versions. I can tell this by doing a byte size comparison on the one in the rootfs to the one in the build directory:
Here is the build directory:
user@ubuntu:../buildtmp/work/cortexa9hf-vfp-neon-mx6qdl-poky-linux-gnueabi/gpu-viv-bin-mx6q/1_3.10.17-1.0.2-hfp-r0/gpu-viv-bin-mx6q-3.10.17-1.0.2-hfp/usr/lib$ ll
...
-rwxr-xr-x 1 njozwiak njozwiak 619328 Aug 31 2014 libEGL-dfb.so*
-rwxr-xr-x 1 njozwiak njozwiak 381674 Aug 31 2014 libEGL-fb.so*
lrwxrwxrwx 1 njozwiak njozwiak 12 Aug 31 2014 libEGL.so -> libEGL-fb.so*
lrwxrwxrwx 1 njozwiak njozwiak 12 Aug 31 2014 libEGL.so.1 -> libEGL-fb.so*
lrwxrwxrwx 1 njozwiak njozwiak 12 Aug 31 2014 libEGL.so.1.0 -> libEGL-fb.so*
-rwxr-xr-x 1 njozwiak njozwiak 394640 Aug 31 2014 libEGL-wl.so*
-rwxr-xr-x 1 njozwiak njozwiak 360435 Aug 31 2014 libEGL-x11.so*
...
Here is the contents of the rootfs
user@ubuntu:../build/tmp/deploy/images/nitrogen6x$ tar jtvf my-build-nitrogen6x-20150410213651.rootfs.tar.bz2 | grep libEGL
lrwxrwxrwx root/root 0 2015-04-10 19:09 ./usr/lib/libEGL.so -> libEGL.so.1.0
-rw-r--r-- root/root 360435 2015-04-10 18:32 ./usr/lib/libEGL.so.1.0
lrwxrwxrwx root/root 0 2015-04-10 19:09 ./usr/lib/libEGL.so.1 -> libEGL.so.1.0
The links are pointing to the LinuxFB versions of the libraries, but it was the libEGL-x11 library that was installed in the rootfs. I also noted the build date on gpu-viv-bin-mx6q libraries as August 31st. That seems fishy to me as it means the libraries were pre-packaged with the BSP and not built.
Here is my custom recipe. How do I build an image for LinuxFB and get the GPU drivers to install properly?
DISTRO_FEATURES_remove = "x11 wayland directfb"
IMAGE_FEATURES += "dev-pkgs splash ssh-server-openssh"
LICENSE = "MIT"
inherit core-image
CORE_IMAGE_EXTRA_INSTALL += " \
packagegroup-fsl-gstreamer \
packagegroup-fsl-tools-gpu \
packagegroup-fslc-gstreamer1.0 \
packagegroup-fsl-gstreamer-full \
packagegroup-fslc-gstreamer1.0-full \
"