Skip to content

adding cppcheck libraries option#323

Merged
jacobperron merged 2 commits intoament:masterfrom
zflat:cppcheck_libraries
Sep 29, 2021
Merged

adding cppcheck libraries option#323
jacobperron merged 2 commits intoament:masterfrom
zflat:cppcheck_libraries

Conversation

@zflat
Copy link
Copy Markdown
Contributor

@zflat zflat commented Sep 20, 2021

I am adding a libraries option to ament_cppcheck that is passed to cppcheck. See the cppcheck documentation http://cppcheck.net/manual.html#library-configuration for an explanation of what this option does.

Here is an example of using ament_cppcheck with this option from CMakeLists.txt:

  find_package(ament_cmake_cppcheck REQUIRED)
  ament_cppcheck(LANGUAGE c++
    LIBRARIES googletest qt
    INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/include)

This addresses the issue I raised in #321

William Wedler added 2 commits September 20, 2021 16:53
Signed-off-by: William Wedler <william.wedler@resquared.com>
Signed-off-by: William Wedler <william.wedler@resquared.com>
@zflat zflat force-pushed the cppcheck_libraries branch from 3bdf743 to 2b8a74e Compare September 20, 2021 20:53
Copy link
Copy Markdown
Contributor

@jacobperron jacobperron left a comment

Choose a reason for hiding this comment

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

Thanks for the addition! The change looks good to me, running CI for ROS 2, running linter tests only:

  • Linux Build Status
  • Linux-aarch64 Build Status
  • macOS Build Status
  • Windows Build Status (standby, unrelated infrastructure issue on Windows)

@nuclearsandwich
Copy link
Copy Markdown
Contributor

Windows build requeued: Build Status

@zflat
Copy link
Copy Markdown
Contributor Author

zflat commented Sep 29, 2021

@jacobperron What is the process for this to be merged?

@jacobperron
Copy link
Copy Markdown
Contributor

@jacobperron What is the process for this to be merged?

Pinging me just like this 😄 Sorry for the delay!

@jacobperron jacobperron merged commit ebd524b into ament:master Sep 29, 2021
mjeronimo pushed a commit that referenced this pull request Oct 20, 2021
* adding ament_cppcheck libraries option

Signed-off-by: William Wedler <william.wedler@resquared.com>

* pass libraries option via CMake

Signed-off-by: William Wedler <william.wedler@resquared.com>

Co-authored-by: William Wedler <william.wedler@resquared.com>
mjeronimo pushed a commit that referenced this pull request Oct 22, 2021
* adding ament_cppcheck libraries option

Signed-off-by: William Wedler <william.wedler@resquared.com>

* pass libraries option via CMake

Signed-off-by: William Wedler <william.wedler@resquared.com>

Co-authored-by: William Wedler <william.wedler@resquared.com>
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.

3 participants