This error does not occur when you double-click exe execution, and when you pass command-line arguments, the workaround:
int main(int argc, char * argv [])
{
Q_init_resource (RC);
Resolve Library path issues [email protected]
Qtextcodec *xcodec = Qtextcodec::codecforlocale ();
QString Exedir = Xcodec->tounicode (Qbytearray (argv[0]));
QString Bke_current_dir = Qfileinfo (exedir). path ();
Qstringlist Libpath;
Libpath << bke_current_dir+qstring::fromlocal8bit ("/plugins/platforms");
Libpath << bke_current_dir <<bke_current_dir+qstring::fromlocal8bit ("/plugins/imageformats");
Libpath << bke_current_dir+qstring::fromlocal8bit ("/plugins");
Libpath << qapplication::librarypaths ();
Qapplication::setlibrarypaths (LIBPATH);
//=========================
Qapplication A (argc, argv);
MainWindow W;
W.show ();
return A.exec ();
}
QT Library Connectivity Issues