Build the Image
This section provides step-by-step instructions for setting up the workspace, starting the containerized build environment, preparing the Yocto configuration, and starting the image build process.
Initialize the Workspace
Create a new directory for the build environment and initialize repo
with the appropriate manifest.
This will download the necessary layers for the build.
mkdir genio cd genio repo init -u https://github.com/grinn-global/manifest-grinn-genio.git -b kirkstone repo sync
Run the Docker Container
Start the Grinn Yocto Docker container, mounting the current working directory into the container and mapping your user ID.
docker run -it \
-e CUSTOM_UID=$(id -u) \
-e CUSTOM_GID=$(id -g) \
-v $(pwd):$(pwd) \
-w $(pwd) \
ghcr.io/grinn-global/grinn-yocto-container
Configure the Build Environment
Set the TEMPLATECONF
environment variable and source the Yocto environment script.
export TEMPLATECONF=$(pwd)/src/meta-grinn-genio/conf/templates/default source src/poky/oe-init-build-env
Build the Image
Set the MACHINE
variable to specify the target hardware platform. Then run bitbake
to build the image.
export MACHINE=grinn-genio-510-sbc bitbake rity-demo-image
Note
The build process may take a while, depending on your system’s resources.
After the build completes, verify that the image was created by checking the output directory.
ls tmp/deploy/images/grinn-genio-510-sbc