How to detect if 64 bit MSVC with cmake? : <p>I have a project which uses cmake, one target is set to only build with MSVC:</p>

<pre><code> if (MSVC)
     add_library(test SHARED source.cpp) 
 endif()
</code></pre>

<p>Now the other issue is that this target is only designed for MSVC 32bit. So how can I detect that the generator is MSVC64 and skip this target?</p>
