QPluginLoader cannot load plugin [solved]
-
the problem solved
-
Hi
What was the problem and how did you solve it? -
the problem was that the plugin wasn't created good and the QPluginLoader wasn't recognized it as a plugin.
i returned the macro Q_OBJECT to InPluginImp class and i moved the inheritance from QOBJECT to the InPluginInterface class.
-
Ah
Please mark the topic as SOLVED
Thanks -
hi,
now i getting this error:
C:\workspace\16-5-15\src\mainProject\build-mainProject-Desktop_Qt_5_3_MinGW_32bit-Debug\VisualReceiverErrorsAnalysis\debug\moc_inpluginimp.cpp:149: error: undefined reference to `InPluginImp::InPluginImp()'and this one:
moc_inpluginimp.cpp:-1: error: undefined reference to `InPluginImp::getProcessing(myPlotInterface&, QVector<ReducingInterface*>)'collect2.exe:-1: error: error: ld returned 1 exit status
there is a solution for it?..
-
Did you properly implement both these functions ? Do you build the corresponding cpp file ?
-
yes..
-
it seems like a problem with the moc.cpp file of inpluginimp
-
when i putting down the Q_OBJECT macro from the inPluginImp class the errors gone but the again the first problem in this topic comming back
-
When adding/removing the Q_OBJECT macro, do you re-run qmake before building ?
-
yes
-
it says to me that the moc_inpluginimp.cpp file isn't found..
but the file is in the build directory of the project in the debuge directory -
@LeaA said:
#ifndef INPLUGININTERFACE_H
#define INPLUGININTERFACE_H
#pragma once
.....
.....
#endif // INPLUGININTERFACE_HT_T WTF ?
-
sorry,i didn't understand you..
-
@jalomic said:
#pragma once
#ifndef INPLUGININTERFACE_H and #pragma once - it is the same thinks.
You not need #ifndef INPLUGININTERFACE_H if you have #pragma once
Sorry for offtop -
@LeaA Try to disable "shadow build"
-
I put down some header files from the pro. file and it solved