mirror of
https://github.com/glfw/glfw.git
synced 2024-11-14 18:34:34 +00:00
Fix Windows failing to build
This commit is contained in:
parent
0d0a840b22
commit
2c27136b39
@ -25,47 +25,9 @@
|
|||||||
//
|
//
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
|
||||||
// We don't need all the fancy stuff
|
|
||||||
#ifndef NOMINMAX
|
|
||||||
#define NOMINMAX
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef VC_EXTRALEAN
|
|
||||||
#define VC_EXTRALEAN
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef WIN32_LEAN_AND_MEAN
|
|
||||||
#define WIN32_LEAN_AND_MEAN
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// This is a workaround for the fact that glfw3.h needs to export APIENTRY (for
|
|
||||||
// example to allow applications to correctly declare a GL_KHR_debug callback)
|
|
||||||
// but windows.h assumes no one will define APIENTRY before it does
|
|
||||||
#undef APIENTRY
|
|
||||||
|
|
||||||
// GLFW on Windows is Unicode only and does not work in MBCS mode
|
|
||||||
#ifndef UNICODE
|
|
||||||
#define UNICODE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// GLFW requires Windows XP or later
|
|
||||||
#if WINVER < 0x0501
|
|
||||||
#undef WINVER
|
|
||||||
#define WINVER 0x0501
|
|
||||||
#endif
|
|
||||||
#if _WIN32_WINNT < 0x0501
|
|
||||||
#undef _WIN32_WINNT
|
|
||||||
#define _WIN32_WINNT 0x0501
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// GLFW uses DirectInput8 interfaces
|
// GLFW uses DirectInput8 interfaces
|
||||||
#define DIRECTINPUT_VERSION 0x0800
|
#define DIRECTINPUT_VERSION 0x0800
|
||||||
|
|
||||||
// GLFW uses OEM cursor resources
|
|
||||||
#define OEMRESOURCE
|
|
||||||
|
|
||||||
#include <wctype.h>
|
|
||||||
#include <windows.h>
|
|
||||||
#include <dinput.h>
|
#include <dinput.h>
|
||||||
#include <xinput.h>
|
#include <xinput.h>
|
||||||
#include <dbt.h>
|
#include <dbt.h>
|
||||||
|
@ -25,6 +25,43 @@
|
|||||||
//
|
//
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
|
||||||
|
// We don't need all the fancy stuff
|
||||||
|
#ifndef NOMINMAX
|
||||||
|
#define NOMINMAX
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef VC_EXTRALEAN
|
||||||
|
#define VC_EXTRALEAN
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef WIN32_LEAN_AND_MEAN
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// This is a workaround for the fact that glfw3.h needs to export APIENTRY (for
|
||||||
|
// example to allow applications to correctly declare a GL_KHR_debug callback)
|
||||||
|
// but windows.h assumes no one will define APIENTRY before it does
|
||||||
|
#undef APIENTRY
|
||||||
|
|
||||||
|
// GLFW on Windows is Unicode only and does not work in MBCS mode
|
||||||
|
#ifndef UNICODE
|
||||||
|
#define UNICODE
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// GLFW requires Windows XP or later
|
||||||
|
#if WINVER < 0x0501
|
||||||
|
#undef WINVER
|
||||||
|
#define WINVER 0x0501
|
||||||
|
#endif
|
||||||
|
#if _WIN32_WINNT < 0x0501
|
||||||
|
#undef _WIN32_WINNT
|
||||||
|
#define _WIN32_WINNT 0x0501
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// GLFW uses OEM cursor resources
|
||||||
|
#define OEMRESOURCE
|
||||||
|
|
||||||
|
#include <wctype.h>
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
|
||||||
#define GLFW_WIN32_TLS_STATE _GLFWtlsWin32 win32;
|
#define GLFW_WIN32_TLS_STATE _GLFWtlsWin32 win32;
|
||||||
|
Loading…
Reference in New Issue
Block a user