ADC Home > Reference Library > Technical Q&As > Legacy Documents > Tools >
Important: This document is part of the Legacy section of the ADC Reference Library. This information should not be used for new development.
Current information on this Reference Library topic can be found here:
|
Q: We're having trouble with one of our MPW makefiles. We want to force a full build of the application whenever the "Test.make" file or the "DefineCreator" file is changed, but we've been unable to do this successfully. Although we've had some success, the methods we've tried always execute some of the commands, even if none of the dependents have changed. A: There are two approaches you can take to resolve this problem: Add the make file and the "DefineCreator" file to each dependency line in your make file. For example, in 7Edit, each of the object files is dependent on the corresponding .h and .c files, as well as on the MakeFile itself, so the dependency line for each C file is:
Since adding the MakeFile and any additional files to each dependency line could be more work than it's worth, you could also use a double dependency rule to make all the object files dependent on the MakeFile and your "DefineCreator" file. Your MakeFile might include the following:
(more dependencies following...) If either the MakeFile or the DefineCreator file is changed, the entire application will be rebuilt. You don't need to include any further build commands, since you would be using the default build rules in this case. For additional information, see "Make and Make Files" in Chapter 4 of Building and Managing Programs in MPW. |
|