I'm currently building a C++ DLL, and I have this at the top of the main DLL .cpp
file. This currently is causing the warning "Warning C4005: '_WIN32_WINNT' : macro redefinition"
. What have I done wrong?
I need to include windows.h
, SDKDDKVer.h
and set the minimum windows version to XP. How do I correct my code?
// System Includes
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <d3d9.h>
// Windows Version
#define _WIN32_WINNT _WIN32_WINNT_WINXP
#include <SDKDDKVer.h>
You should include the SDK stuff first: