Disable flaky WebNavigationApiTest.Failures on Windows.
[chromium-blink-merge.git] / third_party / lcov / README
blob7fcd43828bc4f111b1724c69e5296046edc10466
1 -------------------------------------------------
2 - README file for the LTP GCOV extension (LCOV) -
3 - Last changes: 2012-10-10                      -
4 -------------------------------------------------
6 Description
7 -----------
8   LCOV is an extension of GCOV, a GNU tool which provides information about
9   what parts of a program are actually executed (i.e. "covered") while running
10   a particular test case. The extension consists of a set of Perl scripts
11   which build on the textual GCOV output to implement the following enhanced
12   functionality:
14     * HTML based output: coverage rates are additionally indicated using bar
15       graphs and specific colors.
17     * Support for large projects: overview pages allow quick browsing of
18       coverage data by providing three levels of detail: directory view,
19       file view and source code view.
21   LCOV was initially designed to support Linux kernel coverage measurements,
22   but works as well for coverage measurements on standard user space
23   applications.
26 Further README contents
27 -----------------------
28   1. Included files
29   2. Installing LCOV
30   3. An example of how to access kernel coverage data
31   4. An example of how to access coverage data for a user space program
32   5. Questions and Comments
36 1. Important files
37 ------------------
38   README             - This README file
39   CHANGES            - List of changes between releases
40   bin/lcov           - Tool for capturing LCOV coverage data
41   bin/genhtml        - Tool for creating HTML output from LCOV data
42   bin/gendesc        - Tool for creating description files as used by genhtml
43   bin/geninfo        - Internal tool (creates LCOV data files)
44   bin/genpng         - Internal tool (creates png overviews of source files)
45   bin/install.sh     - Internal tool (takes care of un-/installing)
46   descriptions.tests - Test descriptions for the LTP suite, use with gendesc
47   man                - Directory containing man pages for included tools
48   example            - Directory containing an example to demonstrate LCOV
49   lcovrc             - LCOV configuration file
50   Makefile           - Makefile providing 'install' and 'uninstall' targets
53 2. Installing LCOV
54 ------------------
55 The LCOV package is available as either RPM or tarball from:
56      
57   http://ltp.sourceforge.net/coverage/lcov.php
59 To install the tarball, unpack it to a directory and run:
61   make install
63 Use anonymous CVS for the most recent (but possibly unstable) version:
65   cvs -d:pserver:anonymous@ltp.cvs.sourceforge.net:/cvsroot/ltp login
67 (simply press the ENTER key when asked for a password)
69   cvs -z3 -d:pserver:anonymous@ltp.cvs.sourceforge.net:/cvsroot/ltp export -D now utils
71 Change to the utils/analysis/lcov directory and type:
73   make install
76 3. An example of how to access kernel coverage data
77 ---------------------------------------------------
78 Requirements: get and install the gcov-kernel package from
80   http://sourceforge.net/projects/ltp
82 Copy the resulting gcov kernel module file to either the system wide modules
83 directory or the same directory as the Perl scripts. As root, do the following:
85   a) Resetting counters
87      lcov --zerocounters
89   b) Capturing the current coverage state to a file
91      lcov --capture --output-file kernel.info
93   c) Getting HTML output
95      genhtml kernel.info
97 Point the web browser of your choice to the resulting index.html file.
100 4. An example of how to access coverage data for a user space program
101 ---------------------------------------------------------------------
102 Requirements: compile the program in question using GCC with the options
103 -fprofile-arcs and -ftest-coverage. During linking, make sure to specify
104 -lgcov or -coverage.
106 Assuming the compile directory is called "appdir", do the following:
108   a) Resetting counters
110      lcov --directory appdir --zerocounters
112   b) Capturing the current coverage state to a file (works only after the
113      application has been started and stopped at least once)
115      lcov --directory appdir --capture --output-file app.info
117   c) Getting HTML output
119      genhtml app.info
121 Point the web browser of your choice to the resulting index.html file.
123 Please note that independently of where the application is installed or
124 from which directory it is run, the --directory statement needs to
125 point to the directory in which the application was compiled.
127 For further information on the gcc profiling mechanism, please also
128 consult the gcov man page.
131 5. Questions and comments
132 -------------------------
133 See the included man pages for more information on how to use the LCOV tools.
135 Please email further questions or comments regarding this tool to the
136 LTP Mailing list at ltp-coverage@lists.sourceforge.net