Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake Flag to Skip Deprecated Tests or Functionality #204

Open
mjcarroll opened this issue Jan 25, 2022 · 2 comments
Open

CMake Flag to Skip Deprecated Tests or Functionality #204

mjcarroll opened this issue Jan 25, 2022 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@mjcarroll
Copy link
Contributor

Desired behavior

Add a CMake flag which would allow a user to skip tests of deprecated functionality, or to skip building/installing the deprecated functionality entirely.

As we continue to develop the ignition stack, there will naturally be some features that will be deprecated over time as they get relocated or overtaken by other functionality. We already have the ability to mark these via the generated Export.hh headers generated via ign-cmake.

This feature would introduce a similar concept to mark these things at the CMake level. The primary use cases I can think of:

  1. In a source-built workspace, I want to make sure that nothing downstream is depending on a deprecated feature. Rather than warning, turning off building/installing deprecated functions will cause compilation failures. This can also be helpful in catching places where a deprecation warning isn't sufficient (eg a macro or erroneously-included detail header)

  2. In a source-built workspace, I want to skip building and testing all deprecated functionality to save some cycles.

I would propose two flags:

  • SKIP_DEPRECATED_TESTS: Skip building and executing tests against deprecated functionality
  • SKIP_DEPRECATED: Skip building and testing all deprecated functionality in a library.

Note, I am proposing these flags are left OFF in CI builds so that we can guarantee that we aren't regressing. This is primarily for developer quality-of-life.

@mjcarroll mjcarroll added the enhancement New feature or request label Jan 25, 2022
@mjcarroll
Copy link
Contributor Author

An example implementation in ign-common: gazebosim/gz-common#300

@j-rivero
Copy link
Contributor

j-rivero commented Feb 2, 2022

I see value in adding this to ign-cmake, indeed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants