llvm-project
35 строк · 1.2 Кб
1# This file allows users to call find_package(Polly) and pick up our targets.
2
3@POLLY_CONFIG_CODE@
4
5set(LLVM_VERSION @LLVM_VERSION_MAJOR@.@LLVM_VERSION_MINOR@.@LLVM_VERSION_PATCH@)
6find_package(LLVM ${LLVM_VERSION} EXACT REQUIRED CONFIG
7HINTS "@POLLY_CONFIG_LLVM_CMAKE_DIR@")
8
9set(Polly_CMAKE_DIR ${CMAKE_CURRENT_LIST_DIR})
10set(Polly_BUNDLED_ISL @POLLY_BUNDLED_ISL@)
11
12set(Polly_DEFINITIONS ${LLVM_DEFINITIONS})
13set(Polly_INCLUDE_DIRS @POLLY_CONFIG_INCLUDE_DIRS@ ${LLVM_INCLUDE_DIRS})
14set(Polly_LIBRARY_DIRS @POLLY_CONFIG_LIBRARY_DIRS@)
15set(Polly_EXPORTED_TARGETS @POLLY_CONFIG_EXPORTED_TARGETS@)
16set(Polly_LIBRARIES ${LLVM_LIBRARIES} ${Polly_EXPORTED_TARGETS})
17
18# Imported Targets:
19@ISL_CONFIG_CODE@
20
21if (NOT TARGET Polly)
22add_library(Polly @POLLY_CONFIG_TARGET_Polly_TYPE@ IMPORTED)
23set_property(TARGET Polly PROPERTY INTERFACE_LINK_LIBRARIES @ISL_TARGET@)
24endif()
25
26if (NOT TARGET LLVMPolly)
27add_library(LLVMPolly @POLLY_CONFIG_TARGET_LLVMPolly_TYPE@ IMPORTED)
28set_property(TARGET LLVMPolly PROPERTY INTERFACE_LINK_LIBRARIES Polly)
29endif()
30
31# Exported locations:
32file(GLOB CONFIG_FILES "${Polly_CMAKE_DIR}/PollyExports-*.cmake")
33foreach(f ${CONFIG_FILES})
34include(${f})
35endforeach()
36