EHS/include/ehs/system/OS.h

36 lines
725 B
C
Raw Permalink Normal View History

2024-02-05 22:25:30 -08:00
#pragma once
#if defined(_WIN32) || defined(_WIN64)
2024-07-21 10:45:06 -07:00
#define EHS_OS_WINDOWS
2024-02-05 22:25:30 -08:00
#define EHS_FILE __FILE__
#define EHS_FUNC __FUNCTION__
#define EHS_LINE __LINE__
2024-07-24 01:36:20 -07:00
#if defined(EHS_LIB_EXPORT)
2024-07-21 10:45:06 -07:00
#define EHS_LIB_IO __declspec(dllexport)
2024-07-24 01:36:20 -07:00
#elif defined(EHS_LIB_IMPORT)
2024-07-21 10:45:06 -07:00
#define EHS_LIB_IO __declspec(dllimport)
#else
#define EHS_LIB_IO
#endif
2024-02-05 22:25:30 -08:00
#ifndef NOMINMAX
#define NOMINMAX
#endif
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <Windows.h>
typedef void* Handle;
#elif defined(__linux__)
#define EHS_OS_LINUX
#define EHS_FILE __FILE__
#define EHS_FUNC __FUNCTION__
#define EHS_LINE __LINE__
2024-07-21 10:45:06 -07:00
#define EHS_LIB_IO
2024-02-05 22:25:30 -08:00
2024-07-21 10:45:06 -07:00
typedef int Handle;
2024-02-05 22:25:30 -08:00
#endif