From 3a641953caf9fbd43e60e5aa40d4140b10543e6f Mon Sep 17 00:00:00 2001 From: ideal Date: Mon, 4 Mar 2019 20:32:45 +0800 Subject: [PATCH] let check_include_files() can find pcre installed by homebrew on macOS --- cmake/configure.cmake | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmake/configure.cmake b/cmake/configure.cmake index 06ba24df..b0884e1f 100644 --- a/cmake/configure.cmake +++ b/cmake/configure.cmake @@ -18,6 +18,9 @@ include(CheckCSourceCompiles) set(CONNECT_IN_PROGRESS "EINPROGRESS") set(CONNECT_IN_PROGRESS "EINPROGRESS" CACHE STRING "") +if (CMAKE_SYSTEM_NAME STREQUAL Darwin) + set(CMAKE_REQUIRED_INCLUDES "/usr/local/include" "/usr/include") +endif () check_include_files(dlfcn.h HAVE_DLFCN_H) check_include_files(ev.h HAVE_EV_H)