If you are using &quot;NMake Makefiles&quot; as the CMake generator, just be sure to launch cmake (or cmake-gui) from the &quot;Visual Studio x64 Cross Tools Command Prompt&quot;.... That should build x64 code for you without any special adjustments out of the box.<div>
<br></div><div>HTH,</div><div>David</div><div><br><br><div class="gmail_quote">On Tue, Aug 25, 2009 at 12:56 PM, Xiangyun Kong <span dir="ltr">&lt;<a href="mailto:xykong@yahoo.com">xykong@yahoo.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Thanks. After I use the new generator, it always looks for the 32 bit<br>
 cl.exe  at vc_root/VC/bin,<br>
and complain that the cl.exe does not work, even though I set the<br>
PATH as vc_root/VC/bin/x86_amd64.<br>
<br>
I used to use NMake Makefile, which does not complain about that.<br>
<br>
Xiangyun<br>
<br>
--- On Tue, 8/25/09, Tyler Roscoe &lt;<a href="mailto:tyler@cryptio.net">tyler@cryptio.net</a>&gt; wrote:<br>
<br>
&gt; From: Tyler Roscoe &lt;<a href="mailto:tyler@cryptio.net">tyler@cryptio.net</a>&gt;<br>
&gt; Subject: Re: [CMake] Cross-compilation related question<br>
&gt; To: &quot;Xiangyun Kong&quot; &lt;<a href="mailto:xykong@yahoo.com">xykong@yahoo.com</a>&gt;<br>
&gt; Cc: <a href="mailto:cmake@cmake.org">cmake@cmake.org</a><br>
&gt; Date: Tuesday, August 25, 2009, 1:05 AM<br>
<div><div></div><div class="h5">&gt; On Tue, Aug 25, 2009 at 12:08:10AM<br>
&gt; -0700, Xiangyun Kong wrote:<br>
&gt; &gt; I am trying to do a cross-compilation with CMake. I<br>
&gt; got a problem<br>
&gt; &gt; in creating a 64-bit shared library on a Win32<br>
&gt; platform.<br>
&gt; &gt; The problem is the CMAKE is always appending the<br>
&gt; &gt; /machine:I386 following my arch setup /machine:x64.<br>
&gt;<br>
&gt; Use the &quot;Visual Studio 200X Win64&quot; generator instead of the<br>
&gt; &quot;Visual<br>
&gt; Studio 200X&quot; generator.<br>
&gt;<br>
&gt; tyler<br>
&gt;<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>
</div></div></blockquote></div><br></div>