93 | | Basically, drop a file inside of the main directory when building the Venice BSP with the name starting with custom_rootfs will be ran. Example file name is custom_rootfs_test.sh |
94 | | {{{ |
95 | | builder@jammy:~/venice$ ls |
96 | | Makefile buildroot firmware-imx-8.10 ftdi-usb-spi linux-venice.tar.xz noble-venice.ext4.xz setup-environment uboot-env.bin |
97 | | atf cryptodev-linux firmware-imx-8.10.bin gnss_devkit mkimage_jtag noble-venice.img.gz u-boot venice |
98 | | build custom_rootfs_test.sh firmware.img linux noble-venice.ext4 nrc7292 ublox-dev-kit-README.txt venice-imx8mm-flash.bin |
99 | | }}} |
100 | | |
101 | | Inside this file, run a script that runs on the build machine to create and grab files to be placed into the Ubuntu filesystem. |
102 | | |
103 | | The Ubuntu filesystem is of ext2 format, and thus e2tools must be used. In the example below, e2cp is a command that ends up copying files into the /root directory (default Gateworks home directory) when the Ubuntu OS is booted. |
104 | | |
105 | | The below example does some random things such as grabbing a tar ball, creating a readme and then copying it into the Ubuntu OS. |
106 | | |
107 | | After creating this file, re-run the make argument to rebuild the Gateworks BSP with the custom changes now integrated: |
108 | | {{{ |
| 93 | Basically, drop an 'executable' file inside of the main directory when building the Venice BSP with the name starting with custom_kernel, custom_rootfs, custom_image: |
| 94 | * custom_kernel* - will be called passing in the kernel-directory and the install-directory before generation of the kernel tarball. While this is intended for kernel related things (as they go in the kernel tarball) there is no reason you can't also add other files here) |
| 95 | * custom_rootfs* - will be called passing in the ext filesystem image where you can either use things from the e2tools package (e2cp, e2rm, e2ln, e2mkdir) to manipulate the filesystem or use other methods (such as mounting it, manipulating it, unmounting it) |
| 96 | * custom_image* - will be called passing in the uncompressed disk image where you can manipulate it with anything necessary (such as editing the partition table) before it is compressed. |
| 97 | |
| 98 | Make sure the files are executable and they should probably have a 'set -e' in them so that any command that errors out breaks the build process. |
| 99 | |
| 100 | After creating or altering these custom* scripts, re-run the make argument to rebuild the Gateworks BSP with the custom changes now integrated: |
| 101 | {{{#!bash |