summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ae172fa)
raw | patch | inline | side by side (parent: ae172fa)
author | Sebastian Harl <sh@tokkee.org> | |
Sat, 21 Dec 2013 20:55:21 +0000 (21:55 +0100) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sat, 21 Dec 2013 20:55:21 +0000 (21:55 +0100) |
$GCC might be true for clang as well but clang does not support gcov coverage
testing.
testing.
configure.ac | patch | blob | history |
diff --git a/configure.ac b/configure.ac
index d927b60a939ce2533a297170d9afb97ce74b0587..4977fb5986b7c4902a120fce4415609731128976 100644 (file)
--- a/configure.ac
+++ b/configure.ac
[enable_gcov="$enableval"],
[enable_gcov="no"])
+dnl $GCC is based on some heuristics which might apply to clang as well.
+dnl However, clang does not support gcov.
+cc_is_gcc="no"
+case "x$CC" in
+ gcc)
+ cc_is_gcc="yes"
+ ;;
+ gcc-*)
+ cc_is_gcc="yes"
+ ;;
+esac
+
COVERAGE_CFLAGS=""
COVERAGE_LDFLAGS=""
-if test "x$enable_gcov" = "xyes" && test "x$GCC" == "xyes"; then
+if test "x$enable_gcov" = "xyes" && test "x$GCC$cc_is_gcc" == "xyesyes"; then
COVERAGE_CFLAGS="-O0"
cov_flag_have_problem="no"