diff options
author | Hilko Bengen <bengen@hilluzination.de> | 2012-01-20 08:44:44 +0100 |
---|---|---|
committer | Richard W.M. Jones <rjones@redhat.com> | 2012-01-23 18:16:15 +0000 |
commit | 6c17e9845c761297d7cafd38573fb6ed3f12db5f (patch) | |
tree | ba1fbcdf954ecf1acc9e36b0c979fe43743e85d3 | |
parent | e80cb70b33eab48f3176b887ddb2d415a8957459 (diff) | |
download | libguestfs-6c17e9845c761297d7cafd38573fb6ed3f12db5f.tar.gz libguestfs-6c17e9845c761297d7cafd38573fb6ed3f12db5f.tar.xz libguestfs-6c17e9845c761297d7cafd38573fb6ed3f12db5f.zip |
Fixed out-of-tree compilation of OCaml code after .depend files removal
(cherry picked from commit 251c6e994de97d9e87a0ace01144c12366e12c2b)
-rw-r--r-- | ocaml/Makefile.am | 9 | ||||
-rw-r--r-- | resize/Makefile.am | 5 | ||||
-rw-r--r-- | sparsify/Makefile.am | 5 |
3 files changed, 11 insertions, 8 deletions
diff --git a/ocaml/Makefile.am b/ocaml/Makefile.am index 35cba466..fbeefc94 100644 --- a/ocaml/Makefile.am +++ b/ocaml/Makefile.am @@ -139,12 +139,13 @@ t/%.cmx: t/%.ml mlguestfs.cmxa depend: .depend -.depend: $(wildcard *.mli) $(wildcard *.ml) +.depend: $(wildcard $(abs_srcdir)/*.mli) $(wildcard $(abs_srcdir)/*.ml) rm -f $@ $@-t - $(OCAMLFIND) ocamldep $^ | \ - $(SED) -e 's/ *$$//' | \ + $(OCAMLFIND) ocamldep -I ../ocaml -I $(abs_srcdir) $^ | \ + $(SED) 's/ *$$//' | \ $(SED) -e :a -e '/ *\\$$/N; s/ *\\\n */ /; ta' | \ - LANG=C sort > $@-t + $(SED) -e 's,$(abs_srcdir)/,$(builddir)/,g' | \ + sort > $@-t mv $@-t $@ -include .depend diff --git a/resize/Makefile.am b/resize/Makefile.am index 5227c236..32c1af7e 100644 --- a/resize/Makefile.am +++ b/resize/Makefile.am @@ -112,11 +112,12 @@ TESTS = test-virt-resize.sh utils_tests # Dependencies. depend: .depend -.depend: $(wildcard *.mli) $(wildcard *.ml) +.depend: $(wildcard $(abs_srcdir)/*.mli) $(wildcard $(abs_srcdir)/*.ml) rm -f $@ $@-t - $(OCAMLFIND) ocamldep -I ../ocaml $^ | \ + $(OCAMLFIND) ocamldep -I ../ocaml -I $(abs_srcdir) $^ | \ $(SED) 's/ *$$//' | \ $(SED) -e :a -e '/ *\\$$/N; s/ *\\\n */ /; ta' | \ + $(SED) -e 's,$(abs_srcdir)/,$(builddir)/,g' | \ sort > $@-t mv $@-t $@ diff --git a/sparsify/Makefile.am b/sparsify/Makefile.am index 4f735c8c..4d73c942 100644 --- a/sparsify/Makefile.am +++ b/sparsify/Makefile.am @@ -105,11 +105,12 @@ TESTS = test-virt-sparsify.sh # Dependencies. depend: .depend -.depend: $(wildcard *.mli) $(wildcard *.ml) +.depend: $(wildcard $(abs_srcdir)/*.mli) $(wildcard $(abs_srcdir)/*.ml) rm -f $@ $@-t - $(OCAMLFIND) ocamldep -I ../ocaml $^ | \ + $(OCAMLFIND) ocamldep -I ../ocaml -I $(abs_srcdir) $^ | \ $(SED) 's/ *$$//' | \ $(SED) -e :a -e '/ *\\$$/N; s/ *\\\n */ /; ta' | \ + $(SED) -e 's,$(abs_srcdir)/,$(builddir)/,g' | \ sort > $@-t mv $@-t $@ |