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

gcc/cmake with Nordic SDK?

I have everything working nicely with gcc, my own Makefiles, and the Nordic SDK12.2. I'd like to move to CMake to better automate my process (in particular, compiling one codebase for multiple boards).

The trouble is that the gcc toolchain from developer.arm.com requires a spec file. Just GCC-ing a normal .c file produces an "_exit undefined" error, so when CMake is told which toolchain to use, it tries to compile a simple .c program, fails, and says "Sorry, that's not any GCC I recognize".

Has anyone ever gotten the Nordic SDK to work with CMake? Perhaps using a different version of the GCC toolchain, or with a trickier cmake toolchain file?

Related