cmake: fix recent cmake regression on macos

This commit is contained in:
Nikolaus Demmel 2019-05-13 21:40:35 +02:00
parent ef8f5e40bd
commit ce03cf1518
1 changed files with 4 additions and 2 deletions

View File

@ -110,9 +110,11 @@ if(APPLE)
set(CMAKE_FIND_FRAMEWORK LAST)
# use brewed llvm's libc++
add_compile_options("-nostdinc++")
include_directories("/usr/local/opt/llvm/include/c++/v1")
# Note: the suffix "/../v1" for the include path is needed to work around a recent cmake issue:
# https://gitlab.kitware.com/cmake/cmake/issues/19251#note_571030
include_directories("/usr/local/opt/llvm/include/c++/v1/../v1")
link_directories("/usr/local/opt/llvm/lib")
add_compile_options("-nostdinc++")
set(STD_CXX_FS c++fs)
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")