Currently in Qt5 there is no way how to set a path to a platform plugin in a
portable way for a deployment environment - due to restriction that platform plugin needs to be found already during creation of QApplication object.
Proposed solution is:
If someone moves the whole application structure (Mac OS bundle for example), then plugin path still would be resolved correctly.
This would require QCoreApplication::applicationDirPath() to be truly static. Currently it depends on QCoreApplication instance. Its easy to remove that requirement in applicationDirPath() and applicationFilePath() [which is called by applicationDirPath() ].
The issue is that we can't remove dependency to "self" in QCoreApplication::arguments(), which is called from applicationFilePath() (for blackberry and Q_OS_UNIX). It would be possible to make it truly static
for Mac, Win, Linux.