diff --git a/src/lime/tools/HXProject.hx b/src/lime/tools/HXProject.hx index 81a9d02634..52a6813f21 100644 --- a/src/lime/tools/HXProject.hx +++ b/src/lime/tools/HXProject.hx @@ -765,7 +765,7 @@ class HXProject extends Script defines.set("targetType", "cpp"); defines.set("cpp", "1"); } - else if (target == Platform.WINDOWS && targetFlags.exists("mingw")) + else if (target == Platform.WINDOWS && (targetFlags.exists("cpp") || targetFlags.exists("mingw"))) { defines.set("targetType", "cpp"); defines.set("cpp", "1"); diff --git a/tools/platforms/WindowsPlatform.hx b/tools/platforms/WindowsPlatform.hx index 9cf73d685f..a3019c0aed 100644 --- a/tools/platforms/WindowsPlatform.hx +++ b/tools/platforms/WindowsPlatform.hx @@ -580,7 +580,7 @@ class WindowsPlatform extends PlatformTarget System.copyFile(targetDirectory + "/obj/ApplicationMain" + (project.debug ? "-debug" : "") + ".exe", executablePath); - if (project.targetFlags.exists("mingw")) + if (project.defines.exists("mingw")) { var libraries = ["libwinpthread-1.dll", "libstdc++-6.dll"]; if (is64)