Kashyap Chamarthy
2014-Feb-22 13:17 UTC
[Libguestfs] [W/ commit: 838a3c9] "inconsistent assumptions over interface Guestfs"
Just did a git pull to the below commit (to get the latest version 1.25.37) and did a local build, this is what I see: Error: The files ../ocaml/guestfs.cmi and perl_edit.cmi make inconsistent assumptions over interface Guestfs Haven't investigated further, thought I'd post it here first: $ git rev-parse --short HEAD 838a3c9 $ ./autogen.sh $ echo $? 0 $ make -j48 [. . .] findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib CC virt_index_validate-index-scan.o ocamlfind ocamlc -g -warn-error CDEFLMPSUVYZX -package str,unix -I ../src/.libs -I ../ocaml -I ../mllib -package gettext-stub -c list_entries.mli -o list_entries.cmi CC index-scan.o findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib ocamlfind ocamlopt -g -warn-error CDEFLMPSUVYZX -package str,unix -I ../src/.libs -I ../ocaml -I ../mllib -package gettext-stub -c index_parser.ml -o index_parser.cmx ocamlfind ocamlopt -g -warn-error CDEFLMPSUVYZX -package str,unix -I ../src/.libs -I ../ocaml -I ../mllib -package gettext-stub -c cmdline.ml -o cmdline.cmx findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib ocamlfind ocamlopt -g -warn-error CDEFLMPSUVYZX -package str,unix -I ../src/.libs -I ../ocaml -I ../mllib -package gettext-stub -c list_entries.ml -o list_entries.cmx findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib CCLD virt-index-validate ocamlfind ocamlopt -g -warn-error CDEFLMPSUVYZX -package str,unix -I ../src/.libs -I ../ocaml -I ../mllib -package gettext-stub -c builder.ml -o builder.cmx findlib: [WARNING] Interface perl_edit.cmi occurs in several directories: ., ../mllib File "builder.ml", line 1: Error: The files ../ocaml/guestfs.cmi and perl_edit.cmi make inconsistent assumptions over interface Guestfs make[2]: *** [builder.cmx] Error 2 make[2]: Leaving directory `/home/tuser1/src/libguestfs/builder' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/tuser1/src/libguestfs' make: *** [all] Error 2 -- /kashyap
Richard W.M. Jones
2014-Feb-23 18:03 UTC
Re: [Libguestfs] [W/ commit: 838a3c9] "inconsistent assumptions over interface Guestfs"
On Sat, Feb 22, 2014 at 06:47:59PM +0530, Kashyap Chamarthy wrote:> Just did a git pull to the below commit (to get the latest version > 1.25.37) and did a local build, this is what I see: > > Error: The files ../ocaml/guestfs.cmi and perl_edit.cmi > make inconsistent assumptions over interface GuestfsThe error means you need to do a 'make clean'. I believe it is caused by having an *.ml file move from one directory to another, which leaves an "orphaned" *.cmi file in the old directory. This confuses the compiler because the cmi file is never recompiled, and so continues to refer to an old Guestfs interface (try 'ocamlobjinfo mllib/perl_edit.cmi' to see interface hashes). In any case, 'make clean' will delete *.cmi files and fix the problem. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-p2v converts physical machines to virtual machines. Boot with a live CD or over the network (PXE) and turn machines into KVM guests. http://libguestfs.org/virt-v2v
Kashyap Chamarthy
2014-Feb-23 19:40 UTC
Re: [Libguestfs] [W/ commit: 838a3c9] "inconsistent assumptions over interface Guestfs"
On Sun, Feb 23, 2014 at 06:03:54PM +0000, Richard W.M. Jones wrote:> On Sat, Feb 22, 2014 at 06:47:59PM +0530, Kashyap Chamarthy wrote: > > Just did a git pull to the below commit (to get the latest version > > 1.25.37) and did a local build, this is what I see: > > > > Error: The files ../ocaml/guestfs.cmi and perl_edit.cmi > > make inconsistent assumptions over interface Guestfs > > The error means you need to do a 'make clean'.Ah, I mistakenly thought I did a 'make clean' before that. Looking in my history buffer, I didn't.> I believe it is caused > by having an *.ml file move from one directory to another, which > leaves an "orphaned" *.cmi file in the old directory. This confuses > the compiler because the cmi file is never recompiled, and so > continues to refer to an old Guestfs interface (try > 'ocamlobjinfo mllib/perl_edit.cmi' to see interface hashes).Learnt something new there.> In any > case, 'make clean' will delete *.cmi files and fix the problem.Yes, it indeed did it. Thanks, Rich. -- /kashyap
Maybe Matching Threads
- [PATCH] Fix building on architectures where ocamlopt is not available
- Re: enable build for ocaml bytecode
- Bug#731166: Error: Syntax error: 'end' expected
- [libnbd PATCH] build: Fix OCaml build on Fedora 29
- [PATCH 1/2] ocaml: Factor out flags into configure script.