[gn] Support dots in CMake paths in the sync script
Some file paths use dots to pick up sources from parent directories.
Differential Revision: https://reviews.llvm.org/D60734
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@358774 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/utils/gn/build/sync_source_lists_from_cmake.py b/utils/gn/build/sync_source_lists_from_cmake.py
index 480b5aa..3fb155c 100755
--- a/utils/gn/build/sync_source_lists_from_cmake.py
+++ b/utils/gn/build/sync_source_lists_from_cmake.py
@@ -25,7 +25,7 @@
# Matches e.g. | "foo.cpp",|, captures |foo| in group 1.
gn_cpp_re = re.compile(r'^\s*"([^"]+\.(?:cpp|c|h|S))",$', re.MULTILINE)
# Matches e.g. | foo.cpp|, captures |foo| in group 1.
- cmake_cpp_re = re.compile(r'^\s*([A-Za-z_0-9/-]+\.(?:cpp|c|h|S))$',
+ cmake_cpp_re = re.compile(r'^\s*([A-Za-z_0-9./-]+\.(?:cpp|c|h|S))$',
re.MULTILINE)
for gn_file in gn_files:
diff --git a/utils/gn/secondary/clang/tools/libclang/BUILD.gn b/utils/gn/secondary/clang/tools/libclang/BUILD.gn
index 7417e59..59420c8 100644
--- a/utils/gn/secondary/clang/tools/libclang/BUILD.gn
+++ b/utils/gn/secondary/clang/tools/libclang/BUILD.gn
@@ -73,6 +73,7 @@
"CXType.h",
"Index_Internal.h",
"Indexing.cpp",
+ "../../include/clang-c/Index.h",
]
if (host_os == "mac") {
ldflags = [