Skip to content

Add support for Clang-based code coverage.#108

Open
eyal0 wants to merge 1 commit intobilke:masterfrom
eyal0:clang_code_coverage
Open

Add support for Clang-based code coverage.#108
eyal0 wants to merge 1 commit intobilke:masterfrom
eyal0:clang_code_coverage

Conversation

@eyal0
Copy link
Copy Markdown
Contributor

@eyal0 eyal0 commented Mar 24, 2026

This fixes #107.

# 5. Build a Debug build:
# cmake -DCMAKE_BUILD_TYPE=Debug ..
# make
# make my_coverage_target
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add how to set up this target.

# EXCLUDE "tests/*" # Patterns to exclude (can be relative to PROJECT_SOURCE_DIR)
# INCLUDE "src/*" # Patterns to include (can be relative to PROJECT_SOURCE_DIR)
# )
function(setup_target_for_coverage_lcov)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
function(setup_target_for_coverage_lcov)
function(setup_target_for_coverage_grcov)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought about that, too. It uses grcov for processing but in the end, creates an lcov file. I'm not sure what is the best name.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah ok, thanks. Ok, then keep the name as is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for clang style code coverage

2 participants