title: Finding Reasons for Linking Errors in Visual Studio
body: <p>I'm in the process of porting one of my project to an existing framework I've been developing. As a result I have two project, one that's the original I developed and then the ported one. </p>
  
  <p>The problem I'm having is that the new project doesn't link. The error is <em>"... unresolved external symbol ..."</em> where the symbols should be defined in a library that's linked together with the project. By using VS command line tool <strong>dumpbin.exe</strong> I confirmed that the symbols said to be missing are in the library. The original project works fine, only by removing the library from the <em>Linker->Input->Additional Dependencies</em> do I get the same errors for that project.</p>
  
  <p>Are there other reasons for <em>"... unresolved external symbol ..."</em> or am I simply not linking the library?</p>
  
  <p><strong>Details</strong></p>
  
  <p>The library in question is <em>OpenCL.lib</em> and the errors are <i>"error LNK2019: unresolved external symbol _clBuildProgram@24 referenced in function ..."</i> for all OpenCL API calls. Using the technique described in <a href="https://stackoverflow.com/questions/488809/tools-for-inspecting-lib-files">Tools for inspecting .lib files?</a> I get the symbols for each function as one would expect.</p>