This is an automated email from the ASF dual-hosted git repository.
jbarrett pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode-native.git
The following commit(s) were added to refs/heads/develop by this push:
new 83f86e8 GEODE-5209: Added coverage instructions to BUILDING.md (#301)
83f86e8 is described below
commit 83f86e8e574b48de3b27680406840e465e463d62
Author: Ryan McMahon <[email protected]>
AuthorDate: Fri May 25 08:54:16 2018 -0700
GEODE-5209: Added coverage instructions to BUILDING.md (#301)
---
BUILDING.md | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/BUILDING.md b/BUILDING.md
index e76a84c..6b79740 100644
--- a/BUILDING.md
+++ b/BUILDING.md
@@ -41,6 +41,8 @@ The recommended generator for most unix platforms is
'Makefiles' (default):
$ cmake ..
+For enabling C++ code coverage on Linux, see [Code Coverage](#code-coverage).
+
#### Xcode
The recommended generator for Xcode is `Xcode`:
@@ -64,6 +66,15 @@ For faster builds, use optional parallelism parameters in
the last build step:
$ cmake --build . -- /m
+### Code Coverage
+
+If building on Linux, you can enable C++ code coverage by adding
`-DUSE_CODE_COVERAGE=ON` to the CMake [Generator](#generator) command. You can
then generate a C++ code coverage report by downloading
[lcov](http://ltp.sourceforge.net/coverage/lcov.php). After acquiring lcov,
finish the [Steps to build](#Steps-to-build) section above. Then, run the
tests as described in the [CONTRIBUTING.md](CONTRIBUTING.md). Finally, run the
following commands from the `build` directory:
+
+ $ lcov --capture --directory . --output-file coverage.info
+ $ genhtml coverage.info --output-directory coverage_report
+
+You can then open the `index.html` file in the `coverage_report` directory
using any browser.
+
## Installing
By default a system-specific location is used by CMake as the destination of
the `install` target, e.g., `/usr/local` on UNIX system. To explicitly specify
the location in which the Native Client will be installed, add
`-DCMAKE_INSTALL_PREFIX=/path/to/installation/destination` to the _initial_
`cmake` execution command.
--
To stop receiving notification emails like this one, please contact
[email protected].