16.12.2012 Views

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

make<br />

1. Extract the suffix from the target. If that target does not have a suffix, go to step<br />

6.<br />

2. Is it in the .SUFFIXES list? If not, quit the search.<br />

3. If it is in the .SUFFIXES list, look for a double suffix rule that matches the target<br />

suffix.<br />

4. If there is a match, extract the base name of the file, add on the second suffix,<br />

and determine if the resulting file exists. If the resulting file does not exist, keep<br />

searching the double suffix rules.<br />

If the resulting file does exist, use the recipe for this rule.<br />

5. If a successful match is not made, the inference has failed.<br />

6. If the target did not have a suffix, check the single suffix rules in the order that<br />

the suffixes are specified in the .SUFFIXES target.<br />

7. For each single suffix rule, add the suffix to the target name and determine if<br />

the resulting filename exists.<br />

8. If the filename exists, execute the recipe associated with that suffix rule. If the<br />

filename doesn’t exist, continue trying the rest of the single suffix rules. If a<br />

successful match is not made, the inference has failed.<br />

When the .P<strong>OS</strong>IX special target is not specified, make handles suffix rules in the<br />

same manner as traditional implementations of make. The following steps describe<br />

the search algorithm for suffix rules in this situation.<br />

1. Extract the suffix from the target. If that target does not have a suffix, go to<br />

step 8.<br />

2. Is it in the .SUFFIXES list? If not, then quit the search.<br />

3. If it is in the .SUFFIXES list, look for a double suffix rule that matches the target<br />

suffix.<br />

4. If you find one, then extract the base name of the file, add on the second suffix<br />

and see if the resulting file exists. If it does, go to step 7. If not, continue with<br />

step 5.<br />

5. Is there an inference rule for the resulting file? If yes, run the recipe associated<br />

with that rule (which should describe how to make the file exist) and go to step<br />

7.<br />

6. Search for the next double-suffix rule that matches the target suffix and return<br />

to step 4. If the double-suffix rules are exhausted, then the inference has<br />

failed.<br />

7. Use the recipe for the target rule.<br />

8. If the target did not have a suffix, then check the single-suffix rules in the order<br />

that the suffixes are specified in the .SUFFIXES target.<br />

9. For each single-suffix rule, add the suffix to the target name and see if the<br />

resulting filename exists.<br />

10. If the file exists, then run the recipe associated with that suffix rule. If it doesn’t<br />

exist, continue trying the rest of the single-suffix rules.<br />

11. If a successful match is not made, then the inference has failed.<br />

make also provides a special feature in the suffix rule mechanism for archive library<br />

handling. If you specify a suffix rule of the form:<br />

.suf.a:<br />

recipe<br />

the rule matches any target having the LIBRARY attribute set, regardless of what the<br />

actual suffix was. For example, if your makefile contains the rules:<br />

402 z/<strong>OS</strong> <strong>V1R9.0</strong> <strong>UNIX</strong> <strong>System</strong> <strong>Services</strong> <strong>Command</strong> Reference

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!