I was wondering what the difference is between using cmake
and (compile_commands
and compile_flags
) in VSCode? I'm running into an issue where even though I've got my CMake set up correctly (builds just fine on Clion), I run into issues when trying to use the exact same code in VSCode.
I've got the offending line below
#include "palisade.h"
where palisade
is installed in "/usr/local/include/palisade"
and my CMake explicitly looks for it and finds it
find_package(Palisade)
I've also generated the file compile_commands.json
via cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=1
but I'm still running into issues of the library not being found
Probably it will helps.
In main CMakeLists.txt add line
and in c_cpp_properties.json
This will allow InteliSence to use the dependencies created by cmake.