43 lines
1.8 KiB
Markdown
43 lines
1.8 KiB
Markdown
## How the build process works
|
|
|
|
The following process is followed to build images:
|
|
|
|
* Iterate through all of the stage directories in alphanumeric order
|
|
|
|
* Bypass a stage directory if it contains a file called
|
|
"SKIP"
|
|
|
|
* Run the script `prerun.sh` which is generally just used to copy the build
|
|
directory between stages.
|
|
|
|
* In each stage directory iterate through each subdirectory and then run each of the
|
|
install scripts it contains, again in alphanumeric order. **These need to be named
|
|
with a two digit padded number at the beginning.**
|
|
There are a number of different files and directories which can be used to
|
|
control different parts of the build process:
|
|
|
|
- **00-run.sh** - A unix shell script. Needs to be made executable for it to run.
|
|
|
|
- **00-run-chroot.sh** - A unix shell script which will be run in the chroot
|
|
of the image build directory. Needs to be made executable for it to run.
|
|
|
|
- **00-debconf** - Contents of this file are passed to debconf-set-selections
|
|
to configure things like locale, etc.
|
|
|
|
- **00-packages** - A list of packages to install. Can have more than one, space
|
|
separated, per line.
|
|
|
|
- **00-packages-nr** - As 00-packages, except these will be installed using
|
|
the `--no-install-recommends -y` parameters to apt-get.
|
|
|
|
- **00-patches** - A directory containing patch files to be applied, using quilt.
|
|
If a file named 'EDIT' is present in the directory, the build process will
|
|
be interrupted with a bash session, allowing an opportunity to create/revise
|
|
the patches.
|
|
|
|
* If the stage directory contains files called "EXPORT_NOOBS" or "EXPORT_IMAGE" then
|
|
add this stage to a list of images to generate
|
|
|
|
* Generate the images for any stages that have specified them
|
|
|
|
It is recommended to examine build.sh for finer details. |