From be3cc33800f04d76a2e87346ff45bc747da4541b Mon Sep 17 00:00:00 2001 From: Xiaofeng Wang Date: Fri, 29 Jul 2022 19:37:51 +0800 Subject: [PATCH] Fix build on apple M1 --- CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index c6f1a445..8d4222b0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -183,6 +183,12 @@ elseif(WIN32) endif() endif() +if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Darwin") + if(CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL "arm64") + include_directories(SYSTEM "/opt/homebrew/include") + endif() +endif() + # mediakit 以及各个 runtime 依赖 update_cached_list(MK_LINK_LIBRARIES "") update_cached_list(MK_COMPILE_DEFINITIONS ENABLE_VERSION)