[CMake] Adding files to a project without building them
Benjamin Schindler
bschindler at inf.ethz.ch
Tue Jun 30 09:10:41 EDT 2009
Hi
I have a project which has a multitude of different files:
cu, xsd, cpp, h
I built a rather complex build system to cope with all of them, but for
Visual Studio users, this is not yet good enough: The files which are
not included in an add_executable are not visible in the Visual Studio
solution/project which is quite a pain. For header files this is no
problem because I can just add them to the executable/library, but for
xsd and other files, this is a problem as Visual Studio actually invokes
some tools on the files which it should not.
I then tried to add the files using source_group() - and this did not
work: Only files which are listed as sources in ADD_EXECUTABLE or
ADD_LIBRARY are added to the source group, the others aren't.
How can I avoid this problem?
Thanks
Benjamin Schindler
More information about the CMake
mailing list