Page 1 of 1

Want to build a custom Raspbian .img, but would like to learn the foundation...

Posted: Sat Jun 09, 2018 2:06 pm
by biggezy
Hi all,

My goal is to ultimately create a ready-to-flash SD card .img file of Raspbian that contains custom programs/packages built in so that when I boot up the Pi, it'll automatically run my programs, show custom splash screen, etc. Doing some research, I think building on top of Pi-Gen is the way to go (correct me if i'm wrong).

But before doing that, I'd like to learn the building blocks that would help me understand how to do this rather than being told how.

Is there any specific material that anyone would recommend reading to understand how the Debian OS/packaging/file system/boot up process/etc. works that'll help me with this task.

Currently reading: Debian GNU/Linux Installation guide and Debian boot process material on the web

Thanks!

Re: Want to build a custom Raspbian .img, but would like to learn the foundation...

Posted: Sat Jun 09, 2018 3:31 pm
by bensimmo
The alternative is to take Raspbian or Raspbian Lite, add/remove and customise as you want.
And then just clone that.

Which is what we pretty much do when we download from RPi website and write it to SD.

We don't install, but just copy an image.

Re: Want to build a custom Raspbian .img, but would like to learn the foundation...

Posted: Sat Jun 09, 2018 3:47 pm
by epoch1970

Re: Want to build a custom Raspbian .img, but would like to learn the foundation...

Posted: Sat Jun 09, 2018 10:57 pm
by davesteele
I'll say two things.

It's pretty easy to self-host pi-gen on a 32 GB SD Raspbian card. It's actually much faster on a Pi than on my desktop, due to QEMU overhead.

Pi-gen is a lightweight wrapper around the command line process for generating the image. The layout is easy to follow.