Revision: 1167
http://vcs.pcre.org/viewvc?view=rev&revision=1167
Author: ph10
Date: 2012-10-23 16:51:31 +0100 (Tue, 23 Oct 2012)
Log Message:
-----------
Check for gcc when coverage is enabled in CMake.
Modified Paths:
--------------
code/trunk/CMakeLists.txt
Modified: code/trunk/CMakeLists.txt
===================================================================
--- code/trunk/CMakeLists.txt 2012-10-23 11:22:56 UTC (rev 1166)
+++ code/trunk/CMakeLists.txt 2012-10-23 15:51:31 UTC (rev 1167)
@@ -165,7 +165,7 @@
"Enable Valgrind support.")
SET(PCRE_SUPPORT_COVERAGE OFF CACHE BOOL
- "Enable GCOV support.")
+ "Enable code coverage support using gcov.")
OPTION(PCRE_SHOW_REPORT "Show the final configuration report" ON)
OPTION(PCRE_BUILD_PCREGREP "Build pcregrep" ON)
@@ -298,6 +298,9 @@
IF(PCRE_SUPPORT_COVERAGE)
SET(SUPPORT_GCOV 1)
+ IF(NOT CMAKE_COMPILER_IS_GNUCC)
+ MESSAGE(FATAL_ERROR "Code coverage reports can only be generated when using GCC")
+ ENDIF(NOT CMAKE_COMPILER_IS_GNUCC)
ENDIF(PCRE_SUPPORT_COVERAGE)
# This next one used to contain