summaryrefslogtreecommitdiffstats
path: root/Source/cmExecProgramCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-06-15 13:56:52 (GMT)
committerBrad King <brad.king@kitware.com>2015-06-15 13:58:29 (GMT)
commit83af11d4112443ed732cd240eb0bfdfd27048825 (patch)
treeff429535c5b71a8761d6c9ed0c6b2027a1a3ecc1 /Source/cmExecProgramCommand.cxx
parent84672a84097444e1c280ec40d2a77f905cdb09cb (diff)
downloadCMake-83af11d4112443ed732cd240eb0bfdfd27048825.zip
CMake-83af11d4112443ed732cd240eb0bfdfd27048825.tar.gz
CMake-83af11d4112443ed732cd240eb0bfdfd27048825.tar.bz2
Fix preprocessor checks WIN32 => _WIN32
The latter is predefined by Windows toolchains and is more reliable. Reported-by: Michael Stürmer <michael.stuermer@schaeffler.com>
Diffstat (limited to 'Source/cmExecProgramCommand.cxx')
-rw-r--r--Source/cmExecProgramCommand.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/cmExecProgramCommand.cxx b/Source/cmExecProgramCommand.cxx
index e021d0b..41785c2 100644
--- a/Source/cmExecProgramCommand.cxx
+++ b/Source/cmExecProgramCommand.cxx
@@ -156,7 +156,7 @@ bool cmExecProgramCommand::RunCommand(const char* command,
verbose = false;
}
-#if defined(WIN32) && !defined(__CYGWIN__)
+#if defined(_WIN32) && !defined(__CYGWIN__)
// if the command does not start with a quote, then
// try to find the program, and if the program can not be
// found use system to run the command as it must be a built in
@@ -219,7 +219,7 @@ bool cmExecProgramCommand::RunCommand(const char* command,
return false;
}
-#if defined(WIN32) && !defined(__CYGWIN__)
+#if defined(_WIN32) && !defined(__CYGWIN__)
if(dir)
{
cmsysProcess_SetWorkingDirectory(cp, dir);
@@ -305,7 +305,7 @@ bool cmExecProgramCommand::RunCommand(const char* command,
}
if(!msg.empty())
{
-#if defined(WIN32) && !defined(__CYGWIN__)
+#if defined(_WIN32) && !defined(__CYGWIN__)
// Old Windows process execution printed this info.
msg += "\n\nfor command: ";
msg += command;