[Cmake] Adding suffixes to debug/release builds

Bill Hoffman bill.hoffman@kitware.com
Wed, 29 Jan 2003 11:56:49 -0500


This is Partially done in CMake 1.6.  It only works for the Visual Studio 7 generator.   It is a bit tricky to implement, and that is why it has not yet been completely done.
Perhaps the next version.

-Bill


At 05:50 PM 1/29/2003 +0100, NTR wrote:
>Hi,
>
>this is a question that has been asked before, but I couldn't find the
>answer.
>
>---
>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.)...
>---
>
>I guess this could be partially solved by changing the dsp templates.
>However, it would be nice if a cross-platform solution existed so libraries
>would have consistent naming.
>
>Regards,
>Niels
>
>PS: The result could be something like for "foo" library
>foo.lib
>food.lib
>foo.dll
>food.dll
>etc.
>_______________________________________________
>Cmake mailing list
>Cmake@public.kitware.com
>http://public.kitware.com/mailman/listinfo/cmake