MAKEPPREPLAY(1)
π MAKEPPREPLAY π
okay bestie, this is the page for makeppreplay from the Makepp manual, and honestly? it's giving speed demon. it's got a lil nickname too: mppr. no cap. π«Ά
β¨ DESCRIPTION β¨
first up, the iconique option index, exactly as it appears, so you can vibe-check which letter maps to which flag:
?: -?, A: -A,
--args-file,
--arguments-file, C: -C,
-c, D: --directory,
--dry-run, H: -h,
--help, I: -I,
--include,
--include-dir, J: --just-print, K: -k,
--keep-going, L: --log,
--log-file, M: -M,
$MAKPPREPLAYFLAGS,
--module, N: -n,
--no-log,
--no-print-directory,
--no-warn, P: --profile, R: --recon,
--root-dir,
--root-directory, S: -s,
--sed, T: -t,
--temporary, V: -V,
--version
and here's how you actually, like, invoke it:
makeppreplay [ option ... ] [ VAR=value ] [ target ... ]
mppr [ option ... ] [ VAR=value ] [ target ... ]
so. Makeppreplay tries to do the same things makepp did. that's the whole assignment. β¨ and the way it does it is so smart β it goes solely based on the remembered build info, which means it saves SO much time by not doing all this:
- not reading makefiles π
- not parsing commands π«
- not scanning files π
- not looking at every repository file to see whether it fits π
but unlike makepp, it reuses all repository links it finds. periodt.
β οΈ heads up: it does not know about phony or default targets. so you have to give it real files or directories, as a shortcut for all files makepp has built therein. by default it builds all files makepp built in the current or chosen directory.
now the part where we get real. this approach is only correct when there are no structural changes, i.e.:
- no different modules to be linked
- no moved files
- no different
#includestatements, which should possibly have caused those files to be (re)built
after updating from version control, or when building against a repository, where others may have caused such changes, you should call makepp once after potential changes (e.g. in the morning after an overnight repository update), to be sure your build infos are up to date. bestie, do not skip this step. π
not reading makefiles means it will not know any subs (Perl functions) defined in them. for this you should put all your functions into an external module. it will also not know about any variable settings, which is only a problem if your Perl code accesses them (because in rule actions they have already been expanded).
π TODO π
this is still experimental and imperfect. slay for honesty honestly.
- Build up a complete dependency tree starting from the given targets and decide which of them to build based on their build check methods. That requires the method to be remembered in the build info.
- After implementing the previous bullet item, accept more makepp opts, like
-jor--dont-build. - Allow build cache with implicit
--no-populate-bc(because makeppreplay doesn't guarantee a correct build). Makepp might later publish to the build cache anything it retains. - Have makepp remember build info for all failed commands and for those it didn't attempt because their dependencies failed. This is only partially possible, because dependencies may only be found out after building the files that require them. What should happen with (a has no build info):
a: b
b: c
cmd_producing_a_and_b
π OPTIONS π
options include some of the makepp options, plus two new ones, for loading modules that would normally be loaded from a makefile. iykyk.
-Afilename,--args-file=filename,--arguments-file=filename β Read the file and parse it as possibly quoted whitespace- and/or newline-separated options.-Cdirectory,--directory=directory β Cd to the given directory before loading the makefile and trying to build the targets. This is more or less equivalent to specifying a directory with-F, except that subsequent-C,-f,-F,-Iand-Roptions are interpreted relative to the new directory, rather than the old one.-c,--root-dir,--root-directoryβ Cd up to the directory containing aRootMakeppfile.-Idirectory,--include=directory,--include-dir=directory β Add directory to Perl load path@INC.-?,-h,--helpβ Print out a brief summary of the options.-k,--keep-goingβ Build as many files as possible, even if some of them have errors. By default, makepp stops when it encounters the first error, even if there are other files that need to be built that don't depend on the erroneous file.--log=logfilename,--log-file=logfilename β Changes the name of the log file to the indicated name. By default, the log file is called.makepp/log. This file is readable withmakepplog,mppl.-Mmodule[=arg,...],--module=module[=arg,...]β Load module and import any functions it exports.-n,--dry-run,--just-print,--reconβ Print out commands without actually executing them. π zero side effects, just vibes.--no-logβ Don't bother writing a detailed description of what was done to the log file.--no-print-directoryβ Turn off the entering or leaving directory messages.--profileβ Output raw timestamps before and after each action.-sperl-expression,--sed=perl-expression β Run the perl expression against the command before running it, like for preprocessor-s 's/ -c / -E /; s/\.o\b/.i/g'. This would transform a compilation command (-c) into a preprocessor (-E) invocation, changing the.osuffix to.i, which is a conventional suffix for preprocessed C. Or you might want to add some debug output to your linker. If you have only one command in the rule, you can do this by substituting it into the first space:-s 's/ / -Wl,-t /'.
π when the command is altered, nothing is remembered about this, i.e. makepp will think you have manually modified the file, causing a rebuild.
π¨ note that (unlike makepp) makeppreplay does not parse the command, so it won't notice that the target filename was changed. So you must still request the.otarget, even though a.iwill be built. Andmakeppcleanwon't know to remove it.
-t,--temporaryβ Makeppreplay modifies the build info of all files it touched and of all dependencies it found modified. It marks them in such a way that makepp nevertheless knows that it needs to rescan these files. But with this option you can prevent these modifications, so that makepp will simply consider all files makeppreplay created as incorrect.-V,--versionβ Print out the version number.--no-warnβ Don't print any warning messages.
π¦ EXAMPLES π¦
probably the most common use is relinking either a program or a library after editing a source file:
makeppreplay subdir/foo.o bin/bar
mppr subdir/foo.o lib/libbar.so
go off, honestly. π₯
πΈ ENVIRONMENT πΈ
Makeppreplay looks at the following environment variable:
$MAKPPREPLAYFLAGSβ Any options you may want to always pass.
π AUTHOR π
Daniel Pfeiffer (occitan@esperanto.org)
and that's the whole page bestie, we ate π β¨
perl v5.32.0 Β· 2021-01-06 β mwah, love u, go build something ππ¦
π¦ where this page comes from
- debian bookworm: makepp 2.0.98.5-2.1
- ubuntu jammy: makepp 2.0.98.5-2.1
- ubuntu noble: makepp 2.0.98.5-2.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms