51 lines
2.2 KiB
Diff
51 lines
2.2 KiB
Diff
diff --git a/cmake/modules/AddClang.cmake b/cmake/modules/AddClang.cmake
|
|
index 9bbbfc032b7d..947bd0da865d 100644
|
|
--- a/cmake/modules/AddClang.cmake
|
|
+++ b/cmake/modules/AddClang.cmake
|
|
@@ -119,8 +119,8 @@ macro(add_clang_library name)
|
|
install(TARGETS ${lib}
|
|
COMPONENT ${lib}
|
|
${export_to_clangtargets}
|
|
- LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
|
|
- ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX}
|
|
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}${LLVM_LIBDIR_SUFFIX}
|
|
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}${LLVM_LIBDIR_SUFFIX}
|
|
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
|
|
|
|
if (NOT LLVM_ENABLE_IDE)
|
|
@@ -175,7 +175,7 @@ endmacro()
|
|
macro(add_clang_symlink name dest)
|
|
add_llvm_tool_symlink(${name} ${dest} ALWAYS_GENERATE)
|
|
# Always generate install targets
|
|
- llvm_install_symlink(${name} ${dest} ALWAYS_GENERATE)
|
|
+ llvm_install_symlink(${name} ${dest} ${CMAKE_INSTALL_FULL_BINDIR} ALWAYS_GENERATE)
|
|
endmacro()
|
|
|
|
function(clang_target_link_libraries target type)
|
|
diff --git a/lib/Headers/CMakeLists.txt b/lib/Headers/CMakeLists.txt
|
|
index 078988980c52..14b58614b40a 100644
|
|
--- a/lib/Headers/CMakeLists.txt
|
|
+++ b/lib/Headers/CMakeLists.txt
|
|
@@ -234,7 +234,7 @@ set_target_properties(clang-resource-headers PROPERTIES
|
|
FOLDER "Misc"
|
|
RUNTIME_OUTPUT_DIRECTORY "${output_dir}")
|
|
|
|
-set(header_install_dir lib${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}/include)
|
|
+set(header_install_dir ${CMAKE_INSTALL_LIBDIR}${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}/include)
|
|
|
|
install(
|
|
FILES ${files} ${generated_files}
|
|
diff --git a/tools/libclang/CMakeLists.txt b/tools/libclang/CMakeLists.txt
|
|
index 4e0647971ab4..68dd67fcc476 100644
|
|
--- a/tools/libclang/CMakeLists.txt
|
|
+++ b/tools/libclang/CMakeLists.txt
|
|
@@ -216,7 +216,7 @@ foreach(PythonVersion ${CLANG_PYTHON_BINDINGS_VERSIONS})
|
|
COMPONENT
|
|
libclang-python-bindings
|
|
DESTINATION
|
|
- "lib${LLVM_LIBDIR_SUFFIX}/python${PythonVersion}/site-packages")
|
|
+ "${CMAKE_INSTALL_LIBDIR}${LLVM_LIBDIR_SUFFIX}/python${PythonVersion}/site-packages")
|
|
endforeach()
|
|
if(NOT LLVM_ENABLE_IDE)
|
|
add_custom_target(libclang-python-bindings)
|