I have a config file that contains:
#include "libconfig.h++"
I have installed libconfig via homebrew and I am trying to compile my c++ program so that I can use the library but I am having trouble linking to it.
The location of the libconfig .a files is located at /usr/local/Cellar/libconfig/1.4.9/lib/
The documentation says: To link with the library, specify ‘-lconfig++’ as an argument to the linker.
So I have been trying variations on g++ config.cpp -L /usr/local/Cellar/libconfig/1.4.9/lib -lconfig++ -o out.o
But I getting the same error message:
config.cpp:4:10: fatal error: 'libconfig.h++' file not found
#include "libconfig.h++"
Can someone please explain what I am doing wrong?