Skip to content

Commit 517880e

Browse files
authored
Fix compilation with WIN32_LEAN_AND_MEAN (#768)
1 parent 90a2819 commit 517880e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

windows/hid.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,12 @@
3030
extern "C" {
3131
#endif
3232

33+
#ifdef WIN32_LEAN_AND_MEAN
34+
/* It may be set by IDE/project and apparently HIDAPI relies
35+
* on certain Windows headers being included by default. */
36+
#undef WIN32_LEAN_AND_MEAN
37+
#endif
38+
3339
#include "hidapi_winapi.h"
3440

3541
#include <windows.h>

0 commit comments

Comments
 (0)