Detect MSYS2 from Python

To detect if running under MSYS2 Python, check the parameters described in this GitHub Issue.