[libc-commits] [PATCH] D132212: [libc] Install startup files with the install-libc target.

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Fri Aug 19 13:15:50 PDT 2022


This revision was automatically updated to reflect the committed changes.
Closed by commit rG4d977663167e: [libc] Install startup files with the install-libc target. (authored by sivachandra).

Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132212

Files:
  libc/CMakeLists.txt
  libc/loader/linux/CMakeLists.txt


Index: libc/loader/linux/CMakeLists.txt
===================================================================
--- libc/loader/linux/CMakeLists.txt
+++ libc/loader/linux/CMakeLists.txt
@@ -83,3 +83,14 @@
   SRC
     crtn.cpp
 )
+
+add_custom_target(libc-startup)
+set(startup_components crt1 crti crtn)
+foreach(target IN LISTS startup_components)
+  set(fq_target_name libc.loader.linux.${target})
+  add_dependencies(libc-startup ${fq_target_name})
+  get_target_property(loader_object ${fq_target_name} LOADER_OBJECT)
+  install(FILES ${loader_object}
+          DESTINATION ${CMAKE_INSTALL_LIBDIR}
+          COMPONENT ${LIBC_COMPONENT})
+endforeach()
Index: libc/CMakeLists.txt
===================================================================
--- libc/CMakeLists.txt
+++ libc/CMakeLists.txt
@@ -148,7 +148,7 @@
 if(LLVM_LIBC_FULL_BUILD)
   set(LIBC_TARGET libc)
   set(LIBC_COMPONENT libc)
-  set(LIBC_INSTALL_DEPENDS "libc;libc-headers")
+  set(LIBC_INSTALL_DEPENDS "libc;libc-headers;libc-startup")
   set(LIBC_INSTALL_TARGET install-libc)
   set(LIBC_ARCHIVE_NAME c)
 else()


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D132212.454092.patch
Type: text/x-patch
Size: 1083 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20220819/39ce8820/attachment.bin>


More information about the libc-commits mailing list