ChorusOS 4.0 Introduction

Enabling Debugging for Components Built with imake

To build all your components with symbolic debugging information turned on:

Other ways can be used to selectively build your components with symbolic debugging information. These are presented below.

To enable symbolic debugging throughout the component directory and its sub-directories:

  1. Edit the Project.tmpl file located in the root of the component source directory, and add the following line to the end:

    DEBUG=$(DEBUG_ON)

  2. Change directory to the root of your build directory and remove all the object files and executables:


    % make clean
    

  3. Rebuild the local Makefile:


    % make Makefile
    

  4. Rebuild the sub-directory Makefiles:


    % make Makefiles
    

  5. Finally, rebuild the component:


    % make
    

To enable symbolic debugging in selected component directories:

  1. Edit the Imakefile within each desired component source directory, and add the following line to the end:

    DEBUG=$(DEBUG_ON)

  2. Change directory to the root of your build directory and remove all the object files and executables:


    % make clean
    

  3. Rebuild the local Makefile:


    % make Makefile
    

  4. Finally, rebuild the component:


    % make
    

If you prefer not to modify the Imakefile or Project.tmpl files, there is an alternative way of enabling debugging. You can pass the debug option within the make command itself:

Once a component has been compiled in debug mode, rebuild and reboot the system image.