Atmel CAVR-4 Manuale Utente
CAVR-4
176
Descriptions of options
AVR® IAR C/C++ Compiler
Reference Guide
For example:
foo.r90: c:\iar\product\include\stdio.h
foo.r90: d:\myproject\include\foo.h
Example 1
To generate a listing of file dependencies to the file
listing.i
, use:
iccavr prog --dependencies=i listing
Example 2
To generate a listing of file dependencies to a file called
listing.i
in the
mypath
directory, you would use:
iccavr prog --dependencies mypath\listing
Note: Both
\
and
/
can be used as directory delimiters.
Example 3
An example of using
--dependencies
with a popular make utility, such as gmake
(GNU make):
1
Set up the rule for compiling files to be something like:
%.r90 : %.c
$(ICC) $(ICCFLAGS) $< --dependencies=m $*.d
That is, besides producing an object file, the command also produces a dependency file
in makefile style (in this example, using the extension
in makefile style (in this example, using the extension
.d
).
2
Include all the dependency files in the makefile using, for example:
-include $(sources:.c=.d)
Because of the dash (
-
) it works the first time, when the
.d
files do not yet exist.
--diag_error
--diag_error=tag,tag,...
Use this option to classify diagnostic messages as errors. An error indicates a violation
of the C or C++ language rules, of such severity that object code will not be generated,
and the exit code will be non-zero.
of the C or C++ language rules, of such severity that object code will not be generated,
and the exit code will be non-zero.
Example
The following example classifies warning
Pe117
as an error:
--diag_error=Pe117