[llvm] r368074 - Add order-dependencies to object libraries
Chris Bieneman via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 6 12:41:24 PDT 2019
Author: cbieneman
Date: Tue Aug 6 12:41:23 2019
New Revision: 368074
URL: http://llvm.org/viewvc/llvm-project?rev=368074&view=rev
Log:
Add order-dependencies to object libraries
Summary: If you are generating an object library that depends on table-gen generate sources, you need the object library to depend on the tablgen target. Currently llvm_add_library doesn't add dependencies for object libraries at all, which is clearly problematic.
Reviewers: compnerd, hintonda, smeenai
Reviewed By: smeenai
Subscribers: mgorny, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D65818
Modified:
llvm/trunk/cmake/modules/AddLLVM.cmake
Modified: llvm/trunk/cmake/modules/AddLLVM.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/AddLLVM.cmake?rev=368074&r1=368073&r2=368074&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/AddLLVM.cmake (original)
+++ llvm/trunk/cmake/modules/AddLLVM.cmake Tue Aug 6 12:41:23 2019
@@ -448,6 +448,9 @@ function(llvm_add_library name)
list(APPEND objlibs ${obj_name})
set_target_properties(${obj_name} PROPERTIES FOLDER "Object Libraries")
+ if(ARG_DEPENDS)
+ add_dependencies(${obj_name} ${ARG_DEPENDS})
+ endif()
endif()
if(ARG_SHARED AND ARG_STATIC)
More information about the llvm-commits
mailing list