llvmbot wrote:

<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang

Author: Stefan Gränitz (weliveindetail)

<details>
<summary>Changes</summary>

I cross-compile clang-repl with GCC-10 on Ubuntu 20.04 and get this error when 
linking with gold: PLT offset too large, try linking with --long-plt

---
Full diff: https://github.com/llvm/llvm-project/pull/78959.diff


1 Files Affected:

- (modified) clang/tools/clang-repl/CMakeLists.txt (+4) 


``````````diff
diff --git a/clang/tools/clang-repl/CMakeLists.txt 
b/clang/tools/clang-repl/CMakeLists.txt
index 2ccbe292fd49e09..8589e37418354e7 100644
--- a/clang/tools/clang-repl/CMakeLists.txt
+++ b/clang/tools/clang-repl/CMakeLists.txt
@@ -22,3 +22,7 @@ clang_target_link_libraries(clang-repl PRIVATE
 if(CLANG_PLUGIN_SUPPORT)
   export_executable_symbols_for_plugins(clang-repl)
 endif()
+
+if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "ARM")
+  target_link_options(clang-repl PRIVATE LINKER:--long-plt)
+endif()

``````````

</details>


https://github.com/llvm/llvm-project/pull/78959
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to