[cmake-developers] Review Request: Topic ExternalProject-independent-step-targets
Brad King
brad.king at kitware.com
Wed Dec 18 11:52:00 EST 2013
On 12/16/2013 09:23 AM, Daniele E. Domenichelli wrote:
> After some tests I managed to reproduce the behaviour in this test that
> fails, both with ninja (always) and with make -j2 (only sometimes), but
> I'm no longer sure if this is a bug or not.
[snip]
> The problem seems to be that the file level dependency is not set, if
> I add:
>
> add_custom_command(APPEND
> OUTPUT ${CMAKE_BINARY_DIR}/CMakeFiles/Proj2-step-stamp
> DEPENDS Proj1)
>
> the dependency issue is fixed.
>
> So maybe this is just a bug in this CMake code and not in CMake.
> Nonetheless I think it should be possible to do something like
> add_dependencies(Proj2-step Proj1) for targets created with ExternalProjects
> without caring about file level dependencies... what do you think?
>
> Maybe adding a function
> ExternalProject_Add_Dependencies(name step targets)
> that internally calls both add_dependencies and add_custom_command(APPEND)?
Yes, I think that makes sense. Perhaps
ExternalProject_Add_Step_Dependencies
?
-Brad
More information about the cmake-developers
mailing list