I am wondering if someone could help me compile and include external library into my application. I’ve looked at the docs, but haven’t had any luck yet.
As some background, I am working on a product, and would like to share libraries across multiple applications, such as factory test app, manufacturing, board bringup, etc. I am compiling everything locally so I can make modifications to particle firmware code, and would like to keep all libraries on my local machine.
My folder structure is the following:
top_dir apps - test_project -- firmware --- test_project.cpp lib - test_lib -- test_lib --- test_lib.cpp --- test_lib.h submodules - particle_firmware
I would like to include test_lib.h in my test_project.cpp app. I’m compiling from the top directory with the command:
./po electron build apps/$APP_TO_BUILD where ./po is the po-util executable
If it helps, I’m using a modified version of po-util. I’m able to compile successfully without trying to include test.h into my program, but when compiling with #include “test.h” in my program, I get an error. I’ve tried the instructions at https://github.com/spark/firmware/blob/develop/docs/build.md#external_libs but still haven’t had any luck.
Any help figuring this out would be much appreciated!