Skip to content
Go to file

Latest commit

Introduce value assignment tracing and include tracing.

The `--dump_variable_assignment_trace <path>` command line option dumps the following data for every variable reference:
  * The stack trace of the variable reference
  * The stack trace where the value was assigned

The `--dump_include_json <path>`  option dumps the Makefile inclusion graph.

If `<path>` is `-`, the output is dumped to stderr.

If tracing is disabled, its CPU/RAM overhead is negligible according to rudimentary measurements. When enabled, it incurs a ~2x increase in memory use and a ~15x increase in execution time (dominated by I/O, since the output is quite wordy; without I/O it's ~10%)

The variable assignment trace correctly reports:
  * Simply and recursively expanded variables
  * Regular and rule-specific variables
  * Automatic variables (although the call stack where their value is set is currently not indicated; this is fixable)

Some example `jq` commands for the include graph:

List of Makefiles including a specific one:
jq '.nodes[] | select((.includes | index("$MAKEFILE") != null)) | .file'
List of Makefiles included by a Makefile:

jq '.nodes[] | select(.file == "$MAKEFILE")'
List of all seen Makefiles:

jq '.nodes[].file'

Git stats


Failed to load latest commit information.
Latest commit message
Commit time


Build and Test

kati is an experimental GNU make clone. The main goal of this tool is to speed-up incremental build of Android.

Currently, kati does not offer a faster build by itself. It instead converts your Makefile to a ninja file.

How to use for Android

For Android-N+, ckati and ninja is used automatically. There is a prebuilt checked in under prebuilts/build-tools that is used.

All Android's build commands (m, mmm, mmma, etc.) should just work.


An experimental GNU make clone




No releases published
You can’t perform that action at this time.