[cmake-commits] king committed cmSystemTools.cxx 1.352 1.353
cmake-commits at cmake.org
cmake-commits at cmake.org
Sun Oct 7 16:22:18 EDT 2007
Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv1671
Modified Files:
cmSystemTools.cxx
Log Message:
COMP: Simplified include file logic. The windows.h header should be included for all compilers on windows.
Index: cmSystemTools.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmSystemTools.cxx,v
retrieving revision 1.352
retrieving revision 1.353
diff -u -d -r1.352 -r1.353
--- cmSystemTools.cxx 5 Oct 2007 19:51:01 -0000 1.352
+++ cmSystemTools.cxx 7 Oct 2007 20:22:16 -0000 1.353
@@ -18,35 +18,26 @@
#include <ctype.h>
#include <errno.h>
#include <time.h>
+#include <string.h>
#include <cmsys/RegularExpression.hxx>
#include <cmsys/Directory.hxx>
#include <cmsys/System.h>
-// support for realpath call
-#ifndef _WIN32
-#include <limits.h>
-#include <stdlib.h>
-#include <sys/param.h>
-#include <sys/wait.h>
-#endif
-
-#if defined(_WIN32) && (defined(_MSC_VER) || defined(__BORLANDC__))
-# define CM_SYSTEM_TOOLS_WINDOWS
-#include <string.h>
-#include <windows.h>
-#include <direct.h>
-#include <io.h>
-#define _unlink unlink
+#if defined(_WIN32)
+# include <windows.h>
#else
-#include <sys/types.h>
-#include <fcntl.h>
-#include <unistd.h>
-#include <utime.h>
+# include <sys/types.h>
+# include <unistd.h>
+# include <utime.h>
#endif
#include <sys/stat.h>
+#if defined(_WIN32) && (defined(_MSC_VER) || defined(__WATCOMC__) || defined(__BORLANDC__) || defined(__MINGW32__))
+# include <io.h>
+#endif
+
#if defined(CMAKE_BUILD_WITH_CMAKE)
# include <libtar/libtar.h>
# include <memory> // auto_ptr
@@ -68,7 +59,7 @@
# endif
#endif
-#ifdef CM_SYSTEM_TOOLS_WINDOWS
+#ifdef _WIN32
class cmSystemToolsWindowsHandle
{
public:
More information about the Cmake-commits
mailing list