Read the documentation section "How to Create Qt Plugins" carefully. You may be missing one of the required steps.


Making an application extensible through plugins involves the following steps:
  • Define a set of interfaces (classes with only pure virtual functions) used to talk to the plugins.
  • Use the Q_DECLARE_INTERFACE() macro to tell Qt's meta-object system about the interface.
  • Use QPluginLoader in the application to load the plugins.
  • Use qobject_cast() to test whether a plugin implements a given interface.

Writing a plugin involves these steps:
  • Declare a plugin class that inherits from QObject and from the interfaces that the plugin wants to provide.
  • Use the Q_INTERFACES() macro to tell Qt's meta-object system about the interfaces.
  • Export the plugin using the Q_EXPORT_PLUGIN2() macro.
  • Build the plugin using a suitable .pro file.

--
blog.msoares.pro.br