set substitute-path (gdb mode only)

Set a substitution rule for finding source files.

Syntax

set substitute-path from-path  to-path

Parameters

from-path

The path to be replaced.

to-path

The new path.

Description

This command sets a substitution rule for finding source files.

Example

In this example, the debuggee is compiled in Funct/src/temp/src, but the sources are in Funct/src. The debugger needs a substitute path to find the sources.

The debugger cannot find the sources because there is no sustitute path, so the list command does not display any source code:

(idb)  list main
No source file named /site/Funct/src/temp/src/c_sanity.c.  
(idb)  show substitute-path
(idb) 

The set substitute-path command tells the debugger where to find the sources, so the list command displays the source code:

(idb)  set substitute-path '/site/Funct/src/temp/src' '/site/Funct/src'
(idb)  show substitute-path
/site/Funct/src/temp/src  ->  /site/Funct/src
(idb)   
(idb)  list main
16      }
17
18      iab2 (na, sum, ivar, nb)
19          int *na, sum[], *ivar, *nb;
20      {

See Also


Submit feedback on this help topic

Copyright © 1996-2010, Intel Corporation. All rights reserved.