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: mcuboot: Use imgtool instead of west for signing #78983

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

nordicjm
Copy link
Collaborator

modules: mcuboot: Add Kconfig for firmware updater image

Adds a Kconfig which can be selected when building for firmware
updater mode to select if this is the application or the firmware
updater image that is being built



cmake: mcuboot: Use imgtool instead of west for signing

Uses imgtool directly to sign images instead of calling west sign,
this also removes the MCUBOOT_CMAKE_WEST_SIGN_PARAMS Kconfig option
as this has no effect



doc: release: 3.4: Remove Kconfig option usage for removed Kconfig

Removes the Kconfig extension function around a Kconfig that has
been removed



scripts: west_commands: sign: Deprecate imgtool signing

Deprecates signing for imgtool using west sign



doc: release: 4.0: Add note on imgtool west sign change

Adds a note that the build system now uses imgtool directly



doc: migration: 4.0: Add notes on deprecation of imgtool west sign

Adds details on the deprecation of this feature

Fixes #78044

modules/Kconfig.mcuboot Outdated Show resolved Hide resolved
pdgendt
pdgendt previously approved these changes Sep 25, 2024
@mmahadevan108
Copy link
Collaborator

cc @butok

@butok
Copy link
Contributor

butok commented Sep 25, 2024

The Zephyr "west sign" documentation should be updated https://docs.zephyrproject.org/latest/develop/west/sign.html

@nordicjm
Copy link
Collaborator Author

The Zephyr "west sign" documentation should be updated https://docs.zephyrproject.org/latest/develop/west/sign.html

Updated

pdgendt
pdgendt previously approved these changes Sep 26, 2024
butok
butok previously approved these changes Sep 26, 2024
mmahadevan108
mmahadevan108 previously approved these changes Sep 26, 2024
@mmahadevan108
Copy link
Collaborator

@tejlmand , kindly review.

de-nordic
de-nordic previously approved these changes Sep 26, 2024
Copy link
Collaborator

@tejlmand tejlmand left a comment

Choose a reason for hiding this comment

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

some observations related to the use of devicetree CMake functions which should be addressed or replied if this is handled / guaranteed elsewhere in the build system.

Rest looks fine.

modules/Kconfig.mcuboot Show resolved Hide resolved
cmake/mcuboot.cmake Outdated Show resolved Hide resolved
cmake/mcuboot.cmake Outdated Show resolved Hide resolved
Adds a Kconfig which can be selected when building for firmware
updater mode to select if this is the application or the firmware
updater image that is being built

Signed-off-by: Jamie McCrae <[email protected]>
Uses imgtool directly to sign images instead of calling west sign,
this also removes the MCUBOOT_CMAKE_WEST_SIGN_PARAMS Kconfig option
as this has no effect

Signed-off-by: Jamie McCrae <[email protected]>
Removes the Kconfig extension function around a Kconfig that has
been removed

Signed-off-by: Jamie McCrae <[email protected]>
Fixes a compliance error

Signed-off-by: Jamie McCrae <[email protected]>
Deprecates signing for imgtool using west sign

Signed-off-by: Jamie McCrae <[email protected]>
Adds a note that the build system now uses imgtool directly

Signed-off-by: Jamie McCrae <[email protected]>
Adds details on the deprecation of this feature

Signed-off-by: Jamie McCrae <[email protected]>
Adds a signing page under build, which contains information on
how to sign images from the build system, this removes the old
details for using west sign with imgtool from the west sign page

Signed-off-by: Jamie McCrae <[email protected]>

# If single slot mode, or if in firmware updater mode and this is the firmware updater image,
# use slot 0 information
if(NOT CONFIG_MCUBOOT_BOOTLOADER_MODE_SINGLE_APP AND (NOT CONFIG_MCUBOOT_BOOTLOADER_MODE_FIRMWARE_UPDATER OR CONFIG_MCUBOOT_APPLICATION_FIRMWARE_UPDATER))
Copy link
Collaborator

Choose a reason for hiding this comment

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

minor nit, quite a long line.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RFC: Remove west sign support for imgtool
8 participants