[libc-commits] [PATCH] D77256: [libc] Collect objects only from visible deps of an object library.

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed Apr 1 16:54:31 PDT 2020


sivachandra created this revision.
sivachandra added a reviewer: abrachet.
Herald added subscribers: libc-commits, tschuett, MaskRay, mgorny.
Herald added a project: libc-project.

A typo in an earlier change allowed this check to be missed.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D77256

Files:
  libc/cmake/modules/LLVMLibCRules.cmake


Index: libc/cmake/modules/LLVMLibCRules.cmake
===================================================================
--- libc/cmake/modules/LLVMLibCRules.cmake
+++ libc/cmake/modules/LLVMLibCRules.cmake
@@ -142,7 +142,12 @@
       ${target_name}
       ${ADD_OBJECT_DEPENDS}
     )
-    foreach(obj_target IN LISTS ADD_ENTRYPOINT_OBJ_SPECIAL_OBJECTS)
+    foreach(obj_target IN LISTS ADD_OBJECT_DEPENDS)
+      if(NOT TARGET ${obj_target})
+        # Not all targets will be visible. So, we will ignore those which aren't
+        # visible yet.
+        continue()
+      endif()
       get_target_property(obj_type ${obj_target} "TARGET_TYPE")
       if((NOT obj_type) OR (NOT (${obj_type} STREQUAL ${OBJECT_LIBRARY_TARGET_TYPE})))
         continue()


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D77256.254338.patch
Type: text/x-patch
Size: 751 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20200401/19f87694/attachment.bin>


More information about the libc-commits mailing list