[opam-devel] printing detailed dependency analysis

Roberto Di Cosmo roberto at dicosmo.org
Wed Mar 27 16:00:04 GMT 2013


Hmmm... I tried the option, but unlike Ashish, I get an unreadable
output with an extra-wide shallow forest with a lot of \N nodes... 
(opam 0.9.5 here, maybe I am lagging behind) :-(

In the meanwhile, I used the ceve tool, that comes with
dose: it is able to extract the dependency cone of a package from
a Cudf file, and generate the dependeny graph.

For example, after running

  opam upgrade --cudf=foo

one can type

  ceve -c "cryptokit-sha512" -Tdot cudf://foo-1.cudf | dot -Tpng -o cryptokit-sha512.png

to obtain the attached image.

Notice that ceve has not been so extensively tested, and bug reports
and bug fixes are welcome here https://gforge.inria.fr/projects/dose/

--Roberto

On Wed, Mar 27, 2013 at 03:50:09PM +0100, Thomas Gazagnaire wrote:
> Remark: this is really just a hack, I agree it would be good to move that thing into a proper command later.
> 
> We've discussed about creating 'opam-check' which will do this kind of computations using opam-lib, but we've never really had the time to do this properly. As always, contributions are welcome as this is quite distinct from the core of OPAM (eg. the mechanics of installing/removing packages).
> 
> Thomas
> 
> 
> On Mar 27, 2013, at 3:47 PM, Thomas Gazagnaire wrote:
> 
> > You can try:
> > 
> > $ opam upgrade --cudf=foo ocamlfind
> > 
> > hopefully this is just a no-op which produces foo.dot. Then:
> > 
> > $ dot -Tpng foo.dot > foo.png
> > 
> > This will build the graph of all available packages where the roots are the installed ones.
> > 
> > --
> > Thomas
> > 
> > 
> > 
> > On Mar 27, 2013, at 3:31 PM, Ashish Agarwal wrote:
> > 
> >> Is there any way to get a detailed print out of a package's dependency tree? I'm in a situation that is hard to debug.
> >> 
> >> _______________________________________________
> >> opam-devel mailing list
> >> opam-devel at lists.ocaml.org
> >> http://lists.ocaml.org/listinfo/opam-devel
> > 
> 
> _______________________________________________
> opam-devel mailing list
> opam-devel at lists.ocaml.org
> http://lists.ocaml.org/listinfo/opam-devel

-- 
Roberto Di Cosmo
 
------------------------------------------------------------------
Professeur               En delegation a l'INRIA
PPS                      E-mail: roberto at dicosmo.org
Universite Paris Diderot WWW  : http://www.dicosmo.org
Case 7014                Tel  : ++33-(0)1-57 27 92 20
5, Rue Thomas Mann       
F-75205 Paris Cedex 13   Identica: http://identi.ca/rdicosmo
FRANCE.                  Twitter: http://twitter.com/rdicosmo
------------------------------------------------------------------
Attachments:
MIME accepted, Word deprecated
      http://www.gnu.org/philosophy/no-word-attachments.html
------------------------------------------------------------------
Office location:
 
Bureau 320 (3rd floor)
Batiment Sophie Germain
Avenue de France
Metro Bibliotheque Francois Mitterrand, ligne 14/RER C
-----------------------------------------------------------------
GPG fingerprint 2931 20CE 3A5A 5390 98EC 8BFC FCCA C3BE 39CB 12D3                        
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cryptokit-sha512.png
Type: image/png
Size: 14686 bytes
Desc: not available
URL: <http://lists.ocaml.org/pipermail/opam-devel/attachments/20130327/7022dc48/attachment.png>


More information about the opam-devel mailing list