[PATCH] D61456: [gn] Update the clangd test lit site configuration
Petr Hosek via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu May 2 12:25:53 PDT 2019
phosek updated this revision to Diff 197837.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61456/new/
https://reviews.llvm.org/D61456
Files:
llvm/utils/gn/secondary/clang-tools-extra/clangd/test/BUILD.gn
llvm/utils/gn/secondary/clang-tools-extra/clangd/test/clangd_lit_site_cfg_files.gni
llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn
Index: llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn
===================================================================
--- llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn
+++ llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn
@@ -1,4 +1,5 @@
import("//clang-tools-extra/test/clang_tools_extra_lit_site_cfg_files.gni")
+import("//clang-tools-extra/clangd/test/clangd_lit_site_cfg_files.gni")
import("//clang/test/clang_lit_site_cfg_files.gni")
import("//lld/test/lld_lit_site_cfg_files.gni")
import("//llvm/test/llvm_lit_site_cfg_files.gni")
@@ -42,6 +43,12 @@
config_map +=
"map_config('" + rebase_path("//clang-tools-extra/test/Unit/lit.cfg.py") +
"', '" + rebase_path(clang_tools_extra_lit_unit_site_cfg_file) + "')\n"
+ config_map +=
+ "map_config('" + rebase_path("//clang-tools-extra/clangd/test/lit.cfg.py") +
+ "', '" + rebase_path(clangd_lit_site_cfg_file) + "')\n"
+ config_map +=
+ "map_config('" + rebase_path("//clang-tools-extra/clang/unittests/lit.cfg.py") +
+ "', '" + rebase_path(clangd_lit_unit_site_cfg_file) + "')\n"
config_map += "map_config('" + rebase_path("//clang/test/lit.cfg.py") +
"', '" + rebase_path(clang_lit_site_cfg_file) + "')\n"
config_map += "map_config('" + rebase_path("//clang/test/Unit/lit.cfg.py") +
Index: llvm/utils/gn/secondary/clang-tools-extra/clangd/test/clangd_lit_site_cfg_files.gni
===================================================================
--- /dev/null
+++ llvm/utils/gn/secondary/clang-tools-extra/clangd/test/clangd_lit_site_cfg_files.gni
@@ -0,0 +1,4 @@
+clangd_lit_site_cfg_file =
+ "$root_gen_dir/clang-tools-extra/clangd/test/lit.site.cfg.py"
+clangd_lit_unit_site_cfg_file =
+ "$root_gen_dir/clang-tools-extra/clangd/unittests/lit.site.cfg.py"
Index: llvm/utils/gn/secondary/clang-tools-extra/clangd/test/BUILD.gn
===================================================================
--- llvm/utils/gn/secondary/clang-tools-extra/clangd/test/BUILD.gn
+++ llvm/utils/gn/secondary/clang-tools-extra/clangd/test/BUILD.gn
@@ -1,10 +1,7 @@
import("//clang-tools-extra/clangd/xpc/enable.gni")
import("//llvm/triples.gni")
import("//llvm/utils/gn/build/write_cmake_config.gni")
-
-clangd_lit_site_cfg_file = "$root_gen_dir/clang-tools-extra/clangd/test/lit.cfg"
-clangd_lit_unit_site_cfg_file =
- "$root_gen_dir/clang-tools-extra/clangd/unittests/lit.cfg"
+import("clangd_lit_site_cfg_files.gni")
template("write_lit_config") {
write_cmake_config(target_name) {
@@ -20,7 +17,7 @@
write_lit_config("lit_site_cfg") {
# Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER.
- input = "//clang-tools-extra/clangd/test/lit.cfg.in"
+ input = "//clang-tools-extra/clangd/test/lit.site.cfg.py.in"
output = clangd_lit_site_cfg_file
extra_values = [
@@ -46,12 +43,14 @@
write_lit_config("lit_unit_site_cfg") {
# Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER.
- input = "//clang-tools-extra/clangd/unittests/lit.cfg.in"
+ input = "//clang-tools-extra/clangd/unittests/lit.site.cfg.py.in"
output = clangd_lit_unit_site_cfg_file
extra_values =
[ "CMAKE_CURRENT_BINARY_DIR=" +
rebase_path(get_label_info("//clang-tools-extra/clangd/unittests",
- "target_out_dir")) ]
+ "target_out_dir")),
+ "CMAKE_CURRENT_SOURCE_DIR=" +
+ rebase_path("//clang-tools-extra/clangd/unittest")]
if (host_os == "win") {
# See comment for Windows solink in llvm/utils/gn/build/toolchain/BUILD.gn
extra_values += [ "SHLIBDIR=" + rebase_path("$root_out_dir/bin") ]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61456.197837.patch
Type: text/x-patch
Size: 3657 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190502/85fd5118/attachment-0001.bin>
More information about the cfe-commits
mailing list