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

Can't build nRF Connect asset tracker

Hi all

I have an identical problem to this: https://devzone.nordicsemi.com/f/nordic-q-a/51567/can-t-build-nrf-connect-project

All my setup is the same, and the problem is exactly the same.

I've run west update after switching to tag v1.0.0

I have a mbedtls director in my ncs folder

Kind regards

Grant

Parents
  • Hello Grant,

    I am not able to reproduce this problem. Can you please provide output from your case in Segger Embedded Studio?

    Did you follow all steps

    What version of Segger Embedded Studio are you using? 

    In each subfolder of NCS, please issue the command:

    git rev-parse HEAD


    And paste the parse for each:
    mbedtls
    mcuboot
    modules
    nrf
    nrfxlib
    test
    zephyr

  • Hi Øyvind

    I'm running a clean version of Windows 10, and using SES V4.20a.

    Yes I followed all the steps using the Getting Started Assistant v1.0.1, and they all verify ok.

    I initially cloned the SDK into a path that had a space in a folder name, and that created issues when importing the project. So I deleted that whole directory (sourcecode_root) and re-cloned the SDK.

    Below are the git rev-parse results:

    mbedtls
    53546ea099f6f53d0be653a64accd250e170337f

    mcuboot
    424c716fb23234c3b0710d86dab6b2d5c64f8110

    modules
    fatal: not a git repository (or any of the parent directories): .git

    nrf
    1f3f87db7158ea553061a68782154a2dcc87ebb5

    nrfxlib
    757708d44dfc118397c7586af45e5d1ebed08509

    test
    fatal: not a git repository (or any of the parent directories): .git

    zephyr
    bd8fd7f8982a2a2b03d65e415b8de17b94fa5a9a

    From SES I initially get this JavaScript alert:

    The output in SES is:

    Loading solution asset_tracker.emProject
    Executing load commands
    cmake -GNinja -DBOARD=nrf9160_pca10090ns -DBOARD_DIR=C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090 -DZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb -DGNUARMEMB_TOOLCHAIN_PATH=C:/gnuarmemb -BC:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns -HC:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker -DEXTRA_KCONFIG_TARGETS=menuconfig_ses -DEXTRA_KCONFIG_TARGET_COMMAND_FOR_menuconfig_ses=C:/Mockingbird/arm_segger_embedded_studio_v420a_win_x64_nordic/html/configure_nordic_project_menuconfig.py
    -- Using application from 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker'
    Zephyr version: 1.14.99
    -- Selected BOARD nrf9160_pca10090ns
    -- Found west: C:/Python37/Scripts/west.exe (found suitable version "0.6.1", minimum required is "0.6.0")
    -- Cache files will be written to: C:\Users\user\AppData\Local/.cache/zephyr
    USING OUT OF TREE BOARD
    -- Loading C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090/nrf9160_pca10090ns.dts as base
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/dts/common/common.dts
    Device tree configuration written to C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/include/generated/generated_dts_board.conf
    Parsing Kconfig tree in C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/Kconfig
    Loaded configuration 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/.config'
    No change to 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/.config'
    Including module: nrf in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrf
    -- Using application from 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/samples/nrf9160/spm'
    Zephyr version: 1.14.99
    Changed board to secure nrf9160_pca10090 (NOT NS)
    USING OUT OF TREE BOARD
    -- Loading C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090/nrf9160_pca10090.dts as base
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/dts/common/common.dts
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/samples/nrf9160/spm/nrf9160_pca10090.overlay
    Device tree configuration written to C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/include/generated/generated_dts_board.conf
    Parsing Kconfig tree in C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/Kconfig
    Loaded configuration 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/.config'
    No change to 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/.config'
    Including module: nrf in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrf
    Including module: nffs in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\fs\nffs
    Including module: segger in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\debug\segger
    Including module: mcuboot in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\mcuboot\zephyr
    Including module: mcumgr in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\lib\mcumgr
    Including module: tinycbor in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\lib\tinycbor
    Including module: nrfxlib in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrfxlib
    FATAL ERROR: Unknown project name/path: mbedtls-nrf (use "west list" to list all projects)
    CMake Error at C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrfxlib/nrf_security/CMakeLists.txt:31 (message):
    Failed to find mbedtls, cannot build security libraries


    -- Configuring incomplete, errors occurred!
    See also "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeOutput.log".
    See also "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeError.log".
    Project load failed
    Reported error: solution load command failed (1)

    And I've attached the CMakeError.log and CMakeOutput.log

    Kind regards

    Grant

    The target system is: Generic - 1.14.99 - arm
    The host system is: Windows - 10.0.17134 - AMD64
    Compiling the C compiler identification source file "CMakeCCompilerId.c" succeeded.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags: -c 
    
    The output was:
    0
    
    
    Compilation of the C compiler identification source "CMakeCCompilerId.c" produced "CMakeCCompilerId.o"
    
    The C compiler identification is GNU, found in "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/3.15.2/CompilerIdC/CMakeCCompilerId.o"
    
    Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" succeeded.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags: -c 
    
    The output was:
    0
    
    
    Compilation of the CXX compiler identification source "CMakeCXXCompilerId.cpp" produced "CMakeCXXCompilerId.o"
    
    The CXX compiler identification is GNU, found in "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/3.15.2/CompilerIdCXX/CMakeCXXCompilerId.o"
    
    Checking whether the ASM compiler is GNU using "--version" matched "(GNU assembler)|(GCC)|(Free Software Foundation)":
    arm-none-eabi-gcc.exe (GNU Tools for Arm Embedded Processors 7-2018-q2-update) 7.3.1 20180622 (release) [ARM/embedded-7-branch revision 261907]
    Copyright (C) 2017 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    Performing C SOURCE FILE Test toolchain_is_ok succeeded with the following output:
    Change Dir: C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeTmp
    
    Run Build Command(s):C:/ProgramData/chocolatey/bin/ninja.exe cmTC_a53f8 && [1/2] Building C object CMakeFiles/cmTC_a53f8.dir/src.c.obj
    
    [2/2] Linking C executable cmTC_a53f8
    
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/bin/ld.exe: warning: cannot find entry symbol _start; defaulting to 00008000
    
    
    
    Source file was:
    int main(void) { return 0; }
    
    Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags:  
    
    The output was:
    1
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): In function `exit':
    exit.c:(.text.exit+0x2c): undefined reference to `_exit'
    collect2.exe: error: ld returned 1 exit status
    
    
    Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" failed.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags:  
    
    The output was:
    1
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): In function `exit':
    exit.c:(.text.exit+0x2c): undefined reference to `_exit'
    collect2.exe: error: ld returned 1 exit status
    
    
    

Reply
  • Hi Øyvind

    I'm running a clean version of Windows 10, and using SES V4.20a.

    Yes I followed all the steps using the Getting Started Assistant v1.0.1, and they all verify ok.

    I initially cloned the SDK into a path that had a space in a folder name, and that created issues when importing the project. So I deleted that whole directory (sourcecode_root) and re-cloned the SDK.

    Below are the git rev-parse results:

    mbedtls
    53546ea099f6f53d0be653a64accd250e170337f

    mcuboot
    424c716fb23234c3b0710d86dab6b2d5c64f8110

    modules
    fatal: not a git repository (or any of the parent directories): .git

    nrf
    1f3f87db7158ea553061a68782154a2dcc87ebb5

    nrfxlib
    757708d44dfc118397c7586af45e5d1ebed08509

    test
    fatal: not a git repository (or any of the parent directories): .git

    zephyr
    bd8fd7f8982a2a2b03d65e415b8de17b94fa5a9a

    From SES I initially get this JavaScript alert:

    The output in SES is:

    Loading solution asset_tracker.emProject
    Executing load commands
    cmake -GNinja -DBOARD=nrf9160_pca10090ns -DBOARD_DIR=C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090 -DZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb -DGNUARMEMB_TOOLCHAIN_PATH=C:/gnuarmemb -BC:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns -HC:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker -DEXTRA_KCONFIG_TARGETS=menuconfig_ses -DEXTRA_KCONFIG_TARGET_COMMAND_FOR_menuconfig_ses=C:/Mockingbird/arm_segger_embedded_studio_v420a_win_x64_nordic/html/configure_nordic_project_menuconfig.py
    -- Using application from 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker'
    Zephyr version: 1.14.99
    -- Selected BOARD nrf9160_pca10090ns
    -- Found west: C:/Python37/Scripts/west.exe (found suitable version "0.6.1", minimum required is "0.6.0")
    -- Cache files will be written to: C:\Users\user\AppData\Local/.cache/zephyr
    USING OUT OF TREE BOARD
    -- Loading C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090/nrf9160_pca10090ns.dts as base
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/dts/common/common.dts
    Device tree configuration written to C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/include/generated/generated_dts_board.conf
    Parsing Kconfig tree in C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/Kconfig
    Loaded configuration 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/.config'
    No change to 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/.config'
    Including module: nrf in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrf
    -- Using application from 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/samples/nrf9160/spm'
    Zephyr version: 1.14.99
    Changed board to secure nrf9160_pca10090 (NOT NS)
    USING OUT OF TREE BOARD
    -- Loading C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/boards/arm/nrf9160_pca10090/nrf9160_pca10090.dts as base
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/dts/common/common.dts
    -- Overlaying C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/samples/nrf9160/spm/nrf9160_pca10090.overlay
    Device tree configuration written to C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/include/generated/generated_dts_board.conf
    Parsing Kconfig tree in C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/zephyr/Kconfig
    Loaded configuration 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/.config'
    No change to 'C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/spm/zephyr/.config'
    Including module: nrf in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrf
    Including module: nffs in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\fs\nffs
    Including module: segger in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\debug\segger
    Including module: mcuboot in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\mcuboot\zephyr
    Including module: mcumgr in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\lib\mcumgr
    Including module: tinycbor in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\modules\lib\tinycbor
    Including module: nrfxlib in path: C:\Mockingbird\johncrisford\Nordic_sourcecode_root\ncs\nrfxlib
    FATAL ERROR: Unknown project name/path: mbedtls-nrf (use "west list" to list all projects)
    CMake Error at C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrfxlib/nrf_security/CMakeLists.txt:31 (message):
    Failed to find mbedtls, cannot build security libraries


    -- Configuring incomplete, errors occurred!
    See also "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeOutput.log".
    See also "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeError.log".
    Project load failed
    Reported error: solution load command failed (1)

    And I've attached the CMakeError.log and CMakeOutput.log

    Kind regards

    Grant

    The target system is: Generic - 1.14.99 - arm
    The host system is: Windows - 10.0.17134 - AMD64
    Compiling the C compiler identification source file "CMakeCCompilerId.c" succeeded.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags: -c 
    
    The output was:
    0
    
    
    Compilation of the C compiler identification source "CMakeCCompilerId.c" produced "CMakeCCompilerId.o"
    
    The C compiler identification is GNU, found in "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/3.15.2/CompilerIdC/CMakeCCompilerId.o"
    
    Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" succeeded.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags: -c 
    
    The output was:
    0
    
    
    Compilation of the CXX compiler identification source "CMakeCXXCompilerId.cpp" produced "CMakeCXXCompilerId.o"
    
    The CXX compiler identification is GNU, found in "C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/3.15.2/CompilerIdCXX/CMakeCXXCompilerId.o"
    
    Checking whether the ASM compiler is GNU using "--version" matched "(GNU assembler)|(GCC)|(Free Software Foundation)":
    arm-none-eabi-gcc.exe (GNU Tools for Arm Embedded Processors 7-2018-q2-update) 7.3.1 20180622 (release) [ARM/embedded-7-branch revision 261907]
    Copyright (C) 2017 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    Performing C SOURCE FILE Test toolchain_is_ok succeeded with the following output:
    Change Dir: C:/Mockingbird/johncrisford/Nordic_sourcecode_root/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/CMakeFiles/CMakeTmp
    
    Run Build Command(s):C:/ProgramData/chocolatey/bin/ninja.exe cmTC_a53f8 && [1/2] Building C object CMakeFiles/cmTC_a53f8.dir/src.c.obj
    
    [2/2] Linking C executable cmTC_a53f8
    
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/bin/ld.exe: warning: cannot find entry symbol _start; defaulting to 00008000
    
    
    
    Source file was:
    int main(void) { return 0; }
    
    Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags:  
    
    The output was:
    1
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): In function `exit':
    exit.c:(.text.exit+0x2c): undefined reference to `_exit'
    collect2.exe: error: ld returned 1 exit status
    
    
    Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" failed.
    Compiler: C:/gnuarmemb/bin/arm-none-eabi-gcc.exe 
    Build flags: 
    Id flags:  
    
    The output was:
    1
    c:/gnuarmemb/bin/../lib/gcc/arm-none-eabi/7.3.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): In function `exit':
    exit.c:(.text.exit+0x2c): undefined reference to `_exit'
    collect2.exe: error: ld returned 1 exit status
    
    
    

Children
Related