lueschem / edi

Embedded development infrastructure.
https://www.get-edi.io
GNU Lesser General Public License v3.0
38 stars 12 forks source link

Migration strategy from Buildroot/Yocto to edi? #76

Closed sureshjoshi closed 1 year ago

sureshjoshi commented 2 years ago

This is neither a bug request, nor a feature request - more of a documentation request (or a "please point me in the right direction" request).

I just discovered this project today, and I like the tooling in use (happens to also be what I use on a day-to-day basis, except I use rauc in lieu of mender). Very cool project!

Anyways, I might have missed this in the documentation - but is there a recommended strategy for creating a Debian RFS on custom hardware once we already have custom uboot, kernel, and device trees?

I'd like to take what I already have, and strictly replace the RFS part with whatever is needed to get a no-frills Debian Buster/Bullseye up and running. Essentially, I can provide the board-support package, and then would like to drop into Debian. So, literally, just the RFS image - and I can slowly build up the rest of the configuration/documentation/OTA updates around this image.

Thanks!

lueschem commented 2 years ago

Hi @sureshjoshi, the scenario you describe sounds familiar: From the vendor you get a Yocto BSP but you would like to replace it with a Debian based BSP. To be honest, we have gone trough that process already several times. Maybe this blog post can help a bit: https://www.get-edi.io/Getting-Started-with-a-new-Embedded-System/ (Note: The post is slightly outdated as I am not using u-boot on the Raspberry Pi 4 any more.) Depending on your hardware, you also might want to take a look at https://github.com/lueschem/edi-var or https://github.com/lueschem/edi-cl/. Usually it is pretty straight forward to transform the kernel into a Debian package: https://github.com/lueschem/edi-var/blob/master/docs/kernel_build.md For u-boot you can usually take the same binary and flash it to the appropriate location (see also https://github.com/lueschem/edi-var/tree/master/plugins/postprocessing_commands/image/var-som-mx8m-nano). To bridge the gap between u-boot and the kernel I use a small Debian package: https://github.com/lueschem/edi-boot-shim

Does this help?

sureshjoshi commented 2 years ago

Thanks for all the resources @lueschem !

I think where I am/was getting stuck is creation of the deb package for the custom kernel, while also being bootable from u-boot (having literally never done it).

I'll review your resources and report back!