From 9dc5063262d0a5130cf0723a33079f3fd17560c3 Mon Sep 17 00:00:00 2001 From: Apple SWE Date: Tue, 13 Mar 2018 18:29:45 -0700 Subject: [PATCH] sched.h needs to be imported on Darwin/OSX targets. sched_yield is used but the include reference on Darwin is missing. This patch conditionally guards on Darwin/OSX to import sched.h first. Reviewed-by: Jeremy Huddleston Sequoia Signed-off-by: Jeremy Huddleston Sequoia --- src/gallium/drivers/swr/swr_fence.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/gallium/drivers/swr/swr_fence.cpp b/src/gallium/drivers/swr/swr_fence.cpp index 3005eb9aaad..b05ac8cec02 100644 --- a/src/gallium/drivers/swr/swr_fence.cpp +++ b/src/gallium/drivers/swr/swr_fence.cpp @@ -29,6 +29,10 @@ #include "swr_screen.h" #include "swr_fence.h" +#ifdef __APPLE__ +#include +#endif + #if defined(PIPE_CC_MSVC) // portable thread yield #define sched_yield SwitchToThread #endif -- 2.30.2