B0_build_trace.Compilation_database
JSON compilation database.
Output build operation spawns in JSON compilation database format (see also here).
The format is a bit underpowered (see also the discusion in the merlin issue tracker here) and doesn't exactly match b0's build model here are a few notes on the treatment:
file
field. b0's operations do not identify a "main source" processed by a step. For now we use the first element of B0_zero.Op.reads
TODO maybe we should spell out this convention in B0_memo
.output
field. b0's operations support multiple writes. If multiple files are written we repeat the command for each write. We add an numbered id
field to indicate that this is the same command.env
key as an array of strings.command
, we only use arguments
.val of_ops : B0_zero.Op.t list -> B0_json.Jsong.t