57 lines
2.4 KiB
C
Raw Normal View History

2019-08-19 19:19:58 +08:00
#ifndef HGL_COMPILER_MICROSOFT_INCLUDE
#define HGL_COMPILER_MICROSOFT_INCLUDE
//--------------------------------------------------------------------------------------------------
#define HGL_COMPILER_NAME OS_TEXT("Microsoft C/C++")
#define HGL_LIB_COMPILER_NAME OS_TEXT("MSC")
2020-07-10 18:18:03 +08:00
#if _MSC_VER < 1900 //Visual C++ 2017
2020-06-13 19:08:29 +08:00
#error Please upgrade your compiler or development tools to Microsoft C/C++ 19.1 (Visual C++ 2017) or later.
2019-08-19 19:19:58 +08:00
#else
2020-06-13 19:08:29 +08:00
#if _MSC_VER >= 1920
#define HGL_LIB_COMPILER_VERSION OS_TEXT("19.2") //Visual C++ 2019
#elif _MSC_VER >= 1910
2019-08-19 19:19:58 +08:00
#define HGL_LIB_COMPILER_VERSION OS_TEXT("19.1") //Visual C++ 2017
2020-07-10 18:18:03 +08:00
#elif _MSC_VER >= 1900
#define HGL_LIB_COMPILER_VERSION OS_TEXT("19.0") //Visual C++ 2015
2019-08-19 19:19:58 +08:00
#else
#define HGL_LIB_COMPILER_VERSION OS_TEXT("Unknow")
#endif//_MSC_VER
#endif//_MSC_VER
#define HGL_THREAD_LOCAL_STORAGE __declspec(thread) //线程本地储存
//--------------------------------------------------------------------------------------------------
#define HGL_FMT_I64 "%I64d"
#define HGL_FMT_U64 "%I64u"
//参考文档最后查阅支持版本为VC2013网址http://msdn.microsoft.com/en-us/library/tcxf1dw6.aspx
//--------------------------------------------------------------------------------------------------
#define _USE_MATH_DEFINES // 使用数学常数定义
//--------------------------------------------------------------------------------------------------
#ifndef _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
#endif//
#ifndef _CRT_SECURE_NO_DEPRECATE
#define _CRT_SECURE_NO_DEPRECATE
#endif//
#ifndef _CRT_NON_CONFORMING_SWPRINTFS
#define _CRT_NON_CONFORMING_SWPRINTFS
#endif//
#ifdef _DLL
#define HGL_LIB_CRT "Dynamic"
#else
#define HGL_LIB_CRT "Static"
#endif//_DLL
#define HGL_LIB_FRONT HGL_LIB_OS "_" HGL_LIB_COMPILER_NAME "_" HGL_LIB_DEBUG_NAME "_" HGL_LIB_CRT "_"
#define HGL_LIB_END ".LIB"
//--------------------------------------------------------------------------------------------------
#include<hgl/platform/compiler/DataTypeWin.h>
#include<hgl/platform/compiler/DataTypeTiny.h>
#include<hgl/platform/compiler/Property.h>
//--------------------------------------------------------------------------------------------------
#endif//HGL_COMPILER_MICROSOFT_INCLUDE