title: CMake generated VS project expecting lib instead of dll
body: <p>Here is my minimal example of below: <a href="https://www.dropbox.com/s/7fwsr3sigb60rtw/leveling-test.zip?dl=0" rel="noreferrer">https://www.dropbox.com/s/7fwsr3sigb60rtw/leveling-test.zip?dl=0</a></p>
  
  <p>My current project folder structure and relevant CMakeLists content:</p>
  
  <pre><code>leveling
  ├── CMakeLists.txt: add_subdirectory(deps) 
  └── deps
      ├── CMakeLists.txt: add_subdirectory(xml-reading)
      └── xml-reading
          ├── CMakeLists.txt: add_subdirectory(deps)
          │                   add_library(xml-reading ...)
          │                   target_include_directories(xml-reading PUBLIC ${CMAKE_CURRENT_LIST_DIR}/deps/tinyxml2)
          │                   target_link_libraries(xml-reading PUBLIC tinyxml2)
          └── deps
              ├── CMakeLists.txt: add_subdirectory(tinyxml2)
              └── tinyxml2
  </code></pre>
  
  <p>this generates a xml-reading.dll file. </p>
  
  <p>But then the leveling project linker options have <code>/DYNAMICBASE "bin\windows-32\debug\xml-reading.lib" "bin\windows-32\debug\BOBPrimitives.lib" "bin\windows-32\debug\tinyxml2d.lib"</code></p>
  
  <p>Which yields:
  <code>2&gt;LINK : fatal error LNK1104: cannot open file 'bin\windows-32\debug\xml-reading.lib'</code></p>
  
  <p>What's up?</p>
  
  <ul>
  <li>I tried adding SHARED to <code>add_library(xml-reading SHARED ...)</code>, didn't help</li>
  <li>As a workaround I set STATIC at <code>add_library(xml-reading STATIC ...)</code> to force it to produce a .lib file - <strong>but I'd like to understand what's going on</strong></li>
  </ul>