diff --git a/Common/Core/vtkConfigure.h.in b/Common/Core/vtkConfigure.h.in index 7358c459d77..41533daeb7f 100644 --- a/Common/Core/vtkConfigure.h.in +++ b/Common/Core/vtkConfigure.h.in @@ -73,7 +73,7 @@ /* Atomic operations */ #cmakedefine VTK_HAVE_SYNC_BUILTINS -#if defined(WIN32) +#if defined(_WIN32) #cmakedefine VTK_HAS_INTERLOCKEDADD #endif diff --git a/Common/Core/vtkWin32Header.h b/Common/Core/vtkWin32Header.h index b3dc5b79f54..b4e40d0bc80 100644 --- a/Common/Core/vtkWin32Header.h +++ b/Common/Core/vtkWin32Header.h @@ -45,7 +45,7 @@ Do_not_include_vtkWin32Header_directly__vtkSystemIncludes_includes_it; // // Windows specific stuff------------------------------------------ -#if defined(_WIN32) || defined(WIN32) +#if defined(_WIN32) // define strict header for windows #ifndef STRICT diff --git a/Common/System/Testing/Cxx/otherTimerLog.cxx b/Common/System/Testing/Cxx/otherTimerLog.cxx index fc81994a098..571703bbfff 100644 --- a/Common/System/Testing/Cxx/otherTimerLog.cxx +++ b/Common/System/Testing/Cxx/otherTimerLog.cxx @@ -48,7 +48,7 @@ void otherTimerLogTest(ostream& strm) { a *= a; } -#ifndef WIN32 +#ifndef _WIN32 sleep (1); #else Sleep(1000); diff --git a/Filters/FlowPaths/vtkParticleTracerBase.cxx b/Filters/FlowPaths/vtkParticleTracerBase.cxx index f1b96a7187c..926c2c815cc 100644 --- a/Filters/FlowPaths/vtkParticleTracerBase.cxx +++ b/Filters/FlowPaths/vtkParticleTracerBase.cxx @@ -133,7 +133,7 @@ vtkParticleTracerBase::vtkParticleTracerBase() this->SetNumberOfInputPorts(2); #ifdef JB_H5PART_PARTICLE_OUTPUT -#ifdef WIN32 +#ifdef _WIN32 vtkDebugMacro(<<"Setting vtkH5PartWriter"); vtkH5PartWriter *writer = vtkH5PartWriter::New(); #else diff --git a/Filters/FlowPaths/vtkTemporalStreamTracer.cxx b/Filters/FlowPaths/vtkTemporalStreamTracer.cxx index 2b6873fd369..fb194a57c09 100644 --- a/Filters/FlowPaths/vtkTemporalStreamTracer.cxx +++ b/Filters/FlowPaths/vtkTemporalStreamTracer.cxx @@ -46,7 +46,7 @@ PURPOSE. See the above copyright notice for more information. #include "vtkToolkits.h" // For VTK_USE_MPI #include -#ifdef WIN32 +#ifdef _WIN32 #undef JB_H5PART_PARTICLE_OUTPUT #else // #define JB_H5PART_PARTICLE_OUTPUT @@ -66,7 +66,7 @@ using namespace vtkTemporalStreamTracerNamespace; //---------------------------------------------------------------------------- //#define JB_DEBUG__ #if defined JB_DEBUG__ - #ifdef WIN32 + #ifdef _WIN32 #define OUTPUTTEXT(a) vtkOutputWindowDisplayText(a); #else #endif @@ -132,7 +132,7 @@ vtkTemporalStreamTracer::vtkTemporalStreamTracer() this->SetNumberOfInputPorts(2); #ifdef JB_H5PART_PARTICLE_OUTPUT -#ifdef WIN32 +#ifdef _WIN32 vtkDebugMacro(<<"Setting vtkH5PartWriter"); vtkH5PartWriter *writer = vtkH5PartWriter::New(); #else diff --git a/Filters/StatisticsGnuR/vtkRInterface.cxx b/Filters/StatisticsGnuR/vtkRInterface.cxx index dfc19368bc0..193b0b09777 100644 --- a/Filters/StatisticsGnuR/vtkRInterface.cxx +++ b/Filters/StatisticsGnuR/vtkRInterface.cxx @@ -41,7 +41,7 @@ vtkStandardNewMacro(vtkRInterface); #include "Rversion.h" #include "Rdefines.h" -#ifndef WIN32 +#ifndef _WIN32 #define CSTACK_DEFNS #define R_INTERFACE_PTRS #include "Rinterface.h" @@ -75,7 +75,7 @@ class vtkImplementationRSingleton return; } -#ifndef WIN32 +#ifndef _WIN32 R_SignalHandlers = 0; #endif @@ -97,7 +97,7 @@ class vtkImplementationRSingleton R_CStackLimit = (uintptr_t)-1; #endif - #ifndef WIN32 + #ifndef _WIN32 R_Interactive = static_cast(TRUE); #endif setup_Rmainloop(); @@ -112,7 +112,7 @@ class vtkImplementationRSingleton rcommand.append("f<-file(paste(tempdir(), \"/Routput.txt\", sep = \"\"), open=\"wt+\")\nsink(f)\n"); this->tmpFilePath.clear(); this->tmpFilePath.append(R_TempDir); -#ifdef WIN32 +#ifdef _WIN32 this->tmpFilePath.append("\\Routput.txt"); #else this->tmpFilePath.append("/Routput.txt"); diff --git a/IO/Image/Testing/Cxx/TestTIFFReaderMultiple.cxx b/IO/Image/Testing/Cxx/TestTIFFReaderMultiple.cxx index 25f5487af57..ba00c7659eb 100644 --- a/IO/Image/Testing/Cxx/TestTIFFReaderMultiple.cxx +++ b/IO/Image/Testing/Cxx/TestTIFFReaderMultiple.cxx @@ -16,7 +16,7 @@ #include #include "vtkTestErrorObserver.h" -#ifndef WIN32 +#ifndef _WIN32 #include #endif @@ -28,7 +28,7 @@ int TestTIFFReaderMultiple(int argc, char *argv[]) return EXIT_FAILURE; } -#ifndef WIN32 +#ifndef _WIN32 // See how many file descriptors are in use int fdUsedBefore = 1; for (int i = 0; i < 1024; ++i) @@ -62,7 +62,7 @@ int TestTIFFReaderMultiple(int argc, char *argv[]) errorObserver->Clear(); } -#ifndef WIN32 +#ifndef _WIN32 // See how many file descriptors are in use int fdUsedAfter = 1; for (int i = 0; i < 1024; ++i) diff --git a/IO/Import/vtkVRMLImporter_Yacc.h b/IO/Import/vtkVRMLImporter_Yacc.h index f227d7d9866..2f46b905c5b 100644 --- a/IO/Import/vtkVRMLImporter_Yacc.h +++ b/IO/Import/vtkVRMLImporter_Yacc.h @@ -1702,7 +1702,7 @@ void vtkVRMLYaccData::expect(int type) #define FLEX_SCANNER -#ifdef WIN32 +#ifdef _WIN32 #include #else #include diff --git a/IO/LSDyna/private/LSDynaFamily.cxx b/IO/LSDyna/private/LSDynaFamily.cxx index 19bf9db4464..3dcb31c7143 100644 --- a/IO/LSDyna/private/LSDynaFamily.cxx +++ b/IO/LSDyna/private/LSDynaFamily.cxx @@ -36,7 +36,7 @@ namespace // Usually stat uses 32 bit fields, and stat64 (with underscores in Windows) uses 64 bit fields. // But on OS X and FreeBSD, stat uses 64 bit fields these days. #if (VTK_SIZEOF_ID_TYPE == 8) && !defined(_DARWIN_FEATURE_64_BIT_INODE) && !defined(__FreeBSD__) - #ifndef WIN32 + #ifndef _WIN32 #define USE_STAT_64 #else #define USE_WIN_STAT_64 @@ -64,7 +64,7 @@ namespace vtkLSDynaFile_t VTK_LSDYNA_OPENFILE(const char* fname) { -#ifndef WIN32 +#ifndef _WIN32 vtkLSDynaFile_t f = open(fname, O_RDONLY); return f; #else diff --git a/IO/LSDyna/private/LSDynaFamily.h b/IO/LSDyna/private/LSDynaFamily.h index 96c396a9c28..1cd99b90d19 100644 --- a/IO/LSDyna/private/LSDynaFamily.h +++ b/IO/LSDyna/private/LSDynaFamily.h @@ -42,7 +42,7 @@ //this is needs to be moved over to fseekpos and ftellpos //in the future -#ifndef WIN32 +#ifndef _WIN32 # include typedef off_t vtkLSDynaOff_t; // sanity typedef int vtkLSDynaFile_t; @@ -53,7 +53,7 @@ typedef int vtkLSDynaFile_t; # define VTK_LSDYNA_READ(fid,ptr,cnt) read(fid,ptr,cnt) # define VTK_LSDYNA_ISBADFILE(fid) (fid < 0) # define VTK_LSDYNA_CLOSEFILE(fid) close(fid) -#else // WIN32 +#else // _WIN32 typedef long vtkLSDynaOff_t; // insanity typedef FILE* vtkLSDynaFile_t; # define VTK_LSDYNA_BADFILE 0 diff --git a/IO/LSDyna/vtkLSDynaReader.cxx b/IO/LSDyna/vtkLSDynaReader.cxx index cf6104325fe..5067ebac72f 100644 --- a/IO/LSDyna/vtkLSDynaReader.cxx +++ b/IO/LSDyna/vtkLSDynaReader.cxx @@ -152,7 +152,7 @@ static const char* vtkLSDynaCellTypes[] = static void vtkLSGetLine( ifstream& deck, std::string& line ) { -#if !defined(_WIN32) && !defined(WIN32) && !defined(_MSC_VER) && !defined(__BORLANDC__) +#if !defined(_WIN32) && !defined(_MSC_VER) && !defined(__BORLANDC__) // One line implementation for everyone but Windows (MSVC6 and BCC32 are the troublemakers): std::getline( deck, line, '\n' ); #else @@ -3424,11 +3424,11 @@ int vtkLSDynaReader::ReadInputDeckKeywords( ifstream& deck ) { deckExt = ""; } -#ifndef WIN32 +#ifndef _WIN32 xmlSummary = deckDir + "/" + deckName + ".lsdyna"; #else xmlSummary = deckDir + "\\" + deckName + ".lsdyna"; -#endif // WIN32 +#endif // _WIN32 // As long as we don't kill the input deck, write the summary XML: if ( xmlSummary != this->InputDeck ) { @@ -3460,11 +3460,11 @@ int vtkLSDynaReader::WriteInputDeckSummary( const char* fname ) std::string dbName = this->P->Fam.GetDatabaseBaseName(); if ( this->IsDatabaseValid() && ! dbDir.empty() && ! dbName.empty() ) { -#ifndef WIN32 +#ifndef _WIN32 if ( dbDir[0] == '/' ) #else if ( dbDir[0] == '\\' ) -#endif // WIN32 +#endif // _WIN32 { // OK, we have an absolute path, so it should be safe to write it out. xmlSummary diff --git a/IO/MySQL/vtkMySQLQuery.cxx b/IO/MySQL/vtkMySQLQuery.cxx index a97b5891dfc..b4e6b62a454 100644 --- a/IO/MySQL/vtkMySQLQuery.cxx +++ b/IO/MySQL/vtkMySQLQuery.cxx @@ -25,7 +25,7 @@ #include -#if defined(WIN32) +#if defined(_WIN32) # include # include # define LOWERCASE_COMPARE _stricmp diff --git a/Interaction/Style/vtkInteractorStyleUnicam.cxx b/Interaction/Style/vtkInteractorStyleUnicam.cxx index 458a0afd2c0..b3617155a68 100644 --- a/Interaction/Style/vtkInteractorStyleUnicam.cxx +++ b/Interaction/Style/vtkInteractorStyleUnicam.cxx @@ -39,7 +39,7 @@ vtkStandardNewMacro(vtkInteractorStyleUnicam); // define 'TheTime()' function-- returns time in elapsed seconds -#if defined(_WIN32) || defined(WIN32) +#if defined(_WIN32) # include "vtkWindows.h" static double TheTime() diff --git a/Rendering/OpenGL/vtkOpenGLExtensionManager.cxx b/Rendering/OpenGL/vtkOpenGLExtensionManager.cxx index 302ded28a7a..0d48943f1b3 100644 --- a/Rendering/OpenGL/vtkOpenGLExtensionManager.cxx +++ b/Rendering/OpenGL/vtkOpenGLExtensionManager.cxx @@ -870,7 +870,7 @@ void vtkOpenGLExtensionManager::ReadOpenGLExtensions() extensions_string += glu_extensions; } -#if defined(WIN32) +#if defined(_WIN32) // Don't use this->LoadExtension or we will go into an infinite loop. vtkgl::LoadExtension("WGL_ARB_extensions_string", this); if (vtkwgl::GetExtensionsStringARB) diff --git a/Testing/GenericBridge/vtkBridgeExport.h b/Testing/GenericBridge/vtkBridgeExport.h index 694468f657b..686f36a8b4f 100644 --- a/Testing/GenericBridge/vtkBridgeExport.h +++ b/Testing/GenericBridge/vtkBridgeExport.h @@ -26,7 +26,7 @@ # define VTK_BRIDGE_EXPORT #else -#if defined(WIN32) && defined(VTK_BUILD_SHARED_LIBS) +#if defined(_WIN32) && defined(VTK_BUILD_SHARED_LIBS) #if defined(vtkBridge_EXPORTS) #define VTK_BRIDGE_EXPORT __declspec( dllexport ) diff --git a/ThirdParty/VPIC/VPICGlobal.cxx b/ThirdParty/VPIC/VPICGlobal.cxx index d57f9c59ca3..a14a9337044 100644 --- a/ThirdParty/VPIC/VPICGlobal.cxx +++ b/ThirdParty/VPIC/VPICGlobal.cxx @@ -12,7 +12,7 @@ #include #include -#ifdef WIN32 +#ifdef _WIN32 const static char * Slash = "\\"; #else const static char * Slash = "/"; diff --git a/ThirdParty/VPIC/VPICView.cxx b/ThirdParty/VPIC/VPICView.cxx index ef8fc680e81..fc140c52238 100644 --- a/ThirdParty/VPIC/VPICView.cxx +++ b/ThirdParty/VPIC/VPICView.cxx @@ -8,7 +8,7 @@ #include #include "math.h" -#ifdef WIN32 +#ifdef _WIN32 const static char * Slash = "\\"; #else const static char * Slash = "/"; diff --git a/Utilities/DICOMParser/DICOMAppHelper.cxx b/Utilities/DICOMParser/DICOMAppHelper.cxx index 3e12087c966..d3954b63e68 100644 --- a/Utilities/DICOMParser/DICOMAppHelper.cxx +++ b/Utilities/DICOMParser/DICOMAppHelper.cxx @@ -705,7 +705,7 @@ void DICOMAppHelper::TransferSyntaxCallback(DICOMParser *parser, { #ifdef DEBUG_DICOM_APP_HELPER -#ifdef WIN32 +#ifdef _WIN32 char platformByteOrder = 'L'; #else char platformByteOrder = 'B'; diff --git a/Utilities/MetaIO/vtkmetaio/localMetaConfiguration.h b/Utilities/MetaIO/vtkmetaio/localMetaConfiguration.h index 48df5f6ec66..edb39df4348 100644 --- a/Utilities/MetaIO/vtkmetaio/localMetaConfiguration.h +++ b/Utilities/MetaIO/vtkmetaio/localMetaConfiguration.h @@ -55,7 +55,7 @@ #include #include - #if (defined(_WIN32) || defined(WIN32)) && defined(vtkmetaio_BUILD_SHARED_LIBS) + #if defined(_WIN32) && defined(vtkmetaio_BUILD_SHARED_LIBS) #ifdef vtkmetaio_EXPORTS #define METAIO_EXPORT __declspec(dllexport) #define METAIO_EXTERN diff --git a/Utilities/ParseOGLExt/ParseOGLExt.cxx b/Utilities/ParseOGLExt/ParseOGLExt.cxx index 3672f26c98d..9654ee3d324 100644 --- a/Utilities/ParseOGLExt/ParseOGLExt.cxx +++ b/Utilities/ParseOGLExt/ParseOGLExt.cxx @@ -76,7 +76,7 @@ class Extension { switch (itype) { case WGL: - out << "#ifdef WIN32" << endl; + out << "#ifdef _WIN32" << endl; break; case GLX: out << "#ifdef VTK_USE_X" << endl; diff --git a/Wrapping/Java/vtkJavaAwt.h b/Wrapping/Java/vtkJavaAwt.h index 8f0e83adad0..e78fba8318e 100644 --- a/Wrapping/Java/vtkJavaAwt.h +++ b/Wrapping/Java/vtkJavaAwt.h @@ -32,7 +32,7 @@ #endif #endif -#if defined(_WIN32) || defined(WIN32) +#if defined(_WIN32) #define WIN32_JAWT_LOCK_HACK #endif @@ -108,7 +108,7 @@ Java_vtk_vtkPanel_RenderCreate(JNIEnv *env, jobject canvas, jobject id0) } // Here is the win32 drawing code -#if defined(_WIN32) || defined(WIN32) +#if defined(_WIN32) temp0->Finalize(); JAWT_Win32DrawingSurfaceInfo* dsi_win; dsi_win = (JAWT_Win32DrawingSurfaceInfo*)dsi->platformInfo; @@ -209,7 +209,7 @@ Java_vtk_rendering_awt_vtkInternalAwtComponent_RenderCreate(JNIEnv *env, jobject } // Here is the win32 drawing code -#if defined(_WIN32) || defined(WIN32) +#if defined(_WIN32) temp0->Finalize(); JAWT_Win32DrawingSurfaceInfo* dsi_win; dsi_win = (JAWT_Win32DrawingSurfaceInfo*)dsi->platformInfo; diff --git a/Wrapping/Tcl/vtkTclUtil.h b/Wrapping/Tcl/vtkTclUtil.h index e196067367c..45db3c0b4a0 100644 --- a/Wrapping/Tcl/vtkTclUtil.h +++ b/Wrapping/Tcl/vtkTclUtil.h @@ -20,7 +20,7 @@ #include "vtkCommand.h" #include "vtkTcl.h" -#ifdef WIN32 +#ifdef _WIN32 #define VTKTCL_EXPORT __declspec( dllexport ) #else #define VTKTCL_EXPORT