[CMake] What is the VS10 .rule file generated for each ADD_CUSTOM_COMMAND?

Gabriel Petrovay gabipetrovay at gmail.com
Sat Jun 25 11:39:35 EDT 2011


Hi,

1. What is the rule file?
2. What is the logic by which this file is generated?

I have a list of src files that need to be generated, each by an
ADD_CUSTOM_COMMAND

in a FOREACH loop:

FOREACH(SRC ${SRC_LIST})

// no code here

ADD_CUSTOM_COMMAND(...)

// no code here

ENDFOREACH(SRC)


And all  BUT the first generated SRC files get a SRC.rule file in the same
build directory? Why this?

Moreover, if I look in the vcxproj file generated I see that the
<CustomBuild> is slightly different for the first SRC in the list.

The first <CustomBuild> elements (for the 1st item in SRC_LIST) has as
"Include" attribute the relative path (from the current build dir) to
the MAIN_DEPENDENCY.
The rest <CustomBuild> elements (for the rest items in SRC_LIST) have as
"Include" attribute the relative path (from the current build dir) to
the SRC.rule file.

Why is this?



-- 
MSc Gabriel Petrovay
Mobile: +41(0)787978034
www.28msec.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20110625/512d1f0c/attachment.htm>


More information about the CMake mailing list