| ... | ... | @@ -47,15 +47,20 @@ option(ZIG_TEST_COVERAGE "Build Zig with test coverage instrumentation" OFF) |
| 47 | 47 | option(ZIG_FORCE_EXTERNAL_LLD "If your system has the LLD patches use it instead of the embedded LLD" OFF) |
| 48 | 48 | |
| 49 | 49 | find_package(llvm) |
| 50 | | include_directories(${LLVM_INCLUDE_DIRS}) |
| 51 | | |
| 52 | 50 | find_package(clang) |
| 53 | | include_directories(${CLANG_INCLUDE_DIRS}) |
| 54 | 51 | |
| 55 | 52 | if(ZIG_FORCE_EXTERNAL_LLD) |
| 56 | 53 | find_package(lld) |
| 54 | include_directories(${LLVM_INCLUDE_DIRS}) |
| 57 | 55 | include_directories(${LLD_INCLUDE_DIRS}) |
| 56 | include_directories(${CLANG_INCLUDE_DIRS}) |
| 58 | 57 | else() |
| 58 | # This goes first so that we find embedded LLD instead |
| 59 | # of system LLD. |
| 60 | include_directories("${CMAKE_SOURCE_DIR}/deps/lld/include") |
| 61 | |
| 62 | include_directories(${LLVM_INCLUDE_DIRS}) |
| 63 | include_directories(${CLANG_INCLUDE_DIRS}) |
| 59 | 64 | set(EMBEDDED_LLD_LIB_SOURCES |
| 60 | 65 | "${CMAKE_SOURCE_DIR}/deps/lld/lib/Driver/DarwinLdDriver.cpp" |
| 61 | 66 | "${CMAKE_SOURCE_DIR}/deps/lld/lib/Config/Version.cpp" |