XCode: Real targets do not depend on ZERO_CHECK
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
ALL_BUILD is a dummy target that depends on all other targets. This is convenient for building all the targets in the project. XCode supports parallel builds, so targets that are not dependent on each other are built simultaneously.
ZERO_CHECK is a dummy target that checks if the XCode project has become invalidated due to changes to CMake files. It may regenerate the project that is currently open.
In 2.8.11.2, only ALL_BUILD depends on ZERO_CHECK. If you build another specific target, ZERO_CHECK will not execute. This means that the XCode project will not validate itself. Building a specific executable is a convenient way to start debugging it, so this is a very common use case for my colleagues.
Additionally, I am concerned that ZERO_CHECK is run in parallel with real targets. Not only is this a wasted effort if the project needs to be regenerated, but more importantly I'm concerned that if an arbitrary project fails to compile, the ZERO_CHECK task may get terminated before it finishes and I'm not sure what effect this would have on the build tree. I have not confirmed this behavior, but I have noticed irregular behavior that is only occuring with XCode projects.
-
Create an XCode project from CMake.
-
Change the target from ALL_BUILD to any real target (i.e. a library or executable).
-
Modify a CMake file used by the project. I suggest modifying the definition of the target you selected in step 2 as this is the worst case scenario.
-
Build the target (Command-B).