[cmake-developers] Review Request: Topic ExternalProject_exclude-from-all
Brad King
brad.king at kitware.com
Thu Mar 27 11:53:07 EDT 2014
On 03/27/2014 11:34 AM, Brad King wrote:
> A simpler way to look for the argument:
>
> if(";${ARGN};" MATCHES ";EXCLUDE_FROM_ALL;([^;]*);")
> # ... test CMAKE_MATCH_1
> endif()
Actually you don't need to parse the arg ahead of time.
The "ALL" option to add_custom_target just tells it to
*not* set the EXCLUDE_FROM_ALL target property. Instead
you can leave out "ALL", parse the args as normal, and
then add
set_property(TARGET ... PROPERTY EXCLUDE_FROM_ALL FALSE)
when the EXCLUDE_FROM_ALL option is not set.
-Brad
More information about the cmake-developers
mailing list