summaryrefslogtreecommitdiff
path: root/libc/lib
diff options
context:
space:
mode:
authorJoseph Huber <jhuber6@vols.utk.edu>2023-01-27 12:08:28 -0600
committerJoseph Huber <jhuber6@vols.utk.edu>2023-01-27 14:06:00 -0600
commit8583291dfc43f5769291d8e70d84125154e61341 (patch)
tree9a48a26378f096af023c63d93ff49066b90c8c08 /libc/lib
parent057a2c239e801810fc28d3e87fc4e9cf50be0fc5 (diff)
downloadllvm-8583291dfc43f5769291d8e70d84125154e61341.tar.gz
[libc] Do not install to the default triple in GPU mode
Currently this logic causes the `libcgpu.a` to be installed to the user's default triple. The GPU target isn't really true to this in a cross-compiling sense so we should just default to the regular `/lib` directory Reviewed By: sivachandra, lntue Differential Revision: https://reviews.llvm.org/D142774
Diffstat (limited to 'libc/lib')
-rw-r--r--libc/lib/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/lib/CMakeLists.txt b/libc/lib/CMakeLists.txt
index 86246b8b583d..c91097d5bc7a 100644
--- a/libc/lib/CMakeLists.txt
+++ b/libc/lib/CMakeLists.txt
@@ -11,7 +11,7 @@ set_target_properties(
if(LIBC_TARGET_TRIPLE)
set(LIBC_INSTALL_LIBRARY_DIR lib${LLVM_LIBDIR_SUFFIX}/${LIBC_TARGET_TRIPLE})
-elseif(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR)
+elseif(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR AND NOT LIBC_GPU_BUILD)
set(LIBC_INSTALL_LIBRARY_DIR
lib${LLVM_LIBDIR_SUFFIX}/${LLVM_DEFAULT_TARGET_TRIPLE})
else()