QPluginLoader Plugin verification data mismatch



  • I can succesfully load this plugin:

    ...
    Q_PLUGIN_METADATA(IID "com.my.api")
    ...
    

    I can't load this plugin:

    ...
    Q_PLUGIN_METADATA(IID "com.my.api" FILE "api.json")
    ...
    

    api.json contains:

    {
        "name" :            "api",
        "version" :         "1.0"
    }
    

    This code then prints Plugin verification data mismatch error:

        QPluginLoader loader("api.dll");
        qDebug() << loader.errorString(); // Plugin verification data mismatch
    

    Why and how to append my JSON data to the plugin?



  • Hi @Martin ,

    May be silly , Did you put the following line in the main export class of the plugin:

    Q_PLUGIN_METADATA(IID "com.my.api" FILE "api.json"

    Possibly check :
    Version of Qt version, the same (major and minor)version but a different Qt configuration?
    Name mangling difference by compiler.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.