On 10/07/2014 04:53 PM, Adam Strzelecki wrote:
> In meantime I've pushed stage/cmp0055-disable-ninja-side-effects
> that make CMake warn about this compatibility layer when such
> phony rules are about to be emitted.

What I've been trying to say is that this is NOT about compatibility
with broken projects.  It is a *fundamental limitation* of the current
CMake custom command specification interface (add_custom_command).
If you start requiring explicit specification of side-effects as
custom command outputs, you will make it *impossible* for project code
to specify their build rules for cases involving side-effect outputs
whose timestamps do not need to be newer than their inputs.  Non-Ninja
build systems do *not* support this.  This issue:

 Add explicit specification of custom command side effect outputs
 http://www.cmake.org/Bug/view.php?id=14963

documents a few such cases.  It explains that we need a new interface,
perhaps as an option to add_custom_command, to specify side-effect
outputs of rules.

Another possible middle-ground workaround is to generate phony rules
only for custom command dependencies that are marked with the
GENERATED property.  That would avoid the phony rule bloat and
simply require projects to explicitly mark their generated side
effects.  We still won't be able to tell Ninja which rule generates
them, but at least we could reduce the number of phony rules.
However, there is no way this will be done for 3.1 by tomorrow,
so it would be best to think about a full solution to #14963 to
start development now and target the 3.2 release.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to