From 46efbba2a40fb9cf5734c23ff0b3d18af7822c8c Mon Sep 17 00:00:00 2001 From: Joe Sylve Date: Tue, 25 Jun 2019 17:56:10 -0500 Subject: [PATCH 1/4] Fix ABSL_WAITER_MODE detection for mingw --- absl/synchronization/internal/waiter.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/absl/synchronization/internal/waiter.h b/absl/synchronization/internal/waiter.h index a3e3124e441..6c3ef308471 100644 --- a/absl/synchronization/internal/waiter.h +++ b/absl/synchronization/internal/waiter.h @@ -40,7 +40,7 @@ #if defined(ABSL_FORCE_WAITER_MODE) #define ABSL_WAITER_MODE ABSL_FORCE_WAITER_MODE -#elif defined(_WIN32) +#elif defined(_WIN32) && _WIN32_WINNT >= 0x0600 #define ABSL_WAITER_MODE ABSL_WAITER_MODE_WIN32 #elif defined(__linux__) #define ABSL_WAITER_MODE ABSL_WAITER_MODE_FUTEX From f6d9d5054b0947568318e2afba39475528d4dd4f Mon Sep 17 00:00:00 2001 From: Andy Getz Date: Mon, 30 Sep 2019 18:02:36 -0400 Subject: [PATCH 2/4] Use `_WIN32_WINNT_VISTA` symbol instead of numeric 0x0600 --- absl/synchronization/internal/waiter.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/absl/synchronization/internal/waiter.h b/absl/synchronization/internal/waiter.h index 6c3ef308471..df8696f7331 100644 --- a/absl/synchronization/internal/waiter.h +++ b/absl/synchronization/internal/waiter.h @@ -20,6 +20,7 @@ #ifndef _WIN32 #include +#include #endif #ifdef ABSL_HAVE_SEMAPHORE_H @@ -40,7 +41,7 @@ #if defined(ABSL_FORCE_WAITER_MODE) #define ABSL_WAITER_MODE ABSL_FORCE_WAITER_MODE -#elif defined(_WIN32) && _WIN32_WINNT >= 0x0600 +#elif defined(_WIN32) && _WIN32_WINNT >= _WIN32_WINNT_VISTA #define ABSL_WAITER_MODE ABSL_WAITER_MODE_WIN32 #elif defined(__linux__) #define ABSL_WAITER_MODE ABSL_WAITER_MODE_FUTEX From 0dacb26349b272b6e999c5839f83b2e4feda97e2 Mon Sep 17 00:00:00 2001 From: Andy Getz Date: Wed, 2 Oct 2019 17:41:22 -0400 Subject: [PATCH 3/4] fix ifndef vs ifdef typo =/ --- absl/synchronization/internal/waiter.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/absl/synchronization/internal/waiter.h b/absl/synchronization/internal/waiter.h index df8696f7331..46e4dcfa9b3 100644 --- a/absl/synchronization/internal/waiter.h +++ b/absl/synchronization/internal/waiter.h @@ -18,8 +18,9 @@ #include "absl/base/config.h" -#ifndef _WIN32 +#ifdef _WIN32 #include +#else #include #endif From 6abed8f09f527cd60fce9da5842af27b6af05872 Mon Sep 17 00:00:00 2001 From: Andy Getz Date: Wed, 2 Oct 2019 18:11:02 -0400 Subject: [PATCH 4/4] fix typo in typo fix today is not my day --- absl/synchronization/internal/waiter.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/absl/synchronization/internal/waiter.h b/absl/synchronization/internal/waiter.h index 46e4dcfa9b3..0757b91d79d 100644 --- a/absl/synchronization/internal/waiter.h +++ b/absl/synchronization/internal/waiter.h @@ -19,9 +19,9 @@ #include "absl/base/config.h" #ifdef _WIN32 -#include -#else #include +#else +#include #endif #ifdef ABSL_HAVE_SEMAPHORE_H