From: Francesco Petrogalli Date: Mon, 23 Jan 2023 23:56:37 +0000 (+0100) Subject: [build] Fix stand-alone builds of clang. X-Git-Tag: upstream/17.0.6~19898 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5d02e38f56dfa6c46dd71658c185582af1ffb07b;p=platform%2Fupstream%2Fllvm.git [build] Fix stand-alone builds of clang. The target RISCVTargetParserTablegen needs to be visible for stand-alone [1] builds of clang to prevent configuration failures. [1] https://llvm.org/docs/GettingStarted.html#stand-alone-builds Reviewed By: tstellar Differential Revision: https://reviews.llvm.org/D142403 --- diff --git a/llvm/cmake/modules/LLVMConfig.cmake.in b/llvm/cmake/modules/LLVMConfig.cmake.in index f1362fa..85e8784 100644 --- a/llvm/cmake/modules/LLVMConfig.cmake.in +++ b/llvm/cmake/modules/LLVMConfig.cmake.in @@ -140,9 +140,9 @@ if(NOT TARGET LLVMSupport) @llvm_config_include_buildtree_only_exports@ endif() -# By creating intrinsics_gen, omp_gen and acc_gen here, subprojects that depend -# on LLVM's tablegen-generated headers can always depend on this target whether -# building in-tree with LLVM or not. +# By creating the following targets here, subprojects that depend on +# LLVM's tablegen-generated headers can always depend on this target +# whether building in-tree with LLVM or not. if(NOT TARGET intrinsics_gen) add_custom_target(intrinsics_gen) endif() @@ -152,6 +152,9 @@ endif() if(NOT TARGET acc_gen) add_custom_target(acc_gen) endif() +if(NOT TARGET RISCVTargetParserTablegen) + add_custom_target(RISCVTargetParserTableGen) +endif() set_property(GLOBAL PROPERTY LLVM_TARGETS_CONFIGURED On) include(${LLVM_CMAKE_DIR}/LLVM-Config.cmake)