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

external_lib not compiling out of the box

I am trying to get external_lib example application to compile for NRF5340pdk. I am using nRF Connect SDK v1.4.1 and picked the example provided in zepher/samples/application_development/external_lib. The code does not compile and does not seem to give any obvious errors. I am using a windows 10 PC for development. Do I need to do something more to get it to compile and run?

Parents
  • Thanks Vidar. I am using NCS 1.4.0, I get the following error:


    [6/144] Performing build step for 'mylib_project'
    FAILED: mylib/src/mylib_project-stamp/mylib_project-build mylib/lib/libmylib.a
    cmd.exe /C "cd /D C:\Users\ahebbar539\ncs\v1.4.1\zephyr\samples\application_development\external_lib\mylib && make PREFIX

    For some reason, it looks like the Makefile command:

    mkdir -p ./obj ./lib
    The syntax of the command is incorrect 

    could be the problem. I got the above when I run the make command. 

  • Thanks, your log pointed me in the right direction. Turns out the mkdir executable included with the ncs toolchain (in v1.4.1\toolchain\usr\bin\) does not support any of the option arguments for some reason (i.e. -p, -m, --help), which I have reported now. The reason I didn't get the error was that I already had a working version of mkdir installed on my system ( from this package) in addition to the one in the NCS toolchain.

    Please try to replace executable in v1.4.1\toolchain\usr\bin\ with one that works.

Reply
  • Thanks, your log pointed me in the right direction. Turns out the mkdir executable included with the ncs toolchain (in v1.4.1\toolchain\usr\bin\) does not support any of the option arguments for some reason (i.e. -p, -m, --help), which I have reported now. The reason I didn't get the error was that I already had a working version of mkdir installed on my system ( from this package) in addition to the one in the NCS toolchain.

    Please try to replace executable in v1.4.1\toolchain\usr\bin\ with one that works.

Children
No Data
Related