More fixes for situations where ocamlopt is not available

- run bindtests.opt only if available
- use ocamlc -custom
- Don't try to install native code if it hasn't been built (Thanks to Olaf Hering)
This commit is contained in:
Hilko Bengen
2014-02-28 19:58:04 +01:00
parent 0b285e07a0
commit 876983365a
4 changed files with 13 additions and 9 deletions

View File

@@ -58,16 +58,13 @@ inspect_vm: inspect_vm.ml
$(OCAMLFIND) ocamlopt $(OCAMLFINDFLAGS) -package unix -linkpkg \
-warn-error A -I .. mlguestfs.cmxa $< -o $@
else
# This avoids:
# Error: Error on dynamically loaded library: ../dllmlguestfs.so: libguestfs.so.0: cannot open shared object file: No such file or directory
create_disk: create_disk.ml
$(top_builddir)/run $(OCAMLFIND) ocamlc $(OCAMLFINDFLAGS) -package unix -linkpkg \
-warn-error A -I .. mlguestfs.cma $< -o $@
$(OCAMLFIND) ocamlc $(OCAMLFINDFLAGS) -package unix -linkpkg \
-warn-error A -I .. mlguestfs.cma -custom $< -o $@
inspect_vm: inspect_vm.ml
$(top_builddir)/run $(OCAMLFIND) ocamlc $(OCAMLFINDFLAGS) -package unix -linkpkg \
-warn-error A -I .. mlguestfs.cma $< -o $@
$(OCAMLFIND) ocamlc $(OCAMLFINDFLAGS) -package unix -linkpkg \
-warn-error A -I .. mlguestfs.cma -custom $< -o $@
endif
endif