title: MSBUILD / csc: Cleanest way of handling x64 mscorlib warning 1607
body: <p>I'm trying to use VS08SP1's default project system to invoke a C# compile in explicit x64 mode (as distinct from <code>AnyCpu</code>).  When I explicitly mark a module as x64, I get a:</p>
  
  <blockquote>
    <p>warning CS1607: Assembly generation -- Referenced assembly 'mscorlib.dll' targets a different processor</p>
  </blockquote>
  
  <p>One way of removing that is with a <code>/nowarn:1607</code>.  <a href="http://www.google.com/search?q=warning+CS1607%3A+Assembly+generation+--+Referenced+assembly+%27mscorlib.dll%27+targets+a+different+processor&amp;sourceid=ie7&amp;rls=com.microsoft:en-ie:IE-SearchBox&amp;ie=&amp;oe=" rel="noreferrer">Based on my research</a>, there are no problems in practice with doing this.  If anyone can hilight a real-world issue they've encountered, please feel free to answer.</p>
  
  <p>However, this just feels wrong! So another approach I used was to do <code>/nostdlib+</code>, and then add a <code>&lt;Reference&gt;</code> with a hardcoded <code>&lt;HintPath&gt;</code> to the explicitly 64 bit mscorlib:</p>
  
  <pre><code>&lt;Reference Include="mscorlib"&gt;
    &lt;HintPath&gt;$(windir)\Microsoft.NET\Framework64\v2.0.50727\mscorlib.dll&lt;/HintPath&gt;
  &lt;/Reference&gt;
  </code></pre>
  
  <p>This works and is probably better (unless anyone cares to point out reasons why the previous approach is better), but can someone confirm this is an appropriate thing to do, hopefully citing something authorative?</p>