module Depsolver:sig..end
type solver
val load : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> solverval is_consistent : Cudf.universe -> Algo.Diagnostic.diagnosisval edos_install : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package -> Algo.Diagnostic.diagnosis
Packages marked as `Keep_package must be always installed.
val edos_coinstall : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package list -> Algo.Diagnostic.diagnosisval edos_coinstall_prod : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package list list -> Algo.Diagnostic.diagnosis listval trim : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.universeval trimlist : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package list -> Cudf.package listval find_broken : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package listval find_installable : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package listval find_listbroken : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package list -> Cudf.package listval find_listinstallable : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
Cudf.universe -> Cudf.package list -> Cudf.package listval univcheck : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?callback:(Algo.Diagnostic.diagnosis -> unit) ->
?explain:bool -> Cudf.universe -> intunivcheck check if all packages in the universe can be installed.
Since not all packages are directly tested for installation, if a packages
is installable, the installation might be empty. To obtain an installation
set for each installable packages, the correct procedure is to iter on the
list of packages.callback : : execute a function for each package. This function can
have side effects and can be used to collect the installation set or the
failure reason.val univcheck_lowmem : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?callback:(Algo.Diagnostic.diagnosis -> unit) ->
?explain:bool -> Cudf.universe -> int
val listcheck : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?callback:(Algo.Diagnostic.diagnosis -> unit) ->
?explain:bool -> Cudf.universe -> Cudf.package list -> intlistcheck ~callback:c subuniverse l check if all packages in l can be
installed.
Invariant : l is a subset of universe can be installed in the solver universe.
It is responsability of the user to pass listcheck an appropriate subuniverse`
Returns the number of broken packages
callback : : execute a function for each package.val dependency_closure : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?maxdepth:int ->
?conjunctive:bool -> Cudf.universe -> Cudf.package list -> Cudf.package listdependency_closure index l return the union of the dependency closure of
all packages in l .maxdepth : the maximum cone depth (infinite by default)conjunctive : consider only conjunctive dependencies (false by default)val reverse_dependencies : Cudf.universe -> Cudf.package list Common.CudfAdd.Cudf_hashtbl.treverse_dependencies univ compute the reverse dependency list of all
packages in the universe univval reverse_dependency_closure : ?maxdepth:int -> Cudf.universe -> Cudf.package list -> Cudf.package listreverse_dependencies_closure univ compute the reverse dependency list of all
packages in l in the universe univtype enc =
| |
Cnf |
| |
Dimacs |
val output_clauses : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?enc:enc -> Cudf.universe -> stringoutput_clauses enc univ return a string encoded accordingly to enc
(default cnf).typedepclean_result =Cudf.package *
(Cudf_types.vpkglist * Cudf_types.vpkg * Cudf.package list) list *
(Cudf_types.vpkg * Cudf.package list) list
val depclean : ?global_constraints:(Cudf_types.vpkglist * Cudf.package list) list ->
?callback:(depclean_result -> unit) ->
Cudf.universe -> Cudf.package list -> depclean_result listp in packagelist, depclean univ packagelist detect
redundundant dependencies that refer to packages that are either missing
or not co-installable together with the root package ptype solver_result =
| |
Sat of |
| |
Unsat of |
| |
Error of |
val dummy_request : Cudf.packageval check_request : ?cmd:string ->
?criteria:string ->
?dummy:Cudf.package ->
?explain:bool -> Cudf.cudf -> solver_resultcheck_request check if there exists a solution for the give cudf document
if ?cmd is specified, it will be used to call an external cudf solver to
satisfy the request.
if ?criteria is specified it will be used as optimization criteria.
if ?explain is specified and there is no solution for the give request, the
result will contain the failure reason.val check_request_using : ?call_solver:(Cudf.cudf -> Cudf.preamble option * Cudf.universe) ->
?criteria:string ->
?dummy:Cudf.package ->
?explain:bool -> Cudf.cudf -> solver_resultcheck_request, but allows to specify any function to call the
external solver. It should raise Depsolver.Unsat on failure.val installation_graph : solution:Cudf.universe ->
Common.CudfAdd.Cudf_set.t * Common.CudfAdd.Cudf_set.t ->
Defaultgraphs.ActionGraph.G.t