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: Find package with version ranges are ignored for Zephyr SDK #80200

Closed
tejlmand opened this issue Oct 22, 2024 · 0 comments · Fixed by #80194
Closed

CMake: Find package with version ranges are ignored for Zephyr SDK #80200

tejlmand opened this issue Oct 22, 2024 · 0 comments · Fixed by #80194
Assignees
Labels
bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug

Comments

@tejlmand
Copy link
Collaborator

Describe the bug

CMake find_package() supports the use of ranges since CMake 3.19, however using version ranges together with Zephyr SDK are ignored.

For example the following line: find_package(Zephyr-sdk 0.16...<0.17) results in Zephyr SDK v0.17 being selected on a system where both Zephyr SDK 0.16.9 and 0.17.0 are installed.

Expected behavior
Zephyr SDK 0.16.9 being selected.

Impact
Unexpected Zephyr SDK selected.

Logs and console output

Environment (please complete the following information):

  • OS: Linux
  • Toolchain : Zephyr SDK 0.16.9, 0.17.0

Additional context
N/A

@tejlmand tejlmand added bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug labels Oct 22, 2024
@tejlmand tejlmand self-assigned this Oct 22, 2024
tejlmand added a commit to tejlmand/zephyr that referenced this issue Oct 22, 2024
Fixes: zephyrproject-rtos#80200

CMake `find_package(<package> <version>)` support the use of ranges,
like `1.0.0...4.0.0`.

Update the FindZephyr-sdk.cmake module to support this.
This allows looking up the Zephyr SDK with an upper boundry, for example
`find_package(Zephyr-sdk 0.16...<0.17)`.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
tejlmand added a commit to tejlmand/zephyr that referenced this issue Oct 22, 2024
Fixes: zephyrproject-rtos#80200

CMake `find_package(<package> <version>)` support the use of ranges,
like `1.0.0...4.0.0`.

Update the FindZephyr-sdk.cmake module to support this.
This allows looking up the Zephyr SDK with an upper boundry, for example
`find_package(Zephyr-sdk 0.16...<0.17)`.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
carlescufi pushed a commit that referenced this issue Oct 24, 2024
Fixes: #80200

CMake `find_package(<package> <version>)` support the use of ranges,
like `1.0.0...4.0.0`.

Update the FindZephyr-sdk.cmake module to support this.
This allows looking up the Zephyr SDK with an upper boundry, for example
`find_package(Zephyr-sdk 0.16...<0.17)`.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
pdgendt pushed a commit to pdgendt/zephyr that referenced this issue Oct 24, 2024
Fixes: zephyrproject-rtos#80200

CMake `find_package(<package> <version>)` support the use of ranges,
like `1.0.0...4.0.0`.

Update the FindZephyr-sdk.cmake module to support this.
This allows looking up the Zephyr SDK with an upper boundry, for example
`find_package(Zephyr-sdk 0.16...<0.17)`.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
henrikbrixandersen pushed a commit that referenced this issue Oct 29, 2024
Fixes: #80200

CMake `find_package(<package> <version>)` support the use of ranges,
like `1.0.0...4.0.0`.

Update the FindZephyr-sdk.cmake module to support this.
This allows looking up the Zephyr SDK with an upper boundry, for example
`find_package(Zephyr-sdk 0.16...<0.17)`.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant