[CMake] add_custom_command doesn't know about target; but get_target_property does

Nils Gladitz nilsgladitz at gmail.com
Fri Aug 22 12:49:41 EDT 2014


On 22.08.2014 18:18, Braden McDaniel wrote:
> Actually, upon closer inspection, it looks like this doesn't work because
>   $<TARGET_FILE:${EXPORT_TARGET}> won't be aware of the current configuration at CMake
>   configure-time. I'm trying to get the configuration-dependent path of the emitted library.
> (And I need to support Windows project files.)

It generates one file per configuration (see the $<CONFIG> generator 
expression at the end of the output filename)
and uses the configuration specific expansion of $<TARGET_FILE> 
respectively.

Nils


More information about the CMake mailing list