module Dir:sig..end
A directory part defines a clean directory in which a selection of
part products (both source and build) can be gathered and
renamed. Directory parts can be marked as being
Assemblage.Dir.installable; drivers can use this information to devise an
installation procedure for your project's outcomes.
typekind =[ `Bin
| `Doc
| `Etc
| `Lib
| `Man
| `Other of Assemblage.Path.t
| `Sbin
| `Share
| `Share_root
| `Stublibs
| `Toplevel ]
val pp_kind : Format.formatter -> kind -> unitpp_kind ppf k prints an unspecified representation of k on
ppf.val kind : [< `Dir ] Assemblage.part -> kindkind p is p's kind.val install : [< `Dir ] Assemblage.part -> boolkind p is true if the directory contents is meant to be installed.
FIXME a few combinators to quickly devise spec values
would be welcome, e.g. put a specific part in sub directory, etc.
typespec =Assemblage.Part.kind Assemblage.Part.t ->
(Assemblage.Path.t * Assemblage.Path.rel option) list Assemblage.Conf.value
Given a part p it returns a list of tuples (prod, path),
where prod is a product of p to add to the directory and
path specifies under which name, relative to the directory, it
should be added. If path is None and prod is in p's
build root directory, the path relative to this directory is used.
val all : specall is a specifier that keeps any product of any part.val all_output : specall_output is a specifier that keeps any output product of any part.val all_input : specall_input is a specifier that keeps any input product of any part.val file_exts : Assemblage.Path.ext list -> specfile_exts exts is a specifier that keeps, in any part,
products that have an extension in exts.val bin : specbin is Assemblage.Dir.all_output except in the following cases:
`Bin parts of kind `OCaml keeps only one of the
byte and native code executable without its extension. If
both are available favors native code over byte code.`Bin parts of kind `C keeps only the part's
executable.val lib : speclib is Assemblage.Dir.all_output except in the following cases:
`Lib parts of kind `OCaml, keeps only the library's
archives and the library's unit's cmx, cmi and cmti
files according to their
interface specification.`Lib parts of kind `C, keeps only the library's
archives.val doc : specdoc is Assemblage.Dir.all except in the following cases:
`Doc parts of kind `OCamldoc it is any_output.val v : ?usage:Assemblage.Part.usage ->
?exists:bool Assemblage.Conf.value ->
?args:Assemblage.Args.t ->
?spec:spec ->
?install:bool ->
kind ->
[< `Base | `Bin | `Dir | `Doc | `Lib | `Unit ] Assemblage.part list ->
[< Assemblage.part_kind > `Dir ] Assemblage.partv spec install kind needs is a directory of type kind that
gathers the products of existing needs as determined by
the directory specifier spec.
If install is true the directory structure is meant to be
installed at a root location defined by kind. install
defaults to true except for kind `Other.
The name of the part is automatically derived from kind
in the obvious way. For `Other p the name is the basename of
p.
The default for spec depends in kind as follows:
`Bin, Assemblage.Dir.bin is used.`Lib, Assemblage.Dir.lib is used.`Doc, Assemblage.Dir.doc is used.Assemblage.Dir.all is used.
Note. Due to the way assemblage and ocamldoc work, trying
to install a `Doc part will be disappointing.