I'm trying to bundle up a small C++ program using automake and autotools. In my current setup, a required library is installed in a location that the configure script is able to find, but is not found when invoking g++ from make.
I can fix this by passing in the relevant -I option when calling configure (such that the proper include path is passed along to the compiler), but I'd prefer that the configure script to fail to find the library whenever make cannot find it either.
Alternatively, I'd like the configure script to generate the necessary -I commands so that the compiler finds everything it needs.
Is there some standard way to do this?
gcc -o conftest -I/usr/local/include -I/sw/include -L/usr/local /lib -L/sw/lib conftest.c -lCCfits >&5which succeeds. The relevant line from make isg++ [...irrelevant flags...] -MMD -g -O2 -MT DendroFits.o -MD -MP -MF .deps/DendroFits.Tpo -c -o DendroFits.o DendroFits.cppwhich fails withDendroFits.h:14:18: warning: CCfits: No such file or directory- ChrisBDentroFits.his unable to find the definition ofCCFits. Please check if the relevant headers have been included into this header. - Samveen