[PATCH] D136574: [clang] Copy cmake_policy() to silence CMake warnings in standalone builds
Michał Górny via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Oct 23 22:24:08 PDT 2022
mgorny created this revision.
mgorny added reviewers: nickdesaulniers, kastiglione, compnerd, MaskRay, thesamesam, tstellar.
Herald added a subscriber: StephenFan.
Herald added a project: All.
mgorny requested review of this revision.
https://reviews.llvm.org/D136574
Files:
clang/CMakeLists.txt
Index: clang/CMakeLists.txt
===================================================================
--- clang/CMakeLists.txt
+++ clang/CMakeLists.txt
@@ -3,6 +3,12 @@
# If we are not building as a part of LLVM, build Clang as an
# standalone project, using LLVM as an external library:
if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
+ if(POLICY CMP0114)
+ cmake_policy(SET CMP0114 OLD)
+ endif()
+ if(POLICY CMP0116)
+ cmake_policy(SET CMP0116 OLD)
+ endif()
project(Clang)
set(CLANG_BUILT_STANDALONE TRUE)
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D136574.470049.patch
Type: text/x-patch
Size: 539 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20221024/9d5d19ba/attachment.bin>
More information about the cfe-commits
mailing list