autoconf tip

I always dreaded having to do modifications in Makefile.in (e.g., adding a new file to the compilation) because then I’d have to nuke the build directory (you do build your project outside of the source tree, right? ;-) ) and run configure again for the Makefile to be generated and then rebuild everything again.

Well, of course this is a dumb approach to the problem, and today I just found out (almost by accident) the smarter way to do it: run the config.status script in the build directory. It will regenerate the Makefile and you can just type make from there, compiling or recompiling just what’s needed.


Leave a Reply