carbidecpp22devenv/configuration/org.eclipse.osgi/bundles/309/1/.cp/tasks/cdt_t_debug_exes.htm
author cawthron
Fri, 04 Dec 2009 10:01:33 -0600
changeset 5 684bf18fdedf
permissions -rw-r--r--
add files for RCL_2_2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
5
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     1
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     2
<html lang="en">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     3
<head>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     4
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     5
<meta http-equiv="Content-Style-Type" content="text/css" />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     6
<meta name="LASTUPDATED" content="06/17/05 11:09:43" />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     7
<title>Debugging Existing Executables</title>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     8
<link rel="stylesheet" type="text/css" href="../help.css"/>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     9
<style>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    10
ul, li	{ padding: 3px 0px}
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    11
</style>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    12
</head>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    13
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    14
<body>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    15
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    16
<h1>Debugging an Existing Executable </h1>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    17
<p>Use the import feature to import and debug an executable you have already built. This feature will automatically create a project and debug configuration for you. This is helpful if you have an executable built with debug symbols but may not have the project used to build the executable. </p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    18
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    19
  <h4>Importing Executables for Debugging </h4>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    20
  <ol>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    21
    <li>Select the <b>File &gt; Import...</b> menu item.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    22
    <li>In the <b>Import</b> wizard dialog, click <b>C/C++</b> and select <b>C/C++ Executable</b>.<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    23
      <p><img src="../images/cdt_debug_exes01.png" vspace="12"  alt="Import dialog"/></p></li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    24
    <li>Click <b>Next</b>.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    25
   <li>In the <b>Import C/C++ Executable Files</b> page of the <b>Import Executable</b> dialog:<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    26
   <ul>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    27
   	<li>Choose a parser from the <b>Select binary parser</b> list.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    28
   	<li>Type the executable path in the <b>Select executable</b> box or click <b>Browse</b> to locate the executable.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    29
    <li>Type or click <b>Browse</b> to enter a directory path in the <b>Search directory</b> box, then select one or more executables from the <b>C/C++ Executable Files</b> list.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    30
   </ul>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    31
   <p><img src="../images/cdt_debug_exes02.png" vspace="12"   alt="Import Executable dialog"/></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    32
   <p><b>NOTE</b> You can import any executable, but only those built with debug symbols will be let you step through source code and see variable values. </p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    33
   </li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    34
   <li>Click <b>Next</b>.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    35
   <li>In the <b>Choose Project</b> page of the <b>Import Executable</b> dialog:<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    36
   <ul>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    37
   	<li>To import as a new project, activate <b>New project name</b> and type the project name.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    38
   	<li>To import into an existing project, activate <b>Existing project</b> and click <b>Search</b>.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    39
   	<li>To add a launch configuration, activate <b>Create a Launch Configuration</b> and select the configuration from the list, then type a name into the <b>Name</b> box.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    40
   </ul>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    41
   <p><img src="../images/cdt_debug_exes03.png" vspace="12"   alt="Import Executable dialog"/></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    42
   </li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    43
  <li>Click <b>Finish</b>.<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    44
    <p>The executable is added to the <b>C/C++ Projects</b> view.</p></li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    45
  <li>If <b>Create a Launch Configuration</b> was activated, the <b>Debug</b> dialog appears.<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    46
      <p><img src="../images/cdt_debug_exes04.png" vspace="12"  alt="Debug launch configuration dialog"/></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    47
  </li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    48
  <li>Click <b>Debug</b>.<br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    49
  <p>The debugger launches and you can begin debugging the executable.</p></li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    50
  </ol>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    51
  
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    52
  <h3>Setting breakpoints </h3>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    53
  <p>Expand the executable in the <b>C++ Projects</b> view to see the list of source files. Only executables built with debug symbols will show a list of source files. The source files can be opened in the editor so you can set breakpoints. Use these files only for debugging, you can not change them and rebuild the executable with this project. </p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    54
     <p><img src="../images/cdt_debug_exes05.png" alt="C++ Projects View" vspace="12" /></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    55
 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    56
<p><img border="0" src="../images/ngconcepts.gif" alt="Related concepts" width="143" height="21" /> <br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    57
    <a href="../concepts/cdt_c_over_dbg.htm">Debug overview</a><br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    58
  <a href="../concepts/cdt_c_dbg_info.htm">Debug information</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    59
<p><img border="0" src="../images/ngtasks.gif" alt="Related tasks" width="143" height="21" /> <br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    60
  <a href="cdt_o_debug.htm">Debugging</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    61
<p><img border="0" src="../images/ngref.gif" alt="Related reference" width="143" height="21" /> <br />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    62
  <a href="../reference/cdt_o_run_dbg_pages.htm">Run and Debug dialog box</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    63
<hr />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    64
<img src="../images/nokia2007Copyright.png" alt="Nokia Copyright Statement" />
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    65
</body>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    66
</html>