Makepp supports most of the command line options and syntax that other makes support. You can assign variables on the command line which will override any assignment in every Makefile loaded, e.g.,
As with other implementations of make, if you do not specify a target, the first target in the file which is not part of a pattern rule is invoked.
Options include most of the standard make options, plus a few new ones.
-F, except that if the directory does not exist yet but does exist in a repository,
-Fwill make the directory whereas
-foption, makepp looks first for a file in the current directory called
This option can be useful if you execute makepp from unpredictable directories. For example, if you compile from within emacs and you have sources scattered all over your directory tree, the current working directory for the compilation command will be the directory the last source file you edited was in, which may or may not be the top level directory for your compilation. However, you can specify your compilation command as
makepp -F /your/source/dir/topand this will work no matter what your current directory is.
makeppdoes not execute commands in parallel.
Unlike some other versions of make, when jobs are executed in parallel, makepp directs their output to a file and only displays the output when the commands have finished. This prevents output from several different commands from being mixed together on the display, but it does mean that you might have to wait a little longer to see the output.
load_makefilestatement, makepp aborts with an error. You can also turn off makefile loading on a directory-by-directory basis by using the
no_implicit_loadstatement in one of your makefiles.
:signaturemodifier in makefiles which do not have a
signaturestatement. Possible values are
c_compilation_md5. This option has no effect on the signature method for C/C++ compilation; you must use the
signaturestatement or the
:signaturerule modifier to affect that. For more details, see the section on signature checking.
.makepp_log. This can be extremely valuable for debugging a makefile--makepp tells you what it thought all of the dependencies were, and which one(s) it thought changed. However, it does take some extra CPU time, and you might not want to bother.
rc_substitution=0in your makefile.
- Ordinarily, makepp loads each makefile in, then looks to see whether there is a rule that specifies how to update the makefile. If there is, and the makefile needs to be rebuilt, the command is executed, and the makefile is reread. This often causes problems with makefiles produced for the standard unix make utility, because (in my experience) often the make rules for updating makefiles are inaccurate--they frequently omit targets which are modified. This can cause makepp to remake a lot of files unnecessarily. You can often solve this problem by simply preventing makepp from updating the makefile automatically (but you have to remember to update it by hand).
- Don't print any warning messages. Most warning messages are about constructs that you might see in legacy makefiles that makepp considers dangerous, but a few of them concern possible errors in your makefile.
- By default, % in a pattern rule (not in the
$(patsubst )function) matches only the filename, not a directory. In other words, %.c matches only *.c. If you want %.c to match **/*.c, specify this option. You can also enable this in your makefile by the assignment
- Don't print informational messages like "Scanning xyz.h" or "Loading makefile /users/src/bob/funproject/Makefile".
- Specify the given directory as a repository. Repositories are added in the order specified on the command line, so the first one you specify has precedence. All files in the directory (and all its subdirectories) are automatically and temporarily linked to the current directory (and subdirectories) if they are needed.
If you just specify a directory after
-R, its contents are linked into the current directory. You can link its contents into any arbitrary place in the file system by specifying the location before an equals sign, e.g,
- This option is present to allow makepp to work with old makefiles that use recursive make extensively. By default, recursive make is implemented by a subprocess that communicates with the parent process; the build is actually done by the parent process. This allows some of makepp's nice features like repositories to work with recursive make invocations. However, this technique will not work if you load more than one makefile from the same directory, or if you use different command line options on different invocations of recursive make. The
--traditional-recursive-makeoption makes makepp do recursive makes the same way as the traditional make, allowing more makefiles to work, but then repositories and parallel builds do not work properly. This option is rarely needed any more, and makepp will tell you if it runs into a construct that requires it.
- Verbose mode. Explains what it is trying to build, and why each file is being built. This can be useful if you think a file is being rebuilt too often.
This option actually takes what would be written to the log file and displays it on the screen. It's usually easier to run makepp and then look at