[SSSD] [PATCH] TESTS: Build test_child even without cmocka

Jakub Hrozek jhrozek at redhat.com
Wed Dec 3 17:12:43 UTC 2014


test_child was declared to be build always but only actually built when
cmocka was available, which is not the case on all platforms.

We can either 1) move the test_child outside the HAVE_CMOCKA or 2) only
append test_child to check_PROGRAMS when cmocka is available which is what
the attached patch does.

I'm fine with either option. Thanks for opinions/review.
-------------- next part --------------
>From 67db9748960fbaf6deac4c01084bc23bc1321723 Mon Sep 17 00:00:00 2001
From: Jakub Hrozek <jhrozek at redhat.com>
Date: Wed, 3 Dec 2014 17:00:25 +0100
Subject: [PATCH] TESTS: Build test_child even without cmocka

---
 Makefile.am | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/Makefile.am b/Makefile.am
index 7a36543061789bbd370fcbb118b66edeb8025e89..6d754f062245cc073c945218f6755dab1c59c543 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -236,10 +236,13 @@ endif   # HAVE_CMOCKA
 check_PROGRAMS = \
     stress-tests \
     krb5-child-test \
-    test-child \
     $(non_interactive_cmocka_based_tests) \
     $(non_interactive_check_based_tests)
 
+if HAVE_CMOCKA
+check_PROGRAMS += test-child
+endif # HAVE_CMOCKA
+
 PYTHON_TESTS =
 
 if BUILD_PYTHON_BINDINGS
-- 
1.9.3



More information about the sssd-devel mailing list