📄 c-builder2.html
字号:
<dl class="margin"><div class="CellBody"><a name="100097"> </a><img class="figure" border="0" src="images/c-builder42.gif"></div></dl></div></p><dd><p class="Body"><a name="100087"> </a>If you do not calculate dependencies before you start a build, Tornado will prompt you to do so for any of the project files for which dependencies have not previously been calculated. </p><dd><p class="Body"><a name="94449"> </a>The <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Advanced</font></b> option allows you to speed up the build process by specifying paths in which <i class="emphasis">none</i> of the dependencies could have changed since the last build. The timestamps for the files in the specified paths are <i class="emphasis">not</i> checked (<a href="c-builder2.html#94428">Figure 4-13</a>). <div class="frame"><h4 class="EntityTitle"><a name="94428"><font face="Helvetica, sans-serif" size="-1" class="sans">Figure 4-13: Dependency Calculation Option</font></a></h4><dl class="margin"><div class="CellBody"><a name="94433"> </a><img class="figure" border="0" src="images/c-builder13.gif"></div></dl></div></p></dl></dl><font face="Helvetica, sans-serif" class="sans"><h4 class="H4"><i><a name="97000">Build Specifications</a></i></h4></font><dl class="margin"><dl class="margin"><dd><p class="Body"><a name="97001"> </a>Each build for a downloadable application consists of a set of options for makefile rules and macros, as well as for the compiler, assembler, and linker. A default build specification is defined when you create your project. To display information about it, double-click on the build name in the <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Builds</font></b> view of the workspace to display the property sheet for the build. The <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Rules</font></b> page (<a href="c-builder2.html#97017">Figure 4-14</a>) allows you to select from the following build target options: <div class="frame"><h4 class="EntityTitle"><a name="97017"><font face="Helvetica, sans-serif" size="-1" class="sans">Figure 4-14: Build Property Sheet</font></a></h4><dl class="margin"><div class="CellBody"><a name="97022"> </a><img class="figure" border="0" src="images/c-builder26.gif"></div></dl></div></p></dl><dl class="margin"><dd><div class="Item"><a name="105842"> </a><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">objects</font></b></div><dl class="margin"><dd><div class="Indent"><a name="105845"> </a>Objects for all source files in the project.</div><br></dl><dd><div class="Item"><a name="105843"> </a><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">archive</font></b></div><dl class="margin"><dd><div class="Indent"><a name="105846"> </a>An archive (library) file.</div><br></dl><dd><div class="Item"><a name="105844"> </a><i class="textVariable">projectName</i><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">.out</font></b></div><dl class="margin"><dd><div class="Indent"><a name="105847"> </a>A single, partially-linked and munched object that comprises all of the individual object modules in a project.</div><br></dl></dl><dl class="margin"><dd><p class="Body"><a name="97010"> </a>You can use the project facility to change the options for a given build, create and save new build specifications, and select the specification to use for a build. You can, for example, create one build specification for your project that includes debug information, and another that does not. For more information, see <a href="c-builder5.html#98349"><i class="title">4.5 Working With Build Specifications</i></a>.</p></dl></dl><dl class="margin"><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/note.gif"></td><td><hr><div class="CalloutCell"><a name="102192"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">NOTE: </font></b></a>It is sometimes useful to build an application for the target simulator, and then to create a new build specification to build it for a real target.</div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout></dl><font face="Helvetica, sans-serif" class="sans"><h4 class="H4"><i><a name="96993">Building an Application</a></i></h4></font><dl class="margin"><dl class="margin"><dd><p class="Body"><a name="96567"> </a>To build a project with the default options, select the name of the project (or any subordinate object in its folder) and then select <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build '</font></b><i class="textVariable">projectName</i><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">.out'</font></b> from the context menu. If you have created build specifications in addition to the default, you can select the build specification you want to use from the <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build</font></b> drop-down list at the top of the workspace window before you start the build.</p></dl></dl><dl class="margin"><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/warning.gif"></td><td><hr><div class="CalloutCell"><a name="102209"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">WARNING: </font></b></a>Tornado only calculates dependencies upon the first use of a file in a build. Once an initial set of dependencies has been calculated, Tornado does not attempt to detect changes in dependencies that may have resulted from modification of the file. If you have changed dependencies by adding or deleting <b class="symbol_lc">#include</b> preprocessor directives, you should regenerate dependencies. </div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dd><p class="Body"><a name="96808"> </a>The <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build Output</font></b> window displays build messages, including errors and warnings (<a href="c-builder2.html#88888">Figure 4-15</a>). <div class="frame"><h4 class="EntityTitle"><a name="88888"><font face="Helvetica, sans-serif" size="-1" class="sans">Figure 4-15: Build Output</font></a></h4><dl class="margin"><div class="CellBody"><a name="88893"> </a><img class="figure" border="0" src="images/c-buildera2.gif"></div></dl></div></p><dd><p class="Body"><a name="88894"> </a>Any compiler errors or warnings include the name of the file, the line number, and the text of the error or warning text. Double-clicking on the line containing the error message opens the file in the editor with a context pointer on the offending line. The error or warning text is also displayed in the status bar at the bottom of the main Tornado window. </p><dd><p class="Body"><a name="88903"> </a>Use the <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Edit</font></b>><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Next Error/Tag</font></b> and <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Edit</font></b>><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Previous Error/Tag</font></b> menu options to navigate between errors when you are using the Tornado editor.</p></dl><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/warning.gif"></td><td><hr><div class="CalloutCell"><a name="104920"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">WARNING: </font></b></a>The default compiler options include <b class="command">-g</b> for debugging information. Using <b class="command">-g</b> with the optimization option <b class="command">-O </b>set to anything but zero may produce unexpected results. See <a href="c-builder5.html#98349"><i class="title">4.5 Working With Build Specifications</i></a> for information about modifying builds and creating new build configurations.</div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dd><p class="Body"><a name="94714"> </a>To force a rebuild of all project objects, select <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Rebuild All</font></b> from the context menu (which performs a <b class="command">make clean</b> before the build). </p></dl></dl><dl class="margin"><dd><font face="Helvetica, sans-serif" size="-1" class="sans"><h5 class="HU"><i><a name="100152">Build Toolbar</a></i></h5></font><dl class="margin"><dd><p class="Body"><a name="100139"> </a>The <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build</font></b> toolbar provides quick access to build commands. Display of the toolbar is controlled with the <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">View</font></b>><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Toolbar</font></b>><b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build Toolbar</font></b> menu option. The toolbar is shown free-floating in <a href="c-builder2.html#100162">Figure 4-16</a>, but is docked by default. <div class="frame"><h4 class="EntityTitle"><a name="100162"><font face="Helvetica, sans-serif" size="-1" class="sans">Figure 4-16: Build Toolbar</font></a></h4><dl class="margin"><div class="CellBody"><a name="100168"> </a><img class="figure" border="0" src="images/c-builder43.gif"></div></dl></div></p><dd><p class="Body"><a name="100137"> </a>The <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Build</font></b> toolbar commands (<a href="c-builder2.html#100190">Table 4-1</a>) are also available from the main menus and the <b class="guiLabel"><font face="Helvetica, sans-serif" size="-1" class="sans">Workspace</font></b> context menu. <p class="table"><h4 class="EntityTitle"><a name="100190"><font face="Helvetica, sans-serif" size="-1" class="sans">Table 4-1: Build Toolbar Buttons</font></a></h4><table border="0" cellpadding="0" cellspacing="0"><tr><td colspan="20"><hr class="tablerule"></td></tr><tr valign="middle"><th rowspan="1" colspan="1"><div class="CellHeading"><b><a name="100196"> </a><font face="Helvetica, sans-serif" size="-1" class="sans">Button</font></b></div></th><td width="10"> </td>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -