NOTE: This page is under construction.
Builder is the program that’s at the heart of the RISC OS build system. Whether you’re building a ROM image, a hard disc image, a collection of standalone programs, or even the build tools themselves, you’ll be doing it with the help of Builder.
h2(#build%20directories). Build directories
All builds occur inside a build directory. The build directory contains all the source files, all the build tools, all the intermediate files, and all the final output files. The first time you run Builder a window will pop up asking you to register the initial build directory. Whether you’ve fetched your source code from CVS or extracted it from an archive, the build directory is always the “RiscOS” folder – so drag that folder into the window to register it with Builder. Note that currently Builder can only work with ‘merged’ folders – i.e. the contents of the “castle”, “bsd”, “mixed”, “gpl”, etc. folders must have been merged together into one single “RiscOS” folder.
If you want to change the location of your build directory or register additional directories, you can do so by selecting the ??? option from the iconbar menu.
If you look inside the ??? folder of your build directory then you’ll see several components files. Each file represents a different build environment. The build enviornment represents the end product which is being built – e.g. the Tungsten file describes how to build an Iyonix ROM image, and the Disc file describes how to build the HardDisc4 image. Different build environments have different dependenices, in terms of which build tools and source components are required. Since all components files are held in the same folder in CVS, this means that even if you’ve only downloaded (or extracted) the Tungsten build tree you’ll still end up with components files for most of the other products. Attempting to use those other components files with your build tree is likely to result in failure due to the build tree lacking some or all of the required components.
h2(#get%20ready). Getting ready to perform a build
If you’ve registered a build tree with Builder then clicking select on the iconbar icon will open the main window. At the top of the window you’ll see two icons to allow you to select the build directory and environment. To get ready to perform a build, first select the build directory, then select the environment. Then move on to select the build stages and other options.
Each time you select an environment Builder will run a couple of scripts behind the scenes to configure your computer ready for performing the build – adding the right build tools to your Run$Path variable, setting the right compiler options for the required CPU type, etc. This configuration step is vitally important if you plan on using the numerous !Mk, !MkSA, etc. scripts to build components individually. Without performing this step the code may be compiled for the wrong CPU type, be linked against the wrong libraries, or use the wrong set of C library headers.
h2(#build%20stages). Build stages
Underneath the build directory and environment selection boxes there are a number of check boxes for selecting the build stages. It’s important to know what each stage does and when it must be used. Builder will run through the different stages in a fixed order, and for each stage which is enabled it will perform the relevant actions for each component.
The stages are performed in the following order:
h4(#clean%20all). The Clean All stage
h4(#export%20headers). The Export headers stage
h4(#export%20libraries). The Export libraries stage
h4(#export%20resources). The Export resources stage
h4(#make%20rom). The Make ROM stage
h4(#link%20rom). The Link ROM stage
h4(#join%20rom). The Join ROM stage
h4(#install disc). The Install disc stage
h2(#other%20options). Other options