EmbeddedRelated.com
Forums
Memfault Beyond the Launch

IAR EW430 Build Actions

Started by Scott White July 9, 2009
Hi,

We are trying to make use of the IAR EW430 project Build Actions (Pre-
Build to be specific) to execute a command-line tool that generates a
custom version string (repository revision, buildcount, etc).

The command-line tool executes perfectly, the version string is
updated however it seems like the IAR EW430 is ignoring the return
value of the tool. As the compilation process always halts after
"Performing Pre-Build Action" with "Total number of errors: 1" and
never builds any of the source.

I've tried returns values of 0 (the normal convention for success),
positive, and negative values all with the same result.

Just wondering if any of you more experienced folk have made use of
this feature within IAR EW430 (latest version)?

Cheers,
Scott White

Beginning Microcontrollers with the MSP430

Problem solved, it ended up being a problem with the auto-versioning
tool, written in C++ but compiled under cygwin.
For some reason return values aren't be conveyed correctly when run
from the command prompt (with access to cygwin1.dll) however within
the cygwin bash shell the tool returns correct return values.

Writing a wrapper batch file to force the return value or recompiling
the tool outside of cygwin works fine.

Just thought I'd post a follow-up in case anyone else ever gets caught
out by a similar problem.
On 10/07/2009, at 6:59 AM, Scott White wrote:

>
> Hi,
>
> We are trying to make use of the IAR EW430 project Build Actions (Pre-
> Build to be specific) to execute a command-line tool that generates a
> custom version string (repository revision, buildcount, etc).
>
> The command-line tool executes perfectly, the version string is
> updated however it seems like the IAR EW430 is ignoring the return
> value of the tool. As the compilation process always halts after
> "Performing Pre-Build Action" with "Total number of errors: 1" and
> never builds any of the source.
>
> I've tried returns values of 0 (the normal convention for success),
> positive, and negative values all with the same result.
>
> Just wondering if any of you more experienced folk have made use of
> this feature within IAR EW430 (latest version)?
>
> Cheers,
> Scott White




Memfault Beyond the Launch