dune/src/build_system.mli

36 lines
861 B
OCaml
Raw Normal View History

2016-12-02 13:54:32 +00:00
(** Build rules *)
2016-12-15 13:00:30 +00:00
open! Import
2016-12-02 13:54:32 +00:00
2016-12-15 11:20:46 +00:00
type t
2016-12-02 13:54:32 +00:00
2017-02-26 21:49:41 +00:00
val create
: contexts:Context.t list
-> file_tree:File_tree.t
-> rules:Build_interpret.Rule.t list
-> t
2016-12-02 13:54:32 +00:00
val is_target : t -> Path.t -> bool
2016-12-02 13:54:32 +00:00
module Build_error : sig
type t
val backtrace : t -> Printexc.raw_backtrace
val dependency_path : t -> Path.t list
val exn : t -> exn
exception E of t
end
(** Do the actual build *)
2016-12-15 11:20:46 +00:00
val do_build : t -> Path.t list -> (unit Future.t, Build_error.t) result
val do_build_exn : t -> Path.t list -> unit Future.t
2016-12-02 13:54:32 +00:00
(** Return all the library dependencies (as written by the user) needed to build these
targets *)
2016-12-15 13:00:30 +00:00
val all_lib_deps : t -> Path.t list -> Build.lib_deps Path.Map.t
2017-03-01 19:19:43 +00:00
(** Return all the library dependencies required to build these targets, by context
name *)
val all_lib_deps_by_context : t -> Path.t list -> Build.lib_deps String_map.t