[Libguestfs] [PATCH] Bugfix: ocaml: Rebuild the tests from source if the main library changes

Jim Meyering jim at meyering.net
Wed Jul 29 11:57:00 UTC 2009


Richard W.M. Jones wrote:
> There's a missing dependency in the ocaml subdirectory which causes
> this error whenever the main library changes:
>
> ocamlfind ocamlopt -cclib -L../src/.libs -I . unix.cmxa mlguestfs.cmxa t/guestfs_005_load.cmx -o t/guestfs_005_load
> File "_none_", line 1, characters 0-1:
> Error: Files t/guestfs_005_load.cmx and mlguestfs.cmxa
>        make inconsistent assumptions over interface Guestfs
> make[3]: *** [t/guestfs_005_load] Error 2
>
> The attached patch adds the missing dep to fix this.

> Subject: [PATCH] ocaml: Rebuild the tests from source if the main library changes.
...
> +# Need to rebuild the tests from source if the main library has
> +# changed at all, otherwise we get inconsistent assumptions.
> +t/%.cmx: t/%.ml mlguestfs.cmxa
> +	$(OCAMLFIND) ocamlopt -c $< -o $@
> +
>  .mli.cmi:
>  	$(OCAMLFIND) ocamlc -c $< -o $@
>  .ml.cmo:

ACK.
Looks fine and I confirm it solves my problem.




More information about the Libguestfs mailing list