This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF connect SDK - broken build

Hi,
after a couple of months of inactivity I try to rebuild my Zephyr-based application under nRF Connect SDK, tag 1.3.0.
I’m dumb-founded to see this unexpected print hereunder.
What’s going on ? Is it anything I did that broke the system ?

Thank you

Gabriele


~/qi2m-dev/ncs$ west build -b qi2m_nrf5340_cpuapp -d build_fot ../apps/fot/
-- west build: generating a build system
Including boilerplate (Zephyr base): /home/gabriele/qi2m-dev/ncs/zephyr/cmake/app/boilerplate.cmake
-- Application: /home/gabriele/qi2m-dev/apps/fot
-- Zephyr version: 2.3.0-rc1 (/home/gabriele/qi2m-dev/ncs/zephyr)
-- Found Python3: /usr/bin/python3.6 (found suitable exact version "3.6.9") found components:  Interpreter
-- Board: qi2m_nrf5340_cpuapp
ZEPHYR_TOOLCHAIN_VARIANT not set, trying to locate Zephyr SDK
CMake Error at /home/gabriele/qi2m-dev/ncs/zephyr/cmake/toolchain/zephyr/host-tools.cmake:115 (message):
  The SDK version you are using is not supported, please update your SDK.
 
  You need SDK version 0.11.1 or newer.
 
  You have version(s):
 
 
 
  The SDK can be downloaded from:
 
 
  https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.11.3/zephyr-sdk-0.11.3-setup.run
 
 
  Note: If you are using SDK 0.11.1 or 0.11.2, remember to set
  ZEPHYR_SDK_INSTALL_DIR and ZEPHYR_TOOLCHAIN_VARIANT
 
Call Stack (most recent call first):
  /home/gabriele/qi2m-dev/ncs/zephyr/cmake/host-tools.cmake:3 (include)
  /home/gabriele/qi2m-dev/ncs/zephyr/cmake/app/boilerplate.cmake:485 (include)
  /home/gabriele/qi2m-dev/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
  /home/gabriele/qi2m-dev/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:35 (include_boilerplate)
  CMakeLists.txt:11 (find_package)
 
 
-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /home/gabriele/.local/bin/cmake -B/home/gabriele/qi2m-dev/ncs/build_fot -S/home/gabriele/qi2m-dev/apps/fot -GNinja -BOARD=qi2m_nrf5340_cpuapp
~/qi2m-dev/ncs$

Parents
  • Hello Marte,
    Thank you for your advice.
    Meanwhile I've decided to move NCS ahead, from 1.3.0 to 1.5.0.
    The environment variable are now OK.
    I can successfully rebuild the Hello World sample application again usign my off-tree board definition.
    Unfortunately a Kconfig issue comes when building MCUBoot as a child application.

    In main CMakeList.txt I have this:
    set(mcuboot_CONF_FILE
    ${CMAKE_CURRENT_SOURCE_DIR}/mcuboot_config_file.conf
    )

    In mcuboot_config_file.conf I have only this:
    CONFIG_MCUBOOT_LOG_LEVEL_OFF=y

    Then I run:
    $ cmake -B build -GNinja -DBOARD_ROOT="/home/gabriele/qi2m-dev/board-definition" .

    and  this is what I get

    CMake suite maintained and supported by Kitware (kitware.com/cmake).
    rm: cannot remove 'build': No such file or directory
    Including boilerplate (Zephyr base): /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake
    -- Application: /home/gabriele/qi2m-dev/apps/fot
    -- Zephyr version: 2.4.99 (/home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr)
    -- Found Python3: /usr/bin/python3.8 (found suitable exact version "3.8.5") found components: Interpreter 
    -- Found west (found suitable version "0.9.99", minimum required is "0.7.1")
    -- Board: qi2m_nrf5340_cpuapp
    -- Cache files will be written to: /home/gabriele/.cache/zephyr
    -- Found dtc: /home/gabriele/qi2m-dev/nrf53sdk/zephyr/sdk/bin/dtc (found suitable version "1.6.0", minimum required is "1.4.6")
    -- Found toolchain: gnuarmemb (/home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain)
    -- Found BOARD.dts: /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp.dts
    -- Found devicetree overlay: src/qi2m.overlay
    qi2m_nrf5340_cpuapp.dts.pre.tmp:61.42-73.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/flash-controller@39000: duplicate unit-address (also used in node /soc/peripheral@50000000/kmu@39000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:348.19-354.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/clock@5000: duplicate unit-address (also used in node /soc/peripheral@50000000/power@5000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:588.31-589.5: Warning (unique_unit_address_if_enabled): /reserved-memory/image@20000000: duplicate unit-address (also used in node /reserved-memory/image_s@20000000)
      also defined at qi2m_nrf5340_cpuapp.dts.pre.tmp:608.14-610.3
    -- Generated zephyr.dts: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/zephyr.dts
    -- Generated devicetree_unfixed.h: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/devicetree_unfixed.h
    -- Generated device_extern.h: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/device_extern.h
    Parsing /home/gabriele/qi2m-dev/apps/fot/Kconfig
    Loaded configuration '/home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp_defconfig'
    Merged configuration '/home/gabriele/qi2m-dev/apps/fot/prj.conf'
    Configuration saved to '/home/gabriele/qi2m-dev/apps/fot/build/zephyr/.config'
    Kconfig header saved to '/home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/autoconf.h'
    -- The C compiler identification is GNU 10.2.1
    -- The CXX compiler identification is GNU 10.2.1
    -- The ASM compiler identification is GNU
    -- Found assembler: /home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain/bin/arm-none-eabi-gcc
    CMake Warning at /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/CMakeLists.txt:414 (message):
      One or more dts_fixup.h files detected:
    
      -
      /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/dts_fixup.h
    
      Use of these files is deprecated; use the devicetree.h API instead.
    
    === child image mcuboot -  begin ===
    Including boilerplate (Zephyr base): /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake
    -- Application: /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr
    -- Zephyr version: 2.4.99 (/home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr)
    -- Found Python3: /usr/bin/python3.8 (found suitable exact version "3.8.5") found components: Interpreter 
    -- Found west (found suitable version "0.9.99", minimum required is "0.7.1")
    -- Board: qi2m_nrf5340_cpuapp
    -- Cache files will be written to: /home/gabriele/.cache/zephyr
    -- Found dtc: /home/gabriele/qi2m-dev/nrf53sdk/zephyr/sdk/bin/dtc (found suitable version "1.6.0", minimum required is "1.4.6")
    -- Found toolchain: gnuarmemb (/home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain)
    -- Found BOARD.dts: /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp.dts
    -- Found devicetree overlay: /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/dts.overlay
    qi2m_nrf5340_cpuapp.dts.pre.tmp:61.42-73.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/flash-controller@39000: duplicate unit-address (also used in node /soc/peripheral@50000000/kmu@39000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:348.19-354.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/clock@5000: duplicate unit-address (also used in node /soc/peripheral@50000000/power@5000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:588.31-589.5: Warning (unique_unit_address_if_enabled): /reserved-memory/image@20000000: duplicate unit-address (also used in node /reserved-memory/image_s@20000000)
      also defined at qi2m_nrf5340_cpuapp.dts.pre.tmp:608.14-610.3
    -- Generated zephyr.dts: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/zephyr.dts
    -- Generated devicetree_unfixed.h: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/include/generated/devicetree_unfixed.h
    -- Generated device_extern.h: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/include/generated/device_extern.h
    Parsing /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/Kconfig
    Loaded configuration '/home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp_defconfig'
    Merged configuration '/home/gabriele/qi2m-dev/apps/fot/mcuboot_config_file.conf'
    Merged configuration '/home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/subsys/partition_manager/partition_manager_enabled.conf'
    
    warning: The choice symbol MCUBOOT_LOG_LEVEL_OFF (defined at
    subsys/logging/Kconfig.template.log_config:8) was selected (set =y), but no symbol ended up as the
    choice selection. See
    http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_MCUBOOT_LOG_LEVEL_OFF.html and/or look
    up MCUBOOT_LOG_LEVEL_OFF in the menuconfig/guiconfig interface. The Application Development Primer,
    Setting Configuration Values, and Kconfig - Tips and Best Practices sections of the manual might be
    helpful too.
    
    
    warning: FLASH_MAP (defined at subsys/storage/flash_map/Kconfig:10) has direct dependencies FLASH_HAS_DRIVER_ENABLED with value n, but is currently being y-selected by the following symbols:
     - MCUBOOT_DEVICE_SETTINGS (defined at /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/Kconfig:563), with value y, direct dependencies y (value: y)
    
    error: Aborting due to Kconfig warnings
    
    CMake Error at /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/kconfig.cmake:262 (message):
      command failed with return code: 1
    Call Stack (most recent call first):
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake:534 (include)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:35 (include_boilerplate)
      CMakeLists.txt:44 (find_package)
    
    -- Configuring incomplete, errors occurred!
    CMake Error at /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/cmake/multi_image.cmake:287 (message):
      CMake generation for mcuboot failed, aborting.  Command: 1
    Call Stack (most recent call first):
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/cmake/multi_image.cmake:84 (add_child_image_from_source)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/modules/mcuboot/CMakeLists.txt:112 (add_child_image)
    
    -- Configuring incomplete, errors occurred!
    See also "/home/gabriele/qi2m-dev/apps/fot/build/CMakeFiles/CMakeOutput.log".

Reply
  • Hello Marte,
    Thank you for your advice.
    Meanwhile I've decided to move NCS ahead, from 1.3.0 to 1.5.0.
    The environment variable are now OK.
    I can successfully rebuild the Hello World sample application again usign my off-tree board definition.
    Unfortunately a Kconfig issue comes when building MCUBoot as a child application.

    In main CMakeList.txt I have this:
    set(mcuboot_CONF_FILE
    ${CMAKE_CURRENT_SOURCE_DIR}/mcuboot_config_file.conf
    )

    In mcuboot_config_file.conf I have only this:
    CONFIG_MCUBOOT_LOG_LEVEL_OFF=y

    Then I run:
    $ cmake -B build -GNinja -DBOARD_ROOT="/home/gabriele/qi2m-dev/board-definition" .

    and  this is what I get

    CMake suite maintained and supported by Kitware (kitware.com/cmake).
    rm: cannot remove 'build': No such file or directory
    Including boilerplate (Zephyr base): /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake
    -- Application: /home/gabriele/qi2m-dev/apps/fot
    -- Zephyr version: 2.4.99 (/home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr)
    -- Found Python3: /usr/bin/python3.8 (found suitable exact version "3.8.5") found components: Interpreter 
    -- Found west (found suitable version "0.9.99", minimum required is "0.7.1")
    -- Board: qi2m_nrf5340_cpuapp
    -- Cache files will be written to: /home/gabriele/.cache/zephyr
    -- Found dtc: /home/gabriele/qi2m-dev/nrf53sdk/zephyr/sdk/bin/dtc (found suitable version "1.6.0", minimum required is "1.4.6")
    -- Found toolchain: gnuarmemb (/home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain)
    -- Found BOARD.dts: /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp.dts
    -- Found devicetree overlay: src/qi2m.overlay
    qi2m_nrf5340_cpuapp.dts.pre.tmp:61.42-73.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/flash-controller@39000: duplicate unit-address (also used in node /soc/peripheral@50000000/kmu@39000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:348.19-354.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/clock@5000: duplicate unit-address (also used in node /soc/peripheral@50000000/power@5000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:588.31-589.5: Warning (unique_unit_address_if_enabled): /reserved-memory/image@20000000: duplicate unit-address (also used in node /reserved-memory/image_s@20000000)
      also defined at qi2m_nrf5340_cpuapp.dts.pre.tmp:608.14-610.3
    -- Generated zephyr.dts: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/zephyr.dts
    -- Generated devicetree_unfixed.h: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/devicetree_unfixed.h
    -- Generated device_extern.h: /home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/device_extern.h
    Parsing /home/gabriele/qi2m-dev/apps/fot/Kconfig
    Loaded configuration '/home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp_defconfig'
    Merged configuration '/home/gabriele/qi2m-dev/apps/fot/prj.conf'
    Configuration saved to '/home/gabriele/qi2m-dev/apps/fot/build/zephyr/.config'
    Kconfig header saved to '/home/gabriele/qi2m-dev/apps/fot/build/zephyr/include/generated/autoconf.h'
    -- The C compiler identification is GNU 10.2.1
    -- The CXX compiler identification is GNU 10.2.1
    -- The ASM compiler identification is GNU
    -- Found assembler: /home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain/bin/arm-none-eabi-gcc
    CMake Warning at /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/CMakeLists.txt:414 (message):
      One or more dts_fixup.h files detected:
    
      -
      /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/dts_fixup.h
    
      Use of these files is deprecated; use the devicetree.h API instead.
    
    === child image mcuboot -  begin ===
    Including boilerplate (Zephyr base): /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake
    -- Application: /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr
    -- Zephyr version: 2.4.99 (/home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr)
    -- Found Python3: /usr/bin/python3.8 (found suitable exact version "3.8.5") found components: Interpreter 
    -- Found west (found suitable version "0.9.99", minimum required is "0.7.1")
    -- Board: qi2m_nrf5340_cpuapp
    -- Cache files will be written to: /home/gabriele/.cache/zephyr
    -- Found dtc: /home/gabriele/qi2m-dev/nrf53sdk/zephyr/sdk/bin/dtc (found suitable version "1.6.0", minimum required is "1.4.6")
    -- Found toolchain: gnuarmemb (/home/gabriele/qi2m-dev/nrf53sdk/sdk/gnu-arm-emb-toolchain)
    -- Found BOARD.dts: /home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp.dts
    -- Found devicetree overlay: /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/dts.overlay
    qi2m_nrf5340_cpuapp.dts.pre.tmp:61.42-73.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/flash-controller@39000: duplicate unit-address (also used in node /soc/peripheral@50000000/kmu@39000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:348.19-354.3: Warning (unique_unit_address_if_enabled): /soc/peripheral@50000000/clock@5000: duplicate unit-address (also used in node /soc/peripheral@50000000/power@5000)
    qi2m_nrf5340_cpuapp.dts.pre.tmp:588.31-589.5: Warning (unique_unit_address_if_enabled): /reserved-memory/image@20000000: duplicate unit-address (also used in node /reserved-memory/image_s@20000000)
      also defined at qi2m_nrf5340_cpuapp.dts.pre.tmp:608.14-610.3
    -- Generated zephyr.dts: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/zephyr.dts
    -- Generated devicetree_unfixed.h: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/include/generated/devicetree_unfixed.h
    -- Generated device_extern.h: /home/gabriele/qi2m-dev/apps/fot/build/mcuboot/zephyr/include/generated/device_extern.h
    Parsing /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/Kconfig
    Loaded configuration '/home/gabriele/qi2m-dev/board-definition/boards/arm/qi2m_nrf5340/qi2m_nrf5340_cpuapp_defconfig'
    Merged configuration '/home/gabriele/qi2m-dev/apps/fot/mcuboot_config_file.conf'
    Merged configuration '/home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/subsys/partition_manager/partition_manager_enabled.conf'
    
    warning: The choice symbol MCUBOOT_LOG_LEVEL_OFF (defined at
    subsys/logging/Kconfig.template.log_config:8) was selected (set =y), but no symbol ended up as the
    choice selection. See
    http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_MCUBOOT_LOG_LEVEL_OFF.html and/or look
    up MCUBOOT_LOG_LEVEL_OFF in the menuconfig/guiconfig interface. The Application Development Primer,
    Setting Configuration Values, and Kconfig - Tips and Best Practices sections of the manual might be
    helpful too.
    
    
    warning: FLASH_MAP (defined at subsys/storage/flash_map/Kconfig:10) has direct dependencies FLASH_HAS_DRIVER_ENABLED with value n, but is currently being y-selected by the following symbols:
     - MCUBOOT_DEVICE_SETTINGS (defined at /home/gabriele/qi2m-dev/nrf53sdk/ncs/bootloader/mcuboot/boot/zephyr/Kconfig:563), with value y, direct dependencies y (value: y)
    
    error: Aborting due to Kconfig warnings
    
    CMake Error at /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/kconfig.cmake:262 (message):
      command failed with return code: 1
    Call Stack (most recent call first):
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/cmake/app/boilerplate.cmake:534 (include)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:35 (include_boilerplate)
      CMakeLists.txt:44 (find_package)
    
    -- Configuring incomplete, errors occurred!
    CMake Error at /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/cmake/multi_image.cmake:287 (message):
      CMake generation for mcuboot failed, aborting.  Command: 1
    Call Stack (most recent call first):
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/cmake/multi_image.cmake:84 (add_child_image_from_source)
      /home/gabriele/qi2m-dev/nrf53sdk/ncs/nrf/modules/mcuboot/CMakeLists.txt:112 (add_child_image)
    
    -- Configuring incomplete, errors occurred!
    See also "/home/gabriele/qi2m-dev/apps/fot/build/CMakeFiles/CMakeOutput.log".

Children
Related