[Cmake] Adding "D" suffix to MSVC debug builds

Markus Meyer msmeyer at gmx.net
Fri Aug 10 16:48:32 EDT 2001


Hi,

it is good practice with libraries built with MSVC to give different builds
of the same library different filename suffixes. This eliminates the
possibility that the linker incorrectly finds and uses a wrong version of
the library. For example, the release build of the (well-known) MFC library
normally is named MFC42.DLL, but the debug build spells MFC42D.DLL.
Furthermore, the Unicode version of MFC has the name MFC42U.DLL, and the
debug build of the unicode version is named MFC42UD.DLL.

Is it possible to do this with CMake automatically? If not, would it be a
big hack to include this? (So far, I'm not familiar with the CMake source
tree.)

For some projects, other suffixes could be necessary (just imagine
graphlib_mmx.dll, graphlib_3dnow.dll, etc.)...

Please let me know what you think about it.


Thanx


Markus





More information about the CMake mailing list