mirror of
https://github.com/catchorg/Catch2.git
synced 2024-12-02 02:03:30 +01:00
Move windows.h reduction logic into windows.h proxy header
Fixes #965 (at least the primary problem, the separate warnings can be taken care of later)
This commit is contained in:
parent
d118ce191d
commit
0a3f899d6a
@ -22,12 +22,6 @@
|
|||||||
|
|
||||||
#elif defined(WIN32) || defined(__WIN32__) || defined(_WIN32) || defined(_MSC_VER)
|
#elif defined(WIN32) || defined(__WIN32__) || defined(_WIN32) || defined(_MSC_VER)
|
||||||
# define CATCH_PLATFORM_WINDOWS
|
# define CATCH_PLATFORM_WINDOWS
|
||||||
# if !defined(NOMINMAX) && !defined(CATCH_CONFIG_NO_NOMINMAX)
|
|
||||||
# define CATCH_DEFINES_NOMINMAX
|
|
||||||
# endif
|
|
||||||
# if !defined(WIN32_LEAN_AND_MEAN) && !defined(CATCH_CONFIG_NO_WIN32_LEAN_AND_MEAN)
|
|
||||||
# define CATCH_DEFINES_WIN32_LEAN_AND_MEAN
|
|
||||||
# endif
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // TWOBLUECUBES_CATCH_PLATFORM_H_INCLUDED
|
#endif // TWOBLUECUBES_CATCH_PLATFORM_H_INCLUDED
|
||||||
|
@ -8,11 +8,17 @@
|
|||||||
#ifndef TWOBLUECUBES_CATCH_WINDOWS_H_PROXY_H_INCLUDED
|
#ifndef TWOBLUECUBES_CATCH_WINDOWS_H_PROXY_H_INCLUDED
|
||||||
#define TWOBLUECUBES_CATCH_WINDOWS_H_PROXY_H_INCLUDED
|
#define TWOBLUECUBES_CATCH_WINDOWS_H_PROXY_H_INCLUDED
|
||||||
|
|
||||||
#ifdef CATCH_DEFINES_NOMINMAX
|
#include "catch_platform.h"
|
||||||
# define NOMINMAX
|
|
||||||
#endif
|
#if defined(CATCH_PLATFORM_WINDOWS)
|
||||||
#ifdef CATCH_DEFINES_WIN32_LEAN_AND_MEAN
|
# if !defined(NOMINMAX) && !defined(CATCH_CONFIG_NO_NOMINMAX)
|
||||||
# define WIN32_LEAN_AND_MEAN
|
# define CATCH_DEFINED_NOMINMAX
|
||||||
|
# define NOMINMAX
|
||||||
|
# endif
|
||||||
|
# if !defined(WIN32_LEAN_AND_MEAN) && !defined(CATCH_CONFIG_NO_WIN32_LEAN_AND_MEAN)
|
||||||
|
# define CATCH_DEFINED_WIN32_LEAN_AND_MEAN
|
||||||
|
# define WIN32_LEAN_AND_MEAN
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __AFXDLL
|
#ifdef __AFXDLL
|
||||||
@ -21,10 +27,10 @@
|
|||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CATCH_DEFINES_NOMINMAX
|
#ifdef CATCH_DEFINED_NOMINMAX
|
||||||
# undef NOMINMAX
|
# undef NOMINMAX
|
||||||
#endif
|
#endif
|
||||||
#ifdef CATCH_DEFINES_WIN32_LEAN_AND_MEAN
|
#ifdef CATCH_DEFINED_WIN32_LEAN_AND_MEAN
|
||||||
# undef WIN32_LEAN_AND_MEAN
|
# undef WIN32_LEAN_AND_MEAN
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user