I'm trying to compile some stuff on a new computer, which depends on some libraries I just installed. They are installed in /usr/local, and my compiler can't find the header files ("fatal error: 'GLFW/glfw3.h' file not found"), but the same compile-command works on the old computer. How can I find the default search path for the compiler, so I can reinstall the libraries there?
I believe changing the default path is complicated, and not necessarily a good idea, but maybe someone else can help you there.
I would try pkg-config, on my computer I get this:
1 2 3 4
$ pkg-config --list-all | grep glfw // figuring out if I can use pkg-config for this library
libglfw // the name of the library
$ pkg-config --cflags libglfw
-pthread
So you put that in your makefile, or whatever: cflags=$(shell pkg-config --cflags linglfw)
From the command line, put ` marks around the pkg-config command ( those aren't signle quotes ).