Important: Please read the Qt Code of Conduct -

Plug and paint example in Qt5 [SOLVED]

  • Hi friends,
    I'm using QtCreator to compile the Plug and Paint example from Qt5
    and i got this error
    /usr/bin/ld: cannot find -lpnp_basictools
    collect2: ld returned 1 exit status

    I have searched in google,they told to install the package libqt4-dev..And i have installed it,still it is showing the same error...Please help me...

  • It's not clear in the docs, but you have to open the Plug and Paint Plugins example too, and compile it.

    It's located in: QTDIR/examples/widgets/tools/plugandpaintplugins

  • thanks Mr.Guigui......Ok now i ll try it..Is it possible to run both plug and paint & plug and paint plugins..And i have found that in pro file,they have included that plug and paint plugin library file...I think that will do the process...Any way sir,i ll try your suggestion...
    How to run both at the same time

  • It is not running...I have tried it...It is asking some executable command...and i realised that plugins cant be compiled..please suggest me some other solutions.

  • You cannot run both. In Qt Creator, I simply open the "Plug and Paint" project and the "Plug and Paint Plugins" project. The "Plug and Paint Plugins" is not runnable, but is required by the other project and you must manually compile it first. It builds two plugins, a static one and a dynamic one, and copies them both in the "Plug and Paint" project in the /plugins directory. If the copy fails, it won't work. Once it's compiled, run the "Plug and Paint" project.

    What errors are you getting? Check the compile output and look for failed copy or permission errors. In the "Plug and Paint" project configuration, you can also add a dependency to the plugins project to always make it compile before the main app.

  • Thank you Mr.Guigui ...compiled successfully..

Log in to reply