title: Qt Plugins: :-1: error: cannot find -lpnp_basictools
body: <p>I have been trying for days now to use third party libraries in my simple Qt projects, but to no success so far.</p>
  
  <p>I have tried the <a href="http://doc.qt.io/qt-5/qtwidgets-tools-plugandpaint-app-example.html" rel="nofollow noreferrer">Plug &amp; Paint Example</a> and the <a href="http://doc.qt.io/qt-5/qtwidgets-tools-plugandpaint-plugins-basictools-example.html" rel="nofollow noreferrer">Plug &amp; Paint Basic Tools Example</a>. The <em>tools/plugandpaint/plugins/basictools/basictools.pro</em> compiles OK, but the <em>tools/plugandpaint/app/app.pro</em> fails to compile:</p>
  
  <pre><code>:-1: error: cannot find -lpnp_basictools
  collect2.exe:-1: error: error: ld returned 1 exit status
  </code></pre>
  
  <p>I have practically copy-pasted the sources from the website to my computer. What could I be missing.</p>
  
  <p><strong>Windows 10</strong></p>
  
  <p><strong>Qt Creator 3.6.0</strong>  </p>
  
  <blockquote>
    <p><em>Based on Qt 5.5.1 (MSVC 2013, 32 bit)<br>
    Built on Dec 15 2015 01:01:38<br>
    From revision b52c2f91f5</em>  </p>
  </blockquote>
  
  <pre><code>LIBS += your_lib_path/your_lib linux：LIBS += -L your_lib_path -lyour_lib win32：LIBS += your_lib_path/your_lib LIBS += -L lib/pcsc/ -lpcsclite LIBS += lib/pcsc/libpcsclite.a 2.add headers INCLUDEPATH += your_include_path INCLUDEPATH += . /usr/local/include）
  </code></pre>
  
  <p><a href="http://doc.qt.io/qt-5/qtwidgets-tools-plugandpaint-app-example.html" rel="nofollow noreferrer">app.pro</a></p>
  
  <pre><code>TARGET = plugandpaint
  DESTDIR = ..
  
  QT += widgets
  
  HEADERS        = interfaces.h \
                   mainwindow.h \
                   paintarea.h \
                   plugindialog.h
  SOURCES        = main.cpp \
                   mainwindow.cpp \
                   paintarea.cpp \
                   plugindialog.cpp
  
  LIBS           = -L../plugins -lpnp_basictools
  
  if(!debug_and_release|build_pass):CONFIG(debug, debug|release) {
     mac:LIBS = $$member(LIBS, 0) $$member(LIBS, 1)_debug
     win32:LIBS = $$member(LIBS, 0) $$member(LIBS, 1)d
  }
  
  # install
  target.path = $$[QT_INSTALL_EXAMPLES]/widgets/tools/plugandpaint
  INSTALLS += target
  
  CONFIG += install_ok  # Do not cargo-cult this!
  </code></pre>
  
  <p><a href="http://doc.qt.io/qt-5/qtwidgets-tools-plugandpaint-plugins-basictools-example.html" rel="nofollow noreferrer">basictoolsplugin.pro</a></p>
  
  <pre><code>TEMPLATE      = lib
  CONFIG       += plugin static
  QT           += widgets
  INCLUDEPATH  += ../../app
  HEADERS       = basictoolsplugin.h
  SOURCES       = basictoolsplugin.cpp
  TARGET        = $$qtLibraryTarget(pnp_basictools)
  DESTDIR       = ../../plugins
  
  # install
  target.path = $$[QT_INSTALL_EXAMPLES]/widgets/tools/plugandpaint/plugins
  INSTALLS += target
  
  CONFIG += install_ok  # Do not cargo-cult this!
  </code></pre>