Add perl(Locale::TextDomain) dependency for virt-win-reg.
[fedora-reviews.git] / guestfs-tools / 0006-builder-Use-correct-ounit2-module.patch
diff --git a/guestfs-tools/0006-builder-Use-correct-ounit2-module.patch b/guestfs-tools/0006-builder-Use-correct-ounit2-module.patch
new file mode 100644 (file)
index 0000000..b5d1846
--- /dev/null
@@ -0,0 +1,64 @@
+From b470270d44e8dc37a2417c1157eefdd9c3d65dd1 Mon Sep 17 00:00:00 2001
+From: "Richard W.M. Jones" <rjones@redhat.com>
+Date: Wed, 24 Mar 2021 18:30:45 +0000
+Subject: [PATCH 6/6] builder: Use correct ounit2 module.
+
+Fixes: commit 4354a3126152a2748cc9097cba139b3908ccc342
+---
+ builder/Makefile.am |  2 +-
+ m4/guestfs-ocaml.m4 | 10 +++++-----
+ 2 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/builder/Makefile.am b/builder/Makefile.am
+index 4d2e07843c..f49a3b0aaa 100644
+--- a/builder/Makefile.am
++++ b/builder/Makefile.am
+@@ -192,7 +192,7 @@ if HAVE_OCAML_PKG_GETTEXT
+ OCAMLPACKAGES += -package gettext-stub
+ endif
+ if HAVE_OCAML_PKG_OUNIT
+-OCAMLPACKAGES_TESTS += -package oUnit
++OCAMLPACKAGES_TESTS += -package ounit2
+ endif
+ OCAMLCLIBS = \
+diff --git a/m4/guestfs-ocaml.m4 b/m4/guestfs-ocaml.m4
+index a2f6cada9f..f5ac7eff29 100644
+--- a/m4/guestfs-ocaml.m4
++++ b/m4/guestfs-ocaml.m4
+@@ -105,7 +105,7 @@ if test "x$OCAML_PKG_guestfs" = "xno"; then
+ fi
+ OCAML_PKG_gettext=no
+-OCAML_PKG_oUnit=no
++OCAML_PKG_ounit2=no
+ ounit_is_v2=no
+ have_Bytes_module=no
+ AS_IF([test "x$OCAMLC" != "xno"],[
+@@ -117,11 +117,11 @@ AS_IF([test "x$OCAMLC" != "xno"],[
+     GUESTFS_CREATE_COMMON_GETTEXT_ML([common/mlgettext/common_gettext.ml])
+-    AC_CHECK_OCAML_PKG(oUnit)
++    AC_CHECK_OCAML_PKG(ounit2)
+     # oUnit >= 2 is required, so check that it has OUnit2.
+-    if test "x$OCAML_PKG_oUnit" != "xno"; then
+-        AC_CHECK_OCAML_MODULE(ounit_is_v2,[OUnit.OUnit2],OUnit2,[+oUnit])
++    if test "x$OCAML_PKG_ounit2" != "xno"; then
++        AC_CHECK_OCAML_MODULE(ounit_is_v2,[OUnit.OUnit2],OUnit2,[+ounit2])
+     fi
+     # Check if we have the 'Bytes' module.  If not (OCaml < 4.02) then
+@@ -141,7 +141,7 @@ AS_IF([test "x$OCAMLC" != "xno"],[
+ AM_CONDITIONAL([HAVE_OCAML_PKG_GETTEXT],
+                [test "x$OCAML_PKG_gettext" != "xno"])
+ AM_CONDITIONAL([HAVE_OCAML_PKG_OUNIT],
+-               [test "x$OCAML_PKG_oUnit" != "xno" && test "x$ounit_is_v2" != "xno"])
++               [test "x$OCAML_PKG_ounit2" != "xno" && test "x$ounit_is_v2" != "xno"])
+ AC_CHECK_PROG([OCAML_GETTEXT],[ocaml-gettext],[ocaml-gettext],[no])
+ AM_CONDITIONAL([HAVE_OCAML_GETTEXT],
+-- 
+2.29.0.rc2
+