Use dynamic libraries in another dynamic libraries
-
wrote on 13 Mar 2018, 13:44 last edited by Zouyi
I am always using QDesignerCustomWidgetInteface. I want to use two kinds of CustomWidget in another CustomWidget to combine two of them so that I need not to write some codes again.
So I write codes as below in project file.
LIBS +=-L. /debug -lxzquxianplugin
LIBS +=-L./debug -lxzyctextpluginWhen I finished the code I debug the codes in creator and started debugging designer. Designer ran well and recognized my new CustomWidget. But when I entered bin/gcc/debug folder and ran executable app Designer that debug mode produced directly without codes and Qt creator, Designer showed that could not find shared library: libxzquxianplugin.so.
I tried to use codes as below.
Debug{LIBS +=absolute path way of xzquxianplugin
LIBS +=absolute path way of xzyctextplugin}
But it still failed to find dynamic library when I ran Designer in debug folders. I cannot understand why it happened. -
Hi
You seems to be on linux
if you ldd the designerplugin1 , where does it think it should get libxzquxianplugin.so.
from ? -
Hi
You seems to be on linux
if you ldd the designerplugin1 , where does it think it should get libxzquxianplugin.so.
from ?wrote on 14 Mar 2018, 08:31 last edited by -
@Zouyi Take a look at http://doc.qt.io/qt-5/linux-deployment.html
-
@Zouyi
Actually i just wanted to KNOW where it looks.
Normally, it looks for plugins in a "plugins" subdirectory inside the directory of the application executable -
@Zouyi
Actually i just wanted to KNOW where it looks.
Normally, it looks for plugins in a "plugins" subdirectory inside the directory of the application executable
5/6