From c1da4104d996fe1a332e5bc01fad937b4773551a Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Tue, 22 Mar 2011 14:22:28 +1030 Subject: [PATCH] ccanlint: fix compilation of API tests with coverage They expect to be linked against the module objects. --- tools/ccanlint/tests/tests_compile_coverage.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/ccanlint/tests/tests_compile_coverage.c b/tools/ccanlint/tests/tests_compile_coverage.c index ea46e79e..4e356099 100644 --- a/tools/ccanlint/tests/tests_compile_coverage.c +++ b/tools/ccanlint/tests/tests_compile_coverage.c @@ -127,7 +127,10 @@ static void do_compile_coverage_tests(struct manifest *m, foreach_ptr(h, &m->run_tests, &m->api_tests) { list_for_each(h, i, list) { - cmdout = cov_compile(m, m, i, NULL, keep); + cmdout = cov_compile(m, m, i, + h == &m->api_tests + ? modobjs : NULL, + keep); if (cmdout) { score_file_error(score, i, 0, "Failed to compile test with coverage: %s", -- 2.39.2