qApp: fix flag handling in Python 3.8+ and a Python 3.9 issue
This is an old problem that was solved for Python 2.7.
From Python 3.8 on, the behavior is the same with Python 3.
The fix finally was to extend a Python 2.7 patch to Python 3
as well. See the Jira issue for details.
This patch includes also a small patch that was mentioned as
necessary for Python 3.9: Python issue 40217. I have seen no
effect of this change yet but applied the patch, anyway.
Origin: https://codereview.qt-project.org/c/pyside/pyside-setup/+/328046
Gbp-Pq: Name qApp-fix-flag-handling.patch