mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 22:52:11 +02:00
From Dave Williams: A few minor changes to the tutorials and the new cdt_c_makefile.htm
This commit is contained in:
parent
aed8d9ac91
commit
0cfcfb222f
8 changed files with 17 additions and 18 deletions
|
@ -77,9 +77,9 @@ $(LINK_TARGET) : $(OBJS)
|
|||
# It says how to create a file with a .o suffix, given a file with a .cpp suffix.
|
||||
# The rule's command uses some built-in Make Macros:
|
||||
# $@ for the pattern-matched target
|
||||
# $< for the pattern-matched dependency
|
||||
# $lt; for the pattern-matched dependency
|
||||
%.o : %.cpp
|
||||
g++ -g -o $@ -c $<
|
||||
g++ -g -o $@ -c $<
|
||||
|
||||
# These are Dependency Rules, which are rules without any command.
|
||||
# Dependency Rules indicate that if any file to the right of the colon changes,
|
||||
|
@ -94,7 +94,7 @@ Test2.o : Test2.h
|
|||
# Alternatively to manually capturing dependencies, several automated
|
||||
# dependency generators exist. Here is one possibility (commented out)...
|
||||
# %.dep : %.cpp
|
||||
# g++ -M $(FLAGS) $< > $@
|
||||
# g++ -M $(FLAGS) $< > $@
|
||||
# include $(OBJS:.o=.dep)
|
||||
</pre>
|
||||
|
||||
|
@ -153,7 +153,7 @@ Messages from the standard error stream (the lines saying Error 255) and standar
|
|||
This is helpful for build large projects.</p>
|
||||
<p>You can remove the -k flag by turning on Project Properties > C/C++ Make Project > Make Builder > Stop on first build error</p>
|
||||
|
||||
<p><font size="+1"><b>Q6</b>. My Console view looks like:</b></font>
|
||||
<p><font size="+1"><b>Q6</b>. My Console view looks like:</p></font>
|
||||
<pre>
|
||||
mingw32-make clean all
|
||||
process_begin: CreateProcess((null), rm -f Test1.o Test2.o Main.o test_me.exe, ...) failed.
|
||||
|
@ -168,11 +168,11 @@ rm -f Test1.o Test2.o Main.o test_me.exe
|
|||
clean :
|
||||
-del $(REBUILDABLES)
|
||||
echo Clean done
|
||||
<pre></p>
|
||||
</pre></p>
|
||||
<p>The leading minus sign tells make to consider the clean rule to be successful even if the del command returns failure. This may be acceptable since the del command will fail if the specified files to be deleted do not exist yet (or anymore).</p>
|
||||
|
||||
|
||||
<p><img src="../images/ng00_04a.gif" ALT="IBM Copyright Statement" ></p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
|
@ -152,7 +152,7 @@ function goBack() {
|
|||
<body>
|
||||
<h2>CDT Managed Make Tutorial</h2>
|
||||
<center>
|
||||
<IFRAME name=textFrame SRC="cdt_w_basic01.htm" TITLE="cdt_w_basic Text" MARGINWIDTH=0 MARGINHEIGHT=0 width=800 height=180 frameborder=0 SCROLLING=auto></IFRAME>
|
||||
<IFRAME name=textFrame SRC="cdt_w_basic01.htm" TITLE="cdt_w_basic Text" MARGINWIDTH=0 MARGINHEIGHT=0 width=800 height=200 frameborder=0 SCROLLING=auto></IFRAME>
|
||||
<table width="600px" border="0" cellspacing="0" summary="">
|
||||
<tr>
|
||||
<td><img src="../images/trans.gif" align="left" width="22" height="22" onClick="goBack();" title="" name="back"></td>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<head>
|
||||
<meta http-equiv="Content-Language" content="en-us">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<title>C/C++ Development Toolkit (CDT) Standard Make Tutorial</title>
|
||||
<title>CDT Standard Make Tutorial</title>
|
||||
<link rel="stylesheet" type="text/css" href="../help.css">
|
||||
|
||||
<script language="JavaScript">
|
||||
|
@ -167,7 +167,7 @@ function goBack() {
|
|||
<body>
|
||||
<h2>CDT Standard Make Tutorial</h2>
|
||||
<center>
|
||||
<IFRAME name=textFrame SRC="cdt_w_standard01.htm" TITLE="cdt_w_standard Text" MARGINWIDTH=0 MARGINHEIGHT=0 width=800 height=150 frameborder=0 SCROLLING=auto></IFRAME>
|
||||
<IFRAME name=textFrame SRC="cdt_w_standard01.htm" TITLE="cdt_w_standard Text" MARGINWIDTH=0 MARGINHEIGHT=0 width=800 height=200 frameborder=0 SCROLLING=auto></IFRAME>
|
||||
<table width="600px" border="0" cellspacing="0" summary="">
|
||||
<tr>
|
||||
<td><img src="../images/trans.gif" align="left" width="22" height="22" onClick="goBack();" title="" name="back"></td>
|
||||
|
|
|
@ -9,8 +9,7 @@
|
|||
<body>
|
||||
<h3>Discovery Options</h3>
|
||||
<p>Click the <b>Discovery Options</b> tab. This page defines the configuration for autodiscovery of include paths and preprocessor symbols for the parser which
|
||||
enables the parser to understand the contents of the C/C++ source code so that you may more effectively use the search and code completion features.
|
||||
Include paths are also used by the builder to locate files that are not in the workspace.</p>
|
||||
enables the parser to understand the contents of the C/C++ source code so that you may more effectively use the search and code completion features. </p>
|
||||
<p>Select the <b>Automate scanner configuration discovery</b> checkbox to configure the scanner discovery to run automatically.</p>
|
||||
|
||||
</body>
|
||||
|
|
|
@ -14,7 +14,8 @@ window.open(url, 'make_example', 'width=400, height=300, menubar=no, toolbar=no,
|
|||
<body>
|
||||
<h3>Enter the make script</h3>
|
||||
|
||||
<p>Enter the build instruction for your <a href="javascript:void(0)" onClick="newWin('make_example.htm')" title="Click here to get the code">makefile</a> that was just created.
|
||||
<p>Enter the build instruction for your <a href="javascript:void(0)" onClick="newWin('make_example.htm')" title="Click here to get the code">makefile</a> that was just created.
|
||||
The Outline view will display the structure of the makefile as you add components.
|
||||
When you enter the code you will notice an asterisk in front of the file name on the tab in the <b>Editor</b> view, this tells you the file changed but has not been saved.</p>
|
||||
|
||||
<p><i>Note: Ensure you have tabs, not spaces before your indented code, as </i><tt>make</tt><i> will not accept spaces before commands.</i></p>
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
<body>
|
||||
<h3>Run Configuration</h3>
|
||||
|
||||
<p>You should now see the <b>Run Configurations</b> dialog box, navigate to the project in the <b>Configurations:</b> view, and then click <b>New</b>.
|
||||
This will create your Run Configuration.</p>
|
||||
|
||||
<p>You should now see the <b>Run Configurations</b> dialog box, navigate to the <b>Configurations:</b> view, and then double click <b>C/C++ Local</b>.
|
||||
This will create your Run Configuration. Select the new Run Configuration in the <b>Configurations:</b> view.</p>
|
||||
<p>Now click the <b>Main</b> tab and then the <b>Search</b> button.</p>
|
||||
|
||||
|
||||
</body>
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<h3>Run Configuration</h3>
|
||||
<p>Select the new Run Configuration in the <b>Configurations:</b> view and click the <b>Main</b> tab. This is where you select your C/C++ Application.</p>
|
||||
<p>Select the new Run Configuration in the <b>Configurations:</b> view and click the <b>Main</b> tab. This is where you select your C/C++ application and other settings that will impact how your application is run.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -9,8 +9,7 @@
|
|||
<font color="#0066ff">Copy the script below and paste it into the <b>makefile</b> file in the Editor View:</font>
|
||||
|
||||
<pre>
|
||||
makefile:
|
||||
all: hello
|
||||
all: hello
|
||||
|
||||
clean:
|
||||
-rm main.o hello.exe hello
|
||||
|
|
Loading…
Add table
Reference in a new issue