Blame SOURCES/0023-tests-Hoist-some-EXTRA_DIST-out-of-automake-conditio.patch

3cdd4c
From 5ccf1068703d300c8b5579b3a6ef0e409b5a713e Mon Sep 17 00:00:00 2001
3cdd4c
From: "Richard W.M. Jones" <rjones@redhat.com>
3cdd4c
Date: Tue, 19 Jul 2022 11:56:47 +0100
3cdd4c
Subject: [PATCH] tests: Hoist some EXTRA_DIST out of automake conditionals
3cdd4c
3cdd4c
We can fail to add some test files (test.tcl, test.lua) to the tarball
3cdd4c
if compiling with those languages disabled, which would cause knock-on
3cdd4c
failures when the tarball was used with the languages enabled.  We
3cdd4c
already fixed this for Ruby etc, this commit fixes it for Tcl and Lua.
3cdd4c
3cdd4c
(cherry picked from commit 3b6763c82909c95431ff57c2fe9be1b98316b057)
3cdd4c
---
3cdd4c
 tests/Makefile.am | 6 ++++--
3cdd4c
 1 file changed, 4 insertions(+), 2 deletions(-)
3cdd4c
3cdd4c
diff --git a/tests/Makefile.am b/tests/Makefile.am
3cdd4c
index 0f4b0746..2667be32 100644
3cdd4c
--- a/tests/Makefile.am
3cdd4c
+++ b/tests/Makefile.am
3cdd4c
@@ -1203,10 +1203,11 @@ EXTRA_DIST += \
3cdd4c
 	$(NULL)
3cdd4c
 
3cdd4c
 # Tcl plugin test.
3cdd4c
+EXTRA_DIST += test.tcl
3cdd4c
+
3cdd4c
 if HAVE_TCL
3cdd4c
 
3cdd4c
 LIBGUESTFS_TESTS += test-tcl
3cdd4c
-EXTRA_DIST += test.tcl
3cdd4c
 
3cdd4c
 test_tcl_SOURCES = test-lang-plugins.c test.h
3cdd4c
 test_tcl_CFLAGS = \
3cdd4c
@@ -1219,10 +1220,11 @@ test_tcl_LDADD = libtest.la $(LIBGUESTFS_LIBS)
3cdd4c
 endif HAVE_TCL
3cdd4c
 
3cdd4c
 # Lua plugin test.
3cdd4c
+EXTRA_DIST += test.lua
3cdd4c
+
3cdd4c
 if HAVE_LUA
3cdd4c
 
3cdd4c
 LIBGUESTFS_TESTS += test-lua
3cdd4c
-EXTRA_DIST += test.lua
3cdd4c
 
3cdd4c
 test_lua_SOURCES = test-lang-plugins.c test.h
3cdd4c
 test_lua_CFLAGS = \
3cdd4c
-- 
3cdd4c
2.31.1
3cdd4c