freebsd / crochet

Build FreeBSD images for RaspberryPi, BeagleBone, PandaBoard, and others.
BSD 2-Clause "Simplified" License
611 stars 188 forks source link

Can crochet run from Linux? #293

Closed ecorm closed 1 year ago

ecorm commented 1 year ago

I'm interested in generating custom FreeBSD images for a BeagleBone Black device, but my desktop development environment is a Linux-based distro. Can crochet run from Linux, or do I need to set up a FreeBSD build PC for this purpose?

I'm already familiar with Buildroot for generating embedded Linux images, but I'm looking into migrating to FreeBSD for a commercial project to avoid legal/licensing issues.

brd commented 1 year ago

Hello! There is some work to build FreeBSD on linux, but I doubt crochet knows how to take advantage of it. Maybe you could use a FreeBSD VM to do it?

These days I would probably look at poudriere image support, it can spit out a raw filesystem image that you can then add the appropriate uboot, etc to using mkimg(1) etc.

ecorm commented 1 year ago

Thanks for the info, brd!

ecorm commented 1 year ago

@brd It seems that with either crochet or poudriere, building an image can take over an hour. Is it possible to use a pre-built FreeBSD kernel, and only compile the extras that are to be included in the device image? Buildroot has this feature, which saves a lot of time.

ecorm commented 1 year ago

@brd, if I understand correctly, both crochet and pourdriere are for cross-compiling the basic OS only, and if I want to add libraries or userland applications, it must be done on the device via the command line.

I need to be able to generate a complete image, including libraries, 3rd party apps, and our in-house app that can be deployed all at once on the device. Buildroot allows me to do that (with Linux as the kernel), but I don't see an equivalent way to do this for FreeBSD.

I hope I am mistaken about these limitations regarding crochet/poudriere.

ecorm commented 1 year ago

I found the poudriere discussion forum on GitHub and made an inquiry there: https://github.com/freebsd/poudriere/discussions/1056