[CMake] Can I determine what a target is in a macro?
Stephen Kelly
steveire at gmail.com
Wed Jul 13 07:44:28 EDT 2011
David Cole wrote:
> The target property TYPE tells you what the type of the library is:
>
> http://cmake.org/cmake/help/cmake-2-8-docs.html#prop_tgt:TYPE
>
> Use:
>
> get_property(type TARGET ${SOME_TARGET} PROPERTY TYPE)
> message("type='${type}'")
>
> to retrieve the value of the TYPE property.
>
> http://cmake.org/cmake/help/cmake-2-8-docs.html#command:get_property
>
>
> HTH,
> David
Just what I was looking for, thanks.
More information about the CMake
mailing list