[Libguestfs] building resize fails due to lack of Unix module
Richard W.M. Jones
rjones at redhat.com
Mon Oct 22 11:21:06 UTC 2012
On Fri, Oct 19, 2012 at 03:09:12PM +0200, Olaf Hering wrote:
>
> Building 1.9.53 fails for me with ocaml 3.10.2 and 3.12.1, likely due to
> commit a0722c7ad846960be54978a31ebe73b76e119203:
>
> [ 318s] ocamlfind ocamlopt -g -warn-error CDEFLMPSUVYZX -package str -I ../src/.libs -I ../ocaml \
> [ 318s] mlguestfs.cmxa -linkpkg ../fish/guestfish-progress.o progress-c.o resize_gettext.cmx resize_utils.cmx progress.cmx resize.cmx -cclib -lncurses -o virt-resize
> [ 318s] No implementations provided for the following modules:
> [ 318s] Unix referenced from progress.cmx
> [ 318s] make[2]: *** [virt-resize] Error 2
> [ 318s] make[2]: Leaving directory `/usr/src/packages/BUILD/libguestfs-1.19.53/resize'
This is actually a bug in resize/Makefile.am introduced by a0722c7a.
It was masked if you had the optional ocaml-gettext package installed
because that implicitly depends on Unix. Try the attached patch.
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
-------------- next part --------------
From a66fd2fac25d5520b4eb2935dea6a501daed946a Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones at redhat.com>
Date: Mon, 22 Oct 2012 12:18:40 +0100
Subject: [PATCH] resize: Depend explicitly on Unix module.
Commit a0722c7ad846960be54978a31ebe73b76e119203 introduced a
dependency on the Unix module. This was not listed in the list of
'-package's, but as long as you had ocaml-gettext installed it would
still work because that pulled in Unix implicitly.
Thanks Olaf Hering.
---
resize/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resize/Makefile.am b/resize/Makefile.am
index 31fd71b..7d4cade 100644
--- a/resize/Makefile.am
+++ b/resize/Makefile.am
@@ -56,7 +56,7 @@ bin_SCRIPTS = virt-resize
# -I $(top_builddir)/src/.libs is a hack which forces corresponding -L
# option to be passed to gcc, so we don't try linking against an
# installed copy of libguestfs.
-OCAMLPACKAGES = -package str -I $(top_builddir)/src/.libs -I ../ocaml
+OCAMLPACKAGES = -package str,unix -I $(top_builddir)/src/.libs -I ../ocaml
if HAVE_OCAML_PKG_GETTEXT
OCAMLPACKAGES += -package gettext-stub
endif
--
1.7.11.4
More information about the Libguestfs
mailing list