[libc-commits] [PATCH] D149753: [libc] Don't use '-nolibc' on the GPU build

Joseph Huber via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed May 3 09:38:26 PDT 2023


This revision was automatically updated to reflect the committed changes.
Closed by commit rGfe710ffe9733: [libc] Don't use '-nolibc' on the GPU build (authored by jhuber6).

Changed prior to commit:
  https://reviews.llvm.org/D149753?vs=519083&id=519130#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D149753/new/

https://reviews.llvm.org/D149753

Files:
  libc/cmake/modules/LLVMLibCTestRules.cmake


Index: libc/cmake/modules/LLVMLibCTestRules.cmake
===================================================================
--- libc/cmake/modules/LLVMLibCTestRules.cmake
+++ libc/cmake/modules/LLVMLibCTestRules.cmake
@@ -658,7 +658,11 @@
   target_compile_options(${fq_build_target_name}
       PRIVATE ${LIBC_HERMETIC_TEST_COMPILE_OPTIONS} ${HERMETIC_TEST_COMPILE_OPTIONS})
 
-  target_link_options(${fq_build_target_name} PRIVATE -nolibc -nostartfiles -nostdlib++ -static)
+  if(LIBC_TARGET_ARCHITECTURE_IS_GPU)
+    target_link_options(${fq_build_target_name} PRIVATE -nostdlib -static)
+  else()
+    target_link_options(${fq_build_target_name} PRIVATE -nolibc -nostartfiles -nostdlib++ -static)
+  endif()
   target_link_libraries(
     ${fq_build_target_name}
     PRIVATE


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149753.519130.patch
Type: text/x-patch
Size: 774 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230503/50942a7e/attachment.bin>


More information about the libc-commits mailing list