summaryrefslogtreecommitdiff
path: root/test/Makefile
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-11-08 09:07:51 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-11-08 09:07:51 +0000
commitfb4fb6ddb0f26ad0269a93f2edc8baa490984122 (patch)
tree4404be2e2052568eda43e0f3179844cbb5ce9570 /test/Makefile
parent16bc8783c9d5cf39a03afdada99bfde7948999f2 (diff)
downloadllvm-fb4fb6ddb0f26ad0269a93f2edc8baa490984122.tar.gz
llvm-fb4fb6ddb0f26ad0269a93f2edc8baa490984122.tar.bz2
llvm-fb4fb6ddb0f26ad0269a93f2edc8baa490984122.tar.xz
Switch to using 'lit.site.cfg.in' for the site config template for Unit tests,
and generate it for CMake builds as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86451 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Makefile')
-rw-r--r--test/Makefile18
1 files changed, 6 insertions, 12 deletions
diff --git a/test/Makefile b/test/Makefile
index ede1b44317..e3e66d53ef 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -202,15 +202,9 @@ lit.site.cfg: site.exp
Unit/lit.site.cfg: $(PROJ_OBJ_DIR)/Unit/.dir FORCE
@echo "Making LLVM unittest 'lit.site.cfg' file..."
- @echo "## Autogenerated by Makefile ##" > $@
- @echo "# Do not edit!" >> $@
- @echo >> $@
- @echo "# Preserve some key paths for use by main LLVM test suite config." >> $@
- @echo "config.llvm_obj_root = \"\"\"$(LLVM_OBJ_ROOT)\"\"\"" >> $@
- @echo >> $@
- @echo "# Remember the build mode." >> $@
- @echo "config.llvm_build_mode = \"\"\"$(BuildMode)\"\"\"" >> $@
- @echo >> $@
- @echo "# Let the main config do the real work." >> $@
- @echo "lit.load_config(config, \"\"\"$(LLVM_SRC_ROOT)/test/Unit/lit.cfg\"\"\")" >> $@
-
+ @sed -e "s#@LLVM_SOURCE_DIR@#$(LLVM_SRC_ROOT)#g" \
+ -e "s#@LLVM_BINARY_DIR@#$(LLVM_OBJ_ROOT)#g" \
+ -e "s#@LLVM_TOOLS_DIR@#$(ToolDir)#g" \
+ -e "s#@LLVMGCCDIR@#$(LLVMGCCDIR)#g" \
+ -e "s#@LLVM_BUILD_MODE@#$(BuildMode)#g" \
+ $(PROJ_SRC_DIR)/Unit/lit.site.cfg.in > $@