On 06/20/2015 04:10 AM, Roman Wüger wrote:
> but the problem with this command is, that for multi configuration
> environments (e.g. Visual Studio), it requires $<CONFIG> in the
> filename which then creates 4 header files. One for each configuration.

Yes, because generator expressions can reference things that depend
on the configuration.  configure_file does not support them because
its result does not depend on the configuration.  I guess I didn't
understand what you meant by "generator expressions can be used with
configure_file to avoid such overhead".

Returning to the original problem, the circular dependency may appear
because using $<TARGET_FILE_DIR:${projectName}> in a custom target
results in an ordering dependency on the target named in the
generator expression.  To confirm this, try hard-coding the path
by hand for one example.

-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