-
Notifications
You must be signed in to change notification settings - Fork 58
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
Support for zenoh features #715
Support for zenoh features #715
Conversation
PR missing one of the required labels: {'bug', 'documentation', 'enhancement', 'internal', 'new feature', 'breaking-change', 'dependencies'} |
5195843
to
e62e278
Compare
- name: Run clippy | ||
run: cargo clippy --all-targets --all-features -- --deny warnings | ||
- name: Run clippy without default features | ||
run: cargo clippy --all-targets --no-default-features --features unstable,shared-memory -- --deny warnings |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if "without default features" then why unstable
and shared-memory
features are enabled?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Default features are those of zenoh, so we do not really have any code behind them - so clippy will only lint zenoh code (also --all-features does not work on windows). On the other hand we have a lot of zenoh-c code behind unstable and shared-memory features which we want to lint.
CMakeLists.txt
Outdated
if (("${cargo_flags}" MATCHES ^.*shared-memory.*$) AND NOT(ZENOHC_BUILD_WITH_SHARED_MEMORY)) | ||
set(ZENOHC_BUILD_WITH_SHARED_MEMORY TRUE) | ||
message(STATUS "Due to ZENOHC_CARGO_FLAGS setting ZENOHC_BUILD_WITH_SHARED_MEMORY = TRUE") | ||
elseif(ZENOHC_BUILD_WITH_SHARED_MEMORY) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Conditions can be simplified:
if(ZENOHC_BUILD_WITH_SHARED_MEMORY)
...
elseif("${cargo_flags}" MATCHES ^.*shared-memory.*$)
...
endif()
CMakeLists.txt
Outdated
set(cargo_flags ${cargo_flags} --features=shared-memory) | ||
endif() | ||
|
||
if(ZENOHC_BUILD_WITH_UNSTABLE_API) | ||
if (("${cargo_flags}" MATCHES ^.*unstable.*$) AND NOT(ZENOHC_BUILD_WITH_UNSTABLE_API)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See above
Support for zenoh features
Closes #626