[opam-devel] A few questions debugging packages & opam

David Allsopp dra-news at metastack.com
Sun Nov 1 14:50:50 GMT 2015


I have a few questions regarding the debugging of package installation in
OPAM. I have the additional challenge that not only do package installations
fail quite regularly for me, but they're often failing because of OPAM
crashing (i.e. uncaught exceptions, unexpected conditions) as I work through
native Windows support, and it's proving a little cumbersome at the moment!

Some quick fire answers to these few questions from an opam expert or two
would be very much appreciated, please :o)

1. Are there any circumstances in which opam (re)install -b deletes the
build directory?

I'm fairly sure that while doing an opam reinstall which crashed (i.e. opam
suffered an exception) during the install bit that the handler deleted the
build directory, despite -b being specified.

If opam really did delete the build directory in this instance, is that a
bug? (in which case I'll add it to my ToDo list)

2. What's the correct set of flags to keep and obtain as much information as
possible for debugging package building?

-b gives me the build directory. Is the only way to get the
.{env,info,out,err} files kept to specify --debug?

3. Is there a tool or better way to view the output of each command (i.e.
the aforementioned files) than going through the .info files to find the
right one and then looking at the appropriate other file?

Would it be appreciated if opam were patched to give the files a canonical
order (i.e. so that ls displays the log files in the order they were
executed)?

4. When changing opam source files which are part of the .cmxa/.cma
libraries (e.g. opam-core, opam-format), I'm frequently forced to do make
clean; make all as otherwise I get "inconsistent assumption" errors over
.cmx implementation (I'm building with 4.02.2).

Is that affecting anyone else, or is there something weird going on with the
Windows Makefile dependencies that I should look into?

Thanks!


David



More information about the opam-devel mailing list