32 lines
817 B
C
32 lines
817 B
C
#ifndef __DYNAMICLIB_WINDOWS_H_
|
|
#define __DYNAMICLIB_WINDOWS_H_
|
|
|
|
#define NOMINMAX
|
|
#ifndef WIN32_LEAN_AND_MEAN
|
|
#define LAM_DEFINED
|
|
#define WIN32_LEAN_AND_MEAN
|
|
#endif
|
|
#include <Windows.h>
|
|
#ifdef LAM_DEFINED
|
|
#undef LAM_DEFINED
|
|
#undef WIN32_LEAN_AND_MEAN
|
|
#endif
|
|
#undef NOMINMAX
|
|
#undef near
|
|
#undef far
|
|
|
|
#ifdef ICSNEOC_MAKEDLL
|
|
#define DLLExport __declspec(dllexport)
|
|
#else
|
|
#define DLLExport __declspec(dllimport)
|
|
#endif
|
|
#define LegacyDLLExport DLLExport _stdcall
|
|
|
|
// MSVC does not have the ability to specify a destructor
|
|
#define ICSNEO_DESTRUCTOR
|
|
|
|
#define icsneo_dynamicLibraryLoad() LoadLibrary(TEXT("icsneoc.dll"))
|
|
#define icsneo_dynamicLibraryGetFunction(handle, func) GetProcAddress((HMODULE) handle, func)
|
|
#define icsneo_dynamicLibraryClose(handle) FreeLibrary((HMODULE) handle)
|
|
|
|
#endif |