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

open nRF connect SDK project failed.

Hello.

I am trying the SEGGER Embedded studio's open nRF connect SDK project, but it fails with an error like the one in the image.
How can I make it succeed?

SEGGER Embedded studio is installed with ToolChainManager.

Also, I found "CMakeError.log" in the build file. Is this related to something else?

Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/ncs/v1.5.1/toolchain/opt/bin/arm-none-eabi-gcc.exe 
Build flags: 
Id flags:  

The output was:
1
c:/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld.exe: c:/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.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:/ncs/v1.5.1/toolchain/opt/bin/arm-none-eabi-gcc.exe 
Build flags: 
Id flags:  

The output was:
1
c:/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld.exe: c:/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.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


Thank you.

  • Hi,

    Thank you for doing the research.

    My PC is Windows 10.
    Initially I installed SES by mistake, following the deprecated Getting Started Assistant instructions.
    Then, the build did not work, so I performed a reinstallation.
    This time, after deleting the old ncs folder, I used Toolchain Manager to install NCS v1.5.1 and SES.

    Thank you.

  • Hi,

    Have you tried installing any of the other versions of NCS to see if you get the same error?

    There might be something in your path in the system environment variables causing this. Could you check if you have Python in your path in the system environment variables, and see if removing this fixes the problem?

    You can also try completely uninstalling and removing nRF Connect for Desktop and the apps installed through there, then reinstalling it again. Make sure you also remove the "nrfconnect" and "nRF Connect" folders in AppData before reinstalling. You will most likely find them in C:/Users/<user_name>/AppData/Roaming.

    You can also install NCS manually by following this guide.

    Best regards,

    Marte

Related