core/sm_platform.h
changeset 141 1ea0bd016431
child 160 c056af9b4aaf
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/core/sm_platform.h	Sun Nov 05 02:47:13 2006 +0000
     1.3 @@ -0,0 +1,23 @@
     1.4 +#ifndef _INCLUDE_SOURCEMOD_PLATFORM_H_
     1.5 +#define _INCLUDE_SOURCEMOD_PLATFORM_H_
     1.6 +
     1.7 +#if defined WIN32 || defined WIN64
     1.8 +#define PLATFORM_WINDOWS
     1.9 +#if !defined WIN32_LEAN_AND_MEAN
    1.10 +#define WIN32_LEAN_AND_MEAN
    1.11 +#endif
    1.12 +#if !defined snprintf
    1.13 +#define snprintf _snprintf
    1.14 +#endif
    1.15 +#include <windows.h>
    1.16 +#include <direct.h>
    1.17 +#define PLATFORM_MAX_PATH		MAX_PATH
    1.18 +#else if defined __linux__
    1.19 +#define PLATFORM_LINUX
    1.20 +#define PLATFORM_POSIX
    1.21 +#include <dirent.h>
    1.22 +#include <errno.h>
    1.23 +#define PLATFORM_MAX_PATH		PATH_MAX
    1.24 +#endif
    1.25 +
    1.26 +#endif //_INCLUDE_SOURCEMOD_PLATFORM_H_