Renesas REJ10J1837-0100 Network Card User Manual


 
High-performance Embedded Workshop 13. HMAKE User Guide
REJ10J1837-0100 Rev.1.00 Nov. 16, 2008
420
There follows some examples of valid variable declarations:
EXECUTABLE = c:\dir\prog.exe
OUTPUT = c:\dir2\file1.out
INPUT = c:\dir2\file1.c
DEPEND = c:\dir2\file2.h \
c:\dir2\file3.h \
c:\dir2\file4.h
In order to use a variable later in the hmake file write the variable name with “$(” added to the front and “)” added to
the back. The variable name (along with the “$()” characters) will be substituted with the variables value. For examples
of this see later under description blocks. Only alphanumeric characters and underscore characters are allowed in
variable names. It is possible to use a variable inside the declaration of a different variable but all variables must be
declared before they are used.
13.3 Description blocks
Basic outline
A description block specifies one or more targets, zero or more dependants and a list of commands which should be
executed if the newest dependent is newer than the newest target. If none of the targets exist and/or none of the
dependants exist then the commands will always be executed. It is not necessary to specify any dependants if you wish
the commands to always be executed. A description block has the following syntax:
<target1> <target2> … : <dependant1> <dependant2> …
<command1>
<command2>
<commandn>
Any number of white space characters are allowed between the last target and the ‘:’ character and the first dependant
and the ‘:’ character. No white space is allowed before the first target. Each target and each dependant must be
separated by at least one white space character. A tab character must be present at the start of a line containing a
command. Variables may be used in a description block using the syntax specified above under variable declarations.
There follows some examples of valid description blocks (one of which uses the variable specified above under variable
declarations):
c:\dir1\file1.obj : c:\dir1\file1.c c:\dir1\file1.h
gcc c:\dir1\file1.c
$(OUTPUT) : $(INPUT) $(DEPEND)
$(EXECUTABLE) $(INPUT)