diff --git a/folly/io/async/fdsock/AsyncFdSocket.h b/folly/io/async/fdsock/AsyncFdSocket.h index d3d84bb5873..8fbfbd9baad 100644 --- a/folly/io/async/fdsock/AsyncFdSocket.h +++ b/folly/io/async/fdsock/AsyncFdSocket.h @@ -19,6 +19,16 @@ #include #include +#ifdef __APPLE__ +#include +#if MAC_OS_X_VERSION_MIN_REQUIRED < 110000 +#ifdef __DARWIN_ALIGN32 +#undef __DARWIN_ALIGN32 +#define __DARWIN_ALIGN32(p) ((__darwin_size_t)((__darwin_size_t)(p) + __DARWIN_ALIGNBYTES32) &~ __DARWIN_ALIGNBYTES32) +#endif +#endif +#endif + namespace folly { // Including `gtest/gtest_prod.h` would make gtest/gmock a hard dep