diff options
Diffstat (limited to 'cmake/modules/CMakeLists.txt')
-rw-r--r-- | cmake/modules/CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/cmake/modules/CMakeLists.txt b/cmake/modules/CMakeLists.txt index 3cc808a46b958..b784c0d215eab 100644 --- a/cmake/modules/CMakeLists.txt +++ b/cmake/modules/CMakeLists.txt @@ -39,7 +39,10 @@ set(CLANG_CONFIG_CMAKE_DIR) set(CLANG_CONFIG_EXPORTS_FILE) if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY) - install(EXPORT ClangTargets DESTINATION ${CLANG_INSTALL_PACKAGE_DIR}) + get_property(clang_has_exports GLOBAL PROPERTY CLANG_HAS_EXPORTS) + if(clang_has_exports) + install(EXPORT ClangTargets DESTINATION ${CLANG_INSTALL_PACKAGE_DIR}) + endif() install(FILES ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/ClangConfig.cmake |