⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dmake.man

📁 在ATmega16芯片上移植的ucosii系统
💻 MAN
📖 第 1 页 / 共 5 页
字号:

     Which will be parsed as expected.  Quoted target and prere-
     quisite specifications may also contain white space thereby
     allowing the use of complex function macro expressions..
     See the EXAMPLES section for how to apply "" quoting to a
     list of targets.

AATTTTRRIIBBUUTTEESS
     ddmmaakkee defines several target attributes.  Attributes may be
     assigned to a single target, a group of targets, or to all
     targets in the makefile.  Attributes are used to modify
     ddmmaakkee actions during target update.  The recognized attri-
     butes are:


     ..EEPPIILLOOGG     Insert shell epilog code when executing a group
                 recipe associated with any target having this
                 attribute set.

     ..FFIIRRSSTT      Used in conjunction with .INCLUDE.  Terminates
                 the inclusion with the first successfully
                 included prerequisite.

     ..GGRROOUUPP      Force execution of a target's recipe as a group
                 recipe.

     ..IIGGNNOORREE     Ignore an error when trying to make any target
                 with this attribute set.

     ..IIGGNNOORREEGGRROOUUPP
                 Disable the special meaning of '[' to initiate a
                 group recipe.

     ..LLIIBBRRAARRYY    Target is a library.

     ..MMKKSSAARRGGSS    If running in an MSDOS environment then use MKS
                 extended argument passing conventions to pass
                 arguments to commands.  Non-MSDOS environments
                 ignore this attribute.

     ..NNOOIINNFFEERR    Any target with this attribute set will not be
                 subjected to transitive closure if it is
                 inferred as a prerequisite of a target whose
                 recipe and prerequisites are being inferred.
                 (i.e. the inference algorithm will not use any
                 prerequisite with this attribute set, as a tar-
                 get) If specified as '.NOINFER:' (ie. with no
                 prerequisites or targets) then the effect is



Version 3.9 PL0                 UW                             11
DMAKE(p)             Unsupported Free Software            DMAKE(p)



                 equivalent to specifying --TT on the command line.

     ..NNOOSSTTAATTEE    Any target with this attribute set will not have
                 command line flag information stored in the
                 state file if .KEEP_STATE has been enabled.

     ..PPHHOONNYY      Any target with this attribute set will have its
                 recipe executed each time the target is made
                 even if a file matching the target name can be
                 located.  Any targets that have a .PHONY attri-
                 buted target as a prerequisite will be made each
                 time the .PHONY attributed prerequisite is made.

     ..PPRREECCIIOOUUSS   Do not remove associated target under any cir-
                 cumstances.  Set by default for any targets
                 whose corresponding files exist in the file sys-
                 tem prior to the execution of ddmmaakkee.

     ..PPRROOLLOOGG     Insert shell prolog code when executing a group
                 recipe associated with any target having this
                 attribute set.

     ..SSEEQQUUEENNTTIIAALL Force a sequential make of the associated
                 target's prerequisites.

     ..SSEETTDDIIRR     Change current working directory to specified
                 directory when making the associated target.
                 You must specify the directory at the time the
                 attribute is specified.  To do this simply give
                 _._S_E_T_D_I_R_=_p_a_t_h as the attribute.  _p_a_t_h is expanded
                 and the result is used as the value of the
                 directory to change to.  If _p_a_t_h contains $$$$@@
                 then the name of the target to be built is used
                 in computing the path to change directory to.
                 If path is surrounded by single quotes then path
                 is not expanded, and is used literally as the
                 directory name.  If the _p_a_t_h contains any `:'
                 characters then the entire attribute string must
                 be quoted using ".  If a target having this
                 attribute set also has the .IGNORE attribute set
                 then if the change to the specified directory
                 fails it will be ignored, and no error message
                 will be issued.

     ..SSIILLEENNTT     Do not echo the recipe lines when making any
                 target with this attribute set, and do not issue
                 any warnings.

     ..SSWWAAPP       Under MSDOS when making a target with this
                 attribute set swap the ddmmaakkee executable to disk
                 prior to executing the recipe line.  Also see
                 the '%' recipe line flag defined in the RECIPES



Version 3.9 PL0                 UW                             12
DMAKE(p)             Unsupported Free Software            DMAKE(p)



                 section.

     ..SSYYMMBBOOLL     Target is a library member and is an entry point
                 into a module in the library.  This attribute is
                 used only when searching a library for a target.
                 Targets of the form lib((entry)) have this
                 attribute set automatically.

     ..UUSSEESSHHEELLLL   Force each recipe line of a target to be exe-
                 cuted using a shell.  Specifying this attribute
                 is equivalent to specifying the '+' character at
                 the start of each line of a non-group recipe.

     ..UUPPDDAATTEEAALLLL  Indicates that all the targets listed in this
                 rule are updated by the execution of the accom-
                 panying recipe.  A common example is the produc-
                 tion of the _y_._t_a_b_._c and _y_._t_a_b_._h files by yyaacccc
                 when it is run on a grammar.  Specifying
                 .UPDATEALL in such a rule prevents the running
                 of yacc twice, once for the y.tab.c file and
                 once for the y.tab.h file.  .UPDATEALL targets
                 that are specified in a single rule are treated
                 as a single target and all timestamps are
                 updated whenever any target in the set is made.
                 As a side-effect, ddmmaakkee internally sorts such
                 targets in ascending alphabetical order and the
                 value of $@ is always the first target in the
                 sorted set.

     All attributes are user setable and except for .UPDATEALL,
     .SETDIR and .MKSARGS may be used in one of two forms.  The
     .MKSARGS attribute is restricted to use as a global attri-
     bute, and the use of the .UPDATEALL and .SETDIR attributes
     is restricted to rules of the second form only.

          ATTRIBUTE_LIST : _t_a_r_g_e_t_s

     assigns the attributes specified by ATTRIBUTE_LIST to each
     target in _t_a_r_g_e_t_s or

          _t_a_r_g_e_t_s ATTRIBUTE_LIST : ...

     assigns the attributes specified by ATTRIBUTE_LIST to each
     target in _t_a_r_g_e_t_s_. In the first form if _t_a_r_g_e_t_s is empty
     (ie. a NULL list), then the list of attributes will apply to
     all targets in the makefile (this is equivalent to the com-
     mon Make construct of _"_._I_G_N_O_R_E _:_" but has been modified to
     the notion of an attribute instead of a special target).
     Not all of the attributes have global meaning.  In particu-
     lar, .LIBRARY, .NOSTATE, .PHONY, .SETDIR, .SYMBOL and
     .UPDATEALL have no assigned global meaning.




Version 3.9 PL0                 UW                             13
DMAKE(p)             Unsupported Free Software            DMAKE(p)



     Any attribute may be used with any target, even with the
     special targets.  Some combinations are useless (e.g.
     .INCLUDE .PRECIOUS: ... ), while others are useful (e.g.
     .INCLUDE .IGNORE : "file.mk" will not complain if file.mk
     cannot be found using the include file search rules, see the
     section on SPECIAL TARGETS for a description of .INCLUDE).
     If a specified attribute will not be used with the special
     target a warning is issued and the attribute is ignored.

MMAACCRROOSS
     ddmmaakkee supports six forms of macro assignment.


     MMAACCRROO == LLIINNEE    This is the most common and familiar form of
                     macro assignment.  It assigns LINE literally
                     as the value of MACRO.  Future expansions of
                     MACRO recursively expand its value.

     MMAACCRROO **== LLIINNEE   This form behaves exactly as the simple '='
                     form with the exception that if MACRO
                     already has a value then the assignment is
                     not performed.

     MMAACCRROO ::== LLIINNEE   This form differs from the simple '=' form
                     in that it expands LINE prior to assigning
                     it as the value of MACRO.  Future expansions
                     of MACRO do not recursively expand its
                     value.

     MMAACCRROO **::== LLIINNEE  This form behaves exactly as the ':=' form
                     with the exception that if MACRO already has
                     a value then the assignment and expansion
                     are not performed.

     MMAACCRROO ++== LLIINNEE   This form of macro assignment allows macro
                     values to grow.  It takes the literal value
                     of LINE and appends it to the previous value
                     of MACRO separating the two by a single
                     space.  Future expansions of MACRO recur-
                     sively expand its value.

     MMAACCRROO ++::== LLIINNEE  This form is similar to the '+=' form except
                     that the value of LINE is expanded prior to
                     being added to the value of MACRO.

     Macro expressions specified on the command line allow the
     macro value to be redefined within the makefile only if the
     macro is defined using the '+=' and '+:=' operators.  Other
     operators will define a macro that cannot be further modi-
     fied.





Version 3.9 PL0                 UW                             14
DMAKE(p)             Unsupported Free Software            DMAKE(p)



     Each of the preceeding macro assignment operators may be
     prefixed by !!  to indicate that the assignment should be
     forced and that no warnings should be issued.  Thus, speci-
     fying !! has the effect of silently forcing the specified
     macro assignment.

     When ddmmaakkee defines a non-environment macro it strips leading
     and trailing white space from the macro value.  Macros
     imported from the environment via either the .IMPORT special
     target (see the SPECIAL TARGETS section), or the --ee, or --EE
     flags are an exception to this rule.  Their values are
     always taken literally and white space is never stripped.
     In addition, named macros defined using the .IMPORT special
     target do not have their values expanded when they are used
     within a makefile.  In contrast, environment macros that are
     imported due to the specification of the --ee or --EE flags are
     subject to expansion when used.

     To specify a macro expansion enclose the name in () or {}
     and precede it with a dollar sign $.  Thus $(TEST)
     represents an expansion of the macro variable named TEST.
     If TEST is defined then $(TEST) is replaced by its expanded
     value.  If TEST is not defined then $(TEST) expands to the
     NULL string (this is equivalent to defining a macro as
     'TEST=' ).  A short form may be used for single character
     named macros.  In this case the parentheses are optional,
     and $(I) is equivalent to $I.  Macro expansion is recursive,
     hence, if the value string contains an expression represent-
     ing a macro expansion, the expansion is performed.  Circular
     macro expansions are detected and cause an error to be
     issued.

     When defining a macro the given macro name is first expanded
     before being used to define the macro.  Thus it is possible
     to define macros whose names depend on values of other mac-
     ros.  For example, suppose CWD is defined as

          CWD = $(PWD:b)

     then the value of $(CWD) is the name of the current direc-
     tory.  This can be used to define macros specific to this
     directory, for example:

          _$(CWD).prt = list of files to print...

     The actual name of the defined macro is a function of the
     current directory.  A construct such as this is useful when
     processing a hierarchy of directories using .SETDIR attri-
     buted targets and a collection of small distributed makefile
     stubs.





Version 3.9 PL0                 UW                             15
DMAKE(p)             Unsupported Free Software            DMAKE(p)



     Macro variables may be defined within the makefile, on the
     command line, or imported from the environment.

     ddmmaakkee supports several non-standard macro expansions: The
     first is of the form:

          _$_(_m_a_c_r_o___n_a_m_e_:_m_o_d_i_f_i_e_r___l_i_s_t_:_m_o_d_i_f_i_e_r___l_i_s_t_:_._._._)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -