Author: Owen Pan Date: 2024-10-24T18:36:58-07:00 New Revision: 78e7d9592d7c3b500ae2bae097d8cd7cd9369671
URL: https://github.com/llvm/llvm-project/commit/78e7d9592d7c3b500ae2bae097d8cd7cd9369671 DIFF: https://github.com/llvm/llvm-project/commit/78e7d9592d7c3b500ae2bae097d8cd7cd9369671.diff LOG: [clang-format][NFC] Use CLANG_SOURCE_DIR in CMakeLists Added: Modified: clang/lib/Format/CMakeLists.txt Removed: ################################################################################ diff --git a/clang/lib/Format/CMakeLists.txt b/clang/lib/Format/CMakeLists.txt index b787b11ac7b744..ff987cc608fb88 100644 --- a/clang/lib/Format/CMakeLists.txt +++ b/clang/lib/Format/CMakeLists.txt @@ -33,10 +33,10 @@ add_clang_library(clangFormat file(GLOB_RECURSE files *.cpp *.h - ../../include/clang/Format/*.h - ../../tools/clang-format/*.cpp - ../../unittests/Format/*.cpp - ../../unittests/Format/*.h + ${CLANG_SOURCE_DIR}/include/clang/Format/*.h + ${CLANG_SOURCE_DIR}/tools/clang-format/*.cpp + ${CLANG_SOURCE_DIR}/unittests/Format/*.cpp + ${CLANG_SOURCE_DIR}/unittests/Format/*.h ) set(check_format_depends) @@ -46,8 +46,8 @@ foreach (file IN LISTS files) COMMAND clang-format ${file} | diff -u ${file} - VERBATIM COMMENT "Checking format of ${file}..." - ) - list(APPEND check_format_depends "clang-format-check-format${i}") + ) + list(APPEND check_format_depends clang-format-check-format${i}) math(EXPR i ${i}+1) endforeach () _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits