MCUBOOT signature key file with NCS V2.0.0

Hi, we are trying to compile our project with NCS V2.0.0. Currently we are using NCS V1.8.0. In CMakeLists.txt we have this line to pass a custom signature key file to MCUBoot:

# MCUboot: set certificate file
set(mcuboot_CONFIG_BOOT_SIGNATURE_KEY_FILE "\"${CMAKE_CURRENT_LIST_DIR}/key/airbolt-rsa-2048.pem\"")

When compiling with NCS V1.8.0 we get this output and everything works:

When compiling with NCS V2.0.0 we get this error:

Next I looked in the extra_kconfig_options.conf file that was generated for MCUBoot:

Instead of putting the string between the quotation marks it was added to the end, causing the compile error.

Is there a better way of passing the signature key fle to MCUBoot?

Parents
  • I see the same problem when trying to pass mcuboot options on the west command line using NCS v2.0.0:

     west build --pristine -b nrf52840dk_nrf52840 -- \
    -D"mcuboot_CONFIG_BOOT_SIGNATURE_KEY_FILE=\"$(shell pwd)/private.pem\"" \
    -D"CONFIG_MCUBOOT_IMAGE_VERSION=\"$(shell ./scripts/unix-time-to-version.sh)\""

    The build system errors out with an escaping error for mcuboot_CONFIG_BOOT_SIGNATURE_KEY_FILE but not for CONFIG_MCUBOOT_IMAGE_VERSION.  In this case I also see the two quotes at the end of the value, rather than the value being surrounded by one quote on each side.

    Seems like a regression?

Reply
  • I see the same problem when trying to pass mcuboot options on the west command line using NCS v2.0.0:

     west build --pristine -b nrf52840dk_nrf52840 -- \
    -D"mcuboot_CONFIG_BOOT_SIGNATURE_KEY_FILE=\"$(shell pwd)/private.pem\"" \
    -D"CONFIG_MCUBOOT_IMAGE_VERSION=\"$(shell ./scripts/unix-time-to-version.sh)\""

    The build system errors out with an escaping error for mcuboot_CONFIG_BOOT_SIGNATURE_KEY_FILE but not for CONFIG_MCUBOOT_IMAGE_VERSION.  In this case I also see the two quotes at the end of the value, rather than the value being surrounded by one quote on each side.

    Seems like a regression?

Children
Related