Use add_llvm_install_targets for install-llvmlibc

Using the LLVM rules for install ensures that DESTDIR and other expected
variables for an LLVM install work correctly.

Tested:
Manually with DESTDIR=/tmp/testinstall/ ninja install-llvmlibc

Reviewed By: lntue

Differential Revision: https://reviews.llvm.org/D129041
This commit is contained in:
Jeff Bailey 2022-07-03 03:42:58 +00:00
parent c3839c0b46
commit bc70ba814d

View file

@ -16,9 +16,8 @@ install(
COMPONENT llvmlibc
)
add_custom_target(
install-llvmlibc
DEPENDS llvmlibc
COMMAND "${CMAKE_COMMAND}" -DCMAKE_INSTALL_COMPONENT=llvmlibc
-P "${LIBC_BINARY_DIR}/cmake_install.cmake"
add_llvm_install_targets(
install-llvmlibc
DEPENDS llvmlibc
COMPONENT llvmlibc
)