title: Correct way of linking crypto++ library with my application
body: <p>I am trying to use Crypto++ library in my Qt application.</p>
  
  <p>Qt version is 5.3.0 Compiled with VS2013
  running on Windows 8.1</p>
  
  <p>Crypto++ Lib compiled with VS2013</p>
  
  <p>Here is the section of my .pro file which links the lib</p>
  
  <pre><code>win32: LIBS += -L$$PWD/cryptopp562/Win32/DLL_Output/Release/ -lcryptopp
  
  INCLUDEPATH += $$PWD/cryptopp562
  DEPENDPATH += $$PWD/cryptopp562
  </code></pre>
  
  <p>Everything appears to be fine. However I get two issues.</p>
  
  <ul>
  <li><p>I am unable to compile the debug version. I assume that this is because I have release version of .lib file</p></li>
  <li><p>When I try to compile my application, I get the following errors</p></li>
  </ul>
  
  <p>crypto.obj:-1: error: LNK2019: unresolved external symbol "class std::basic_string,class std::allocator > const CryptoPP::DEFAULT_CHANNEL" (?DEFAULT_CHANNEL@CryptoPP@@3V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@B) referenced in function "public: virtual bool __thiscall CryptoPP::Unflushable::Flush(bool,int,bool)" (?Flush@?$Unflushable@VFilter@CryptoPP@@@CryptoPP@@UAE_N_NH0@Z)</p>
  
  <p>I get two such errors and I assume that this is due to two functions which calls the lib which are not getting compiled.</p>
  
  <h1>Edit</h1>
  
  <p>My observations:</p>
  
  <ul>
  <li><p>It seems like I am linking to correct static lib, i.e. libcrypt.lib and I have used dumpbin utility to ensure that the missing symbols specified by the error are there in the lib file.</p></li>
  <li><p>It appears that though I am specifying in the .pro file, some how the lib is not being referenced by the project. I have put the following line in my .pro file to reference to static lib</p>
  
  <p>win32: LIBS += -L$$PWD/cryptopp562/Win32/Output/Release/ -lcryptlib</p>
  
  <p>INCLUDEPATH += $$PWD/cryptopp562
  DEPENDPATH += $$PWD/cryptopp562</p>
  
  <p>win32:!win32-g++ PRE_TARGETDEPS += $$PWD/cryptopp562/Win32/Output/Release/cryptlib.lib
  else:win32-g++: PRE_TARGETDEPS += $$PWD/cryptopp562/Win32/Output/Release/libcryptlib.a</p></li>
  </ul>
  
  <p>My question is,</p>
  
  <p>What mistake I am making ?</p>
  
  <p>What is the correct way to link the Crypto++ lib to Qt project.</p>