]> git.ozlabs.org Git - ccan/blobdiff - tools/ccanlint/tests/tests_compile_coverage.c
ccanlint: handle nested modules when mentioned in examples.
[ccan] / tools / ccanlint / tests / tests_compile_coverage.c
index 0d3e7e1db5f87342296643563c9b4e90afeba009..9e13ad938a403f2d25f15c78d91e05e931e4bc98 100644 (file)
 /* Note: we already test safe_mode in run_tests.c */
 static const char *can_run_coverage(struct manifest *m)
 {
+#ifdef __GNUC__
        unsigned int timeleft = default_timeout_ms;
        char *output;
 
        if (!run_command(m, &timeleft, &output, "gcov -h"))
                return talloc_asprintf(m, "No gcov support: %s", output);
        return NULL;
+#else
+       return "No coverage support for this compiler";
+#endif
 }
 
 static void cov_compile(const void *ctx,
@@ -42,7 +46,7 @@ static void cov_compile(const void *ctx,
                                             COMPILE_NORMAL,
                                             COMPILE_COVERAGE),
                               compiler, flags,
-                              lib_list(m, COMPILE_NORMAL),
+                              test_lib_list(m, COMPILE_NORMAL),
                               file->compiled[COMPILE_COVERAGE]);
 }