Boost logo

Boost-Build :

From: Reece Dunn (msclrhd_at_[hidden])
Date: 2005-10-18 15:17:21


David Abrahams wrote:
> Alo Sarv <alo.sarv_at_[hidden]> writes:
>
>>If errors happen, bjam automatically prints
>>the command-line, which IMHO is the best behaviour - keep output clean
>>when there's no errors, and when errors happen, print the offending
>>command-line as well.

I agree, but see below.

>>It says all that's needed - compiler, action, language, configuration,
>>object being compiled - perfect. I have no need to see the full ugly
>>command-line every time I compile. Furthermore, clean output also puts
>>higher priority to warnings, which otherwise simply get hidden between
>>the long command-lines.
>
> I always thought that was better too, but then we constantly hear from
> new users who can't tell what the build system is doing, and who find
> these "actions" messages cryptic.

I personally prefer the actions so that I can locate what action is
causing a specific error. Otherwise, it would become a jumbled mess. The
msvc compiler outputs the cpp file that it is building, but I personally
find that distracting, rather than the action line from the build system!

I also find the skipping target X and MkDir Y actions distracting.

> Well, this seems like sufficient resistance that I'm not going to act
> right away, but I'd like to hear more from those concerned about
> whether this is a problem.

On the subject of changing the bjam output, what are the plans for XML
output and what structure would this take?

I would ideally like to see something like:

<bjam>
<action name="gcc.compile.c++" target="main.o" source="main.c">
<line>error: &lt;...&gt;</line>
<line>error: ...</line>
<command>gcc main.c -o main.o</command>
<status>fail</status>
</action>
<action name="test.run" target="text.exe">
<line>***passed***</line>
<status>succeeded</status>
</action>
<action name="skipping">...</action>
<action name="MkDir">...</action>
</bjam>

The command line is separate from the tool output so you can easily
filter it out if you want to. Also, each line is in its own XML tag to
make it easier to do advanced post-processing from XSLT.

Status is in its own tag at the end of an action to make the writing of
the XML a linear process and to make it easy to query success/failure of
an action.

NOTE: you would only need <status>fail</status> and have it that the
absence of a <status> tag indicates successs.

This would make processing the output a lot easier with the regression
test tools and would allow other tools or XSLT to hook into this and
make post-processing and rendering easier.

- Reece

 


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk