This section describes how to generate a standard ChorusOS system image. Standard system generation builds a non-customized version of the operating system.
During the build you use the following commands:
Creates the build-tree Makefiles.
See the configure(1CC) man page for more information.
Makes the source, object and binary files.
See the make(1S) man page for more information.
Configures features
Configures features
Components are configured using rhe configure command. The configure command features three options:
Chooses the predefined profile for the PowerPC, ppc60x family, for example:
configure -f source_dir/mkernel/sys/ppc60x/ppc60xThis selects the
NUCLEUS
source component, containing a definition
of the variables for the build.
Selects the ChorusOS source components to be included in the build of your system image, for example:
configure -s source_dir/nucleus/bsp/powerpc/mcp7xx \ source_dir/nucleus/bspThe components included determine the identity of the image. In this case, you have included the boot and DRV components in source.
Includes binary components in your system image.
The configure command searches the directories specified by the -s and -b options for the Makefile.src and Makefile.bin files and any file corresponding to Makefile.*.src or Makefile.*.bin. The command displays each component as it adds it to the configuration. The configure command creates two files in build_dir, Makefile and Paths.
A system image is created from components you have configured using the configure command. The system image is created automatically, in four stages:
Selecting the System Image: Choose which of the configured components to include in your system. The system images are defined in:
The Makefile.bin file of the NUCLEUS
component:
source_dir/nucleus/sys/common/Makefile.bin
The conf directory:
build_dir/conf/mkimage/mkimage.xml
Once you have selected your system image, you can use the make command in two ways to build your system image:
Referencing the system image name:
host% make system_image_name
Building all configured components in your work directory:
host% make
The make command automatically performs steps 2, 3 and 4.
Compilation: The default action of make is to compile everything in your work directory, but not to produce a bootable system image. This is because configure might be used to build components which are not directly related to ChorusOS systems.
Compilation can last from 5 minutes to more than an hour, depending on the host you are using and the amount of new files being built. For the chorus system image, the make is as follows:
host% make chorus
Rebuilding the configurable components: If the configuration of the system has changed since the last make, some actors might need to be re-linked. The make command checks if any configurable actors require re-linking.
Running obj/act/pmm/Makefile build_dir/build-DEVTOOLS/host/bin/configurator -c build_dir/conf/ ChorusOS.xml -action configure Running obj/act/sysdump/Makefile Running obj/dbg/Makefile Running obj/kern/Makefile Running obj/chorus.sbin/cinit/hrCtrl/Makefile Running obj/chorus.sbin/cinit/rshd/Makefile Running obj/sys/Makefile
Building the System Image: Once the necessary actors have been re-linked, the make command calls mkimage. This generates the system image.
Start mkdrv Finish mkdrv Start mkimage Brief log file: build_dir/image/RAM/chorus/log.brief Verbose log file: build_dir/image/RAM/chorus/log.verbose Layout file: build_dir/image/RAM/chorus/layout.xml Image file: build_dir/chorus.RAM Finish mkimage
Once you have built your system image, build_dir contains a build directory for each source component included in the build.