[CMake] CMake 2.2 dependency check skip
Ken Martin
ken.martin at kitware.com
Wed Oct 19 13:55:01 EDT 2005
> > The Makefile2 file is only at the top level. I would really like to
> > skip the dependency check when compiling one of the subdirectories
> > (e.g. ParaView/Server/Filters).
OK, I should be clearer here. There are three parts to dependency checking.
There is the check_build_system step that is done to verify that files have
not been removed or that key files have not been changed. Basically it
checks to see if cmake needs to be rerun or if dependencies need to be
regenerated. This step is skipped when doing a make from a subdirectory. The
second piece is actually computing any out of date dependencies, this cannot
be skipped currently to my knowledge. The third step is make's evaluation of
dependencies to determine what files should be recompiled. This also cannot
be skipped.
So in the end the first step is always skipped for subdirs which is a
problem if you are modifying configured files, cmakelist files, or removing
files. The third step really makes no sense to skip ever. The second step,
well I'm a big fan of having up to date dependencies so I really dig the
second step. I've seen many people have problems with their program because
they added an ivar to a header file but not all of the object files that use
it were recompiled. (bus error, bad ESP, seg fault). So that is my take and
the current state. In hindsight I almost think we should not skip the first
step even for subdirectories but I'm always open to suggestions. We can
always add all_nocheck all_nodepend targets to the subdir makefiles.
Thoughts?
Ken
More information about the CMake
mailing list