[CMake] CMAKE_CFG_INTDIR and add_custom_command with object output

James Bigler jamesbigler at gmail.com
Mon Jun 29 19:33:30 EDT 2009


I'm having a problem with Visual Studio 2005.

When I create a custom command that creates an object file, if I don't add
that object file to the source lists, then VS crashes when I close the
solution.

If I do add the object files, then VS starts to forget my object files on
the link line (restarting VS helps it remember them again).

I've discovered though some experimentation that if I modify the VS project
to use a relative path for the output file name
(C:\code\build\src\$(OutDir)\generated.obj becomes $(OutDir)\generated.obj),
then VS doesn't crash and VS doesn't forget my objects.

I'm wondering if other people have used CMAKE_CFG_INTDIR with
add_custom_command and objects and have seen similar problems.

I'm using CMake 2.6.4, VS 2005 SP 1, XP 64.

Thanks,
James
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20090629/19116e0c/attachment.htm>


More information about the CMake mailing list