title: "Ignoring unknown option /NODEFAULTLIB:LIBCMTD"
body: <p>Still suffering through a major compile as detailed <a href="https://stackoverflow.com/questions/11478887/unresolved-externals-nightmare">over here</a>, but I have a specific side question about the use of /NODEFAULTLIB.</p>
  
  <p>I've been trying to use this /NODEFAULTLIB:LIBCMTD switch in order to resolve a linker problem where one of the projects in the solution is using /MTd (LIBCMTD.LIB) instead of /MDd MSVCR90D.DLL.</p>
  
  <p>Unfortunately, as you can probably guess by the title of this post, I don't seem to be using this correctly.  Upon building the solution, I see this warning in three places:</p>
  
  <p><code>
  1>cl : Command line warning D9002 : ignoring unknown option '/NODEFAULTLIB:LIBCMTD'
  </code></p>
  
  <p>I'm running Visual Studio 2008 Standard SP1 on Windows XP Professional SP3.  I'm adding this switch by right-clicking on the troublesome project, selecting properties, expanding the "Configuration Properties", expanding the C/C++ list, selecting "Command Line", and entering /NODEFAULTLIB:LIBCMTD in the "Additional options" field.</p>
  
  <p>I was reading elsewhere on the web that this should be a linker setting, and not a C/C++ setting, so I've also tried entering it under Configuration Properties->Build Events->Pre-Link Event->Command Line, though this gave me warnings of its own without yielding any different results from the compile:</p>
  
  <p><code>
  1>The filename, directory name, or volume label syntax is incorrect.
  1>Project : error PRJ0019: A tool returned an error code from "Performing Pre-Link Event..."
  </code></p>
  
  <p>So folks... what about the /NODEFAULTLIB switch am I not understanding here?  How can I get VS2008 to recognize the command and stop ignoring it?</p>
  
  <p>Thanks,
  -Alex</p>