In order to compile an i.MX8M Plus image with chromium, please follow these steps:
These steps were tested on a Ubuntu 22.04 build machine.
Install required packages
sudo apt install flex bison gperf build-essential zlib1g-dev lib32ncurses5-dev \ x11proto-core-dev libx11-dev lib32z1-dev libgl1-mesa-dev tofrodos libxml2-utils \ openssh-server openssh-client uuid uuid-dev zlib1g-dev liblz-dev lzop liblzo2-2 \ liblzo2-dev git-core curl python3 python3-pip python3-pexpect python3-git \ python3-jinja2 u-boot-tools mtd-utils openjdk-8-jdk device-tree-compiler aptitude \ libcurl4-openssl-dev nss-updatedb chrpath texinfo gawk cpio diffstat \ libncursesw5-dev libssl-dev libegl1-mesa net-tools libsdl1.2-dev xterm socat \ icedtea-netx-common icedtea-netx python3-markdown android-sdk-libsparse-utils \ xsltproc gcc-multilib g++-multilib subversion libc++-dev libstdc++6 \ libstdc++-12-dev python-is-python3 lz4; pip3 install pylint
Clone and build the meta-solidrun-arm-imx8 repository
git clone https://github.com/SolidRun/meta-solidrun-arm-imx8.git -b kirkstone-imx8m
Now, follow the steps in the README file up to step 5, including.
Append the following line to conf/local.conf
CORE_IMAGE_EXTRA_INSTALL += "chromium-ozone-wayland"
run the following command
bitbake chromium-ozone-wayland -c fetch
Continue with the README steps.
Please make sure to build the full image, not the minimal one.
Important notes:
The repo command mentioned in the README file may fail, in this case, please download and use the following repo binary: https://storage.googleapis.com/git-repo-downloads/repo
If you get the following errors during compilation:
WARNING: nnshark-2021.10.imx-r0 do_fetch: Failed to fetch URL gitsm://source.codeaurora.org/external/imx/nnshark.git;protocol=https;branch=2021.10.imx, attempting MIRRORS if available ..
Please add the following mirrors to conf/local.conf
MIRRORS += " \ git://source.codeaurora.org/external/imx/ git://github.com/nxp-imx/;protocol=https \n \ https://source.codeaurora.org/external/imx/ https://github.com/nxp-imx/ \n \ http://source.codeaurora.org/external/imx/ http://github.com/nxp-imx/ \n \ gitsm://source.codeaurora.org/external/imx/ gitsm://github.com/nxp-imx/;protocol=https \n \ "
Using Chromium
Once the image was compiled and deployed, you can start the browser simply by running:
chromium --no-sandbox