Channels ▼


Extending the Eclipse CDT Managed Build System

At this point, if you add C and C++ source files to your project and build your project (CTRL + B), your files should be automatically be processed into a PDF file - assuming your system is set up with make, enscript, and ps2pdf in your path. By using the C/C++ Project view or the Eclipse Navigator view to browse the automatically generated "Default" folder (named after the "Default" configuration you created in your tool-chain), you should be able to see the resulting PDF file (see Figure 3).

[Click image to view at full size]
Figure 3: A Successful Build of A PDF File From C++ Sources

If you're using Windows as your OS, you should even be able to open the PDF file directly if you have a PDF viewer installed that is associated with the .pdf file extension (see Figure 4 for the resulting PDF file viewed in Adobe Acrobat Reader).

[Click image to view at full size]
Figure 4: Resulting PDF Viewed in Adobe Acrobat Reader

Now select your project and display its properties. If you select the C/C++ Build item in the left pane, you can set the options that you have defined for the PostScript PrettyPrinter tool. Select the General category and you will see two check boxes for the options that you defined (see Figure 5). Try unselecting one or both of the options and see how the enscript command line is affected by selecting the PostScript PrettyPrinter tool and examining the All options field.

[Click image to view at full size]
Figure 5: PostScript PrettyPrinter Tool Property Page

That completes our sample tool-chain definition. For more information on how to create extensions to the MBS, see the CDT Plug-in Developer Guide, Programmer's Guide, Managed Build System Extensibility Document, which is provided with the CDT SDK.

Chris was, at the time this article was written, a senior software designer with Texas Instruments Canada Limited and is a CDT Committer. He can be reached at [email protected] Leo is the IDE architect in the Intel Compiler Lab at Intel Corporation. He can be contacted at [email protected]

Related Reading

More Insights

Currently we allow the following HTML tags in comments:

Single tags

These tags can be used alone and don't need an ending tag.

<br> Defines a single line break

<hr> Defines a horizontal line

Matching tags

These require an ending tag - e.g. <i>italic text</i>

<a> Defines an anchor

<b> Defines bold text

<big> Defines big text

<blockquote> Defines a long quotation

<caption> Defines a table caption

<cite> Defines a citation

<code> Defines computer code text

<em> Defines emphasized text

<fieldset> Defines a border around elements in a form

<h1> This is heading 1

<h2> This is heading 2

<h3> This is heading 3

<h4> This is heading 4

<h5> This is heading 5

<h6> This is heading 6

<i> Defines italic text

<p> Defines a paragraph

<pre> Defines preformatted text

<q> Defines a short quotation

<samp> Defines sample computer code text

<small> Defines small text

<span> Defines a section in a document

<s> Defines strikethrough text

<strike> Defines strikethrough text

<strong> Defines strong text

<sub> Defines subscripted text

<sup> Defines superscripted text

<u> Defines underlined text

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task. However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

Disqus Tips To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.