The latest NXP Yocto Scarthgap release cannot build chromium-ozone-wayland for the imx8mpevk MACHINE target. chromium-ozone-wayland fails with an error about missing 'dri' drivers. This seems to be a regression from earlier releases that attempted to patch this issue out. I verified that the "003-Disable-dri-for-imx-gpu.patch" was applied to the correct BUILD.gn file in Chromium. However it seems that "use_imxgpu" argument introduced in this patch is never set to true so the later check on this value in the gn file fails. I've tried following through where this could be going wrong but got lost in a sea of machine overrides.
I've tried both Ubuntu 22.04 and Debian 12 distributions and the error is the same every time. Obviously, I can work around this by some selective file hacking, but I'm worried that other aspects of the i.MX8M Plus GPU support in Chromium may not be incorporated correctly as a result of this.
Log file attached.
I have since worked out what the problem is. The "003-Disable-dri-for-imx-gpu.patch" patches the BUILD.gn file in chromium-117.0.5938.123/content/gpu so that a "use_imxgpu" argument can be used to skip DRI driver inclusion. However, the BUILD.gn file in chromium-117.0.5938.123/media/gpu/sandbox has now also incorporated the same mechanism to include the DRI drivers, which isn't handled by the patch.
I solved this by moving the use_imxgpu argument declaration to chromium-117.0.5938.123/media/gpu/args.gni and then adding an extra !use_imxgpu check to the DRI inclusion in chromium-117.0.5938.123/media/gpu/sandbox/BUILD.gn. This quick fix got me building again. I've thrown together an updated patch file also (not tested yet as I ran out of time).
Hi @ah_mini!
I compile the image without errors.
I follow the steps below:
$ sudo apt update
$ sudo apt upgrade
$ sudo apt install gawk wget git diffstat unzip texinfo gcc build-essential
chrpath socat cpio python3 python3-pip python3-pexpect xz-utils debianutils
iputils-ping python3-git python3-jinja2 python3-subunit zstd liblz4-tool file
locales libacl1
$ mkdir imx-yocto-bsp
$ cd imx-yocto-bsp
$ repo init -u https://github.com/nxp-imx/imx-manifest -b imx-linux-scarthgap -m imx-6.6.23-2.0.0.xml
$ repo sync
$: MACHINE=imx8mpevk DISTRO=fsl-imx-xwayland source ./imx-setup-release.sh -b bld-xwayland
$ nano conf/local.conf
#add the line CORE_IMAGE_EXTRA_INSTALL += "chromium-ozone-wayland"
$ bitbake imx-image-multimedia
do you modify something in one recipe?
maybe one package is missing?
Best Regards!
Chavira
A finding, maybe it helps fixing the issue:: In nanbield there where no dependency of chromium-ozone-wayland to libva. This is "magically" introduced in scarthgap now at:
# append base.bbclass:474 [appendVar]
# " virtual/egl virtual/libgles2 libva"
during setting up var DEPENDS. Where does this come from?
This was:
# append base.bbclass:474 [appendVar]
# " virtual/egl virtual/libgles2"
Same sequence of recipes' parsing.
Quick support urgently appreciated.
Solution is already given here https://community.nxp.com/t5/i-MX-Processors/Chromium-on-IMX8/m-p/1356024/highlight/true#M181574
For im6qdl, libgbm is not available and shall be removed from any package pulling it in (grep for USE_GBM).
For imx8abc this patch https://github.com/OSSystems/meta-browser/issues/649#issuecomment-1613603129 shall be applied too.
Hi @ah_mini!
In general, chromium-ozone-wayland has dependencies of X11 libraries, and such dependencies are satisfied when using a xwayland DISTRO, so, below are my build enviroment on where image is sucessfully build, adding chromium:
- Building BSP 6.6.23 on Ubuntu host PC
- DISTRO=fsl-imx-xwayland
- bitbake imx-image-multimedia
- MACHINE=imx8mp-lpddr4-evk
- Added CORE_IMAGE_EXTRA_INSTALL += "chromium-ozone-wayland" on conf/local.con file.
You could also refer to following Community post for additional details:
https://community.nxp.com/t5/i-MX-Processors/Chromium-on-IMX8/m-p/1420045
Best regards!
Chavira