Manual path mappings

You need to specify the source lookup path in terms of the compilation path and the local file-system path for the newly imported executable file. The CodeWarrior debugger uses both of these paths to debug the executable file. The compilation path is the path to the original project that built the executable file. If the original project is from an IDE on a different computer, you specify the compilation path in terms of the file system on that computer. The local file-system path is the path to the project that the CodeWarrior IDE creates in order to debug the executable file. Path mappings can be added per launch configuration or global, per workspace. In the latest case the mapping will be valid for all the projects within the workspace.

To add a path mapping to a launch configuration:

  1. Click the Source tab of the Debug Configurations dialog.
    Figure 1. Debug Configurations dialog - Source page

    Debug Configurations - Source Page

  2. Click Add.

    The Add Source dialog appears.

  3. Select Path Mapping.
    Figure 2. Add Source dialog

    Add Source dialog

  4. Click OK.

    The Path Mappings dialog appears.

    Figure 3. Path Mappings dialog

    Path Mappings dialog

  5. Specify the Path mappings name in the Name textbox.
  6. Click Add.
  7. In the Compilation path textbox, enter the path to the parent project of the executable file, relative to the computer that generated the file.

    For example, the computer on which you debug the executable file is not the same computer that generated that executable file. On the computer that generated the executable file, the path to the parent project is D:\workspace\originalproject. Enter this path in the Compilation path textbox.

    Tip: You can use the IDE to discover the path to the parent project of the executable file, relative to the computer that generated the file. In the C/C++ Projects view of the C/C++ perspective, expand the project that contains the executable file that you want to debug. Next, expand the group that has the name of the executable file itself. A list of paths appears, relative to the computer that generated the file. Search this list for the names of source files used to build the executable file. The path to the parent project of one of these source files is the path you should enter in the Compilation path textbox.
  8. In the Local file system path textbox, enter the path to the parent project of the executable file, relative to your computer. Alternatively, click the Browse button to specify the parent project.

    An intermediate dialog appears, where the local path can be specified from the Local System or based on one or more Eclipse variables.

  9. Click OK.

    The Path Mappings dialog closes. The mapping information now appears under the path mapping shown in the Source Lookup Path list of the Source page.

  10. If needed, change the order in which the IDE searches the paths.

    The IDE searches the paths in the order shown in the Source Lookup Path list, stopping at the first match. To change this order, select a path, then click the Up or Down button to change its position in the list.

  11. Click Apply.

The IDE saves your changes.