package b0

  1. Overview
  2. Docs

Build kernel

WARNING. This is an unstable API use at your own risk.

Concepts kept:

  • Treat build operations as pure functions that affect the file system and memoize their results.
  • Parallelize build operations by synchronizing on the files they read and writes.
  • Tight control over tool lookup and build environment.

Concepts dropped and to be seen how we can recover them at a higher level:

  • Build aims for cross compilation (build/host OS distinction). This should be capturable as two separate Memos.
  • Build units (named sets of build operation with metadata)
  • Build operation synchronisation, only files for now, we had unit-level. Did introduce Memo.Fut for odig.
  • Build configuration.
  • Build unit/config definition localisation (multiple B0.ml files)
  • Build directory structuring and forced clean builds
  • Build metadata, unit and file level, packages.

TODO.

  • The concept of response file in Tool should likely appear at the Op.spawn level aswell so that we can simply have the sequence of Op.t value for a potential build log (otherwise Op.spawn_args becomes the line with the response file which is not meanigfull)
  • Operations, b0 also had file deletion and copy maybe add them aswell. Copy can be expressed in terms of read/write but maybe better to have as a primitive for concurency. Delete doesn't fit well in the "file ready" model, but could be useful for concurrency.
  • Spawn redirection should maybe create the paths of the file they write to.

v0.0.0 — homepage

B00

module File_cache : sig ... end

File caches.

module Op : sig ... end

Build operations.

module Op_cache : sig ... end

Operation cache.

module Guard : sig ... end

Build operations guards.

module Exec : sig ... end

Build operation executors.

B01

module Env : sig ... end

Build environment.

module Tool : sig ... end

Command line tools.

module Memo : sig ... end

Build memoizer.

OCaml

Innovation. Community. Security.