diff --git a/setuptools/monkey.py b/setuptools/monkey.py
index <HASH>..<HASH> 100644
--- a/setuptools/monkey.py
+++ b/setuptools/monkey.py
@@ -4,6 +4,7 @@ Monkey patching of distutils.
 
 import sys
 import distutils.filelist
+from distutils.util import get_platform
 import platform
 import types
 import functools
@@ -152,13 +153,13 @@ def patch_for_msvc_specialized_compiler():
     Patch functions in distutils to use standalone Microsoft Visual C++
     compilers.
     """
-    # import late to avoid circular imports on Python < 3.5
-    msvc = import_module('setuptools.msvc')
-
-    if platform.system() != 'Windows':
+    if not get_platform().startswith('win'):
         # Compilers only availables on Microsoft Windows
         return
 
+    # import late to avoid circular imports on Python < 3.5
+    msvc = import_module('setuptools.msvc')
+
     def patch_params(mod_name, func_name):
         """
         Prepare the parameters for patch_func to patch indicated function.
Fix exception on mingw built Python 2

The exception is caused by the VCForPython<I> monkey patch. It's not needed on mingw built Python. Disable it and avoid the import by using the same function that `distutils` uses to decide it's running on a mingw built Python.



Fixes #<I>