[Qt-creator] Qt Creator Issues tab does not populate

Alfonso Chartier alfonso.chartier at gmail.com
Fri Mar 8 18:48:21 CET 2013


Hi Tobias,

Thank you very much for the detailed reply. I have asked my coworker for
additional information to see what route we may need to take to get this
resolved (whether configuration, coding or hacking). Here's what he told me:

The compiler is from Tasking for Freescale DSP563xx.

A small sample of the contents of the .err file is given below:

Compiling "C:\spa_z\spa_dsp\TgUmts\TgUmts_oneNand.c"
Assembling "TgUmts_oneNand.src"
Compiling "C:\spa_z\spa_dsp\TgUmts\TgUmts_channel.c"
c563 W135: C:\spa_z\spa_dsp\TgUmts\TgUmts_channel.c: line 2089: statement
not reached
c563 W135: C:\spa_z\spa_dsp\TgUmts\TgUmts_channel.c: line 2095: statement
not reached

Is this output formatted as other standard compilers? By the way, this
output in Qt Creator shows up all black (no red, so I assume it's all going
to stdout?).

For reference, this is the custom error parser regular expression string
configured in CodeWright:

^.*([^ \t]*): line ([0-9]+) *: (.*)$

I believe the wmk.exe program internally calls another tool called mk563,
which is a program we can call directly and seems generally similar to
regular make. Below are its available options (although I don't really see
an equivalent make -w option):
Usage:
        mk563 [option...] [target...] [mac=def ...]
        mk563 -V
        mk563 -?

Summary of options:
        -?      Show invocation syntax.
        -D      Print makefile lines while being read. -DD produces more
                details.
        -G dirname
                Change to specified directory before reading a makefile.
        -K      Don't remove temporary files.
        -S      Undo the effect of -k.
        -V      Display version header only.
        -W target
                Treat target as if it has just been reconstructed.
        -a      Always rebuild target without checking if it is out of date.
        -c      Run as child process.
        -d      Display all time comparisons which indicate a target is out
of
                date. -dd produces more details.
        -e      Environment variables override macro definitions.
        -err file
                Redirect all (error) output to specified file.
        -f file Use specified file instead of 'makefile'.
                '-' denotes standard input.
        -i      Ignore error codes returned by commands.
        -k      On error, abandon the work for the current target only.
        -m file Name of invocation file, '-' means stdin.
        -n      Perform a dry run.
        -p      Make all target files precious.
        -q      Question mode, don't build but set the exit status
indicating
                whether or not the target is up to date.
        -r      Do not read in the file 'mk563.mk'.
        -s      Silent mode. Do not print commands before execution.
        -t      Touch the target files instead of reconstructing them.
        -time   Display current date and time.
        -w      Redirect warnings and errors to standard output.
        -x      Show extended error message.

If configuring either wmk.exe or mk563 as a standard make-based compiler
isn't possible, would another option be to use wmk to send the compiler
output to a .err file and then have a script reformat the .err file after
it finishes it and send it to stdout (or would it be stderr, a mixture of
the two)?

Any additional help/direction you can provide would be greatly appreciated.

Thanks again,

Alfonso


On Fri, Mar 8, 2013 at 12:19 AM, Hunger Tobias <Tobias.Hunger at digia.com>wrote:

> Hello Alfonso!
>
> <snip>Description of problem with output parsing</snip>
>
> > How can I work around this problem?
>
> That depends a lot on what kind of output you get from your tools and
> whether you receive
> the output via stdout (black text in compile output) or stderr (red text).
>
> > How does Qt Creator populate the Issues tab?
>
> Each build step (make, qmake, custom build step, etc.) defines a list of
> output parsers that
> look at each line of output received and extracts Tasks from that which
> are then routed to the
> Issues pane.
>
> The list of parsers for make contains e.g. a gnumakeparser and parsers for
> the tool chain
> you have set up (MSVC, gcc, clang, whatever).
>
> > As a reference, in their existing CodeWright IDE, they manually
> configure a "Custom Error Parser".
>
> Creator does not have that yet, sorry.
>
> > They essentially point the IDE to a .err file generated by the compile
> step and give CodeWright a
> > complex regular expression to use to parse the .err file and populate
> the error list.
>
> Something similar would be necessary, but you will have to do this in code.
>
> > Perhaps this complex configuration doesn't need to be performed to get
> Qt Creator set up for
> > this, but I just have no idea how to get the Issues tab to populate or
> how to continue to troubleshoot this.
>
> How to proceed depends a lot on what the output looks like as well as how
> you get it.
>
> The simplest case would be if wmk is compatible with make (it is called a
> "make tool" on the
> site you pointed too). Compatible in this context means it accepts the
> command line arguments
> we need (-w to print working directories), it produces similar output and
> does not alter the
> compiler output in any way (by e.g. moving the compilers stdout to stderr
> or the other way
> around).
>
> If you are then using a compiler that produces output like GCC or any
> other supported compiler,
> then you only need to have a makestep and override the make command used.
>
> If the tool does something different, then you will need to do some coding.
>
> <hack>
>
> You mention a .err file... You might get away with having a script that
> turns this into a .tasks file.
> When loading a .tasks file into creator it will treat each line as one
> issue to put into the
> isssues pane. That is very convenient for things like static code analysis
> results, etc. but might
> be abused for your use case: You would need a script that turns the .err
> file into a .tasks file
> (e.g. by watching the filesystem or by way of it being a wrapper around
> wmk). Creator will
> watch .tasks files it opened and reload them whenever they change.
>
> </hack>
>
>
> Tobias Hunger
> Senior Software Engineer
> Digia, Qt
>
> Digia Germany GmbH
> Rudower Chaussee 13, 12489 D-Berlin
> Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht
> Charlottenburg, HRB 144331 B,
> Geschäftsführer: Mika Pälsi, Juha Varelius, Anja Wasenius
> Email: tobias.hunger at digia.com
> http://qt.digia.com
> Qt Blog: http://blog.qt.digia.com/
> Qt Facebook: www.facebook.com/qtcommercial
> Qt Twitter: www.twitter.com/qtcommercial
>
> Digia Germany is a group company of Digia Plc,
> Valimotie 21, FI-00380 Helsinki Finland
> Visit us at: www.digia.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20130308/dad05fa3/attachment.html>


More information about the Qt-creator mailing list