Fix compile bug on Bash for Windows (nw)

This commit is contained in:
Brad Hughes 2016-06-29 22:40:17 -04:00
parent 6f29697a38
commit 3ffafa2225

View File

@ -246,7 +246,7 @@ function toolchain(_buildDir, _subDir)
if not os.getenv("MINGW32") then
print("Set MINGW32 envrionment variable.")
end
if not toolchainPrefix then
if toolchainPrefix == nil or toolchainPrefix == "" then
toolchainPrefix = "$(MINGW32)/bin/i686-w64-mingw32-"
end
premake.gcc.cc = toolchainPrefix .. "gcc"
@ -266,7 +266,7 @@ function toolchain(_buildDir, _subDir)
if not os.getenv("MINGW64") then
print("Set MINGW64 envrionment variable.")
end
if not toolchainPrefix then
if toolchainPrefix == nil or toolchainPrefix == "" then
toolchainPrefix = "$(MINGW64)/bin/x86_64-w64-mingw32-"
end
premake.gcc.cc = toolchainPrefix .. "gcc"