From 7173c823825a8562b351316ad00af34f6b351d77 Mon Sep 17 00:00:00 2001 From: Andrey Kamaev Date: Wed, 17 Oct 2012 17:00:53 +0400 Subject: [PATCH] Include unistd.h to parallel.cpp on UNIX-like systems This fixes build without TBB and CUDA. Issue #2445 --- modules/core/src/parallel.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/modules/core/src/parallel.cpp b/modules/core/src/parallel.cpp index 3ba4388470..c31edede85 100644 --- a/modules/core/src/parallel.cpp +++ b/modules/core/src/parallel.cpp @@ -42,6 +42,17 @@ #include "precomp.hpp" +#if defined __linux__ || defined __APPLE__ + #include + #include + #include + #if defined ANDROID + #include + #else + #include + #endif +#endif + #ifdef _OPENMP #define HAVE_OPENMP #endif @@ -85,7 +96,6 @@ #include #elif defined HAVE_GCD #include - #include #include #elif defined HAVE_CONCURRENCY #include