<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:blue;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:gray;
        font-weight:bold;
        font-style:normal;
        text-decoration:none none;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=blue>
<div class=Section1>
<p class=MsoNormal style='text-autospace:none'><b><font size=2 color=gray
face=Arial><span style='font-size:10.0pt;font-family:Arial;color:gray;
font-weight:bold'>I don’t believe this is possible. There was actually a
discussion about this, simultaneous to your question, regarding x86 and x64
builds in the same solution files. The answer given was that it is not
possible, and it is better to have an x86 build tree and an x64 build tree.
There was a link given to a deeper discussion: </span></font></b><b><font
size=2 color=gray face=Consolas><span style='font-size:10.0pt;font-family:Consolas;
color:gray;font-weight:bold'><a
href="http://www.cmake.org/pipermail/cmake/2009-June/029897.html">http://www.cmake.org/pipermail/cmake/2009-June/029897.html</a></span></font></b><font
size=2 face=Consolas><span style='font-size:10.0pt;font-family:Consolas'><o:p></o:p></span></font></p>
<p class=MsoNormal><b><font size=2 color=gray face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:gray;font-weight:bold'><o:p> </o:p></span></font></b></p>
<p class=MsoNormal><b><font size=2 color=gray face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:gray;font-weight:bold'>The
thread yesterday has the subject: Generating a combined x86 and x64 Visual
Studio project<o:p></o:p></span></font></b></p>
<p class=MsoNormal><b><font size=2 color=gray face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:gray;font-weight:bold'><o:p> </o:p></span></font></b></p>
<p class=MsoNormal><b><font size=2 color=gray face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:gray;font-weight:bold'>HTH!<o:p></o:p></span></font></b></p>
<p class=MsoNormal><b><font size=2 color=gray face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:gray;font-weight:bold'><o:p> </o:p></span></font></b></p>
<div>
<div style='border:none;border-top:dotted silver 1.0pt;padding:4.0pt 0in 0in 0in'>
<p class=MsoNormal><b><font size=1 color="#666666" face=Arial><span
style='font-size:9.0pt;font-family:Arial;color:#666666;font-weight:bold'>Aaron
C. Meadows</span></span></font></b><font size=1 color="#666666" face=Arial><span
style='font-size:9.0pt;font-family:Arial;color:#666666'> </span></font><font
size=1 color="#666666" face=Arial><span style='font-size:9.0pt;font-family:
Arial;color:#666666'><o:p></o:p></span></font></p>
</div>
</div>
<div>
<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>
<hr size=2 width="100%" align=center tabindex=-1>
</span></font></div>
<p class=MsoNormal><b><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>From:</span></font></b><font size=2
face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'>
cmake-bounces@cmake.org [mailto:cmake-bounces@cmake.org] <b><span
style='font-weight:bold'>On Behalf Of </span></b>Mark Van Peteghem<br>
<b><span style='font-weight:bold'>Sent:</span></b> Thursday, July 01, 2010 2:13
AM<br>
<b><span style='font-weight:bold'>To:</span></b> cmake@cmake.org<br>
<b><span style='font-weight:bold'>Subject:</span></b> Re: [CMake] Different
configurations with Visual Studio</span></font><o:p></o:p></p>
</div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Thanks, this works. Actually<br>
<br>
if(CMAKE_CONFIGURATION_TYPES)<br>
set(CMAKE_CONFIGURATION_TYPES Debug Release DebugMX31 ReleaseMX31)<o:p></o:p></span></font></p>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> set(CMAKE_CONFIGURATION_TYPES
"${CMAKE_CONFIGURATION_TYPES}" CACHE STRING<o:p></o:p></span></font></p>
</div>
<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>
"Reset the configurations to what we need" FORCE)<br>
endif()<br>
<br>
also works for me. I've added it to the FAQ of the Wiki. But this is only half
of what need. I actually need to make this generate settings for a different
platform as well, I mean 'platform' in the Visual Studio sense, also called
'solution platform' in Visual Studios configuration manager, which is Win32 by
default, but I need it for both Win32 and MX31.<br>
<br>
Can this be done with CMake? I'm afraid not, but if it is possible, how? In the
project file it is written as something like Debug|MX31, but using that in
CMake doesn't work.<br>
<br>
Mark<o:p></o:p></span></font></p>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>2010/6/28 Michael Wild <<a href="mailto:themiwi@gmail.com">themiwi@gmail.com</a>><o:p></o:p></span></font></p>
<div>
<div>
<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'><br>
On 28. Jun, 2010, at 15:17 , Mark Van Peteghem wrote:<br>
<br>
> Hi,<br>
><br>
> I am using CMake to generate Visual Studio project files, later also for<br>
> CodeBlocks.<br>
><br>
> It seems that CMake generates four different configurations for Visual<br>
> Studio: Debug, Release, MinSizeRel and RelWithDebInfo. However, I need
other<br>
> configuations, Debug and Release, both for Win32 and MX3, in one project<br>
> file. How do I change this?<br>
><br>
> I tried this by changing *CMAKE_CONFIGURATION_TYPES *and
CMAKE_BUILD_TYPES,<br>
> e.g.<br>
><br>
> SET(CMAKE_BUILD_TYPES Debug Release DebugMX31 ReleaseMX31)<br>
><br>
> but I have the impression that these variables cannot be changed.<br>
><br>
> --<br>
> Mark<o:p></o:p></span></font></p>
</div>
</div>
<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>You have to change
CMAKE_CONFIGURATION_TYPES in the cache. Here is some template I use:<br>
<br>
# Xcode generator is buggy (linker flags are not inherited from compile flags<br>
# and custom configurations don't work with shared libraries)<br>
if(NOT CMAKE_GENERATOR STREQUAL Xcode)<br>
set(CMAKE_C_FLAGS_SUPERDUPER "--super --duper" CACHE<br>
STRING "Flags used by the compiler during super-duper builds")<br>
set(CMAKE_EXE_LINKER_FLAGS_SUPERDUPER "--super --duper" CACHE<br>
STRING "Flags used by the linker for executables during
super-duper builds")<br>
set(CMAKE_SHARED_LINKER_FLAGS_SUPERDUPER "--super --duper"
CACHE<br>
STRING "Flags used by the linker for shared libraries during
super-duper builds")<br>
set(CMAKE_MODULE_LINKER_FLAGS_SUPERDUPER "--super --duper"
CACHE<br>
STRING "Flags used by the linker for loadable modules during
super-duper builds")<br>
mark_as_advanced(CMAKE_C_FLAGS_COVERAGE CMAKE_EXE_LINKER_FLAGS_SUPERDUPER<br>
CMAKE_SHARED_LINKER_FLAGS_SUPERDUPER
CMAKE_MODULE_LINKER_FLAGS_SUPERDUPER)<br>
# This variable is only set for multi-config IDE generators<br>
if(CMAKE_CONFIGURATION_TYPES)<br>
list(APPEND CMAKE_CONFIGURATION_TYPES SuperDuper)<br>
list(REMOVE_DUPLICATES CMAKE_CONFIGURATION_TYPES)<br>
set(CMAKE_CONFIGURATION_TYPES
"${CMAKE_CONFIGURATION_TYPES}" CACHE STRING<br>
"Semicolon separated list of supported configuration
types [Debug|Release|MinSizeRel|RelWithDebInfo|SuperDuper]"<br>
FORCE)<br>
endif()<br>
endif()<br>
<br>
HTH<br>
<font color="#888888"><span style='color:#888888'><br>
Michael</span></font><o:p></o:p></span></font></p>
</div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
</div>
<br clear=all> This email was sent to you by Thomson Reuters, the global news and information company.<br>
Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Thomson Reuters.
</body>
</html>