00001
00012 #ifndef _PLATFORM_H
00013 #define _PLATFORM_H
00014
00015 #ifdef WIN32
00016 #if 0
00017 #include <Windows.h>
00018 #endif
00019 #define int64 __int64
00020 #define FMT_INT64 "I64"
00021 #define atoi64 _atoi64
00022 #include <float.h>
00023 #ifndef MINGW
00024 #include <ymath.h>
00025 #define INFINITY _Inf._Double
00026 #define isnan _isnan
00027 #define getpid _getpid
00028 #else
00029 #define min(A,B) ((A)<(B)?(A):(B))
00030 #endif
00031 #ifndef R_OK
00032 #define R_OK (4)
00033 #define W_OK (2)
00034 #define X_OK (0)
00035 #define F_OK (0)
00036 #endif
00037 #ifndef isfinite
00038 #define isfinite _finite
00039 #endif
00040 #define strlwr _strlwr
00041 #else
00042 #define int64 long long
00043 #define FMT_INT64 "ll"
00044 #define atoi64 atoll
00045 #define stricmp strcasecmp
00046 #define strnicmp strncasecmp
00047 #define min(A,B) ((A)<(B)?(A):(B))
00048 #define max(A,B) ((A)>(B)?(A):(B))
00049 #ifndef isfinite
00050 #define isfinite finite
00051 #endif
00052 #endif
00053
00054 #ifdef I64
00055 #define NATIVE int64
00056 #else
00057 #define NATIVE int32
00058 #endif
00059
00060 #endif
00061