This sets QT_QPA_PLATFORM, so has to happen before the QApplication is created. BUG: 428339 (cherry picked from commit f8f235cc)