| OLD | NEW |
| (Empty) |
| 1 .TH genhtml 1 "LCOV 1.9" 2010\-08\-06 "User Manuals" | |
| 2 .SH NAME | |
| 3 genhtml \- Generate HTML view from LCOV coverage data files | |
| 4 .SH SYNOPSIS | |
| 5 .B genhtml | |
| 6 .RB [ \-h | \-\-help ] | |
| 7 .RB [ \-v | \-\-version ] | |
| 8 .RS 8 | |
| 9 .br | |
| 10 .RB [ \-q | \-\-quiet ] | |
| 11 .RB [ \-s | \-\-show\-details ] | |
| 12 .RB [ \-f | \-\-frames ] | |
| 13 .br | |
| 14 .RB [ \-b | \-\-baseline\-file ] | |
| 15 .IR baseline\-file | |
| 16 .br | |
| 17 .RB [ \-o | \-\-output\-directory | |
| 18 .IR output\-directory ] | |
| 19 .br | |
| 20 .RB [ \-t | \-\-title | |
| 21 .IR title ] | |
| 22 .br | |
| 23 .RB [ \-d | \-\-description\-file | |
| 24 .IR description\-file ] | |
| 25 .br | |
| 26 .RB [ \-k | \-\-keep\-descriptions ] | |
| 27 .RB [ \-c | \-\-css\-file | |
| 28 .IR css\-file ] | |
| 29 .br | |
| 30 .RB [ \-p | \-\-prefix | |
| 31 .IR prefix ] | |
| 32 .RB [ \-\-no\-prefix ] | |
| 33 .br | |
| 34 .RB [ \-\-no\-source ] | |
| 35 .RB [ \-\-num\-spaces | |
| 36 .IR num ] | |
| 37 .RB [ \-\-highlight ] | |
| 38 .br | |
| 39 .RB [ \-\-legend ] | |
| 40 .RB [ \-\-html\-prolog | |
| 41 .IR prolog\-file ] | |
| 42 .br | |
| 43 .RB [ \-\-html\-epilog | |
| 44 .IR epilog\-file ] | |
| 45 .RB [ \-\-html\-extension | |
| 46 .IR extension ] | |
| 47 .br | |
| 48 .RB [ \-\-html\-gzip ] | |
| 49 .RB [ \-\-sort ] | |
| 50 .RB [ \-\-no\-sort ] | |
| 51 .br | |
| 52 .RB [ \-\-function\-coverage ] | |
| 53 .RB [ \-\-no\-function\-coverage ] | |
| 54 .br | |
| 55 .RB [ \-\-branch\-coverage ] | |
| 56 .RB [ \-\-no\-branch\-coverage ] | |
| 57 .br | |
| 58 .RB [ \-\-demangle\-cpp ] | |
| 59 .br | |
| 60 .IR tracefile(s) | |
| 61 .RE | |
| 62 .SH DESCRIPTION | |
| 63 Create an HTML view of coverage data found in | |
| 64 .IR tracefile . | |
| 65 Note that | |
| 66 .I tracefile | |
| 67 may also be a list of filenames. | |
| 68 | |
| 69 HTML output files are created in the current working directory unless the | |
| 70 \-\-output\-directory option is used. If | |
| 71 .I tracefile | |
| 72 ends with ".gz", it is assumed to be GZIP\-compressed and the gunzip tool | |
| 73 will be used to decompress it transparently. | |
| 74 | |
| 75 Note that all source code files have to be present and readable at the | |
| 76 exact file system location they were compiled. | |
| 77 | |
| 78 Use option | |
| 79 .I \--css\-file | |
| 80 to modify layout and colors of the generated HTML output. Files are | |
| 81 marked in different colors depending on the associated coverage rate. By | |
| 82 default, the coverage limits for low, medium and high coverage are set to | |
| 83 0\-15%, 15\-50% and 50\-100% percent respectively. To change these | |
| 84 values, use configuration file options | |
| 85 .IR genhtml_hi_limit " and " genhtml_med_limit . | |
| 86 | |
| 87 .SH OPTIONS | |
| 88 .B \-h | |
| 89 .br | |
| 90 .B \-\-help | |
| 91 .RS | |
| 92 Print a short help text, then exit. | |
| 93 | |
| 94 .RE | |
| 95 .B \-v | |
| 96 .br | |
| 97 .B \-\-version | |
| 98 .RS | |
| 99 Print version number, then exit. | |
| 100 | |
| 101 .RE | |
| 102 .B \-q | |
| 103 .br | |
| 104 .B \-\-quiet | |
| 105 .RS | |
| 106 Do not print progress messages. | |
| 107 | |
| 108 Suppresses all informational progress output. When this switch is enabled, | |
| 109 only error or warning messages are printed. | |
| 110 | |
| 111 .RE | |
| 112 .B \-f | |
| 113 .br | |
| 114 .B \-\-frames | |
| 115 .RS | |
| 116 Use HTML frames for source code view. | |
| 117 | |
| 118 If enabled, a frameset is created for each source code file, providing | |
| 119 an overview of the source code as a "clickable" image. Note that this | |
| 120 option will slow down output creation noticeably because each source | |
| 121 code character has to be inspected once. Note also that the GD.pm PERL | |
| 122 module has to be installed for this option to work (it may be obtained | |
| 123 from http://www.cpan.org). | |
| 124 | |
| 125 .RE | |
| 126 .B \-s | |
| 127 .br | |
| 128 .B \-\-show\-details | |
| 129 .RS | |
| 130 Generate detailed directory view. | |
| 131 | |
| 132 When this option is enabled, | |
| 133 .B genhtml | |
| 134 generates two versions of each | |
| 135 file view. One containing the standard information plus a link to a | |
| 136 "detailed" version. The latter additionally contains information about | |
| 137 which test case covered how many lines of each source file. | |
| 138 | |
| 139 .RE | |
| 140 .BI "\-b " baseline\-file | |
| 141 .br | |
| 142 .BI "\-\-baseline\-file " baseline\-file | |
| 143 .RS | |
| 144 Use data in | |
| 145 .I baseline\-file | |
| 146 as coverage baseline. | |
| 147 | |
| 148 The tracefile specified by | |
| 149 .I baseline\-file | |
| 150 is read and all counts found in the original | |
| 151 .I tracefile | |
| 152 are decremented by the corresponding counts in | |
| 153 .I baseline\-file | |
| 154 before creating any output. | |
| 155 | |
| 156 Note that when a count for a particular line in | |
| 157 .I baseline\-file | |
| 158 is greater than the count in the | |
| 159 .IR tracefile , | |
| 160 the result is zero. | |
| 161 | |
| 162 .RE | |
| 163 .BI "\-o " output\-directory | |
| 164 .br | |
| 165 .BI "\-\-output\-directory " output\-directory | |
| 166 .RS | |
| 167 Create files in | |
| 168 .I output\-directory. | |
| 169 | |
| 170 Use this option to tell | |
| 171 .B genhtml | |
| 172 to write the resulting files to a directory other than | |
| 173 the current one. If | |
| 174 .I output\-directory | |
| 175 does not exist, it will be created. | |
| 176 | |
| 177 It is advisable to use this option since depending on the | |
| 178 project size, a lot of files and subdirectories may be created. | |
| 179 | |
| 180 .RE | |
| 181 .BI "\-t " title | |
| 182 .br | |
| 183 .BI "\-\-title " title | |
| 184 .RS | |
| 185 Display | |
| 186 .I title | |
| 187 in header of all pages. | |
| 188 | |
| 189 .I title | |
| 190 is written to the header portion of each generated HTML page to | |
| 191 identify the context in which a particular output | |
| 192 was created. By default this is the name of the tracefile. | |
| 193 | |
| 194 .RE | |
| 195 .BI "\-d " description\-file | |
| 196 .br | |
| 197 .BI "\-\-description\-file " description\-file | |
| 198 .RS | |
| 199 Read test case descriptions from | |
| 200 .IR description\-file . | |
| 201 | |
| 202 All test case descriptions found in | |
| 203 .I description\-file | |
| 204 and referenced in the input data file are read and written to an extra page | |
| 205 which is then incorporated into the HTML output. | |
| 206 | |
| 207 The file format of | |
| 208 .IR "description\-file " is: | |
| 209 | |
| 210 for each test case: | |
| 211 .RS | |
| 212 TN:<testname> | |
| 213 .br | |
| 214 TD:<test description> | |
| 215 | |
| 216 .RE | |
| 217 | |
| 218 Valid test case names can consist of letters, numbers and the underscore | |
| 219 character ('_'). | |
| 220 .RE | |
| 221 .B \-k | |
| 222 .br | |
| 223 .B \-\-keep\-descriptions | |
| 224 .RS | |
| 225 Do not remove unused test descriptions. | |
| 226 | |
| 227 Keep descriptions found in the description file even if the coverage data | |
| 228 indicates that the associated test case did not cover any lines of code. | |
| 229 | |
| 230 This option can also be configured permanently using the configuration file | |
| 231 option | |
| 232 .IR genhtml_keep_descriptions . | |
| 233 | |
| 234 .RE | |
| 235 .BI "\-c " css\-file | |
| 236 .br | |
| 237 .BI "\-\-css\-file " css\-file | |
| 238 .RS | |
| 239 Use external style sheet file | |
| 240 .IR css\-file . | |
| 241 | |
| 242 Using this option, an extra .css file may be specified which will replace | |
| 243 the default one. This may be helpful if the default colors make your eyes want | |
| 244 to jump out of their sockets :) | |
| 245 | |
| 246 This option can also be configured permanently using the configuration file | |
| 247 option | |
| 248 .IR genhtml_css_file . | |
| 249 | |
| 250 .RE | |
| 251 .BI "\-p " prefix | |
| 252 .br | |
| 253 .BI "\-\-prefix " prefix | |
| 254 .RS | |
| 255 Remove | |
| 256 .I prefix | |
| 257 from all directory names. | |
| 258 | |
| 259 Because lists containing long filenames are difficult to read, there is a | |
| 260 mechanism implemented that will automatically try to shorten all directory | |
| 261 names on the overview page beginning with a common prefix. By default, | |
| 262 this is done using an algorithm that tries to find the prefix which, when | |
| 263 applied, will minimize the resulting sum of characters of all directory | |
| 264 names. | |
| 265 | |
| 266 Use this option to specify the prefix to be removed by yourself. | |
| 267 | |
| 268 .RE | |
| 269 .B \-\-no\-prefix | |
| 270 .RS | |
| 271 Do not remove prefix from directory names. | |
| 272 | |
| 273 This switch will completely disable the prefix mechanism described in the | |
| 274 previous section. | |
| 275 | |
| 276 This option can also be configured permanently using the configuration file | |
| 277 option | |
| 278 .IR genhtml_no_prefix . | |
| 279 | |
| 280 .RE | |
| 281 .B \-\-no\-source | |
| 282 .RS | |
| 283 Do not create source code view. | |
| 284 | |
| 285 Use this switch if you don't want to get a source code view for each file. | |
| 286 | |
| 287 This option can also be configured permanently using the configuration file | |
| 288 option | |
| 289 .IR genhtml_no_source . | |
| 290 | |
| 291 .RE | |
| 292 .BI "\-\-num\-spaces " spaces | |
| 293 .RS | |
| 294 Replace tabs in source view with | |
| 295 .I num | |
| 296 spaces. | |
| 297 | |
| 298 Default value is 8. | |
| 299 | |
| 300 This option can also be configured permanently using the configuration file | |
| 301 option | |
| 302 .IR genhtml_num_spaces . | |
| 303 | |
| 304 .RE | |
| 305 .B \-\-highlight | |
| 306 .RS | |
| 307 Highlight lines with converted\-only coverage data. | |
| 308 | |
| 309 Use this option in conjunction with the \-\-diff option of | |
| 310 .B lcov | |
| 311 to highlight those lines which were only covered in data sets which were | |
| 312 converted from previous source code versions. | |
| 313 | |
| 314 This option can also be configured permanently using the configuration file | |
| 315 option | |
| 316 .IR genhtml_highlight . | |
| 317 | |
| 318 .RE | |
| 319 .B \-\-legend | |
| 320 .RS | |
| 321 Include color legend in HTML output. | |
| 322 | |
| 323 Use this option to include a legend explaining the meaning of color coding | |
| 324 in the resulting HTML output. | |
| 325 | |
| 326 This option can also be configured permanently using the configuration file | |
| 327 option | |
| 328 .IR genhtml_legend . | |
| 329 | |
| 330 .RE | |
| 331 .BI "\-\-html\-prolog " prolog\-file | |
| 332 .RS | |
| 333 Read customized HTML prolog from | |
| 334 .IR prolog\-file . | |
| 335 | |
| 336 Use this option to replace the default HTML prolog (the initial part of the | |
| 337 HTML source code leading up to and including the <body> tag) with the contents | |
| 338 of | |
| 339 .IR prolog\-file . | |
| 340 Within the prolog text, the following words will be replaced when a page is gene
rated: | |
| 341 | |
| 342 .B "@pagetitle@" | |
| 343 .br | |
| 344 The title of the page. | |
| 345 | |
| 346 .B "@basedir@" | |
| 347 .br | |
| 348 A relative path leading to the base directory (e.g. for locating css\-files). | |
| 349 | |
| 350 This option can also be configured permanently using the configuration file | |
| 351 option | |
| 352 .IR genhtml_html_prolog . | |
| 353 | |
| 354 .RE | |
| 355 .BI "\-\-html\-epilog " epilog\-file | |
| 356 .RS | |
| 357 Read customized HTML epilog from | |
| 358 .IR epilog\-file . | |
| 359 | |
| 360 Use this option to replace the default HTML epilog (the final part of the HTML | |
| 361 source including </body>) with the contents of | |
| 362 .IR epilog\-file . | |
| 363 | |
| 364 Within the epilog text, the following words will be replaced when a page is gene
rated: | |
| 365 | |
| 366 .B "@basedir@" | |
| 367 .br | |
| 368 A relative path leading to the base directory (e.g. for locating css\-files). | |
| 369 | |
| 370 This option can also be configured permanently using the configuration file | |
| 371 option | |
| 372 .IR genhtml_html_epilog . | |
| 373 | |
| 374 .RE | |
| 375 .BI "\-\-html\-extension " extension | |
| 376 .RS | |
| 377 Use customized filename extension for generated HTML pages. | |
| 378 | |
| 379 This option is useful in situations where different filename extensions | |
| 380 are required to render the resulting pages correctly (e.g. php). Note that | |
| 381 a '.' will be inserted between the filename and the extension specified by | |
| 382 this option. | |
| 383 | |
| 384 This option can also be configured permanently using the configuration file | |
| 385 option | |
| 386 .IR genhtml_html_extension . | |
| 387 .RE | |
| 388 | |
| 389 .B \-\-html\-gzip | |
| 390 .RS | |
| 391 Compress all generated html files with gzip and add a .htaccess file specifying | |
| 392 gzip\-encoding in the root output directory. | |
| 393 | |
| 394 Use this option if you want to save space on your webserver. Requires a | |
| 395 webserver with .htaccess support and a browser with support for gzip | |
| 396 compressed html. | |
| 397 | |
| 398 This option can also be configured permanently using the configuration file | |
| 399 option | |
| 400 .IR genhtml_html_gzip . | |
| 401 | |
| 402 .RE | |
| 403 .B \-\-sort | |
| 404 .br | |
| 405 .B \-\-no\-sort | |
| 406 .RS | |
| 407 Specify whether to include sorted views of file and directory overviews. | |
| 408 | |
| 409 Use \-\-sort to include sorted views or \-\-no\-sort to not include them. | |
| 410 Sorted views are | |
| 411 .B enabled | |
| 412 by default. | |
| 413 | |
| 414 When sorted views are enabled, each overview page will contain links to | |
| 415 views of that page sorted by coverage rate. | |
| 416 | |
| 417 This option can also be configured permanently using the configuration file | |
| 418 option | |
| 419 .IR genhtml_sort . | |
| 420 | |
| 421 .RE | |
| 422 .B \-\-function\-coverage | |
| 423 .br | |
| 424 .B \-\-no\-function\-coverage | |
| 425 .RS | |
| 426 Specify whether to display function coverage summaries in HTML output. | |
| 427 | |
| 428 Use \-\-function\-coverage to enable function coverage summaries or | |
| 429 \-\-no\-function\-coverage to disable it. Function coverage summaries are | |
| 430 .B enabled | |
| 431 by default | |
| 432 | |
| 433 When function coverage summaries are enabled, each overview page will contain | |
| 434 the number of functions found and hit per file or directory, together with | |
| 435 the resulting coverage rate. In addition, each source code view will contain | |
| 436 a link to a page which lists all functions found in that file plus the | |
| 437 respective call count for those functions. | |
| 438 | |
| 439 This option can also be configured permanently using the configuration file | |
| 440 option | |
| 441 .IR genhtml_function_coverage . | |
| 442 | |
| 443 .RE | |
| 444 .B \-\-branch\-coverage | |
| 445 .br | |
| 446 .B \-\-no\-branch\-coverage | |
| 447 .RS | |
| 448 Specify whether to display branch coverage data in HTML output. | |
| 449 | |
| 450 Use \-\-branch\-coverage to enable branch coverage display or | |
| 451 \-\-no\-branch\-coverage to disable it. Branch coverage data display is | |
| 452 .B enabled | |
| 453 by default | |
| 454 | |
| 455 When branch coverage display is enabled, each overview page will contain | |
| 456 the number of branches found and hit per file or directory, together with | |
| 457 the resulting coverage rate. In addition, each source code view will contain | |
| 458 an extra column which lists all branches of a line with indications of | |
| 459 whether the branch was taken or not. Branches are shown in the following format: | |
| 460 | |
| 461 ' + ': Branch was taken at least once | |
| 462 .br | |
| 463 ' - ': Branch was not taken | |
| 464 .br | |
| 465 ' # ': The basic block containing the branch was never executed | |
| 466 .br | |
| 467 | |
| 468 This option can also be configured permanently using the configuration file | |
| 469 option | |
| 470 .IR genhtml_branch_coverage . | |
| 471 | |
| 472 .RE | |
| 473 .B \-\-demangle\-cpp | |
| 474 .RS | |
| 475 Specify whether to demangle C++ function names. | |
| 476 | |
| 477 Use this option if you want to convert C++ internal function names to | |
| 478 human readable format for display on the HTML function overview page. | |
| 479 This option requires that the c++filt tool is installed (see | |
| 480 .BR c++filt (1)). | |
| 481 | |
| 482 .SH FILES | |
| 483 | |
| 484 .I /etc/lcovrc | |
| 485 .RS | |
| 486 The system\-wide configuration file. | |
| 487 .RE | |
| 488 | |
| 489 .I ~/.lcovrc | |
| 490 .RS | |
| 491 The per\-user configuration file. | |
| 492 .RE | |
| 493 | |
| 494 .SH AUTHOR | |
| 495 Peter Oberparleiter <Peter.Oberparleiter@de.ibm.com> | |
| 496 | |
| 497 .SH SEE ALSO | |
| 498 .BR lcov (1), | |
| 499 .BR geninfo (1), | |
| 500 .BR genpng (1), | |
| 501 .BR gendesc (1), | |
| 502 .BR gcov (1) | |
| OLD | NEW |