Yocto Scarthgap chromium-ozone-wayland build broken on imx8mpevk

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Yocto Scarthgap chromium-ozone-wayland build broken on imx8mpevk

6,010 次查看
ah_mini
Contributor I

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.

0 项奖励
回复
9 回复数

5,962 次查看
ah_mini
Contributor I

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).

0 项奖励
回复

5,911 次查看
Chavira
NXP TechSupport
NXP TechSupport

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

0 项奖励
回复

5,901 次查看
ah_mini
Contributor I

Yes I did all that but my build setup differs:

MACHINE=imx8mpevk DISTRO=fsl-imx-wayland source ./imx-setup-release.sh -b build

Note I am not building xwayland, just pure wayland.

0 项奖励
回复

5,974 次查看
Chavira
NXP TechSupport
NXP TechSupport

Hi @ah_mini!

Thank you for contacting NXP Support!

 

Can you provide the log file of the error generated by yocto?

 

Best Regards!

Chavira

0 项奖励
回复

5,866 次查看
tw22
Contributor I

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.

0 项奖励
回复

5,756 次查看
tw22
Contributor I

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.

0 项奖励
回复

5,736 次查看
Chavira
NXP TechSupport
NXP TechSupport

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


https://community.nxp.com/t5/i-MX-Processors-Knowledge-Base/Adding-Chromium-to-L5-4-24-2-1-0-I-MX8MQ....

 

Best regards!

Chavira

0 项奖励
回复

5,755 次查看
tw22
Contributor I

HAS_GBM was meant.

0 项奖励
回复

5,945 次查看
ah_mini
Contributor I

Sorry replied to wrong post. See my other post in this thread for logs + potential fix.

0 项奖励
回复