[CMake] Cmake issue regarding conversion of existing Visual Studio .targets files to cmake

David Cole dlrdave at aol.com
Thu Aug 7 09:12:01 EDT 2014


If it works, do it.

Custom commands are the easiest way to do MIDL stuff driven by CMake if
you need things to work with any generator.

Alternatively, if you are guaranteed to be using Visual Studio
generators, you can try just adding the idl file as a source file of
the library or executable that contains it, as the VSMidl test does:
[1] -- but it may only work with source/build tree names that contain
no spaces depending on your VS version. The parent CMakeLists that
builds it arranges for this to be the case: [2]

HTH,
David C.

[1]
http://cmake.org/gitweb?p=cmake.git;a=blob;f=Tests/VSMidl/src/CMakeLists.txt;h=86c04ed9;hb=029edcdf

[2]
http://cmake.org/gitweb?p=cmake.git;a=blob;f=Tests/VSMidl/CMakeLists.txt;h=432506c3;hb=029edcdf




More information about the CMake mailing list