Changeset 2257


Ignore:
Timestamp:
21/08/2008 12:08:44 (4 years ago)
Author:
chris
Message:

Better handle the case where MSVCRT_VERSION is already defined (e.g.
by wxWidgets) before including Box.h, as long as the defined version is
high enough, to avoid mutual incompatibility with wxWidgets (needed for
Boxi).

Define O_BINARY if it's not already defined rather than using configury.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • box/trunk/lib/common/BoxPlatform.h

    r2186 r2257  
    3131#ifdef WIN32 
    3232        #ifdef __MSVCRT_VERSION__ 
    33                 #error Must include Box.h before sys/types.h 
     33                #if __MSVCRT_VERSION__ < 0x0601 
     34                        #error Must include Box.h before sys/types.h 
     35                #endif 
     36        #else 
     37                // need msvcrt version 6.1 or higher for _gmtime64() 
     38                // must define this before importing <sys/types.h> 
     39                #define __MSVCRT_VERSION__ 0x0601 
    3440        #endif 
    35         // need msvcrt version 6.1 or higher for _gmtime64() 
    36         // must define this before importing <sys/types.h> 
    37         #define __MSVCRT_VERSION__ 0x0601 
    3841#endif 
    3942 
     
    154157 
    155158// for Unix compatibility with Windows :-) 
    156 #if !HAVE_DECL_O_BINARY 
     159#ifndef O_BINARY 
    157160        #define O_BINARY 0 
    158161#endif 
Note: See TracChangeset for help on using the changeset viewer.