I see, thanks. I intend to write a Python script that adds the extra platform solution, because we really need that. Visual Studio and Code::Blocks project files are XML files, so it shouldn&#39;t be too hard.<br><br><div class="gmail_quote">
2010/7/2  <span dir="ltr">&lt;<a href="mailto:aaron.meadows@thomsonreuters.com">aaron.meadows@thomsonreuters.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">










<div link="blue" vlink="blue" lang="EN-US">

<div>

<p class="MsoNormal" style=""><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; 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 color="gray" face="Consolas" size="2"><span style="font-size: 10pt; font-family: Consolas; color: gray; font-weight: bold;"><a href="http://www.cmake.org/pipermail/cmake/2009-June/029897.html" target="_blank">http://www.cmake.org/pipermail/cmake/2009-June/029897.html</a></span></font></b><font face="Consolas" size="2"><span style="font-size: 10pt; font-family: Consolas;"></span></font></p>


<p class="MsoNormal"><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: gray; font-weight: bold;"> </span></font></b></p>

<p class="MsoNormal"><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: gray; font-weight: bold;">The
thread yesterday has the subject: Generating a combined x86 and x64 Visual
Studio project</span></font></b></p>

<p class="MsoNormal"><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: gray; font-weight: bold;"> </span></font></b></p>

<p class="MsoNormal"><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: gray; font-weight: bold;">HTH!</span></font></b></p>

<p class="MsoNormal"><b><font color="gray" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: gray; font-weight: bold;"> </span></font></b></p>

<div>

<div style="border-width: 1pt medium medium; border-style: dotted none none; border-color: silver -moz-use-text-color -moz-use-text-color; padding: 4pt 0in 0in;">

<p class="MsoNormal"><b><font color="#666666" face="Arial" size="1"><span style="font-size: 9pt; font-family: Arial; color: rgb(102, 102, 102); font-weight: bold;">Aaron
C. Meadows</span></font></b><font color="#666666" face="Arial" size="1"><span style="font-size: 9pt; font-family: Arial; color: rgb(102, 102, 102);"> </span></font><font color="#666666" face="Arial" size="1"><span style="font-size: 9pt; font-family: Arial; color: rgb(102, 102, 102);"></span></font></p>


</div>

</div>

<div>

<div class="MsoNormal" style="text-align: center;" align="center"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">

<hr width="100%" align="center" size="2">

</span></font></div>

<p class="MsoNormal"><b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold;">From:</span></font></b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma;">
<a href="mailto:cmake-bounces@cmake.org" target="_blank">cmake-bounces@cmake.org</a> [mailto:<a href="mailto:cmake-bounces@cmake.org" target="_blank">cmake-bounces@cmake.org</a>] <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> <a href="mailto:cmake@cmake.org" target="_blank">cmake@cmake.org</a><br>
<b><span style="font-weight: bold;">Subject:</span></b> Re: [CMake] Different
configurations with Visual Studio</span></font></p>

</div><div><div></div><div class="h5">

<p class="MsoNormal"><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>

<p class="MsoNormal"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Thanks, this works. Actually<br>
<br>
if(CMAKE_CONFIGURATION_TYPES)<br>
   set(CMAKE_CONFIGURATION_TYPES Debug Release DebugMX31 ReleaseMX31)</span></font></p>

<div>

<p class="MsoNormal"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">   set(CMAKE_CONFIGURATION_TYPES
&quot;${CMAKE_CONFIGURATION_TYPES}&quot; CACHE STRING</span></font></p>

</div>

<p class="MsoNormal" style="margin-bottom: 12pt;"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">    
&quot;Reset the configurations to what we need&quot; FORCE)<br>
 endif()<br>
<br>
also works for me. I&#39;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 &#39;platform&#39; in the Visual Studio sense, also called
&#39;solution platform&#39; 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&#39;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&#39;t work.<br>
<br>
Mark</span></font></p>

<div>

<p class="MsoNormal"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">2010/6/28 Michael Wild &lt;<a href="mailto:themiwi@gmail.com" target="_blank">themiwi@gmail.com</a>&gt;</span></font></p>

<div>

<div>

<p class="MsoNormal" style="margin-bottom: 12pt;"><font face="Times New Roman" size="3"><span style="font-size: 12pt;"><br>
On 28. Jun, 2010, at 15:17 , Mark Van Peteghem wrote:<br>
<br>
&gt; Hi,<br>
&gt;<br>
&gt; I am using CMake to generate Visual Studio project files, later also for<br>
&gt; CodeBlocks.<br>
&gt;<br>
&gt; It seems that CMake generates four different configurations for Visual<br>
&gt; Studio: Debug, Release, MinSizeRel and RelWithDebInfo. However, I need
other<br>
&gt; configuations, Debug and Release, both for Win32 and MX3, in one project<br>
&gt; file. How do I change this?<br>
&gt;<br>
&gt; I tried this by changing *CMAKE_CONFIGURATION_TYPES *and
CMAKE_BUILD_TYPES,<br>
&gt; e.g.<br>
&gt;<br>
&gt; SET(CMAKE_BUILD_TYPES Debug Release DebugMX31 ReleaseMX31)<br>
&gt;<br>
&gt; but I have the impression that these variables cannot be changed.<br>
&gt;<br>
&gt; --<br>
&gt; Mark</span></font></p>

</div>

</div>

<p class="MsoNormal" style="margin-bottom: 12pt;"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">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&#39;t work with shared libraries)<br>
if(NOT CMAKE_GENERATOR STREQUAL Xcode)<br>
 set(CMAKE_C_FLAGS_SUPERDUPER &quot;--super --duper&quot; CACHE<br>
   STRING &quot;Flags used by the compiler during super-duper builds&quot;)<br>
 set(CMAKE_EXE_LINKER_FLAGS_SUPERDUPER &quot;--super --duper&quot; CACHE<br>
   STRING &quot;Flags used by the linker for executables during
super-duper builds&quot;)<br>
 set(CMAKE_SHARED_LINKER_FLAGS_SUPERDUPER &quot;--super --duper&quot;
CACHE<br>
   STRING &quot;Flags used by the linker for shared libraries during
super-duper builds&quot;)<br>
 set(CMAKE_MODULE_LINKER_FLAGS_SUPERDUPER &quot;--super --duper&quot;
CACHE<br>
   STRING &quot;Flags used by the linker for loadable modules during
super-duper builds&quot;)<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
&quot;${CMAKE_CONFIGURATION_TYPES}&quot; CACHE STRING<br>
     &quot;Semicolon separated list of supported configuration
types [Debug|Release|MinSizeRel|RelWithDebInfo|SuperDuper]&quot;<br>
     FORCE)<br>
 endif()<br>
endif()<br>
<br>
HTH<br>
<font color="#888888"><span style="color: rgb(136, 136, 136);"><br>
Michael</span></font></span></font></p>

</div>

<p class="MsoNormal"><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>

</div></div></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.
</div>



<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br></blockquote></div><br><br clear="all"><br>