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 version 3.31.0 seem to be breaking a cmake command #560

Closed
Braiio opened this issue Nov 10, 2024 · 3 comments
Closed

Cmake version 3.31.0 seem to be breaking a cmake command #560

Braiio opened this issue Nov 10, 2024 · 3 comments

Comments

@Braiio
Copy link

Braiio commented Nov 10, 2024

Hi it seems that following the publishing the new version of cmake 3.31.0, we have one of our builds depending on this package failing.
Enforcing usage of 3.30.5, causes our build to run normally.

Specifically the cmake installed is performing the command west zephyr-export which seem to be performing
west zephyr-export (after installing west package) -> which seems to be performing cmake -P on the following file:

# SPDX-License-Identifier: Apache-2.0

# Purpose of this CMake file is to install a ZephyrConfig package reference in:
# Unix/Linux/MacOS: ~/.cmake/packages/Zephyr
# Windows         : HKEY_CURRENT_USER
#
# Having ZephyrConfig package allows for find_package(Zephyr) to work when ZEPHYR_BASE is not defined.
#
# Create the reference by running `cmake -P zephyr_export.cmake` in this directory.

string(MD5 MD5_SUM ${CMAKE_CURRENT_LIST_DIR})
if(WIN32)
  execute_process(COMMAND ${CMAKE_COMMAND}
                  -E  write_regv
                 "HKEY_CURRENT_USER\\Software\\Kitware\\CMake\\Packages\\Zephyr\;${MD5_SUM}" "${CMAKE_CURRENT_LIST_DIR}"
)
else()
  file(WRITE $ENV{HOME}/.cmake/packages/Zephyr/${MD5_SUM} ${CMAKE_CURRENT_LIST_DIR})
endif()

message("Zephyr (${CMAKE_CURRENT_LIST_DIR})")
message("has been added to the user package registry in:")
if(WIN32)
  message("HKEY_CURRENT_USER\\Software\\Kitware\\CMake\\Packages\\Zephyr\n")
else()
  message("~/.cmake/packages/Zephyr\n")
endif()

file(REMOVE ${CMAKE_CURRENT_LIST_DIR}/${MD5_INFILE})

This always have worked with all the versions up to this point, but now it breaks.

Would appriciate your support,

Ariel

@Braiio Braiio changed the title Bug - Cmake version 3.31.0 Cmake version 3.31.0 seem to be breaking a cmake command Nov 10, 2024
@henryiii
Copy link
Contributor

henryiii commented Nov 11, 2024

Is this also happening with a non-wheel version of CMake 3.31.0? And what sort of error are you seeing? What operating system?

@henryiii
Copy link
Contributor

Also, is this 3.31.0, or 3.31.0.1? The first release was broken and yanked (see #557).

@Braiio
Copy link
Author

Braiio commented Nov 11, 2024

Hi, I believe I have had this tested before the new version was released.

With this new release everything works fine.

Thank you!

@Braiio Braiio closed this as completed Nov 11, 2024
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

No branches or pull requests

2 participants