title: Using DLLs Qt - Undefined Reference
body: <p>I am trying to use and make a DLL in Qt. The DLL, <strong>does not</strong> use any Qt frameworks. Here is my library's .pro file:</p>
  
  <pre><code>TARGET = MyLib
  TEMPLATE = lib
  
  include(Botan.pri)
  win32:INCLUDEPATH += "C:/botan/include"
  win32:LIBS += "C:/botan/libBotan.a"
  
  unix:INCLUDEPATH += "/usr/local/include/botan-1.10"
  unix:LIBS += "/usr/local/lib/libbotan-1.10.a"
  
  HEADERS += \
      HEADERS HERE
  
  SOURCES += \
      SOUCRES HERE
  </code></pre>
  
  <p>My library is compiled successfully, and I get a MyLib.dll in my debug/release folder. I then copied my library sources completely, and removed everything besides the header files for the 'includes' folder.</p>
  
  <p>I then created a new project to use my library.</p>
  
  <p>I added this to my project file:</p>
  
  <pre><code>INCLUDEPATH += "C:/Users/Stevie/Desktop/MyLib/include"
  LIBS += "C:/Users/Stevie/Desktop/MyLib/MyLib.dll"
  </code></pre>
  
  <p>The headers have no problem, and it finds my DLL fine (if I change it to a non-existing path, it throw an error. It doesn't as of now.)</p>
  
  <p>Now when I go into my '.cpp' file, I include my header file, and try and use my library and it throws 'undefined reference to <code>MyLib::</code>...'. I have no idea why, as I am including the DLL and I believe it should be found perfectly fine.</p>
  
  <p>Also, I am 99% sure it isn't with Botan, as I use Botan often like this, and it works fine. Anyway, I include the 'Botan.dll' with it anyway just to be sure, but it's not throwing the undefined errors on Botan.</p>
  
  <p>Thanks.</p>