[compiler-rt] Revert "CompilerRT: Normalize COMPILER_RT_DEFAULT_TARGET_TRIPLE" (PR #89150)

via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 17 15:10:42 PDT 2024


https://github.com/ZijunZhaoCCK created https://github.com/llvm/llvm-project/pull/89150

Reverts llvm/llvm-project#88835

Break the build:
```
  Host compiler does not support '-fuse-ld=lld'.  Please make sure that 'lld'
  is installed and that your host compiler can compile a simple program when
  given the option '-fuse-ld=lld'.
```

>From b207702dbbfa6a4ec65cf983080b13235bb854c0 Mon Sep 17 00:00:00 2001
From: ZijunZhaoCCK <zijunzhao at google.com>
Date: Wed, 17 Apr 2024 15:09:37 -0700
Subject: [PATCH] Revert "CompilerRT: Normalize
 COMPILER_RT_DEFAULT_TARGET_TRIPLE (#88835)"

This reverts commit 16f188761da1df6ba5e6627b8742aacfec8e9ec5.
---
 compiler-rt/cmake/Modules/CompilerRTUtils.cmake | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/compiler-rt/cmake/Modules/CompilerRTUtils.cmake b/compiler-rt/cmake/Modules/CompilerRTUtils.cmake
index 6d413f6753bc0c..e8e5f612d5b03c 100644
--- a/compiler-rt/cmake/Modules/CompilerRTUtils.cmake
+++ b/compiler-rt/cmake/Modules/CompilerRTUtils.cmake
@@ -368,12 +368,6 @@ macro(construct_compiler_rt_default_triple)
           "Default triple for which compiler-rt runtimes will be built.")
   endif()
 
-  if ("${CMAKE_C_COMPILER_ID}" MATCHES "Clang")
-    execute_process(COMMAND ${CMAKE_C_COMPILER} --target=${COMPILER_RT_DEFAULT_TARGET_TRIPLE} -print-effective-triple
-                    OUTPUT_VARIABLE COMPILER_RT_DEFAULT_TARGET_TRIPLE
-                    OUTPUT_STRIP_TRAILING_WHITESPACE)
-  endif()
-
   string(REPLACE "-" ";" LLVM_TARGET_TRIPLE_LIST ${COMPILER_RT_DEFAULT_TARGET_TRIPLE})
   list(GET LLVM_TARGET_TRIPLE_LIST 0 COMPILER_RT_DEFAULT_TARGET_ARCH)
 



More information about the llvm-commits mailing list