What is the best way to auto detect library dependencies in a C/C++ project?
问题 What is the best way to auto detect library dependencies in a C/C++ project? I have a project where I have all the dependencies on the machine. It builds and runs. Now I want to put together a autotools build system. I am looking for a good way to auto detect all the dependencies needed such as header files used and libraries needed for linking. The library bit seems to be the hardest for me to figure out. I'd like to be able to say, generate AC_CHECK_LIB commands for every function in a list