Can't find includes to build library with WP76 toolchain

Hi, I am compiling a shared library (.so) to then include in my legato application. The below is my command line. However I am getting not found error for standard C++ headers e.g. time.h stdlib.h cstring etc… I must be pointing at the wrong locations, please point me in the correct direction…

/home/legato/.leaf/wp76-toolchain_SWI9X07Y_02.37.07.00-linux64/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++ --sysroot=/home/legato/.leaf/wp76-toolchain_SWI9X07Y_02.37.07.00-linux64/sysroots/armv7a-neon-poky-linux-gnueabi/usr/bin/.debug/ -D _XPTR -D _USE_32BIT_TIME_T -g -std=c++11 -fPIC -c -x c++ /home/legato/projects/MyProject/Clock.cpp -o /home/legato/projects/MyProject/obj/arm/Debug/Clock.o

Do I have the correct locations etc? Which env variables might I have to set as well?

you should use VSCode + LEAF use Ctrl+Shift +B to compile the legato application

Thanks for the quick reply. I am having to build this from Visual Studio 2022 as I have a cross platform application. WP76 being one of the targets. So I need to use the toolchain directly to build this library.

Can you provide any suggestion as to where I am going wrong?

Thanks,
Karl

you can search in the toolchain where the header files are placed and then compile with the header file path -I

Solved the problem… by sysroot folder was wrong… that seems to have fixed it