home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume20 / dmake / patch02f < prev    next >
Encoding:
Text File  |  1991-06-29  |  38.4 KB  |  1,078 lines

  1. Newsgroups: comp.sources.misc
  2. From: Dennis Vadura <dvadura@watdragon.waterloo.edu>
  3. Subject:  v20i081:  dmake - dmake version 3.7, Patch02f/12
  4. Message-ID: <1991Jun29.222628.4274@sparky.IMD.Sterling.COM>
  5. X-Md4-Signature: db0e18c554dfd62b6183ff141f56270e
  6. Date: Sat, 29 Jun 1991 22:26:28 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: Dennis Vadura <dvadura@watdragon.waterloo.edu>
  10. Posting-number: Volume 20, Issue 81
  11. Archive-name: dmake/patch02f
  12. Patch-To: dmake: Volume 19, Issue 22-58
  13.  
  14. #!/bin/sh
  15. # this is dp2.05 (part 5 of a multipart archive)
  16. # do not concatenate these parts, unpack them in order with /bin/sh
  17. # file dm37p2 continued
  18. #
  19. if test ! -r _shar_seq_.tmp; then
  20.     echo 'Please unpack part 1 first!'
  21.     exit 1
  22. fi
  23. (read Scheck
  24.  if test "$Scheck" != 5; then
  25.     echo Please unpack part "$Scheck" next!
  26.     exit 1
  27.  else
  28.     exit 0
  29.  fi
  30. ) < _shar_seq_.tmp || exit 1
  31. if test ! -f _shar_wnt_.tmp; then
  32.     echo 'x - still skipping dm37p2'
  33. else
  34. echo 'x - continuing file dm37p2'
  35. sed 's/^X//' << 'SHAR_EOF' >> 'dm37p2' &&
  36. XProcessing of prerequisites which contain macro expansions in their name.
  37. X.IP "\fBBINDING TARGETS\fP" 1.9i
  38. XThe rules that \fBdmake\fP uses to bind
  39. Xa target to an existing file in the file system.
  40. X.IP "\fBPERCENT(%) RULES\fP" 1.9i
  41. XSpecification of recipes to be used by the inference algorithm.
  42. X.IP "\fBMAKING INFERENCES\fP" 1.9i
  43. XThe rules that \fBdmake\fP uses when inferring how to make a target which
  44. Xhas no explicit recipe.  This and the previous section are really a single
  45. Xsection in the text.
  46. X.IP "\fBMAKING TARGETS\fP" 1.9i
  47. XHow \fBdmake\fP makes targets other than libraries.
  48. X.IP "\fBMAKING LIBRARIES\fP" 1.9i
  49. XHow \fBdmake\fP makes libraries.
  50. X.IP "\fBKEEP STATE\fP" 1.9i
  51. XA discussion of how .KEEP_STATE works.
  52. X.IP "\fBMULTI PROCESSING\fP" 1.9i
  53. XDiscussion of \fBdmake's\fP parallel make facilities for architectures that
  54. Xsupport them.
  55. X.IP "\fBCONDITIONALS\fP" 1.9i
  56. XConditional expressions which control the processing of the makefile.
  57. X.IP "\fBEXAMPLES\fP" 1.9i
  58. XSome hopefully useful examples.
  59. X.IP "\fBCOMPATIBILITY\fP" 1.9i
  60. XHow \fBdmake\fP compares with previous versions of make.
  61. X.IP "\fBLIMITS\fP" 1.9i
  62. XLimitations of \fBdmake\fP.
  63. X.IP \fBPORTABILITY\fP 1.9i
  64. XComments on writing portable makefiles.
  65. X.IP \fBFILES\fP 1.9i
  66. XFiles used by \fBdmake\fP.
  67. X.IP "\fBSEE ALSO\fP" 1.9i
  68. XOther related programs, and man pages.
  69. X.IP "\fBAUTHOR\fP" 1.9i
  70. XThe guy responsible for this thing.
  71. X.IP \fBBUGS\fP 1.9i
  72. XHope not.
  73. X.SH STARTUP
  74. XWhen
  75. X.B dmake
  76. Xbegins execution it first processes the command line and then processes
  77. Xan initial startup-makefile.
  78. XThis is followed by an attempt to locate and process a user supplied makefile.
  79. XThe startup file defines the default values of all required control macros
  80. Xand the set of default rules for making targets and inferences.
  81. XWhen searching for the startup makefile,
  82. X.B dmake
  83. Xsearches the following locations, in the order specified,
  84. Xuntil a startup file is located:
  85. X.LP
  86. X.RS
  87. X.IP 1.
  88. XThe location given as the value of the macro
  89. XMAKESTARTUP defined on the command line.
  90. X.IP 2.
  91. XThe location given as the value of the environment variable MAKESTARTUP
  92. Xdefined in the current environment.
  93. X.IP 3.
  94. XThe location given as the value of the macro
  95. XMAKESTARTUP defined internally within \fBdmake\fP.
  96. X.RE
  97. X.LP
  98. XThe above search is disabled by specifying the \-r option on the command line.
  99. XAn error is issued if a startup makefile cannot be found and the \-r
  100. Xoption was not specified.
  101. XA user may substitute a custom startup file by defining
  102. Xthe MAKESTARTUP environment variable or by redefining the
  103. XMAKESTARTUP macro on the command line.
  104. XTo determine where
  105. X.B dmake
  106. Xlooks for the default startup file, check your environment or issue the command
  107. X\fI"dmake \-V"\fP.
  108. X.PP
  109. XA similar search is performed to locate a default user makefile when no
  110. X\fB\-f\fP command line option is specified.
  111. XBy default, the prerequisite list of the special target .MAKEFILES
  112. Xspecifies the names of possible makefiles and the search order that
  113. X\fBdmake\fP should use to determine if one exists.
  114. XA typical definition for this target is:
  115. X.RS
  116. X.sp
  117. X\&.MAKEFILES : makefile.mk Makefile makefile
  118. X.sp
  119. X.RE
  120. X\fBdmake\fP will first look for makefile.mk and then the others.
  121. XIf a prerequisite
  122. Xcannot be found \fBdmake\fP will try to make it before going on to the next
  123. Xprerequisite.  For example, makefile.mk can be checked out of an RCS file
  124. Xif the proper rules for doing so are defined in the startup file.
  125. X.SH SYNTAX
  126. XThis section is a summary of the syntax of makefile statements.
  127. XThe description is given in a style similar to BNF, where { } enclose
  128. Xitems that may appear zero or more times, and [ ] enclose items that
  129. Xare optional.  Alternative productions for a left hand side are indicated
  130. Xby '\(->', and newlines are significant.  All symbols in \fBbold\fP type
  131. Xare text or names representing text supplied by the user.
  132. X.sp 2
  133. X.RS
  134. X.Ip "Makefile" "\(-> { Statement }"
  135. X.Ip "Statement" "\(-> Macro-Definition"
  136. X\(-> Conditional
  137. X\(-> Rule-Definition
  138. X\(-> Attribute-Definition
  139. X.Ip "Macro-Definition" "\(-> \fBMACRO = LINE\fP"
  140. X\(-> \fBMACRO *= LINE\fP
  141. X\(-> \fBMACRO := LINE\fP
  142. X\(-> \fBMACRO *:= LINE\fP
  143. X\(-> \fBMACRO += LINE\fP
  144. X\(-> \fBMACRO +:= LINE\fP
  145. X.Ip "Conditional \(-> " "\fB\&.IF\fR expression"
  146. XX   Makefile
  147. X[ \fB.ELIF\fR expression
  148. XX   Makefile ]
  149. X[ \fB.ELSE\fR
  150. XX   Makefile ]
  151. X\fB\&.END\fR
  152. X.Ip expression    "\(-> \fBLINE\fR"
  153. X\(-> \fBSTRING == LINE\fR
  154. X\(-> \fBSTRING != LINE\fR
  155. X.sp
  156. X.Ip "Rule-Definition \(-> " "target-definition"
  157. XX   [ recipe ]
  158. X.PP
  159. Xtarget-definition \(-> targets [attrs] op { \fBPREREQUISITE\fP } [\fB;\fR rcp-line]
  160. X.Ip "targets" "\(-> target { targets }"
  161. X\(-> \fB"\fRtarget\fB"\fR { targets }
  162. X.Ip "target" "\(-> special-target"
  163. X\(-> \fBTARGET\fR
  164. X.Ip "attrs" "\(-> attribute { attrs }"
  165. X\(-> \fB"\fRattribute\fB"\fR { attrs }
  166. X.Ip "op" "\(-> \fB:\fR { modifier }"
  167. X.Ip "modifier" "\(-> \fB:\fR"
  168. X\(-> \fB^\fR
  169. X\(-> \fB!\fR
  170. X\(-> \fB\-\fR
  171. X.Ip "recipe" "\(-> { \fBTAB\fR rcp-line }"
  172. X\(-> [\fB@\fR][\fB%\fR][\fB\-\fR] \fB[
  173. X.Is "recipe \(-> "
  174. X.Ii " "
  175. XX   \fR{ \fBLINE\fR }
  176. X.Ii " "
  177. X\fB]\fR
  178. X.Ip "rcp-line" "\(-> [\fB@\fR][\fB%\fR][\fB\-\fR][\fB+\fR] \fBLINE\fR"
  179. X.sp
  180. X.Ip Attribute-Definition "\(-> attrs \fB:\fR targets"
  181. X.sp
  182. X.Ip "attribute"     "\(-> \fB.EPILOG\fR"
  183. X\(-> \fB.IGNORE\fR
  184. X\(-> \fB.LIBRARY\fR
  185. X\(-> \fB.MKSARGS\fR
  186. X\(-> \fB.NOINFER\fR
  187. X\(-> \fB.NOSTATE\fR
  188. X\(-> \fB.PHONY\fR
  189. X\(-> \fB.PRECIOUS\fR
  190. X\(-> \fB.PROLOG\fR
  191. X\(-> \fB.SETDIR=\fIpath\fP\fR
  192. X\(-> \fB.SILENT\fR
  193. X\(-> \fB.SEQUENTIAL\fR
  194. X\(-> \fB.SWAP\fR
  195. X\(-> \fB.USESHELL\fR
  196. X\(-> \fB.SYMBOL\fR
  197. X\(-> \fB.UPDATEALL\fR
  198. X.Ip "special-target" "\(-> \fB.ERROR\fR"
  199. X\(-> \fB.EXPORT\fR
  200. X\(-> \fB.GROUPEPILOG\fR
  201. X\(-> \fB.GROUPPROLOG\fR
  202. X\(-> \fB.IMPORT\fR
  203. X\(-> \fB.INCLUDE\fR
  204. X\(-> \fB.INCLUDEDIRS\fR
  205. X\(-> \fB.MAKEFILES\fR
  206. X\(-> \fB.REMOVE\fR
  207. X\(-> \fB.SOURCE\fR
  208. X\(-> \fB.SOURCE.\fIsuffix\fR
  209. X\(-> .\fIsuffix1\fR.\fIsuffix2\fR
  210. X.fi
  211. X.RE
  212. X.sp 1
  213. X.PP
  214. XWhere, \fBTAB\fP represents a <tab> character, \fBSTRING\fP represents an
  215. Xarbitrary sequence of characters, and
  216. X\fBLINE\fP represents a
  217. Xpossibly empty sequence of characters terminated by a non-escaped 
  218. X(not immediately preceded by a backslash '\e') new-line character.
  219. X\fBMACRO\fP, \fBPREREQUISITE\fP,
  220. Xand \fBTARGET\fP each represent a string of characters not
  221. Xincluding space or tab which respectively form the name of a macro,
  222. Xprerequisite or target.
  223. XThe name may itself be a macro expansion expression.
  224. XA \fBLINE\fP can be continued over several physical lines by terminating it with
  225. Xa single backslash character.  Comments are initiated by the
  226. Xpound \fB#\fR character and extend to the end of line.
  227. XAll comment text is discarded, a '#' may be placed into the makefile text
  228. Xby escaping it with '\e' (ie. \e# translates to # when it is parsed).
  229. XAn exception to this occurs when a # is seen inside
  230. Xa recipe line that begins with a <tab> or is inside a group recipe.
  231. XIf you specify the \fB\-c\fP command line switch then this behavior is
  232. Xdisabled and
  233. X.B dmake
  234. Xwill treat all # characters as start of comment indicators unless they
  235. Xare escaped by \e.
  236. XA set of continued lines may be commented out by placing a single # at the
  237. Xstart of the first line.
  238. XA continued line cannot span more than one makefile.
  239. X.PP
  240. X\fBwhite space\fP is defined to be any combination of
  241. X<space>, <tab>, and the sequence \e<nl>
  242. Xwhen \e<nl> is used to terminate a LINE.
  243. XWhen processing \fBmacro\fP definition lines,
  244. Xany amount of white space is allowed on either side of the macro operator
  245. X(=, *=, :=, *:=, += or +:=), and
  246. Xwhite space is stripped from both before and after the macro
  247. Xvalue string.
  248. XThe sequence \e<nl> is treated as
  249. Xwhite space during recipe expansion
  250. Xand is deleted from the final recipe string.
  251. XYou must escape the \e<nl> with another \e in order to get a \e at the end
  252. Xof a recipe line.
  253. XThe \e<nl> sequence is deleted from macro values when they are expanded.
  254. X.PP
  255. XWhen processing \fBtarget\fP definition lines,
  256. Xthe recipe for a target must, in general, follow the first definition
  257. Xof the target (See the RULES AND TARGETS section for an exception), and
  258. Xthe recipe may not span across multiple makefiles.
  259. XAny targets and prerequisites found on a target definition line are taken
  260. Xto be white space separated tokens.
  261. XThe rule operator (\fIop\fP in SYNTAX section) is also considered
  262. Xto be a token but does not require
  263. Xwhite space to precede or follow it.  Since the rule operator begins with a `:',
  264. Xtraditional versions of make do not allow the `:' character to
  265. Xform a valid target name.  \fBdmake\fP allows `:' to be present in
  266. Xtarget/prerequisite names as long as the entire target/prerequisite name is
  267. Xquoted.  For example:
  268. X.sp
  269. X\ta:fred : test
  270. X.sp
  271. Xwould be parsed as TARGET = a, PREREQUISITES={fred, :, test}, which
  272. Xis not what was intended.  To fix this you must write:
  273. X.sp
  274. X\t"a:fred" : test
  275. X.sp
  276. XWhich will be parsed as expected.
  277. XSee the EXAMPLES section for how to apply \fB"\fP quoting
  278. Xto a list of targets.
  279. X.SH ATTRIBUTES
  280. X.B dmake
  281. Xdefines several target attributes.  Attributes may be
  282. Xassigned to a single target, a group of targets, or to all targets in the
  283. Xmakefile.  Attributes are used to modify
  284. X\fBdmake\fP actions during target update.
  285. XThe recognized attributes are:
  286. X.sp
  287. X.IP \fB.EPILOG\fP 1.2i
  288. XInsert shell epilog code when executing a group recipe associated with
  289. Xany target having this attribute set.
  290. X.IP \fB.IGNORE\fP 1.2i
  291. XIgnore an error when trying to make any target with this attribute set.
  292. X.IP \fB.LIBRARY\fP 1.2i
  293. XTarget is a library.
  294. X.IP \fB.MKSARGS\fP 1.2i
  295. XIf running in an MSDOS environment then use MKS extended argument passing
  296. Xconventions to pass arguments to commands.  Non-MSDOS
  297. Xenvironments ignore this attribute.
  298. X.IP \fB.NOINFER\fP 1.2i
  299. XAny target with this attribute set will not be subjected
  300. Xto transitive closure if it is inferred as a prerequisite 
  301. Xof a target whose recipe and prerequisites are being inferred.
  302. X(i.e. the inference algorithm will not use any prerequisite with this attribute 
  303. Xset, as a target)
  304. XIf specified as '.NOINFER:' (ie. with no prerequisites or targets) then the
  305. Xeffect is equivalent to specifying \fB\-T\fP on the command line.
  306. X.IP \fB.NOSTATE\fP 1.2i
  307. XAny target with this attribute set will not have command line flag
  308. Xinformation stored in the state file if .KEEP_STATE has been enabled.
  309. X.IP \fB.PHONY\fP 1.2i
  310. XAny target with this attribute set will have its recipe executed
  311. Xeach time the target is made even if a file matching the target name can
  312. Xbe located.  Any targets that have a .PHONY attributed target as a
  313. Xprerequisite will be made each time the .PHONY attributed prerequisite is
  314. Xmade.
  315. X.IP \fB.PRECIOUS\fP 1.2i
  316. XDo not remove associated target under any circumstances.
  317. XSet by default for any targets whose corresponding files exist in the file
  318. Xsystem prior to the execution of \fBdmake\fP.
  319. X.IP \fB.PROLOG\fP 1.2i
  320. XInsert shell prolog code when executing a group recipe associated with
  321. Xany target having this attribute set.
  322. X.IP \fB.SEQUENTIAL\fP 1.2i
  323. XForce a sequential make of the associated target's prerequisites.
  324. X.IP \fB.SETDIR\fP 1.2i
  325. XChange current working directory to specified directory when making the
  326. Xassociated target.  You must
  327. Xspecify the directory at the time the attribute is specified.  To do this
  328. Xsimply give \fI.SETDIR=path\fP as the attribute.  \fIpath\fP is expanded and
  329. Xthe result is used as the value of the directory to change to.
  330. XIf path is surrounded by single quotes then path is not expanded, and is used
  331. Xliterally as the directory name.
  332. XIf the \fIpath\fP contains any `:' characters then the entire attribute string
  333. Xmust be quoted using ".
  334. XIf a target having this attribute set also has the .IGNORE
  335. Xattribute set then if the change to the specified directory fails it will be
  336. Xignored, and no error message will be issued.
  337. X.IP \fB.SILENT\fP 1.2i
  338. XDo not echo the recipe lines when making any target with this attribute set,
  339. Xand do not issue any warnings.
  340. X.IP \fB.SWAP\fP 1.2i
  341. XUnder MSDOS
  342. Xwhen making a target with this attribute set swap the \fBdmake\fP executable
  343. Xto disk prior to executing the recipe line.  Also see the '%' recipe line
  344. Xflag defined in the RECIPES section.
  345. X.IP \fB.SYMBOL\fP 1.2i
  346. XTarget is a library member and is an entry point into a module in the
  347. Xlibrary.  This attribute is used only when searching a library for a target.
  348. XTargets of the form lib((entry)) have this attribute set automatically.
  349. X.IP \fB.USESHELL\fP 1.2i
  350. XForce each recipe line of a target to be executed using a shell.
  351. XSpecifying this attribute is equivalent to specifying the '+' character at the
  352. Xstart of each line of a non-group recipe.
  353. X.IP \fB.UPDATEALL\fP 1.2i
  354. XIndicates that all the targets listed in this rule are updated by the
  355. Xexecution of the accompanying recipe.
  356. XA common example is the production of the
  357. X.I y.tab.c
  358. Xand
  359. X.I y.tab.h
  360. Xfiles by
  361. X.B yacc
  362. Xwhen it is run on a grammar.  Specifying .UPDATEALL in such a rule
  363. Xprevents the running of yacc twice, once for the y.tab.c file and once
  364. Xfor the y.tab.h file.
  365. X.sp
  366. X.PP
  367. XAll attributes are user setable and except for .UPDATEALL, .SETDIR and .MKSARGS
  368. Xmay be used in one of two forms.
  369. XThe .MKSARGS attribute is restricted to use as a global attribute, and
  370. Xthe use of the .UPDATEALL and .SETDIR attributes is restricted to rules
  371. Xof the second form only.
  372. X.sp
  373. X\tATTRIBUTE_LIST : \fItargets\fP
  374. X.sp
  375. Xassigns the attributes specified by ATTRIBUTE_LIST to each target in
  376. X.I targets
  377. Xor
  378. X.sp
  379. X\t\fItargets\fP ATTRIBUTE_LIST : ...
  380. X.sp
  381. Xassigns the attributes specified by ATTRIBUTE_LIST to each target in
  382. X.I targets.
  383. XIn the first form if
  384. X.I targets
  385. Xis empty (ie. a NULL list), then the
  386. Xlist of attributes will apply to all targets in the makefile
  387. X(this is equivalent to the common Make construct of \fI".IGNORE :"\fP
  388. Xbut has been modified to the notion of an attribute instead of
  389. Xa special target).
  390. XNot all of the attributes have global meaning.
  391. XIn particular, .LIBRARY, .SYMBOL, and .UPDATEALL
  392. Xhave no assigned global meaning.
  393. X.PP
  394. XAny attribute may be used with any target, even with the special targets.
  395. XSome combinations are useless (e.g. .INCLUDE .PRECIOUS: ... ),
  396. Xwhile others are useful (e.g. .INCLUDE .IGNORE : "file.mk" will not complain
  397. Xif file.mk cannot be found using the include file search rules,
  398. Xsee the section on SPECIAL TARGETS for a description of .INCLUDE).
  399. XIf a specified attribute will not be used with the special target a warning
  400. Xis issued and the attribute is ignored.
  401. X.SH MACROS
  402. X.B dmake
  403. Xsupports six types of macro assignment.
  404. X.sp
  405. X.IP "\fBMACRO = LINE\fP" 1.55i
  406. XThis is the most common and familiar form of macro assignment.  It assigns
  407. XLINE literally as the value of MACRO.
  408. XFuture expansions of MACRO recursively expand its value.
  409. X.IP "\fBMACRO *= LINE\fP" 1.55i
  410. XThis form behaves exactly as the simple '=' form with the exception that if
  411. XMACRO already has a value then the assignment is not performed.
  412. X.IP "\fBMACRO := LINE\fP" 1.55i
  413. XThis form differs from the simple '=' form in that it expands LINE
  414. Xprior to assigning it as the value of MACRO.
  415. XFuture expansions of MACRO do not recursively expand its value.
  416. X.IP "\fBMACRO *:= LINE\fP" 1.55i
  417. XThis form behaves exactly as the ':=' form with the exception that if
  418. XMACRO already has a value then the assignment and expansion are not performed.
  419. X.IP "\fBMACRO += LINE\fP" 1.55i
  420. XThis form of macro assignment allows macro values to grow.  It takes the
  421. Xliteral value of LINE and appends it to the previous value of MACRO separating
  422. Xthe two by a single space.
  423. XFuture expansions of MACRO recursively expand its value.
  424. X.IP "\fBMACRO +:= LINE\fP" 1.55i
  425. XThis form is similar to the '+=' form except that the value of LINE is expanded
  426. Xprior to being added to the value of MACRO.
  427. X.PP
  428. XMacro expressions specified on the command line allow the macro value
  429. Xto be redefined within the makefile only if the macro is defined using
  430. Xthe '+=' and '+:=' operators.  Other operators will define a macro that cannot
  431. Xbe further modified.
  432. X.PP
  433. XWhen \fBdmake\fP defines a non-environment macro it strips leading and
  434. Xtrailing white space from the macro value.
  435. XMacros imported from the environment via either the .IMPORT special
  436. Xtarget (see the SPECIAL TARGETS section), or the \fB\-e\fP, or \fB\-E\fP flags
  437. Xare an exception to this rule.  Their values are
  438. Xalways taken literally and white space is never stripped.
  439. XIn addition, named macros defined using the .IMPORT special target do
  440. Xnot have their values expanded when they are used within a makefile.
  441. XIn contrast, environment macros that are imported
  442. Xdue to the specification of the \fB\-e\fP or \fB\-E\fP flags
  443. Xare subject to expansion when used.
  444. X.PP
  445. XTo specify a macro expansion
  446. Xenclose the name in () or {} and precede it with a dollar sign $.
  447. XThus $(TEST) represents an expansion of the macro variable named TEST.
  448. XIf TEST is
  449. Xdefined then $(TEST) is replaced by its expanded value.  If TEST is not
  450. Xdefined then $(TEST) expands to the NULL string (this is equivalent to
  451. Xdefining a macro as 'TEST=' ).  A short form may be used for single character
  452. Xnamed macros.  In this case the parentheses are optional, and $(I) is
  453. Xequivalent to $I.
  454. XMacro expansion is recursive, hence, if the value string contains an expression
  455. Xrepresenting a macro expansion, the expansion is performed.  Circular macro
  456. Xexpansions are detected and cause an error to be issued.
  457. X.PP
  458. XWhen defining a macro the given macro name is first expanded before being used
  459. Xto define the macro.  Thus it is possible to define macros whose names
  460. Xdepend on values of other macros.  For example, suppose CWD is defined as
  461. X.sp
  462. X\tCWD = $(PWD:b)
  463. X.sp
  464. Xthen the value of $(CWD) is the name of the current directory.
  465. XThis can be used to define macros specific to this directory, for
  466. Xexample:
  467. X.sp
  468. X\t_$(CWD).prt = list of files to print...
  469. X.sp
  470. XThe actual name of the defined macro is a function of the current directory.
  471. XA construct such as this is useful when processing a hierarchy of directories
  472. Xusing .SETDIR attributed targets and a collection of small distributed
  473. Xmakefile stubs.
  474. X.PP
  475. XMacro variables may be defined within the makefile, on the command
  476. Xline, or imported from the environment.
  477. X.PP
  478. X.B \fBdmake\fR
  479. Xsupports several non-standard macro expansions:
  480. XThe first is of the form:
  481. X.RS
  482. X.IP \fI$(macro_name:modifier_list:modifier_list:...)\fR
  483. X.RE
  484. X.LP
  485. Xwhere
  486. X.I modifier_list
  487. Xis chosen from the set { D or d, F or f, B or b, S or s, T or t } and
  488. X.RS
  489. X.sp
  490. X.Is "d "
  491. X.Ii "d "
  492. X\- directory portion of all path names
  493. X.Ii "f"
  494. X\- file (including suffix) portion of path names
  495. X.Ii "b"
  496. X\- file (not including suffix) portion of path names
  497. X.Ii "s"
  498. X\- simple pattern substitution
  499. X.Ii "t"
  500. X\- tokenization.
  501. X.sp
  502. X.RE
  503. XThus if we have the example:
  504. X.LP
  505. X\ttest = d1/d2/d3/a.out f.out d1/k.out
  506. X.LP
  507. XThe following macro expansions produce the values on the right of '\(->' after
  508. Xexpansion.
  509. X.RS
  510. X.sp
  511. X.Is "$(test:s/out/in/:f)  "
  512. X.Ii "$(test:d)"
  513. X\(-> d1/d2/d3/ d1/
  514. X.Ii "$(test:b)"
  515. X\(-> a f k
  516. X.Ii "$(test:f)"
  517. X\(-> a.out f.out k.out
  518. X.Ii "${test:db}"
  519. X\(-> d1/d2/d3/a f d1/k
  520. X.Ii "${test:s/out/in/:f}"
  521. X\(-> a.in f.in k.in
  522. X.Ii $(test:f:t"+")
  523. X\(-> a.out+f.out+k.out
  524. X.RE
  525. X.PP
  526. XIf a token ends in a string composed from the value of the macro DIRBRKSTR
  527. X(ie. ends in a directory separator string, e.g. '/' in UNIX) and you use the
  528. X\fB:d\fP modifier then the expansion returns the directory name less the
  529. Xfinal directory separator string.  Thus successive pairs of :d modifiers
  530. Xeach remove a level of directory in the token string.
  531. X.PP
  532. XThe tokenization modifier takes all white space separated tokens from the
  533. Xmacro value and separates them by the quoted separator string.  The separator
  534. Xstring may contain the following escape codes \ea => <bel>,
  535. X\&\eb => <backspace>, \ef => <formfeed>, \en => <nl>, \er => <cr>,
  536. X\&\et => <tab>, \ev => <vertical tab>, \e" => ", and \exxx => <xxx> where
  537. Xxxx is the octal representation of a character.  Thus the
  538. Xexpansion:
  539. X.LP
  540. X.RS
  541. X.nf
  542. X$(test:f:t"+\en")
  543. X.RE
  544. Xproduces:
  545. X.RS
  546. Xa.out+
  547. Xf.out+
  548. Xk.out
  549. X.fi
  550. X.RE
  551. X.PP
  552. XThe second non-standard form of macro expansion allows for recursive macros.
  553. XIt is possible to specify a $(\fImacro_name\fR) or ${\fImacro_name\fR} expansion
  554. Xwhere \fImacro_name\fR contains more $( ... ) or ${ ... } macro expansions
  555. Xitself.
  556. X.PP
  557. XFor example $(CC$(_HOST)$(_COMPILER)) will first expand CC$(_HOST)$(_COMPILER)
  558. Xto get a result and use that result as the name of the macro to expand.
  559. XThis is useful for writing a makefile for more than one target
  560. Xenvironment.  As an example consider the following hypothetical case. 
  561. XSuppose that _HOST and _COMPILER are imported from the environment
  562. Xand are set to represent the host machine type and the host compiler
  563. Xrespectively.
  564. X.RS
  565. X.sp
  566. X.nf
  567. XCFLAGS_VAX_CC = \-c \-O     # _HOST == "_VAX", _COMPILER == "_CC"
  568. XCFLAGS_PC_MSC = \-c \-ML # _HOST == "_PC",  _COMPILER == "_MSC"
  569. X.sp
  570. X# redefine CFLAGS macro as:
  571. X.sp
  572. XCFLAGS := $(CFLAGS$(_HOST)$(_COMPILER))
  573. X.fi
  574. X.sp
  575. X.RE
  576. XThis causes CFLAGS to take on a value that corresponds to the
  577. Xenvironment in which the make is being invoked.
  578. X.PP
  579. XThe final non-standard macro expansion is of the form:
  580. X.RS
  581. X.sp
  582. Xstring1{token_list}string2
  583. X.RE
  584. X.LP
  585. Xwhere string1, string2 and token_list are expanded.  After expansion,
  586. Xstring1 is prepended to each token found in token_list and
  587. Xstring2 is appended to each resulting token from the previous prepend.
  588. Xstring1 and string2 are not delimited by white space
  589. Xwhereas the tokens in token_list are.
  590. XA null token in the token list 
  591. Xis specified using "".
  592. XThus using another example we have:
  593. X.RS
  594. X.sp
  595. X.Is "test/{f1  f2}.o    "
  596. X.Ii "test/{f1 f2}.o"
  597. X--> test/f1.o test/f2.o
  598. X.Ii "test/ {f1 f2}.o"
  599. X--> test/ f1.o f2.o
  600. X.Ii "test/{f1 f2} .o"
  601. X--> test/f1 test/f2 .o
  602. X.Ii "test/{""f1""  """"}.o"
  603. X--> test/f1.o test/.o
  604. X.sp
  605. X.Ii and
  606. X.sp
  607. X.Is "test/{d1 d2}/{f1 f2}.o --> "
  608. X.Ii "test/{d1 d2}/{f1 f2}.o --> "
  609. Xtest/d1/f1.o test/d1/f2.o
  610. Xtest/d2/f1.o test/d2/f2.o
  611. X.sp
  612. X.RE
  613. XThis last expansion is activated only when the first characters of
  614. X.I token_list
  615. Xappear immediately after the opening '{' with no intervening white space.
  616. XThe reason for this restriction is the following incompatibility with
  617. XBourne Shell recipes.  The line
  618. X.RS
  619. X.sp
  620. X{ echo hello;}
  621. X.sp
  622. X.RE
  623. Xis valid /bin/sh syntax; while
  624. X.RS
  625. X.sp
  626. X{echo hello;}
  627. X.sp
  628. X.RE
  629. Xis not.
  630. XHence the latter triggers the enhanced macro expansion while the former
  631. Xcauses it to be suppressed.
  632. XSee the SPECIAL MACROS section for a description of the special macros that
  633. X\fBdmake\fP defines and understands.
  634. X.SH "RULES AND TARGETS"
  635. XA makefile contains a series of entries that specify dependencies.
  636. XSuch entries are called \fItarget/prerequisite\fP or \fIrule\fP definitions.
  637. XEach rule definition
  638. Xis optionally followed by a set of lines that provide a recipe for updating
  639. Xany targets defined by the rule.
  640. XWhenever
  641. X.B dmake
  642. Xattempts to bring a target up to date and an explicit recipe is provided with
  643. Xa rule defining the target, that recipe is used to update the
  644. Xtarget.  A rule definition begins with a line having the following syntax:
  645. X.sp
  646. X.RS
  647. X.nf
  648. X\fI<targets>\fP [\fI<attributes>\fP] \fI<ruleop>\fP [\fI<prerequisites>\fP] [;\fI<recipe>\fP]
  649. X.fi
  650. X.RE
  651. X.sp
  652. X.I targets
  653. Xis a non-empty list of targets.  If the target is a
  654. Xspecial target (see SPECIAL TARGETS section below) then it must appear alone
  655. Xon the rule line.  For example:
  656. X.sp
  657. X.RS
  658. X\&.IMPORT .ERROR : ...
  659. X.RE
  660. X.sp
  661. Xis not allowed since both .IMPORT and .ERROR are special targets.
  662. XSpecial targets are not used in the construction of the dependency graph and
  663. Xwill not be made.
  664. X.PP
  665. X.I attributes
  666. Xis a possibly empty list of attributes.  Any attribute defined in the
  667. XATTRIBUTES section above may be specified.  All attributes will be applied to
  668. Xthe list of named targets in the rule definition.  No other targets will
  669. Xbe affected.
  670. X.sp
  671. X.IP NOTE: 0.75i
  672. XAs stated earlier,
  673. Xif both the target list and prerequisite list are empty but the attributes
  674. Xlist is not, then the specified attributes affect all targets in the makefile.
  675. X.sp
  676. X.PP
  677. X.I ruleop
  678. Xis a separator which is used to identify the targets from the prerequisites.
  679. XOptionally it also provides a facility for modifying the way in which
  680. X.B dmake
  681. Xhandles the making of the associated targets.
  682. XIn its simplest form the operator is a single ':', and need not be separated
  683. Xby white space from its neighboring tokens.  It may additionally be followed
  684. Xby any of the modifiers { !, ^, \-, : }, where:
  685. X.sp
  686. X.IP \fB!\fP
  687. Xsays execute the recipe for the associated targets once for each out of date
  688. Xprerequisite.  Ordinarily the recipe is executed
  689. Xonce for all out of date prerequisites at the same time.
  690. X.IP \fB^\fP
  691. Xsays to insert the specified prerequisites, if any, before any
  692. Xother prerequisites already associated with the specified targets.
  693. XIn general, it is not useful to specify ^ with an empty
  694. Xlist of prerequisites.
  695. X.IP \fB\-\fP
  696. Xsays to clear the previous list of prerequisites before adding
  697. Xthe new prerequisites.  Thus,
  698. X.sp
  699. X\t.SUFFIXES :
  700. X.br
  701. X\t.SUFFIXES : .a .b
  702. X.sp
  703. Xcan be replaced by
  704. X.sp
  705. X\t.SUFFIXES :\- .a .b
  706. X.sp
  707. Xhowever the old form still works as expected.  NOTE:  .SUFFIXES is ignored by
  708. X.B dmake
  709. Xit is used here simply as an example.
  710. X.IP \fB:\fP
  711. XWhen the rule operator is not modified by a second ':'
  712. Xonly one set of rules may be specified for making a target.
  713. XMultiple definitions may be used to add to the
  714. Xlist of prerequisites that a target depends on.
  715. XHowever, if a target is multiply defined
  716. Xonly one definition may specify a recipe
  717. Xfor making the target.
  718. X.sp
  719. XWhen a target's rule operator is modified by a second ':'
  720. X(:: for example) then this definition may not be the only
  721. Xdefinition with a recipe for the target.  There may be other :: target
  722. Xdefinition lines that specify a different set of prerequisites with a
  723. Xdifferent recipe for updating the target.  
  724. XAny such target is made if any of the definitions
  725. Xfind it to be out of date
  726. Xwith respect to the related prerequisites
  727. Xand the corresponding recipe is used to update the
  728. Xtarget.
  729. X.sp 
  730. XIn the following simple example, each rule has a `::' \fIruleop\fP.  In such an
  731. Xoperator we call the first `:' the operator, and the second `:' the modifier.
  732. X.sp
  733. X.nf
  734. Xa.o :: a.c b.h
  735. XX   first recipe for making a.o
  736. XX
  737. Xa.o :: a.y b.h
  738. XX   second recipe for making a.o
  739. X.fi
  740. X.sp
  741. XIf a.o is found to be out of date with respect to a.c then the first recipe
  742. Xis used to make a.o.  If it is found out of date with respect to a.y then
  743. Xthe second recipe is used.  If a.o is out of date with respect to
  744. Xb.h then both recipes are invoked to make a.o.
  745. XIn the last case the order of invocation corresponds to the order in which the
  746. Xrule definitions appear in the makefile.
  747. X.PP
  748. XTargets defined using a single `:' operator
  749. Xwith a recipe may be redefined again with a new recipe by using a
  750. X`:' operator with a `:' modifier.
  751. XThis is equivalent to a target having been
  752. Xinitially defined with a rule using a `:' modifier.
  753. XOnce a target is defined using a `:'
  754. Xmodifier it may not be defined again with a recipe using only the `:' operator
  755. Xwith no `:' modifier.  In both cases the use of a `:' modifier creates a new
  756. Xlist of prerequisites and makes it the current prerequisite list for the target.
  757. XThe `:' operator with no recipe always modifies the current list
  758. Xof prerequisites.
  759. XThus assuming each of the following definitions has a recipe attached, then:
  760. X.RS
  761. X.sp
  762. X.nf
  763. Xjoe :  fred ...    (1)
  764. Xjoe :: more ...    (2)
  765. X.sp
  766. Xand
  767. X.sp
  768. Xjoe :: fred ...    (3)
  769. Xjoe :: more ...    (4)
  770. X.sp
  771. X.fi
  772. X.RE
  773. Xare legal and mean:  add the recipe associated with (2), or (4) to the set
  774. Xof recipes for joe, placing them after existing recipes for
  775. Xmaking joe.
  776. XThe constructs:
  777. X.RS
  778. X.sp
  779. X.nf
  780. Xjoe :: fred ...    (5)
  781. Xjoe : more ...    (6)
  782. X.sp
  783. Xand
  784. X.sp
  785. Xjoe : fred ...    (7)
  786. Xjoe : more ...    (8)
  787. X.sp
  788. X.fi
  789. X.RE
  790. Xare errors since we have two sets of perfectly good recipes for
  791. Xmaking the target.
  792. X.PP
  793. X.I prerequisites
  794. Xis a possibly empty list of targets that must be brought up to date before
  795. Xmaking the current target.
  796. X.PP
  797. X.I recipe
  798. Xis a short form and allows the user to specify short rule definitions
  799. Xon a single line.
  800. XIt is taken to be the first recipe line in a larger recipe
  801. Xif additional lines follow the rule definition.
  802. XIf the semi-colon is present but the recipe line is empty (ie. null string)
  803. Xthen it is taken
  804. Xto be an empty rule.  Any target so defined causes the
  805. X.I "Don't know how to make ..."
  806. Xerror message to be suppressed when
  807. X.B dmake
  808. Xtries to make the target and fails.
  809. XThis silence is maintained for rules that are terminated
  810. Xby a semicolon and have no following recipe lines, for targets listed on the
  811. Xcommand line, for the first target found in the makefile, and for any target
  812. Xhaving no recipe but containing a list of prerequisites (see the COMPATIBILITY
  813. Xsection for an exception to this rule if the AUGMAKE (\fB\-A\fP) flag
  814. Xwas specified.
  815. X.SH "RECIPES"
  816. XThe traditional format used by most versions of Make defines the recipe
  817. Xlines as arbitrary strings that may contain macro expansions.  They
  818. Xfollow a rule definition line and may be spaced
  819. Xapart by comment or blank lines.
  820. XThe list of recipe lines defining the recipe is terminated by a new target
  821. Xdefinition, a macro definition, or end-of-file.
  822. XEach recipe line
  823. X.B MUST
  824. Xbegin with a \fB<TAB>\fP character which
  825. Xmay optionally be followed with one or all
  826. Xof the characters
  827. X.IR "'@%+\-'" "."
  828. XThe
  829. X.I "'\-'"
  830. Xindicates that non-zero exit values (ie. errors)
  831. Xare to be ignored when this recipe line is executed, the
  832. X.I "'\+'"
  833. Xindicates that the current recipe line is to be executed using the shell, the
  834. X.I "'%'"
  835. Xindicates that
  836. X.B dmake
  837. Xshould swap itself out to secondary storage (MSDOS only) before running the
  838. Xrecipe and the
  839. X.I "'@'"
  840. Xindicates that the recipe line should NOT be echoed to the terminal prior to
  841. Xbeing executed.  Each switch is off by default
  842. X(ie. by default, errors are significant, commands are echoed, no swapping is
  843. Xdone and a shell is
  844. Xused only if the recipe line contains a character found in the value of the
  845. XSHELLMETAS macro).
  846. XGlobal settings activated via command line options or special attribute or
  847. Xtarget names may also affect these settings.
  848. XAn example recipe:
  849. X.sp
  850. X.RS
  851. X.nf
  852. Xtarget :
  853. X\tfirst recipe line
  854. X\tsecond recipe line, executed independently of the first.
  855. X\t@a recipe line that is not echoed
  856. X\t\-and one that has errors ignored
  857. X\t%and one that causes dmake to swap out
  858. X\t\+and one that is executed using a shell.
  859. X.fi
  860. X.RE
  861. X.PP
  862. XThe second and new format of the recipe block begins the block with the
  863. Xcharacter '[' (the open group character) in the last non-white space
  864. Xposition of a line, and terminates the
  865. Xblock with the character ']' (the close group character)
  866. Xin the first non-white space position of a line.
  867. XIn this form each recipe line need not have a leading TAB.  This is
  868. Xcalled a recipe group.  Groups so defined are fed intact as a single
  869. Xunit to a shell for execution whenever the corresponding target needs to
  870. Xbe updated.  If the open group character '[' is preceded
  871. Xby one or all of \-, @ or %
  872. Xthen they apply to the entire group in the same way that they
  873. Xapply to single recipe lines.  You may also specify '+' but it is
  874. Xredundant as a shell is already being used to run the recipe.
  875. XSee the MAKING TARGETS section for a description of how
  876. X.B dmake
  877. Xinvokes recipes.
  878. XHere is an example of a group recipe:
  879. X.sp
  880. X.RS
  881. X.nf
  882. Xtarget :
  883. X[
  884. X\tfirst recipe line
  885. X\tsecond recipe line
  886. X\tall of these recipe lines are fed to a
  887. X\tsingle copy of a shell for execution.
  888. X]
  889. X.fi
  890. X.RE
  891. X.sp
  892. X.SH "TEXT DIVERSIONS"
  893. X.B dmake
  894. Xsupports the notion of text diversions.
  895. XIf a recipe line contains the macro expression
  896. X.RS
  897. X.sp
  898. X$(mktmp[,[\fIfile\fP][,\fItext\fP]] \fIdata\fP)
  899. X.sp
  900. X.RE
  901. Xthen all text contained in the \fIdata\fP expression is expanded and
  902. Xis written to a temporary file.  The return
  903. Xvalue of the macro is the name of the temporary file.
  904. X.PP
  905. X.I data
  906. Xcan be any text and must be separated from the 'mktmp' portion of the
  907. Xmacro name by white-space.  The only restriction on the data text is that
  908. Xit must contain a balanced number of parentheses of the same kind as are
  909. Xused to initiate the $(mktmp ...) expression.  For example:
  910. X.sp
  911. X\t$(mktmp $(XXX))
  912. X.sp
  913. Xis legal and works as expected, but:
  914. X.sp
  915. X\t$(mktmp text (to dump to file)
  916. X.sp
  917. Xis not legal.  You can achieve what you wish by either defining a macro that
  918. Xexpands to '(' or by using {} in the macro expression; like this:
  919. X.sp
  920. X\t${mktmp text (to dump to file}
  921. X.sp
  922. XSince the temporary file is opened when the
  923. Xmacro containing the text diversion expression is expanded, diversions may
  924. Xnow be nested and any diversions that are created as part of ':=' macro
  925. Xexpansions persist for the duration of the
  926. X.B dmake
  927. Xrun.
  928. XThe diversion text may contain
  929. Xthe same escape codes as those described in the MACROS section.
  930. XThus if the \fIdata\fP text is to contain new lines they must be inserted
  931. Xusing the \en escape sequence.  For example the expression:
  932. X.RS
  933. X.sp
  934. X.nf
  935. Xall:
  936. XX    cat $(mktmp this is a\en\e
  937. XX    test of the text diversion\en)
  938. X.fi
  939. X.sp
  940. X.RE
  941. Xis replaced by:
  942. X.RS
  943. X.sp
  944. Xcat /tmp/mk12294AA
  945. X.sp
  946. X.RE
  947. Xwhere the temporary file contains two lines both of which are terminated
  948. Xby a new-line.  If the \fIdata\fP text spans multiple lines in the makefile
  949. Xthen each line must be continued via the use of a \e.
  950. XA second more illustrative example generates a response file to an MSDOS
  951. Xlink command:
  952. X.RS
  953. X.sp
  954. X.nf
  955. XOBJ = fred.obj mary.obj joe.obj
  956. Xall : $(OBJ)
  957. XX    link @$(mktmp $(^:t"+\en")\en)
  958. X.fi
  959. X.sp
  960. X.RE
  961. XThe result of making `all' in the second example is the command:
  962. X.RS
  963. X.sp
  964. Xlink @/tmp/mk02394AA
  965. X.sp
  966. X.RE
  967. Xwhere the temporary file contains:
  968. X.RS
  969. X.sp
  970. X.nf
  971. Xfred.obj+
  972. Xmary.obj+
  973. Xjoe.obj
  974. X.fi
  975. X.sp
  976. X.RE
  977. XThe last line of the file is terminated by a new-line which is inserted
  978. Xdue to the \en found at the end of the \fIdata\fP string.
  979. X.PP
  980. XIf the optional \fIfile\fP specifier is present then its expanded value
  981. Xis the name of the temporary file to create.  Whenever a $(mktmp ...) macro
  982. Xis expanded the macro $(TMPFILE) is set to a new temporary file name.  Thus
  983. Xthe construct:
  984. X.RS
  985. X.sp
  986. X$(mktmp,$(TMPFILE) data)
  987. X.sp
  988. X.RE
  989. Xis completely equivalent to not specifying the $(TMPFILE) optional argument.
  990. XAnother example that would be useful for MSDOS users with a Turbo-C compiler
  991. X.RS
  992. X.sp
  993. X$(mktmp,turboc.cfg $(CFLAGS))
  994. X.sp
  995. X.RE
  996. Xwill place the contents of CFLAGS into a local \fIturboc.cfg\fP file.
  997. XThe second optional argument, \fItext\fP, if present alters the name
  998. Xof the value returned by the $(mktmp ...) macro.
  999. X.PP
  1000. XUnder MS-DOS text diversions may be a problem.  Many DOS tools require
  1001. Xthat path names which contain directories use the \e character to delimit
  1002. Xthe directories.  Some users however wish to use the '/' to delimit pathnames
  1003. Xand use environments that allow them to do so.
  1004. XThe macro USESHELL is set to "yes" if the
  1005. Xcurrent recipe is forced to use a shell via the .USESHELL or '+' directives,
  1006. Xotherwise its value is "no".
  1007. XThe
  1008. X.B dmake
  1009. Xstartup files define the macro DIVFILE whose value is either the
  1010. Xvalue of TMPFILE or the value of TMPFILE edited to replace any '/' characters
  1011. Xto the appropriate value based on the current shell and whether it will be
  1012. Xused to execute the recipe.
  1013. X.PP
  1014. XPrevious versions of
  1015. X.B dmake
  1016. Xdefined text diversions using <+, +> strings,
  1017. Xwhere <+ started a text diversion and +> terminated one.
  1018. X.B dmake
  1019. Xis backward compatible with this construct if the <+ and +> appear literally
  1020. Xon the same recipe line or in the same macro value string.  In such instances
  1021. Xthe expression:
  1022. X.sp
  1023. X\t<+data+>
  1024. X.sp
  1025. Xis mapped to:
  1026. X.sp
  1027. X\t$(mktmp data)
  1028. X.sp
  1029. Xwhich is fully output compatible with the earlier construct.  <+, +>
  1030. Xconstructs whose text spans multiple lines must be converted by hand to use
  1031. X$(mktmp ...).
  1032. X.PP
  1033. XIf the environment variable TMPDIR is defined then the
  1034. Xtemporary file is placed into the directory specified by that variable.
  1035. XA makefile can modify the location of temporary files by
  1036. Xdefining a macro named TMPDIR and exporting it using the .EXPORT special
  1037. Xtarget.
  1038. X.SH "SPECIAL TARGETS"
  1039. XThis section describes the special targets that are recognized by \fBdmake\fP.
  1040. XSome are affected by attributes and others are not.
  1041. X.IP \fB.ERROR\fP 1.4i
  1042. XIf defined then the recipe associated with this target is executed
  1043. Xwhenever an error condition is detected by \fBdmake\fP.  All attributes that
  1044. Xcan be used with any other target may be used with this target.  Any
  1045. Xprerequisites of this target will be brought up to date during its processing.
  1046. XNOTE:  errors will be ignored while making this target, in extreme cases this
  1047. Xmay cause some problems.
  1048. X.IP \fB.EXPORT\fP 1.4i
  1049. XAll prerequisites associated with this target are assumed to
  1050. Xcorrespond to macro names and they and their values
  1051. Xare exported to the environment as environment strings at the point in
  1052. Xthe makefile at which this target appears.
  1053. XAny attributes specified with this target are ignored.
  1054. XOnly macros which have been assigned a value in the makefile prior to the
  1055. Xexport directive are exported, macros as yet undefined are not exported.
  1056. X.IP \fB.IMPORT\fP 1.4i
  1057. XPrerequisite names specified for this target are searched for in the
  1058. Xenvironment and defined as macros with their value taken from the environment.
  1059. XIf the special name \fB.EVERYTHING\fP is used as a prerequisite name then
  1060. Xall environment variables defined in the environment are imported.
  1061. XThe functionality of the \fB\-e\fP flag can be forced by placing the construct
  1062. X\&\fI.IMPORT : .EVERYTHING\fP at the start of a makefile.  Similarly, by
  1063. Xplacing the construct at the end, one can emulate the effect of the \fB\-E\fP
  1064. SHAR_EOF
  1065. true || echo 'restore of dm37p2 failed'
  1066. fi
  1067. echo 'End of  part 5'
  1068. echo 'File dm37p2 is continued in part 6'
  1069. echo 6 > _shar_seq_.tmp
  1070. exit 0
  1071.  
  1072. exit 0 # Just in case...
  1073. -- 
  1074. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  1075. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  1076. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  1077. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  1078.