Skip to content

Commit

Permalink
updated docu
Browse files Browse the repository at this point in the history
  • Loading branch information
aschaal committed Jan 7, 2015
1 parent d9a9886 commit 1e02b1e
Show file tree
Hide file tree
Showing 13 changed files with 221 additions and 38 deletions.
2 changes: 1 addition & 1 deletion doc/cmd/install.html
Expand Up @@ -15,7 +15,7 @@
<body>
<h1>How to install bake command line tool</h1>

bake is a ruby gem. It runs with ruby 1.8.6 and above. However, it is <b>highly recommended</b>, that you use <b>ruby 1.9.x</b>, because of a <b>significant speed improvement</b>.
bake is a ruby gem. It runs with ruby 1.9 and above.
<p>
bake and its depedencies can be found on rubygems, which is configured as ruby source per default. Type "gem sources" if you wish to check that.<br>
Installing bake is very easy:
Expand Down
34 changes: 29 additions & 5 deletions doc/cmd/usecmd.html
Expand Up @@ -20,7 +20,8 @@ <h1>How to use bake on command line</h1>
<ul>
<li><b>-b</b> the build configuration name
<li><b>-m</b> the main project directory (default is current directory)
<li><b>-p</b> the project to build (if not specified, the main project will be built with all dependencies)
<li><b>-p</b> the project to build (if not specified, the main project will be built with all dependencies) - note, that ALL configs of the project will be built,
which is usually just one config, but if you have more than one config of the project in the workspace, use a comma separator.
</ul>

<h2>Examples</h2>
Expand All @@ -29,22 +30,45 @@ <h2>Examples</h2>

<pre id="rundrum"><code>bake -b Debug</code></pre>

It is possible to omit "-b":

<pre id="rundrum"><code>bake Debug</code></pre>

It Debug is the default configuration, it's just:

<pre id="rundrum"><code>bake</code></pre>

If you are not in the directory of the main project you want to build:

<pre id="rundrum"><code>bake -b Debug -m w:/root/mainProj</code></pre>
<pre id="rundrum"><code>bake Debug -m w:/root/mainProj</code></pre>

Building just mainProj project:

<pre id="rundrum"><code>bake Debug -m w:/root1/myProj -p myProj</code></pre>

Assuming mainProj has several configs really included in the build (which is uncommon), you can choose one of the configs like this:

<pre id="rundrum"><code>bake Debug -m w:/root1/myProj -p myProj,abc</code></pre>

Code has been checked out into two roots, the console supports ansi colors, you want to stop on first error and build only the project bspAbc:

<pre id="rundrum"><code>bake -b Debug -m w:/root1/myProj -w w:/root1 -w w:/root2 -r -a black -p bspAbc</code></pre>
<pre id="rundrum"><code>bake Debug -m w:/root1/myProj -w w:/root1 -w w:/root2 -r -a black -p bspAbc</code></pre>

To clean the project(s), just add "-c":

<pre id="rundrum"><code>bake Debug -m w:/root1/myProj -w w:/root1 -w w:/root2 -r -a black -p bspAbc -c</code></pre>

To build single file(s), use "-f". All files matching this pattern will be compiled (no wildcards allowed):

To clean the project(s), just add "-c".
<pre id="rundrum"><code>bake Debug -p bspAbc -f main.cpp
bake Debug -f .asm</code></pre>

<h2>roots.bake</h2>

Workspace roots can be defined in a file called "roots.bake", which will be searched from main project directory to root folder. Example:

<pre id="rundrum"><code>../..
C:/another/root
C:/another/root # comments written like this
something/else</code></pre>

If -w and roots.bake are not specified, the default workspace root is the parent directory of the main project.
Expand Down
3 changes: 1 addition & 2 deletions doc/dyk/lint.html
Expand Up @@ -42,8 +42,7 @@ <h3>Notes</h3>
bake Debug -p MyLibraryProject --lint --lint_min 51 --lint_max 100 (lints the next 50 files)
bake Debug -p MyLibraryProject --lint --lint_min 101 (lints the rest of the files)</code></pre>
<p>
Lint in bake uses GCC includes to check system include stuff. Therefore it is required to have a working GCC installation.<br>
But you don't have to use a config with GCC toolchain. Every other toolchain is also valid.
Currently the lint output is buffered and not shown before lint has been finished. The reason is the implementation of the error parser. This will change in future.

</body>

Expand Down
6 changes: 0 additions & 6 deletions doc/dyk/tipps.html
Expand Up @@ -40,12 +40,6 @@ <h3>Symlinks and junctions</h3>
<li>To sync/commit from/to svn, use the original directories created by git.
</ul>

<h3>Single file</h3>
If you want to build a single file, you have to specify it like that:
<pre id="rundrum"><code>bake -b Debug -f src/abc/MyFile.cpp</pre></code>
No need to type so much! If it's not ambiguous, it's enough to specify parts of the filename like this:
<pre id="rundrum"><code>bake -b Debug -f abc/MyFile.cpp
bake -b Debug -f MyFile.cpp</code></pre>
</body>

</html>
4 changes: 3 additions & 1 deletion doc/eclipse/import.html
Expand Up @@ -11,7 +11,6 @@ <h2>General note</h2>
<p>
One major difference is, that .cproject and .project files are just wrappers. Do not use the standard property pages, they will be simply ignored! <b>Edit only the Project.meta files.</b><br>
<b>The .cproject and .project files shall not be committed to your source control.</b>
However, you may commit .cproject and .project files with an empty dummy configuration <b>once</b> to avoid the following importing step for future checkouts.

<h2>Import</h2>

Expand All @@ -23,6 +22,9 @@ <h2>Import</h2>
All (sub)directories with a Project.meta are listed here. Choose the projects to import and press Finish.<p>
<img src="import/Select.png"/>
<img src="import/Import.png"/><br>
<br>
Note, that .(c)project files will not be overwritten per default. If e.g. a project is not a c-project, some bake features will not available.
In this case, enable the recreate option. This is also a good idea, if you want to get rid of old configurations.

</body>

Expand Down
Binary file modified doc/eclipse/import/Import.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 8 additions & 5 deletions doc/eclipse/use.html
Expand Up @@ -19,12 +19,15 @@ <h2>Select a build configuration of the main project</h2>
<p>
This label decoration can be switched off and on via Window->Preferences->General->Appearance->Label Decorations.

<h2>Adjust includes for CDT</h2>
<h2>Adjust includes and defines for CDT</h2>

As you might have already seen, a new menu item for the main project is enabled now: Adjust includes for CDT.<br>
All CDT features work out-of-the-box except those about the #include statements e.g. auto-completion of includes. To import the "bake includes" into the CDT .cproject files, simply click on this menu item.<br>
<b>This is not a must, it's just convenience.</b><br>
Note: importing can take between a few seconds and a minute depending on the size of the workspace and the number of project settings which have to be written.<br>
As you might have already seen, a new menu item for the main project is enabled now: Adjust includes and defines for CDT.<br>
All CDT features work out-of-the-box except those about the #include and #define statements e.g. auto-completion of includes.
To import the includes and defines into the CDT .cproject files, simply click on this menu item.<p>
Compiler internal includes and defines must be specified in InternalInclude and InternalDefine files. See "Syntax" help page how to set the name of these files. Note, that the
variables CPPPath, CPath, ASMPath, ArchiverPath and LinkerPath can be used in these files.<br>
<p>
Adjusting can take between a few seconds and a minute depending on the size of the workspace and the number of project settings which have to be written.<br>

<h2>Build/Clean Projects/Files</h2>

Expand Down
127 changes: 126 additions & 1 deletion doc/further/change.html
Expand Up @@ -7,6 +7,131 @@
<body>
<h1>Changelog</h1>

January 7, 2015 - bake-toolkit 2.0.3<br>
<ul>


<li><b>Changed: default configuration is chosen if configuration name is omitted. This applies to command line as well as to <i>Dependency</i> definitions, e.g.:</b><br>
# Project.meta:<br>
Dependency canDriver # no <i>config</i> attribute<br>
# Command line:<br>
bake -m bla/myProj # no configuration name specified<br>
<b>To show the possible configs of a project, use the --show_configs command line option.</b>
<p>
<li><b>Added: More than one config of a project can be used in the workspace.</b><br>
Example:<br>
Dependency canDriver, config: C1<br>
Dependency canDriver, config: C2<br>
<b>To reference a config of the current project, omit the project name, e.g.:</b><br>
Dependency config: C3<br>
<b>To build a single project, you can still use -p command line argument:</b><br>
bake Debug -p canDriver<br>
<b>However, if canDriver has more than one config in the workspace, all configs will be built. To build only a single config, use a comma separator like this:</b><br>
bake Debug -p canDriver,C1<br>
<p>
<li><b>The default output folder has been changed due to the new feature of having several configs of a project in one workspace.</b><br>
<table border="1">
<tr>
<th></th>
<th>Old</th>
<th>New</th>
</tr>
<tr>
<td><b>Main project</b></td>
<td>$(MainConfigName)</td>
<td>$(MainConfigName)</td>
</tr>
<tr>
<td><b>Sub project</b></td>
<td>$(MainConfigName)_$(MainProjectName)</td>
<td>$(SubConfigName)_$(MainProjectName)_$(MainConfigName)</td>
</tr>
</table>
<b>Be careful if you have something like this in Project.meta:</b><br>
ExternalLibrary "bspCoreZ6/$(MainConfigName)_$(MainProjectName)/src/coreZ6/startup/startupCode.o", search:false<br>
<b>This refers to the old output directory. Change it or if you want to support old and new bake versions,
write a <i>PreStep</i> which copies the file from the new location to the old one.</b>

<p>
<li><b>Changed: with -f a pattern can be specified, not only a single file. All files matching this string will be compiled.</b>
<li><b>Changed: variables in Dependency definitions are not allowed anymore to avoid inconsistencies.</b>
<li><b>Changed: no error will be reported anymore if makefile has no clean target.</b>
<li><b>Changed: Source files will now be compiled and archived ordered by the <i>Files</i> definition in Project.meta, not by a Eclipse-backward-compatibility-ordering.</b>
<li><b>Changed: reworked some error messages, more error annotations are shown in IDEs</b>
<p>
<li><b>Added: "--include_filter" and "--exclude_filter" also work for main step of <i>CustomConfig</i></b>
<li><b>Added: possibility to add comments in roots.bake</b>
<li><b>Added: new variables CPPPath, CPath, ASMPath, ArchiverPath and LinkerPath. These variables can also be used in <i>InternalDefines</i> and <i>InternalInclude</i> files.</b>
<li><b>Added: lint is not restricted to GCC toolchain anymore.</b><br>
<li><b>Added: --docu option. Specify the docu command line in <i>Docu</i> tag of the <i>(Default)Toolchain</i>.</b><br>
<p>
<li><b>Removed: support for Ruby 1.8. Use Ruby 1.9 or higher.</b>
<li><b>Removed: dependencies to cxxproject and rake gems</b>
<li><b>Removed: "-j" as default flag when calling makefiles. This must be explicitly specified.</b>
<li><b>Removed: option to check for unnecessary includes</b>
<li><b>Removed: hardcoded TI compiler commands and flags</b>
<table border="1">
<tr>
<th></th>
<th>Old</th>
<th>New</th>
</tr>
<tr>
<td><b>Compiler command</b></td>
<td>$(ti_home)/ccsv5/tools/compiler/tms470/bin/cl470</td>
<td>ti_cl</td>
</tr>
<tr>
<td><b>Compiler flags</b></td>
<td>-mv7A8 -g --include_path="#{ti_home}/ccsv5/tools/compiler/tms470/include" --diag_warning=225 -me --abi=eabi --code_state=32 --preproc_with_compile</td>
<td></td>
</tr>
<tr>
<td><b>Archiver command</b></td>
<td>$(ti_home)/ccsv5/tools/compiler/tms470/bin/ar470</td>
<td>ti_ar</td>
</tr>
<tr>
<td><b>Linker command</b></td>
<td>$(ti_home)/ccsv5/tools/compiler/tms470/bin/cl470</td>
<td>ti_cl</td>
</tr>
<tr>
<td><b>Linker flags</b></td>
<td>-mv7A8 -g --diag_warning=225 -me --abi=eabi --code_state=32 -z --warn_sections -i"$(ti_home)/ccsv5/tools/compiler/tms470/lib" -i"$(ti_home)/ccsv5/tools/compiler/tms470/include"</td>
<td></td>
</tr>
<tr>
<td><b>Linker lib prefix flags</b></td>
<td>-lDebug/configPkg/linker.cmd</td>
<td></td>
</tr>
</table>
<p>
<li><b>Bugfix: variables in <i>add</i> and <i>remove</i> attributes of <i>Flags</i> now work as intended</b>
<li><b>Bugfix: output folder was not created if no sources are specified for <i>LibraryConfig</i> and <i>ExecutableConfig</i>.</b>
<li><b>Bugfix: "-p" was not forwarded in bakery.</b>
<p>
<li><b>Cosmetic: bakery now calls bake with relative pathnames, which results in nicer outputs.</b>



</ul>

December 19, 2014 - Eclipse plugin 1.2.0<br>
<ul>
<li><b>Bugifx: it is now ensured, that bake will be started from Eclipse working directory</b>
<li><b>Bugfix: projects created with the "new bake project wizard" are now placed in the correct folder.</b>
<li><b>Added: Eclipse working directory shown in bake preference dialog (important if -w option is used with relative paths)</b>
<li><b>Added: Options to recreate .(c)project files when importing bake projects</b>
<li><b>Changed: Eclipse configurations will be named "bake" and not "Do not use this config, use bake instead"</b>
</ul>

December 16, 2014 - Eclipse plugin 1.1.1<br>
<ul>
<li><b>Bugfix: Adjust include and defines broken feature used wrong command line option.</b>
</ul>

November 7, 2014 - bake-toolkit 1.8.0, Eclipse plugin 1.1.0<br>
<ul>
<li><b>Added: InternalIncludes and InternalDefines in DefaultToolchain, which are forwarded to the IDE.</b>
Expand Down Expand Up @@ -55,7 +180,7 @@ <h1>Changelog</h1>
June 6, 2014 - bake-toolkit 1.4.0<br>
<ul>
<li><b>Bugfix: variables can be used in "Set" now</b>
<li><b>Added: variable "MainProjectDir"
<li><b>Added: variable "MainProjectDir"</b>
</ul>

May 23, 2014 - bake-toolkit 1.3.0<br>
Expand Down
1 change: 1 addition & 0 deletions doc/further/wish.html
Expand Up @@ -28,6 +28,7 @@ <h1>Wishes and planned features</h1>
<li>Eclipse: newlines in problems view are shown as a square sign. These signs should be somehow removed without breaking the annotations in the source files
<li>Eclipse: Word wrap in colored console (seems to be a bit tricky)
<li>Eclipse: better error log if plugin does not work
<li>Common: Add docu how to debug in IDEs
</ul>

Internal:
Expand Down
2 changes: 1 addition & 1 deletion doc/index.html
Expand Up @@ -72,7 +72,7 @@ <h3>Further readings</h3>

<p>
<hr>
<table width="100%" border="0"><tr><td align="left">Described bake-toolkit version: 1.8.0</td><td align="right">November 7, 2014</td></tr></table>
<table width="100%" border="0"><tr><td align="left">Described bake-toolkit version: 2.0.3</td><td align="right">January 7, 2015</td></tr></table>

</body>

Expand Down
9 changes: 8 additions & 1 deletion doc/syntax/subst.html
Expand Up @@ -41,6 +41,11 @@ <h3>Substituted variables</h3>
<tr><td>$(ArtifactNameBase)</td> <td>bootloader_1.0</td></tr>
<tr><td>$(Time)</td> <td>2012-12-24 20:00:00 +0200</td></tr>
<tr><td>$(Hostname)</td> <td>MY_COMPUTER</td></tr>
<tr><td>$(CPPPath)</td> <td>/usr/bin</td></tr>
<tr><td>$(CPath)</td> <td>/usr/bin</td></tr>
<tr><td>$(ASMPath)</td> <td>/usr/bin</td></tr>
<tr><td>$(ArchiverPath)</td> <td>/usr/bin</td></tr>
<tr><td>$(LinkerPath)</td> <td>/usr/bin</td></tr>
</table>
<br>
<table border="1">
Expand All @@ -61,6 +66,8 @@ <h3>Substituted variables</h3>
</table>
<p>
If the environment variable does not exist, it will be substituted by an empty string.
<p>
Note, that variables in <b>Dependency</b> definitions are not allowed.

<h3>Equal variables</h3>

Expand All @@ -75,7 +82,7 @@ <h4>In main project</h4>
<h4>In subproject</h4>
<table border="1">
<tr><th bgcolor="#CCCCCC">Variable</th><th bgcolor="#CCCCCC">is equal to</th></tr>
<tr><td>$(OutputDir)</td> <td>$(MainConfigName)_$(MainProjectName)</td></tr>
<tr><td>$(OutputDir)</td> <td>$(ConfigName)_$(MainProjectName)_$(MainConfigName)</td></tr>
</table>

<h3>Auto-adjustment of paths to existing projects</h3>
Expand Down

0 comments on commit 1e02b1e

Please sign in to comment.