Module B0_ocaml.Lib

module Lib: sig .. end
OCaml library lookup.


Libraries


type name = string 
The type for library names. TODO define syntax precisely.
type t 
The type for library specification.

Library sets


type set 
The type for a set of libraries and their usage information.
val empty : set
The empty library set.
val is_empty : set -> bool
is_empty s is true iff s is empty.
val root_libs : set -> t list
root_libs s is the ordered set of libraries requested in the set.
val libs : set -> t list
libs s is the ordered set of libraries requested in the set with their recursive dependencies.
val incs_comp : set -> B0.Fpath.t list
incs_comp s is the list of includes needed to compile a source against the set.
val incs_link : set -> B0.Fpath.t list
incs_link s is the list of includes needed to link an object against the set.
val cmas : set -> B0.Fpath.t list
cmas s is the ordered set of cma files needed to byte link against the library set.
val cmxas : set -> B0.Fpath.t list
cmxas s is the ordered set of cmxa files needed to native link against the library set.

Library set resolution


type resolver 
The type for library set resolvers.
val resolve : B0.Build.t ->
resolver ->
B0_ocaml.conf ->
name list -> B0.Fpath.t -> set B0.Build.fiber
resolve b r libs file lookups libs and their recursive dependencies in build b using resolver r. file is a unique file specifed by the client for storing the result of the lookup which might be needed by the resolver.

All the library archives in the result set are either built or marked as B0.Build.ready.

val get_resolver : B0.Build.t -> resolver option -> resolver
get_resolver b r is the resolver r or a default resolver (potententially looked up in b's config).

Low-level interface


val ocamlfind : B0.Tool.t B0.Conf.key
ocamlfind is the ocamlfind tool.