How to create static library and how to include that library in our Project in nrf-Connect SDK

Hi,

can somebody help me out how to create the static library?

I am using nrf-Connect SDK and VS Code. I did'nt find any help regarding this topic.

Thanks & Regards

Thanuha

Parents Reply Children
  • Thanks a lot Sigurd. 

    now it is compiled successfully. I am little bit confused here what static lib it is taking as input and what it is generating as output static lib.

    this example given above provides the idea of creating and using static library in a single project. I am not much familiar about this cmake file keywords.

    can you please assist me how to create the static library and how to use it in 2 separate projects. what to follow the steps for creation and what to follow for using it?

    thanks & regards

    Thanuha  

  • Hi Sigurd, 

    Now I am able to create and use lib files separately in 2 projects.

    Now my next target is how can I make lib file for my Edge Impulse generated folder. its a bundle of directories and subdirectories written in C++. already I am able to compile this but my requirement is to make a static lib file from this and use and spread it to others

    can you please assist me here?

  • Thanuha said:

    Now I am able to create and use lib files separately in 2 projects.

    Great!

    Thanuha said:

    Now my next target is how can I make lib file for my Edge Impulse generated folder. its a bundle of directories and subdirectories written in C++. already I am able to compile this but my requirement is to make a static lib file from this and use and spread it to others

    can you please assist me here?

    Maybe this edge impulse lib can be useful here. See e.g. this file:

    https://github.com/nrfconnect/sdk-nrf/blob/main/lib/edge_impulse/CMakeLists.txt

Related