Custom Image Generation

I'm working on getting LinuxCNC running on the BeagleBone, and while I
have had good success, the process is far from simple.

In order to make LinuxCNC more accessible on the 'Bone, I would like to
create a custom image that is pre-configured to actually work. While
there have been a few images released by Michael Haberler for the 'Bone,
these are essentially either raw SD images or tgz files of the entire

I am currently planning on forking and modifying the RobertCNelson
omap-image-builder scripts on github to make a customized SD image
builder that includes a compiled LinuxCNC and all it's dependencies, but
I figured I should ask here first.

So...what is the recommended way to create custom images for the 'Bone?

Hi Charles,

If/When you fork, can you let me know if you find something
"non-generic" as I've tried my best to make the script as generic as
possible, but every once in awhile something gets added..

Otherwise it's the exact same script that generates:


Yes, I saw that you're generating several different images from the
scripts (which are awesome by the way! Thanks for sharing!).

Mostly I need to be able to hook into the root image build process in a
couple of places in order to:

* Add the (excessive) amount of packages required to get LinuxCNC to
build and run. If it was only a few, I'd tell people to use your image
and install them by hand. :slight_smile:

* Add hooks to copy or download additional content (ie: the LinuxCNC
source, and some tweaked stuff like a custom rc.local)

* Add the ability to run some native commands in the chroot prior to
tarring the root filesystem. I am hoping I can build from source here,
but if not I'll just copy in a pre-built directory in the previous step.

I didn't see anything obvious to let me hook into the image build
process anywhere, but I'm still crawling through things and might have
missed it. I'm going to try to keep my changes to your code minimal and
limited to adding what I hope to be generally useful extensions that
might get pushed (ie: the ability to run some hook scripts, if present,
and specify extra packages somehow). If you have preferences on how to
implement this, or a mechanism in place that I've missed, let me know.

And thanks again for all the excellent work!