diff --git a/platformio/util.py b/platformio/util.py index 69184943..a10bfa44 100644 --- a/platformio/util.py +++ b/platformio/util.py @@ -113,12 +113,18 @@ def singleton(cls): def get_systype(): data = uname() - systype = data[0] - if "cygwin" in systype.lower(): - systype = "windows" - if data[4]: - systype += "_" + data[4] - return systype.lower() + type_ = data[0].lower() + arch = data[4].lower() if data[4] else "" + + # use native Windows binaries for Cygwin + if "cygwin" in type_: + if arch == "i686": + arch = "x86" + elif arch == "x86_64": + arch = "amd64" + type_ = "windows" + + return "%s_%s" % (type_, arch) if arch else type_ def pioversion_to_intstr():