Unsolved Can not load my .dll file in the app that built by static-release when execute in folder
-
Hi, all
I developed an application and another my library for the former app. The library is dynamically load using QLibrary.
And everything went fine in debug(app)+debug(lib) and release+release whether if I executed the app in QT(F5) or folder .However, when I built my app as "static-release" and loaded my static-release lib(means that static for QT libs. I still want use my library as dynamic loading), the app report "Cannot load library".
Strangely This fail is ONLY when I run the app in folder, but all be fine when run in QT(F5).
I had checked the dll file is definitely exist under my app folder(using QFile::exists()), BUT the fail still reported.
Can anyone help me to solve this question? Although release+release is work for me, but I do not want to attach QT dll in the app folder.ps, I know when I configured, it would show about this :
WARNING: Using static linking will disable the use of dynamically loaded plugins.
I don't know whether if this cause my fail. Please tell me if my own library (dll) is considered as the plugin.
Thanks!
-
You should set the env var QT_DEBUG_PLUGINS to 1 and take a look at the output.
-
@Christian-Ehrlicher Thx for your reply.
I set the QT_DEBUG_PLUGINS to 1 in env
But I don't know how to get message. I used CONFIG += console, but there is no any message. Thanks.