Some .c files in lib/uuid/ contain the following:
#ifdef _WIN32
#define _WIN32_WINNT 0x0500
#include <windows.h>
#define UUID MYUUID
#endif
This seems to have been intended to allow the use of a local "UUID" type
without colliding with "UUID" in the Windows API. However, this is
unnecessary because there's no local "UUID" type -- there's only uuid_t.
None of these .c files need the include of windows.h, either.
Finally, the unconditional definition of _WIN32_WINNT causes a compiler
warning when the user defines _WIN32_WINNT themself.
Since this code is unnecessary and is causing problems, just remove it.
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
],
target: {
windows: {
- // Cannot suppress the _WIN32_WINNT redefined warning.
- cflags: ["-Wno-error"],
include_dirs: [ "external/e2fsprogs/include/mingw" ],
enabled: true
},
#include "config.h"
-#ifdef _WIN32
-#define _WIN32_WINNT 0x0500
-#include <windows.h>
-#define UUID MYUUID
-#endif
#include <stdio.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#include "config.h"
-#ifdef _WIN32
-#define _WIN32_WINNT 0x0500
-#include <windows.h>
-#define UUID MYUUID
-#endif
-
#include <stdio.h>
#include <stdlib.h>
#include "config.h"
-#ifdef _WIN32
-#define _WIN32_WINNT 0x0500
-#include <windows.h>
-#define UUID MYUUID
-#endif
-
#include <stdio.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>