caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] Annoying warning about double installation of topdirs.cmi
@ 2016-08-16 13:04 Kakadu
  2016-08-16 19:01 ` Gerd Stolpmann
  2016-08-26 13:10 ` Louis Gesbert
  0 siblings, 2 replies; 3+ messages in thread
From: Kakadu @ 2016-08-16 13:04 UTC (permalink / raw)
  To: Caml List

Hey,

After introducing compiler-libs we have starting getting a warning
when we use compiler-libs as ocamlfind package.

findlib: [WARNING] Interface topdirs.cmi occurs in several
directories: /home/kakadu/.opam2/4.02.3/lib/ocaml,
/home/kakadu/.opam2/4.02.3/lib/ocaml/compiler-libs

(* It has its own mantis issue [1] where gasche have said that we
should discuss it in the mail list before fixing it. *)

It happens because we install topdirs.cmi both to `ocamlc -where` and
`ocamlc -where`/compiler-libs. Of course these are identical files
with the same size and MD5 checksum.

The obvious choice should be not installing this file to `ocamlc
-where` (I) or to `ocamlc -where`/compiler-libs (II).

(I) Seems to be the right solution architecture-wise but it can
introduce backward-incompatibility in OPAM: after initialization it
puts some code into ~/.ocamlinit which relies on topdirs.cmi [2].
Personally, I removed this line from my ~/.ocamlinit because it seems
useless for my case. So, by removing `topdirs.cmi` from `ocamlc
-where` we should probably release bugfix release for opam.

(II) removing `topdirs.cmi` from `ocamlfind query compiler-libs` means
that we split files for this library between two directories which is
not good in general. Also, there is a probability that we can break
compilation of some packages but I think that it is unlikely.

Patches implementing both approaches are very likely to be very
straightforward. We only need to decide right solution. Maybe we can
even get it into 4.04.

Kakadu

[1] http://caml.inria.fr/mantis/view.php?id=6754
[2]
let () =
  try Topdirs.dir_directory (Sys.getenv "OCAML_TOPLEVEL_PATH")
  with Not_found -> ()
;;

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-08-26 13:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-16 13:04 [Caml-list] Annoying warning about double installation of topdirs.cmi Kakadu
2016-08-16 19:01 ` Gerd Stolpmann
2016-08-26 13:10 ` Louis Gesbert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).