Commit 0c5fea18 authored by Jaikrishnan Menon's avatar Jaikrishnan Menon

Codegen: More CMake fixes for MacOS native builds

parent 6d4d2513
......@@ -15,10 +15,14 @@ include(ExternalProject)
find_package(LLVM CONFIG)
set(LLVM_PACKAGED FALSE)
if(LLVM_FOUND)
if(${LLVM_PACKAGE_VERSION} VERSION_GREATER "4.0")
message(STATUS "Found LLVM ${LLVM_PACKAGE_VERSION}")
message(STATUS "Found LLVM ${LLVM_PACKAGE_VERSION}")
set(LLVM_PACKAGED TRUE)
else()
message(STATUS "Found LLVM ${LLVM_PACKAGE_VERSION} but need atleast 4.0")
set(LLVM_FOUND FALSE)
endif()
endif()
......@@ -87,3 +91,4 @@ endif()
set(LLVM_INCLUDE_DIR ${LLVM_INCLUDE_DIR} PARENT_SCOPE)
set(LLVM_LIB_DIR ${LLVM_LIB_DIR} PARENT_SCOPE)
set(LLVM_LINK_LIBS ${LLVM_LINK_LIBS} PARENT_SCOPE)
set(LLVM_PACKAGED ${LLVM_PACKAGED} PARENT_SCOPE)
......@@ -159,6 +159,6 @@ install(DIRECTORY
add_dependencies(ngraph eigen)
if(LLVM_INCLUDE_DIR)
if(NOT LLVM_PACKAGED AND LLVM_INCLUDE_DIR)
add_dependencies(ngraph ext_llvm)
endif()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment