From: jpr Date: Wed, 30 May 2007 11:05:47 +0000 (+0000) Subject: (Try to) fix troubles with WIN32 vs _WIN32 at compile time X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=20f7cba5b9d4012e8f038e47588c4de3962d147c;p=gdcm.git (Try to) fix troubles with WIN32 vs _WIN32 at compile time --- diff --git a/Example/Volume2Dicom.cxx b/Example/Volume2Dicom.cxx index 8ab62085..4ed808b7 100644 --- a/Example/Volume2Dicom.cxx +++ b/Example/Volume2Dicom.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: Volume2Dicom.cxx,v $ Language: C++ - Date: $Date: 2007/05/23 14:18:04 $ - Version: $Revision: 1.12 $ + Date: $Date: 2007/05/30 11:05:47 $ + Version: $Revision: 1.13 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -33,7 +33,7 @@ #include #include #include -#ifdef WIN32 +#ifdef _WIN32 #define stat _stat #endif diff --git a/src/gdcmopenjpeg/codec/CMakeLists.txt b/src/gdcmopenjpeg/codec/CMakeLists.txt index 3f3c7d5a..00de4f36 100644 --- a/src/gdcmopenjpeg/codec/CMakeLists.txt +++ b/src/gdcmopenjpeg/codec/CMakeLists.txt @@ -37,7 +37,8 @@ IF(NOT BUILD_SHARED_LIBS) ENDIF(NOT BUILD_SHARED_LIBS) # Loop over all executables: -FOREACH(exe j2k_to_image image_to_j2k) +#FOREACH(exe j2k_to_image image_to_j2k) +FOREACH(exe image_to_j2k) ADD_EXECUTABLE(${exe} ${exe}.c ${common_SRCS}) TARGET_LINK_LIBRARIES(${exe} ${OPJ_PREFIX}openjpeg) # On unix you need to link to the math library: diff --git a/src/gdcmopenjpeg/codec/image_to_j2k.c b/src/gdcmopenjpeg/codec/image_to_j2k.c index 81200869..427a5efd 100644 --- a/src/gdcmopenjpeg/codec/image_to_j2k.c +++ b/src/gdcmopenjpeg/codec/image_to_j2k.c @@ -35,7 +35,7 @@ #include "compat/getopt.h" #include "convert.h" -#ifndef WIN32 +#ifndef _WIN32 #define stricmp strcasecmp #define strnicmp strncasecmp #endif diff --git a/src/gdcmopenjpeg/libopenjpeg/j2k_lib.c b/src/gdcmopenjpeg/libopenjpeg/j2k_lib.c index 230be80c..3a6fae12 100644 --- a/src/gdcmopenjpeg/libopenjpeg/j2k_lib.c +++ b/src/gdcmopenjpeg/libopenjpeg/j2k_lib.c @@ -24,17 +24,17 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#ifdef WIN32 +#ifdef _WIN32 #include #else #include #include #include -#endif /* WIN32 */ +#endif /* _WIN32 */ #include "opj_includes.h" double opj_clock() { -#ifdef WIN32 +#ifdef _WIN32 /* WIN32: use QueryPerformance (very accurate) */ LARGE_INTEGER freq , t ; /* freq is the clock speed of the CPU */ diff --git a/src/gdcmopenjpeg/libopenjpeg/openjpeg.c b/src/gdcmopenjpeg/libopenjpeg/openjpeg.c index 6097cdba..31429119 100644 --- a/src/gdcmopenjpeg/libopenjpeg/openjpeg.c +++ b/src/gdcmopenjpeg/libopenjpeg/openjpeg.c @@ -24,14 +24,14 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#ifdef WIN32 +#ifdef _WIN32 #include -#endif /* WIN32 */ +#endif /* _WIN32 */ #include "opj_includes.h" /* ---------------------------------------------------------------------- */ -#ifdef WIN32 +#ifdef _WIN32 #ifndef OPJ_STATIC BOOL APIENTRY DllMain(HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) {